TAPI - Set TAPI values¶

tapiSetValue()

Set TAPI values


SYNTAX

tapiSetValue(DeviceID, Param1, Param2)

The DeviceID is an integer containing the number of the line device to be queried, counting from 1 up to the total number of devices. Where DeviceID is not relevant, any value can be supplied.

When the callback function receives a message with handle, it must pass this back to Sculptor using one of the following function calls, according to whether the call is a call handle or a line handle:

tapiSetValue(DeviceID, TAPI_VAR_CALL_HANDLE, Handle)

tapiSetValue(DeviceID, TAPI_VAR_LINE_HANDLE, Handle)

It is the application’s responsibility to determine the handle type from the message context. See the demo program $SCULPTOR/demo/tapi/tapi.f for examples.

Definitions of the values for use with TAPI can be found in the include file $SCULPTOR/include/tapi.h.


EXAMPLES

!function TapiCallBack(Handle, Msg, DevID, Param1, Param2, Param3) {
   switch (Msg) {
   case == LINE_CALLINFO:
       switch (Param1) {
       case == LINECALLINFOSTATE_CALLERID:                   /* The handle is a call handle */
           tapiSetValue(DevID, TAPI_VAR_CALL_HANDLE, Handle) /* Tell Sculptor this is the handle to use */
   ...                                                       /* Retrieve current print position */

   case == LINE_LINEDEVSTATE:
       switch (Param1) {
       case == LINEDEVSTATE_RINGING:                         /* The handle is a line handle */
           tapiSetValue(DevID, TAPI_VAR_LINE_HANDLE, Handle) /* Tell Sculptor this is the handle to use */

RELATED TOPICS

TAPI

Assisted telephony service functions

Basic telephony service functions