Previous PageTable Of Contents../index.htmlIndexNext Page

cc_ReqANI( )

Description | Termination Events | Cautions | Example | Errors | See Also

Name:

int cc_ReqANI(crn, ani_buf, reqtype, mode)

Inputs:

CRN crn

  call reference number

 

char *ani_buf

  pointer to address of ANI buffer

 

int reqtype

  type of information requested

 

unsigned long mode

  synchronous or asynchronous

Returns:

0 on success
< 0 on failure

Includes:

cclib.h

Category:

Optional call handling

Mode:

synchronous or asynchronous

Technology:

PRI (4ESS only)

Top Of PageDescription

The cc_ReqANI( ) function returns the caller ID for Automatic Number Identification (ANI)-on-demand services. The caller ID is usually included in the ISDN setup message. However, if the caller ID does not exist and the serving network is AT&T, the driver will automatically request the caller ID from the network if the ANI-on-demand feature is enabled. The information is returned in a NULL terminated ASCII string.

Parameter

Description

crn:

The call reference number. Each call needs a CRN.

ani_buf:

The address of the buffer where ANI information is stored.

reqtype:

The type of information requested. Possible values are:

  ISDN_CPN_PREF - calling party number preferred

  ISDN_BN_PREF - billing number preferred

  ISDN_CPN - calling party number only

  ISDN_BN - billing number only

  ISDN_CA_TSC - special uses

mode:

Specifies asynchronous (EV_ASYNC) or synchronous (EV_SYNC) mode.

The cc_ReqANI( ) function can operate as either a multitasking or non-multitasking function. It is a multitasking function when the caller number is offered upon request and the network provides this type of service (such as AT&T's ANI-on-demand service). cc_ReqANI( ) is a non-multitasking function when the calling party number is received or when the network does not offer an ANI-on-demand service. Thus, if ANI is already available, the function returns immediately because it does not have to instruct the interface device to query the switch.

In EV_ASYNC mode, the function will always return an event. In EV_SYNC mode, the function will return automatically with the ANI if one is available. Otherwise, the function will wait for completion of the ANI-on-demand request.

NOTE:
If ANI is always available, use the cc_GetANI( ) function, instead of the cc_ReqANI( ) function, for a faster return.

Top Of PageTermination Events

Top Of PageCautions

Top Of PageExample

Top Of PageErrors

If the function returns < 0 to indicate failure, use the cc_CauseValue( ) function to retrieve the reason code for the failure. The cc_ResultMsg( ) function can be used to interpret the reason code. Error codes are defined in the files ccerr.h, isdnerr.h, and isdncmd.h.

Error codes from the cc_ReqANI( ) function include the following:

Error Code

Description

ERR_ISDN_LIB | E_ISBADPAR

Bad input parameter

ERR_ISDN_LIB | E_ISNULLPTR

Null pointer error

ERR_ISDN_LIB | E_ISBADIF

Bad interface number

ERR_ISDN_LIB | E_ISBADCALLID

Bad call identifier

ERR_ISDN_LIB | E_ISBADTS

Bad time slot

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 December, 2001