[Freeswitch-users] Received DTMF not available
Sean Devoy
sdevoy at bizfocused.com
Wed May 14 19:31:30 MSD 2014
Hi Grant,
Check inside your JS script for a value. It is waiting for the hangup event to run so DTMFvalues should exist.
You <action application="log" ... may be running before the DTMF is received.
Sean
From: freeswitch-users-bounces at lists.freeswitch.org [mailto:freeswitch-users-bounces at lists.freeswitch.org] On Behalf Of Grant Bagdasarian
Sent: Wednesday, May 14, 2014 7:59 AM
To: FreeSWITCH Users Help (freeswitch-users at lists.freeswitch.org)
Subject: [Freeswitch-users] Received DTMF not available
Hello,
I'm originating calls from Freeswitch to remote destinations.
When the destination answers the call (wait_for_answer) I ask the destination for some digits.
<action application="play_and_get_digits" data="6 8 2 5000 # ${prompts_directory}/ask_and_collect.wav ${prompts_directory}/invalid.wav dtmfInput \d 2500"/>
<action application="set" data="api_hangup_hook=jsrun $${scripts_directory}/collect_data.js ${internal_reference} DTMFInput=${dtmfInput}"/>
<action application="log" data="INFO The caller entered the following code for verification: ${dtmfInput}" />
It happens quite often where the variable $[dtmfInput} doesn't have a value, even though I see the console output in Freeswitch receiving the DTMF events.
2014-05-14 13:29:26.316614 [DEBUG] switch_rtp.c:3901 RTP RECV DTMF 3:2880
2014-05-14 13:29:26.316614 [DEBUG] switch_channel.c:471 RECV DTMF 3:2880
2014-05-14 13:29:26.956611 [DEBUG] switch_rtp.c:3901 RTP RECV DTMF 1:2880
2014-05-14 13:29:26.956611 [DEBUG] switch_channel.c:471 RECV DTMF 1:2880
I'm using RFC2833 mode.
Any ideas why this happens?
Regards,
Grant
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20140514/9d07b670/attachment.html
Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users
mailing list