<div dir="ltr"><div><div>Are you really setting the same digit and same realm twice in your dialplan? It would seem to me that that would not work. I suspect you would want to set BDA once on each call leg so that they could both have it working.<br>
<br></div>To the other person asking about BDA vs. DBA: BDA stands for bind_digit_application, which is a dialplan app.<br><br></div>-MC<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jun 3, 2013 at 4:35 AM, julien terrasson <span dir="ltr">&lt;<a href="mailto:julien.terrasson@gmail.com" target="_blank">julien.terrasson@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><br></div><br>Hi Michael,<br><br>This is what i&#39;m trying to do :<br><br></div><div>Scenario 1 : When <u>calling party</u> press the &quot;*&quot; key, i want the <u>called party</u> to execute &quot;debug_bda&quot; extension.<br>

Scenario 2 : When <u>called party</u> press the &quot;*&quot; key, i want the <u>calling party</u> to execute &quot;debug_bda&quot; extension.<br><br></div><div><div><div>debug_bda is simply displaying the uuid so i can check from the logs which peer/party is executing the extension.<br>

<br></div><div>I&#39;m using bind_digit_action to do that :<div class="im"><br><br>&lt;action application=&quot;bind_digit_action&quot; data=&quot;my_context,*,<span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,0)">exec:execute_extension,<b>debug_bda</b></span>,<span style="color:rgb(0,255,0)">self</span>,peer</span>&quot;/&gt;<br>

<div>

&lt;action application=&quot;bind_digit_action&quot; data=&quot;my_context,*,<span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,0)">exec:execute_extension,<b>debug_bd</b>a</span>,peer,<span style="color:rgb(0,255,0)">self</span></span>&quot;/&gt;<br>



</div><br></div>Scenario 1 is working as i was expecting.<br>But in scenario 2, i can only get the <u>called party</u> to execute the extension (debug infos are hereunder)..<br></div><div>I would like to understand why it doesn&#39;t work as expected..  <br>

</div><div><br><div>NB : There was a copy/paste issue in my first previous which i
 corrected (instead of debug_bda i copied/paste toggle_recording extension). <br></div><div><br></div>Regards,<br><br></div><div>Julien<br></div><div><br>*************************************************************************************************************************************************************************************<div dir="ltr">

<div>Maybe I&#39;m the one 
missing something, but I didn&#39;t see a question. Can you clarify what it 
is you are trying to do with bda and what information you seek?<br><br></div>-MC<br></div>
<br>*************************************************************************************************************************************************************************************<div class="im"><br><br>On Sun, Jun 2, 2013 at 2:06 PM, julien terrasson <span dir="ltr">&lt;<a href="mailto:julien.terrasson@gmail.com" target="_blank">julien.terrasson@gmail.com</a>&gt;</span> wrote:<br>


</div><div dir="ltr"><div class="im"><div><div><br></div>Hi,<br><br></div><div>Either there is something wrong in the way bind_digit_action works, either i&#39;m missing something..<br></div><div>Would be gratefull is somebody can have a look at the issue hereunder. <br>



</div><div><br></div><div>0/ Version :<br><br>FreeSWITCH Version 1.5.2b+git~20130527T075833Z~f3541e00f4 (git f3541e0 2013-05-27 07:58:33Z)<br><br></div>1/ This is what i defined in the default.xml dialplan<br></div><div>
<div class="im"><div><br>


 &lt;action application=&quot;bind_digit_action&quot; data=&quot;my_context,*,<span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,0)">exec:execute_extension,<b>debug_bda</b></span>,<span style="color:rgb(0,255,0)">self</span>,peer</span>&quot;/&gt;<br>



 &lt;action application=&quot;bind_digit_action&quot; data=&quot;my_context,*,<span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,0)">exec:execute_extension,<b>debug_bd</b>a</span>,peer,<span style="color:rgb(0,255,0)">self</span></span>&quot;/&gt;<br>



<br></div><div>Where debug_dba simply display the uuid of the session that is calling the extension :<br></div></div><div><br>    &lt;extension name=&quot;<b>debug_bda</b>&quot;&gt;<br>        &lt;condition field=&quot;destination_number&quot; expression=&quot;^debug_bda&quot;&gt;<br>

            &lt;action application=&quot;log&quot; data=&quot;INFO debug_bind_digit_action is called from uuid : ${uuid} !&quot;/&gt;<div><div class="h5"><br>        &lt;/condition&gt;<br>    &lt;/extension&gt; <br><br>2/ After placing, bridging &amp; answering the call, i get the following uuids :<br>



</div></div></div></div><div><div class="h5"><div><br></div><div>caller uuid = 077a67ec-cbc5-11e2-b73b-85c636846b34<br></div><div>called uuid = 07803d02-cbc5-11e2-b750-85c636846b34<br><br></div><div>3/ Then if i test the script :<br>
<br>Pressing the &quot;*&quot; key on the caller leg, called uuid is display =&gt; <span style="color:rgb(0,255,0)">TEST OK</span> (log hereunder)<br>


<br>freeswitch@debian&gt; 2013-06-02 22:43:59.414932 [DEBUG] switch_rtp.c:4908 RTP RECV DTMF *:800<br>2013-06-02 22:43:59.414932 [DEBUG] mod_dptools.c:186 sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Digit match binding [exec:execute_extension][debug_bda]<br>



2013-06-02 22:43:59.414932 [DEBUG] switch_core_session.c:1141 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>2013-06-02 22:43:59.434933 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>



2013-06-02 22:43:59.554961 [DEBUG] switch_core_session.c:1141 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>2013-06-02 22:43:59.574934 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>



2013-06-02 22:43:59.694963 [DEBUG] switch_ivr.c:612 sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> Command Execute playback(local_stream://moh)<br>EXECUTE sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> playback(local_stream://moh)<br>



2013-06-02 22:43:59.694963 [DEBUG] switch_ivr.c:612 sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Command Execute execute_extension(debug_bda)<br>EXECUTE sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> execute_extension(debug_bda)<br>



2013-06-02 22:43:59.694963 [DEBUG] mod_local_stream.c:479 Opening Stream [moh/8000] 8000hz<br>2013-06-02 22:43:59.694963 [DEBUG] switch_ivr_play_say.c:1308 Codec Activated L16@8000hz 1 channels 20ms<br>2013-06-02 22:43:59.694963 [INFO] mod_dialplan_xml.c:558 Processing 1001 &lt;1001&gt;-&gt;debug_bda in context default<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;unloop] continue=false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (PASS) [unloop] ${unroll_loops}(true) =~ /^true$/ break=on-false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (FAIL) [unloop] ${sip_looped_call}() =~ /^true$/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;Local_Extension] continue=false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (FAIL) [Local_Extension] destination_number(debug_bda) =~ /^(1003)$/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;debug_bda] continue=false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (PASS) [debug_bda] destination_number(debug_bda) =~ /^debug_bda/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Action log(INFO debug_bind_digit_action is called from uuid : ${uuid} !)<br>



2013-06-02 22:43:59.694963 [NOTICE] switch_core_session.c:2838 Execute 
log(INFO debug_bind_digit_action is called from uuid : ${uuid} !)<br>EXECUTE sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> log(INFO debug_bind_digit_action is called from uuid : 07803d02-cbc5-11e2-b750-85c636846b34 !)<br>



<span style="color:rgb(0,255,0)">2013-06-02 22:43:59.694963 [INFO] mod_dptools.c:1539 debug_bind_digit_action is called from uuid : 07803d02-cbc5-11e2-b750-85c636846b34 !<br></span>2013-06-02 22:43:59.714996 [DEBUG] switch_ivr_play_say.c:1694 done playing file local_stream://moh<br>



2013-06-02 22:43:59.714996 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>2013-06-02 22:43:59.714996 [DEBUG] switch_ivr_bridge.c:349 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>



2013-06-02 22:43:59.714996 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>2013-06-02 22:43:59.714996 [DEBUG] switch_ivr_bridge.c:349 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>



<br><br>Pressing the &quot;*&quot; key on the called leg, <span style="color:rgb(255,0,0)">called uuid</span> is display =&gt; <span style="color:rgb(255,0,0)">TEST FAILED</span> (log hereunder)<br><br><br>freeswitch@debian&gt; 2013-06-02 22:44:19.754933 [DEBUG] switch_rtp.c:4908 RTP RECV DTMF *:1280<br>



2013-06-02 22:44:19.754933 [DEBUG] switch_channel.c:419 RECV DTMF *:1280<br>2013-06-02 22:44:19.754933 [DEBUG] mod_dptools.c:186 sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Digit match binding [exec:execute_extension][debug_bda]<br>



2013-06-02 22:44:19.754933 [DEBUG] switch_ivr_bridge.c:419 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>2013-06-02 22:44:19.754933 [DEBUG] switch_core_session.c:1141 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>



2013-06-02 22:44:19.774938 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>2013-06-02 22:44:19.894950 [DEBUG] switch_core_session.c:1141 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>



2013-06-02 22:44:19.914960 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>2013-06-02 22:44:20.034916 [DEBUG] switch_ivr.c:612 sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> Command Execute playback(local_stream://moh)<br>



EXECUTE sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> playback(local_stream://moh)<br>2013-06-02 22:44:20.034916 [DEBUG] switch_ivr.c:612 sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Command Execute execute_extension(debug_bda)<br>



EXECUTE sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> execute_extension(debug_bda)<br>2013-06-02 22:44:20.034916 [DEBUG] mod_local_stream.c:479 Opening Stream [moh/8000] 8000hz<br>



2013-06-02 22:44:20.034916 [DEBUG] switch_ivr_play_say.c:1308 Codec Activated L16@8000hz 1 channels 20ms<br>2013-06-02 22:44:20.034916 [INFO] mod_dialplan_xml.c:558 Processing 1001 &lt;1001&gt;-&gt;debug_bda in context default<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;unloop] continue=false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (PASS) [unloop] ${unroll_loops}(true) =~ /^true$/ break=on-false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (FAIL) [unloop] ${sip_looped_call}() =~ /^true$/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;Local_Extension] continue=false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (FAIL) [Local_Extension] destination_number(debug_bda) =~ /^(1003)$/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> parsing [default-&gt;debug_bda] continue=false<br>



Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Regex (PASS) [debug_bda] destination_number(debug_bda) =~ /^debug_bda/ break=on-false<br>Dialplan: sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> Action log(INFO debug_bind_digit_action is called from uuid : ${uuid} !)<br>



2013-06-02 22:44:20.034916 [NOTICE] switch_core_session.c:2838 Execute 
log(INFO debug_bind_digit_action is called from uuid : ${uuid} !)<br>EXECUTE sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> log(INFO debug_bind_digit_action is called from uuid : 07803d02-cbc5-11e2-b750-85c636846b34 !)<br>



<span style="color:rgb(255,0,0)">2013-06-02 22:44:20.034916 [INFO] mod_dptools.c:1539 debug_bind_digit_action is called from uuid : 07803d02-cbc5-11e2-b750-85c636846b34 !<br></span>2013-06-02 22:44:20.054921 [DEBUG] switch_ivr_play_say.c:1694 done playing file local_stream://moh<br>



2013-06-02 22:44:20.054921 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>2013-06-02 22:44:20.054921 [DEBUG] switch_ivr_bridge.c:349 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>



2013-06-02 22:44:20.054921 [DEBUG] switch_core_session.c:861 Send signal sofia/external5090/<a href="http://sip:1003@89.88.82.75:52810" target="_blank">sip:1003@89.88.82.75:52810</a> [BREAK]<br>2013-06-02 22:44:20.054921 [DEBUG] switch_ivr_bridge.c:349 Send signal sofia/external5090/<a href="mailto:1001@mydomain.no-ip.org" target="_blank">1001@mydomain.no-ip.org</a> [BREAK]<br>



<br></div><div>Thanks for your help.<br></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" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" 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" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Michael S Collins<br>Twitter: @mercutioviz<br><a href="http://www.FreeSWITCH.org" target="_blank">http://www.FreeSWITCH.org</a><br><a href="http://www.ClueCon.com" target="_blank">http://www.ClueCon.com</a><br>
<a href="http://www.OSTAG.org" target="_blank">http://www.OSTAG.org</a><br><br>
</div>