<div dir="ltr">Hi Luiz,<div><br></div><div>After you accept the connection on port 8084 do you send a connect command, and receive the CHANNEL_DATA event?</div><div>In that event you get the channel uuid &quot;Unique-ID&quot;.  You need this to use sendmsg.</div>
<div><br></div><div>Then the syntax is:</div><div><br></div><div>sendmsg &lt;uuid&gt;</div><div>call-command: execute</div><div>execute-app-name: (export, set, bridge, etc)</div><div>execute-app-arg: (appropriate arguments)</div>
<div>[optional event-lock: true]</div><div>\n</div><div>\n</div><div><br></div><div>Does this get you any further?</div><div>Ian.</div><div><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, May 5, 2014 at 8:19 PM, Luiz Fernando Softov <span dir="ltr">&lt;<a href="mailto:fernando@softov.com.br" target="_blank">fernando@softov.com.br</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">Hi everyone.<br><br><br><div style="font-family:arial,sans-serif;font-size:13px">I have this problem making outbound call. Maybe someone can help me with this.</div>
<div style="font-family:arial,sans-serif;font-size:13px">
<br><span style="background-color:rgba(255,255,255,0)">I&#39;m have a service in C (TCP Server),  where i receive all calls.<br><br></span><div><span style="background-color:rgba(255,255,255,0)">&lt;extension name=&quot;outcalls&quot;&gt;</span></div>

<div><span style="background-color:rgba(255,255,255,0)">    &lt;condition&gt;</span></div><div><span style="background-color:rgba(255,255,255,0)">        &lt;action application=&quot;socket&quot; data=&quot;<a href="http://127.0.0.1:8084/" target="_blank">127.0.0.1:8084</a> async full&quot;/&gt;</span></div>

<div><span style="background-color:rgba(255,255,255,0)">        &lt;action application=&quot;hangup&quot;/&gt;</span></div><div><span style="background-color:rgba(255,255,255,0)">    &lt;/condition&gt;</span></div><div><span style="background-color:rgba(255,255,255,0)">&lt;/extension&gt;</span></div>

<span style="background-color:rgba(255,255,255,0)"><br>In this service I do all the work of billing and control of active calls.<br><br>This is my commands, where i receive a connection to make a call to 1001<br><br></span><div>

<span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>call-command: set\n<br>execute-app-name: dialed_extension=1001\n\n<br><br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>

call-command: export\n<br>execute-app-name: dialed_extension=1001<br><br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>call-command: set\n<br>execute-app-name: bypass_media=true\n\n<br>

<br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>call-command: set\n<br>execute-app-name: call_timeout=30\n\n<br><br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>

call-command: set\n<br>execute-app-name: hangup_after_bridge=true\n\n<br><br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>call-command: set\n<br>execute-app-name: continue_on_fail=true\n\n<br>

<br></span></div><div><span style="background-color:rgba(255,255,255,0)">sendmsg execute\n<br>call-command: bridge\n<br>execute-app-name: user/${dialed_extension}@${domain_name}\n\n</span></div><span style="background-color:rgba(255,255,255,0)"><br>

<br>But now I stopped because I can not cancel the bridge and do something with the call.<br><br>I tried, but all commands i have sended like <br><br>sendmsg execute\n<br>call-command: hangup\n<br>execute-app-name: CHANNEL_UNACCEPTABLE\n\n<br>

<br>or <br><br>sendmsg execute\n<br>call-command: break\n\n<br><br>Do nothing with the call<br><br>I receive only this in FS log<br><br>[DEBUG] switch_core_session.c:1151 Send signal sofia/internal/<a style="color:rgb(34,34,34)">1001@192.168.211.69</a>[BREAK]<br>

<br>I tried with and without &quot;event-lock: true&quot;<br><br>I need to do this such as: credit is over, I need to cancel the current bridge and play a sound to the user and hangup call<br><br>or to simple hangup a call</span></div>

<div style="font-family:arial,sans-serif;font-size:13px"><br><span style="background-color:rgba(255,255,255,0)"></span><div><font style="background-color:rgba(255,255,255,0)">I receive this in FS console LOG after a-leg or bleg hangup a phone and call terminated<br>

<br><div>[DEBUG] switch_ivr.c:614 sofia/internal/<a style="color:rgb(34,34,34)">1001@192.168.211.69</a>Command Execute hangup()</div><div>[DEBUG] switch_core_session.c:2614 sofia/internal/<a style="color:rgb(34,34,34)">1001@192.168.211.69</a>Channel is hungup and application &#39;hangup&#39; does not have the zombie_exec flag.</div>

<div>[DEBUG] switch_ivr.c:657 sofia/internal/<a style="color:rgb(34,34,34)">1001@192.168.211.69</a> skip receive message [AUDIO_SYNC] (channel is hungup already)</div><div><br></div><div><br></div>This is for each &quot;sendmsg&quot; i send after bridge was answered.</font></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></div></div>