Voice API Programming Guide — June 2005 27
4
4.Event Handling
This chapter provides information on functions used to retrieve and handle events. Topics include:
•Overview of Event Handling. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
•Event Management Functions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.1 Overview of Event HandlingAn event indicates that a specific activity has occurred on a channel. The voice driver reports
channel activity to the application program in the form of events, which allows the program to
identify and respond to a specific occurrence on a channel. Events provide feedback on the
progress and completion of functions and indicate the occurrence of other channel activities. Voice
library events are defined in the dxxxlib.h header file.
For a list of events that may be returned by the voice software, see the Voice API Library Reference.
4.2 Event Management FunctionsEvent management functions are used to retrieve and handle events being sent to the application
from the firmware. These functions are contained in the Standard Runtime Library (SRL) and
defined in srllib.h. The SRL provides a set of common system functions that are device
independent and are applicable to all Intel® telecom devices. For more information on event
management and event handling, see the Standard Runtime Library API Programming Guide.
Event management functions include:
•sr_enbhdlr( )
•sr_dishdlr()
•sr_getevtdev()
•sr_getevttype()
•sr_getevtlen()
•sr_getevtdatap()
For details on SRL functions, see the Standard Runtime Library API Library Reference.
The event management functions retrieve and handle voice device termination events for functions
that run in asynchronous mode, such as dx_dial( ) and dx_play( ). For complete function reference
information, see the Voice API Library Reference.