Previous PageTable Of Contents../index.htmlIndexNext Page

d42_setparm( )

Description | Cautions | Example | Errors | See Also

Name:

int d42_setparm(devh, parmnum, parmvalp)

Inputs:

int devh

  board or channel descriptor

 

int parmnum

  parameter name

 

void *parmvalp

  pointer to an application buffer containing the parameter value

Returns:

0
-1

  if success

Includes:

D42LIB.H

Mode:

synchronous

Top Of PageDescription

The d42_setparm( ) function sets a board or channel parameter. Depending on the parameter to be set, the value can be either a character string or an integer. The input board and channel parameter values for parmnum are listed in Table 2.

Parameter

Description

devh:

specifies the valid board device or channel device descriptor obtained by a call to dx_open( )

parmnum:

contains the parameter name to update

parmvalp:

application buffer containing the parameter value

NOTE:
Setting board parameters affects all the channels on the board, but setting channel parameters affects only the specified channel.

To set board parameters the following requirements must be met:

To set channel parameters the following requirements must be met:

This function returns a failure if:

Top Of PageCautions

When setting a parameter, the user passes a pointer to a variable containing the new parameter value. This variable should be treated as an unsigned integer for all parameters. The application should cast the parmvalp parameter to a (void *) to avoid compiler warnings.


Table 2. Board and Channel Parameters for d42_setparm( )

Board Parameters

Description

D4BD_CALLID

Enable Caller ID

Values: 0 - disable (default)

1 - enable

D4BD_REPORT_RESET

Enable report reset

Values: 0 - disable (default)

1 - enable

   

Channel Parameters

Description

D4CH_CHANNELSTATUS

Receive asynchronous channel

Values: 0 - disable (default)

1 - enable

Top Of PageExample

Top Of PageErrors

If this function returns -1 to indicate a failure, one of the following (most common) codes will be contained in dx_errno. For a complete list of error codes and definitions, refer to Appendix C.

ED42_BADDEVICE

Invalid or wrong device handle

ED42_UNSUPPORTED

Function not supported on this board

ED42_SYSTEM

System level error

ED42_INVALARG

Invalid argument passed to function

Top Of PageSee Also


Previous PageTable Of ContentsTop Of PageIndexNext Page

Click here to contact Dialogic Customer Engineering

Copyright 2001, Dialogic Corporation
All rights reserved
This page generated November, 2001