ADI Service Function Reference Manual (6341-19): Alphabetical Function Reference
(Page 31 of 69 in this chapter) Version
adiReleaseCall
Description
- Performs one of the following actions:
- Abandons call placement.
- Acknowledges a network disconnect event.
Note: This function and all other ADI call control functions have been superseded by the NCC service. For more information, see the Natural Call Control Service Developer's Reference Manual.
Prototype
- DWORD adiReleaseCall ( CTAHD ctahd)
- ctahd CTA context handle returned by ctaCreateContext.
Return Values
Events
Details
- This function is primarily used to release a connected call or to acknowledge a network disconnection. It may also be used to abandon outbound call placement.
- Whenever the network disconnects a call, the ADI service sends an ADIEVN_CALL_DISCONNECTED event to the application and prevents it from issuing DSP-related functions. Any active DSP-related functions are terminated with the reason code set to CTA_REASON_RELEASED. The internal resources remain allocated to the call until the application acknowledges the network disconnect by invoking adiReleaseCall. The ADI service then resets the call control state to Idle (ADI_CC_STATE_IDLE) and generates an ADIEVN_CALL_RELEASED event. The application is then eligible to receive or place another call.
- The application can disconnect a call by invoking adiReleaseCall in the placing call state (ADI_CC_STATE_PLACING_CALL), in the connected state (ADI_CC_STATE_CONNECTED), or in the answering state (ADI_CC_STATE_ANSWERING_CALL). In any case, a call released event is generated after the network release procedure completes and the ADI service resets the call control state to Idle.
- ADIEVN_CALL_DISCONNECTED is not generated if release is initiated by the application.
- Some protocols allow you to use adiSetExtendedArgs to set additional arguments to adiReleaseCall.For more information about controlling calls under specific TCPs, refer to the AG CAS Installation and Developer's Manual.
Note: This function is not available when using the NOCC protocol.
See Also
- adiAnswerCall, adiPlaceCall
, adiRejectCall, adiSetExtendedArgs
Example
void myReleaseCall( CTAHD ctahd )
{
CTA_EVENT event;
adiReleaseCall( ctahd );
do
{
myGetEvent( &event ); /* see ctaWaitEvent example */
} while( event.id != ADIEVN_CALL_RELEASED );
/* Can now place another call and/or wait for an incoming call. */
}
(Page 31 of 69 in this chapter) Version
Want to send us feedback on our documentation? Email: Tech_Pubs@nmss.com
Copyright © 2000, Natural MicroSystems, Inc. All rights
reserved.