Previous PageTable Of Contents../index.htmlIndexNext Page

dcb_setdigitmsk( )

Description | Cautions | Example | Errors | See Also

Name:

int dcb_setdigitmsk(devh,confid,bitmask,action)

Inputs:

int devh

  DCB/SC DSP device handle

 

int confid

  conference identifier

 

unsigned int bitmask

  event bitmask

 

unsigned int action

  change type

Returns:

0 on success
-1 on failure

Includes:

srllib.h
dtilib.h
msilib.h
dcblib.h

Category:

Configuration

Mode:

synchronous

Top Of PageDescription

The dcb_setdigitmsk( ) function enables specific digit detection for a conference. This current bitmask is examined by a call to dcb_getdigitmsk( ).

Parameter

Description

devh:

The DCB/SC DSP device handle.

confid:

The conference identifier.

bitmask:

The digit bitmask.

action:

Specifies how the digit mask is changed. Possible values are:

  • CBA_SETMSK - enables notification of events specified in bitmask and disables notification of previously set events.
  • CBA_ADDMSK - enables messages from the conference specified in bitmask, in addition to previously set events.
  • CBA_SUBMSK - disables messages from the conference specified in bitmask.

NOTE:
If MSG_VOLDIG is enabled to give transparent volume control to the conferees, the digits for volume increase, decrease, and reset will not cause digit events to be generated. As a result, the application will not know if the volume changes.

The bitmask determines the digits to be detected. Upon detection of a digit, a DCBEV_DIGIT event is generated on a DCB/SC DSP handle. The sr_getevtdatap( ) function can be used to retrieve the following structure:

The possible values for bitmask are:

CBMM_ZERO Detect digit 0

CBMM_ONE Detect digit 1

CBMM_TWO Detect digit 2

CBMM_THREE Detect digit 3

CBMM_FOUR Detect digit 4

CBMM_FIVE Detect digit 5

CBMM_SIX Detect digit 6

CBMM_SEVEN Detect digit 7

CBMM_EIGHT Detect digit 8

CBMM_NINE Detect digit 9

CBMM_STAR Detect digit *

CBMM_POUND Detect digit #

CBMM_A Detect digit A

CBMM_B Detect digit B

CBMM_C Detect digit C

CBMM_D Detect digit D

CBMM_ALL Detect ALL digits

For example, to enable notification of the digits specified in the bitmask parameter and disable notification of previously set digits:

To enable an additional digit specified in bitmask without disabling the currently enabled digits:

To disable digits in bitmask without disabling any other digits:

To disable all currently enabled digits:

To enable an event handler for a specified event, follow these steps:

  1. Call sr_enbhdlr( ). This function specifies the event and the application defined event handler that is called from a signal handler.
  2. Call dcb_setdigitmsk( ). This function sets the digit message mask.
NOTE:
The request for an event to be posted to an event handler must be specified using both the sr_enbhdlr( ) and dcb_setdigitmsk( ) functions.

Top Of PageCautions

This function fails when:

Top Of PageExample

Top Of PageErrors

If the function does not complete successfully, it will return -1 to indicate an error. Use the Standard Attribute functions ATDV_LASTERR( ) to obtain the applicable error value, or ATDV_ERRMSGP( ) to obtain a more descriptive error message.

Refer to the error type tables found in Chapter 2 of this guide. Error defines can be found in dtilib.h, msilib.h or dcblib.h.

Top Of PageSee Also


Previous PageTable Of ContentsTop Of PageIndexNext Page

Click here to contact Dialogic Customer Engineering

Copyright 2000, Dialogic Corporation
All rights reserved
This page generated January, 2002