<div dir="ltr">Part of dialplan<div>
<p class=""><span class=""> <extension name="early_media_dtmf"><br></span> <condition><br> <action application="pre_answer"/><br> <action application="play_and_get_digits" data="2 5 1 7000 # /usr/share/freeswitch/sounds/en/us/callie/conference/8000/conf-pin.wav '' foobar \d+"/><br> <action application="log" data="INFO captured digits ${foobar}"/><br> </condition><br> </extension></p></div><div><br></div><div>FS output</div><div>
<p class=""><span class="">2016-01-31 00:20:24.399711 [DEBUG] switch_rtp.c:6865 RTP RECV DTMF 1:1600<br></span>2016-01-31 00:20:24.399711 [INFO] switch_channel.c:502 RECV DTMF 1:1600<br>2016-01-31 00:20:24.819718 [DEBUG] switch_rtp.c:6865 RTP RECV DTMF 2:1600<br>2016-01-31 00:20:24.819718 [INFO] switch_channel.c:502 RECV DTMF 2:1600<br>2016-01-31 00:20:25.159703 [DEBUG] switch_rtp.c:6865 RTP RECV DTMF 3:1600<br>2016-01-31 00:20:25.159703 [INFO] switch_channel.c:502 RECV DTMF 3:1600<br>2016-01-31 00:20:25.539688 [DEBUG] switch_rtp.c:6865 RTP RECV DTMF 4:1600<br>2016-01-31 00:20:25.539688 [INFO] switch_channel.c:502 RECV DTMF 4:1600<br>2016-01-31 00:20:25.819704 [DEBUG] switch_rtp.c:6865 RTP RECV DTMF 5:1600<br>2016-01-31 00:20:25.819704 [INFO] switch_channel.c:502 RECV DTMF 5:1600<br>EXECUTE sofia/internal/<a href="mailto:1001@91.103.196.13">1001@91.103.196.13</a> log(INFO captured digits 12345)<br>2016-01-31 00:20:25.819704 [INFO] mod_dptools.c:1692 captured digits 12345</p><p class=""><span class=""><br></span></p><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jan 31, 2016 at 12:06 AM, Bote Man <span dir="ltr"><<a href="mailto:bote_radio@botecomm.com" target="_blank">bote_radio@botecomm.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="EN-US" link="blue" vlink="purple"><div><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Some (many) carriers only allow one-way audio from the switch to the caller so that you don’t get free phone calls. Early media is the part of the call that is not billed. If they allow the caller to send audio to the switch during this free period it would open them up to fraud.<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Bote<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><div style="border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt"><div><div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in"><p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Dmitriy Borisov<br><b>Sent:</b> Saturday, 30 January, 2016 15:19<br><b>Subject:</b> [Freeswitch-users] DTMF capture and early media<u></u><u></u></span></p></div></div><div><div class="h5"><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal" style="margin-bottom:12.0pt">Hi, All!<u></u><u></u></p><pre><span style="color:black"><a href="https://tools.ietf.org/html/rfc3960" target="_blank">https://tools.ietf.org/html/rfc3960</a> has next part:<br></span>Early media refers to media (e.g., audio and video) that is exchanged<u></u><u></u></pre><pre> before a particular session is accepted by the called user. Within a<u></u><u></u></pre><pre> dialog, early media occurs from the moment the initial INVITE is sent<u></u><u></u></pre><pre> until the User Agent Server (UAS) generates a final response. It may<u></u><u></u></pre><pre> be unidirectional or <span style="background:yellow">bidirectional</span>, and can be generated by the<u></u><u></u></pre><pre> caller, the callee, or both. <span style="font-family:"Arial","sans-serif"">Typical examples of early media</span> generated by <br> the callee are ringing tone and announcements (e.g.,<u></u><u></u></pre><pre> queuing status). Early media generated by the caller typically<u></u><u></u></pre><pre> consists of voice commands or <span style="background:yellow">dual tone multi-frequency (DTMF) tones<u></u><u></u></span></pre><pre style="margin-bottom:12.0pt"><span style="background:yellow"> to drive interactive voice response (IVR) systems.</span><u></u><u></u></pre><pre><span style="background:white">But I know that in FreeSWITCH in preanswer state I can`t capture DTMF. Why? <br>This part of RFC is conflicting with some other standard? It can be very intresting feature.</span><u></u><u></u></pre><p class="MsoNormal"><br clear="all"><u></u><u></u></p><div><div><div><div><div><div><div><div><div><div><div><p class="MsoNormal">--<u></u><u></u></p></div><div><p class="MsoNormal">С уважением,<u></u><u></u></p></div><div><p class="MsoNormal">Борисов Дмитрий<u></u><u></u></p></div><div><p class="MsoNormal">Отдел облачных технологий 1С-Рарус<u></u><u></u></p></div><div><p class="MsoNormal">Тел. +7 (495) 231-20-02 доб.: 15-94<u></u><u></u></p></div><div><p class="MsoNormal">--<u></u><u></u></p></div><div><p class="MsoNormal">with best regards,<u></u><u></u></p></div><div><p class="MsoNormal">Dmitriy Borisov<u></u><u></u></p></div><div><p class="MsoNormal">1C-Rarus Cloud Services<u></u><u></u></p></div><div><p class="MsoNormal">tel.: <span style="font-size:9.5pt">+7 (495) 231-20-02 add.: 15-94</span><u></u><u></u></p></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div><br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br></blockquote></div><br></div>