ioctl(ixj1, IXJCTL_FILTER_CADENCE, pCadence)
Return Value
Returns 0 on success. Can return ENOMEM if there is insufficient memory to install the filter cadence or EFAULT if there is a problem with the pointer.
Parameters
A pointer to an IXJ_FILTER_CADENCE structure.
typedef struct { char enable; char en_filter; unsigned int filter; unsigned int on1; unsigned int off1; unsigned int on2; unsigned int off2; unsigned int on3; unsigned int off3; } IXJ_FILTER_CADENCE;
Remarks
The enable element should be set to 1 to enable the cadence, 0 to disable it. The en_filter element determines if the associated filter will also trigger while it is being used in a cadence. The on elements are time values that the associated filter must be in a detect state. The off elements are time values that the associated filter must be in a no detect state. All times are in 10ms units. The cadences will set the fc0, fc1, fc2, and fc3 bits in the exception structure when they trigger, they will also generate a SIGIO if the application has registered for asynchronous notifications.
See Also:
IXJCTL_SET_FILTER, IXJCTL_FILTER_CADENCE, PHONE_EXCEPTION
Example:
This example code will cause the exception bit fc0 to be set when the frequency specified on filter 0 has been present for 2 seconds. The exception bit f0 will not be set.
IXJ_FILTER_CADENCE pCadence; pCadence.enable = 1; pCadence.en_filter = 0; pCadence.filter = 0; pCadence.on1 = 200; pCadence.off1 = 0; pCadence.on2 = 0; pCadence.off2 = 0; pCadence.on3 = 0; pCadence.off3 = 0; ioctl(ixj1, IXJCTL_FILTER_CADENCE &pCadence);
©1996-2001 Quicknet Technologies, Inc.