
Description | Cautions | Example | Errors
Name: |
int dx_setdigbuf(chdev,mode) | |
Inputs: |
int chdev |
|
int mode |
| |
Returns: |
0 if successful | |
-1 if failure | ||
Includes: |
srllib.h | |
dxxxlib.h | ||
Category: |
I/O | |
Mode: |
synchronous | |
The dx_setdigbuf( ) function sets the digit buffering mode that will be used by the Voice Driver. Once the digit buffer is full (31 digits), the application may select whether subsequent digits will be ignored or will overwrite the oldest digits in the queue.
The function parameters are defined as follows:
Parameter |
Description | |
chdev |
specifies the valid Dialogic channel device handle obtained by a call to dx_open( ). | |
mode |
specifies the type of digit buffering that will be used. Mode can be: | |
|
Incoming digits will be ignored if the digit buffer is full (default). | |
|
Incoming digits will overwrite the oldest digits in the buffer if the buffer is full. | |
When you call dx_setdigbuf( ), the function clears the previously detected digits in the digit buffer.
#include <srllib.h>
#include <dxxxlib.h>
#include <windows.h>
int chfd;
int init_digbuf()
{
/* open the device using dx_open, chfd has the device handle */
/*
* Set up digit buffering to be Cyclic. When digit
* queue overflows oldest digit will be overwritten
*/
if (dx_setdigbuf(chfd, DX_DIGCYCLIC) == -1) {
printf("Error during setdigbuf %s\n", ATDV_ERRMGSP(chfd));
return(1);
}
return(0);
}
If this function returns -1 to indicate failure, use ATDV_LASTERR( ) and ATDV_ERRMSGP( ) to retrieve one of the following error reasons:
|
EDX_BADPARM |
|
EDX_SYSTEM |
|
EDX_TIMEOUT |
|
Click here to contact Dialogic Customer Engineering
Copyright 2002, Dialogic Corporation