DMC TSC-34/RU Specifikace Strana 49

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 179
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 48
System Software Diagnostics Guide — September 2006 49
Tracing CAS Signaling Using Global Call
LINEDEV bdev; /* board level device number */
int rc; /* Return code */
int value; /* value to be for specified parameter */
GC_INFO gc_error_info; /* GlobalCall error information data */
char devname[30]; /* Board/Trunk device name */
main()
{
/* Open a trunk device */
sprintf(dename, ":N_dtiB1:P_pdk_ar_r2_io");
if(gc_OpenEx(&bdev, devname, EV_SYNC, &ldev) != GC_SUCCESS)
{
/* Process the error as decided earlier */
gc_ErrorInfo( &gc_error_info );
printf ("Error: gc_OpenEx() on devname: %s, GC ErrorValue: 0x%hx - %s,
CCLibID: %i - %s, CC ErrorValue: 0x%lx - %s\n",
devname, gc_error_info.gcValue, gc_error_info.gcMsg,
gc_error_info.ccLibId, gc_error_info.ccLibName,
gc_error_info.ccValue, gc_error_info.ccMsg);
return (gc_error_info.gcValue);
}
rc = gc_StartTrace(bdev, NULL);
if (rc != GC_SUCCESS)
{
/* Process the error */
gc_ErrorInfo( &gc_error_info );
printf ("Error: gc_StartTrace() on devname: %s, GC ErrorValue: 0x%hx - %s,
CCLibID: %i - %s, CC ErrorValue: 0x%lx - %s\n",
devname, gc_error_info.gcValue, gc_error_info.gcMsg,
gc_error_info.ccLibId, gc_error_info.ccLibName,
gc_error_info.ccValue, gc_error_info.ccMsg);
return (gc_error_info.gcValue);
}
else
{
/* continue */
}
}
8.4 Disabling Tracing Using gc_StopTrace( )
The gc_StopTrace( ) function stops the logging of debug information for a specific line device that
was started using gc_StartTrace( ).
To use this feature, the line device must be the handle for a trunk or virtual board. After the
gc_StopTrace( ) function returns success, the application may be notified of the availability of the
last remaining trace data via GCEV_TRACEDATA.
Sample application code
Note: The following sample code was written for an application running on a system in which an Intel
NetStructure DMT160TEC board was used as the network interface, an Intel NetStructure
DMV2400A board was used as a play/record resource board, and the boards were connected via a
CT Bus.
Zobrazit stránku 48
1 2 ... 44 45 46 47 48 49 50 51 52 53 54 ... 178 179

Komentáře k této Příručce

Žádné komentáře