Previous PageTable Of ContentsHomeIndexNext Page


6.2.  Debugging Applications that Use ANAPI Protocols

The anapi.cfg file contains a number of parameters that are useful for debugging. Table 20 describes the debug-related parameters. Unless otherwise instructed, these parameters should retain their original settings.

When logging is enabled, the log file generated is anapi.log.<pid>, where pid = the process identification number.

For Linux applications, the log file is generated by compiling the ancountry.c file with the symbol DEBUG defined and then setting the parameters $11 and $12 in the anapi.cfg file as indicated in Table 20. To write additional information directly to the ANAPI log file, use the anapirs_log_printf( ) function. This function works like the fprintf( ) function except that a file descriptor is not used.

For Windows applications, the log file is generated by setting parameters $11 and $12 in the anapi.cfg file as indicated in Table 20.


Table 20.  anapi.cfg File Parameters

Parameter

Description

$11

Logging utility enabled (1=YES, 0=NO): 1

  · Set to 1 to enable logging, either to the screen (set $13 parameter to 1) or to the anapi.log file to track all the events that occur at the device selected for monitoring (parameter $12).

  · Set to 0 to ignore parameters $12, $13, and $15.

$12

Device handle of channel to monitor (-1=none, 0=All): 0

  · A value of -1 means do not monitor any device.

  · A value of 0 means monitor all opened devices.

$13

Echo on screen (1=YES, 0=NO): 1

  · Set to 1 to send the debug information to the screen.

  · Set to 0 to ignore parameter.

$15

Size of debug memory (1=1 event or action in memory): 1

The debug memory saves passed actions or events to a buffer. The built-in debug function does not use this feature. Change this parameter only if you implement your own debug function and you need a larger circular buffer than 1 event or action.

  · Set to 0 to ignore feature.

  · Set to 1 to store one action or event in the buffer.

Any unspecified parameter defaults to 0. If parameters $13 and $15 are set to 0, then they are ignored.


Previous PageTable Of ContentsTop Of PageIndexNext Page

Click here to contact Telecom Support Resources

Copyright 2003, Intel Corporation
All rights reserved
This page generated February, 2003