
Description | Cautions | Example | Errors
Name: |
char * ATDX_BDNAMEP(chdev) | |
Inputs: |
int chdev |
|
Returns: |
pointer to Board device name string if successful | |
Includes: |
srllib.h | |
Category: |
Extended Attribute | |
The ATDX_BDNAMEP( ) function returns a pointer to the board device name on which the channel accessed by chdev resides.
As illustrated in the example, this may be used to open the board device that corresponds to a particular channel device prior to setting board parameters.
The function parameter is defined as follows:
Parameter |
Description |
chdev |
specifies the valid channel device handle obtained when the channel was opened using dx_open( ). |
None.
#include <stdio.h>
#include <srllib.h>
#include <dxxxlib.h>
#include <windows.h>
main()
{
int chdev, bddev;
char *bdnamep;
.
.
/* Open the channel device */
if ((chdev = dx_open("dxxxB1C1", NULL)) == -1) {
/* Process error */
}
/* Display board name */
bdnamep = ATDX_BDNAMEP(chdev);
printf("The board device is: %s\n", bdnamep);
/* Open the board device */
if ((bddev = dx_open(bdnamep, NULL)) == -1) {
/* Process error */
}
.
.
}
This function will fail and return a pointer to "Unknown device" if an invalid channel device handle is specified in chdev.
Click here to contact Dialogic Customer Engineering
Copyright 2002, Dialogic Corporation