Previous PageTable Of Contents../index.htmlIndexNext Page

cc_AnswerCall( )

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

Name:

int cc_AnswerCall(crn, rings, mode)

Inputs:

CRN crn

  call reference number

 

int rings

  number of rings before return

 

unsigned long mode

  synchronous or asynchronous

Returns:

0 on success
< 0 on failure

Includes:

cclib.h

Category

Call control

Mode:

synchronous or asynchronous

Technology:

BRI/2; BRI/SC; PRI (all protocols)

Top Of PageDescription

The cc_AnswerCall( ) function accepts a connection request from the remote end and connects the call. This function is equivalent to a conventional "offhook" command in answering an incoming call. The cc_AnswerCall( ) function is used any time after:

In asynchronous mode, the CCEV_ANSWERED event indicates successful completion of the cc_AnswerCall( ) function. After the successful completion of the function call, the call state changes from Offered or Accepted, if cc_AcceptCall( ) was used, to Connected.

Parameter

Description

crn:

The call reference number. Each call needs a CRN.

rings:

Specifies how long the protocol handler will wait before returning to the calling entity. In ISDN systems, rings must be set to zero or an error will be returned.

Mode:

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

Top Of PageTermination Events

Top Of PageCautions

This function is called only after an inbound call has been detected.

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_AnswerCall( ) function include the following:

Error Code

Description

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