SMctlDtmf
Previous Topic  Next Topic 

Synopsis:

       SMctlDtmf(vox_chan,on_off[,AsDigit(=1),toneset,mode])


Arguments:

       vox_chan The voice channel

       on_off -  Set to 0 to turn off DTMF tone detection, or 1 to turn it on.

       AsDigit Set to 0 if there is no digit mapping or 1 (default) if the digits are to be mapped to digit codes.

       toneset ­­- The tone set ID to use (one of the internal Aculab tonesets)

       mode -  The tone detection mode.


Description:  This function controls how the specified vox_chan handles the detection of DTMF digits.      Detection of DTMF can be turned on or off by setting the on_off flag to 1 or 0 respectively.


The AsDigit argument defines whether the received DTMF will be converted to the corresponding DTMF character (E.g. #, *, 0 etc) or whether the tone ID within the tone set will be returned instead.     By default AsDigit is set to 1 which means convertion will take place.    Set this to 0 to receive the tone id instead.


Returns: 0 if successful or -1 if bad vox_chan was specified.