[svn-commits] jdixon: branch jdixon/chan_usbradio-1.4 r134222 - /team/jdixon/chan_usbradio-...
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Mon Jul 28 18:19:35 CDT 2008
Author: jdixon
Date: Mon Jul 28 18:19:35 2008
New Revision: 134222
URL: http://svn.digium.com/view/asterisk?view=rev&rev=134222
Log:
Added dtmf disable option
Modified:
team/jdixon/chan_usbradio-1.4/channels/chan_zap.c
Modified: team/jdixon/chan_usbradio-1.4/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/team/jdixon/chan_usbradio-1.4/channels/chan_zap.c?view=diff&rev=134222&r1=134221&r2=134222
==============================================================================
--- team/jdixon/chan_usbradio-1.4/channels/chan_zap.c (original)
+++ team/jdixon/chan_usbradio-1.4/channels/chan_zap.c Mon Jul 28 18:19:35 2008
@@ -2819,6 +2819,9 @@
return res;
}
+static void disable_dtmf_detect(struct zt_pvt *p);
+static void enable_dtmf_detect(struct zt_pvt *p);
+
static int zt_setoption(struct ast_channel *chan, int option, void *data, int datalen)
{
char *cp;
@@ -2864,14 +2867,21 @@
case 1:
ast_log(LOG_DEBUG, "Set option TONE VERIFY, mode: MUTECONF(1) on %s\n",chan->name);
ast_dsp_digitmode(p->dsp,DSP_DIGITMODE_MUTECONF | p->dtmfrelax); /* set mute mode if desired */
+ enable_dtmf_detect(p);
break;
case 2:
ast_log(LOG_DEBUG, "Set option TONE VERIFY, mode: MUTECONF/MAX(2) on %s\n",chan->name);
ast_dsp_digitmode(p->dsp,DSP_DIGITMODE_MUTECONF | DSP_DIGITMODE_MUTEMAX | p->dtmfrelax); /* set mute mode if desired */
+ enable_dtmf_detect(p);
+ break;
+ case 3:
+ ast_log(LOG_DEBUG, "Set option TONE VERIFY, mode: DISABLE DTMF(3) on %s\n",chan->name);
+ disable_dtmf_detect(p);
break;
default:
ast_log(LOG_DEBUG, "Set option TONE VERIFY, mode: OFF(0) on %s\n",chan->name);
ast_dsp_digitmode(p->dsp,DSP_DIGITMODE_DTMF | p->dtmfrelax); /* set mute mode if desired */
+ enable_dtmf_detect(p);
break;
}
break;
More information about the svn-commits
mailing list