Inherit_codec requires late negotiation - is that enabled too? Otherwise the aleg codec has already been picked before hitting the dialplan.<div><div><br><br>On Wednesday, September 18, 2013, sangdrax8  wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Did I explain a bit to much detail for the users list?<br>
<br>
Does anyone use &quot;inherit_codec=true&quot; and have it working?<br>
<br>
<br>
On Tue, Sep 17, 2013 at 2:27 PM, sangdrax8 &lt;<a>sangdrax8@gmail.com</a>&gt; wrote:<br>
&gt; I pulled the latest freeswitch from git this morning, and am still<br>
&gt; having issues using inherit_codec=true.  It seems the only way I can<br>
&gt; get it to defer to the choice of the b-leg call is to remove the<br>
&gt; ringback, and thus the need for early media.<br>
&gt;<br>
&gt; My setup has 2 phones with the following codecs configured:<br>
&gt;<br>
&gt; phone1000:  g722, ulaw<br>
&gt; phone1001:  ulaw<br>
&gt;<br>
&gt; My goal is to have a call initiated by phone1000 (a-leg) to defer the<br>
&gt; codec choice until phone1001 (b-leg) chooses one.  This would allow<br>
&gt; them to talk with no transcoding required by freeswitch.  With the<br>
&gt; following dial plan, this fails to work.<br>
&gt;<br>
&gt; &lt;extension name=&quot;Local_Extension&quot;&gt;<br>
&gt;       &lt;condition field=&quot;destination_number&quot; expression=&quot;^(10[01][0-9])$&quot;&gt;<br>
&gt;         &lt;action application=&quot;export&quot; data=&quot;dialed_extension=$1&quot;/&gt;<br>
&gt;         &lt;action application=&quot;set&quot; data=&quot;ringback=${us-ring}&quot;/&gt;<br>
&gt;         &lt;action application=&quot;set&quot; data=&quot;transfer_ringback=$${hold_music}&quot;/&gt;<br>
&gt;         &lt;action application=&quot;set&quot; data=&quot;call_timeout=30&quot;/&gt;<br>
&gt;         &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;<br>
&gt;         &lt;action application=&quot;set&quot; data=&quot;inherit_codec=true&quot; /&gt;<br>
&gt;         &lt;action application=&quot;bridge&quot;<br>
&gt; data=&quot;user/${dialed_extension}@${domain_name}&quot;/&gt;<br>
&gt;       &lt;/condition&gt;<br>
&gt; &lt;/extension&gt;<br>
&gt;<br>
&gt; It does log that it is going to defer:<br>
&gt;<br>
&gt; 2013-09-17 13:15:10.956535 [DEBUG] mod_sofia.c:4542 [zrtp_passthru]<br>
&gt; Setting a-leg inherit_codec=true<br>
&gt; 2013-09-17 13:15:10.956535 [DEBUG] mod_sofia.c:4545 [zrtp_passthru]<br>
&gt; Setting b-leg absolute_codec_string=&#39;G722@8000h@20i@64000b,PCMU@8000h@20i@64000b&#39;<br>
&gt;<br>
&gt;<br>
&gt; then it tries to provide the ringback for the a-leg, and it negotiates<br>
&gt; to g722 since freeswitch supports that and it is the first match.<br>
&gt; Later when the b-leg is answered, it also negotiates, this time to<br>
&gt; ulaw as that is all b supports.  My call completes, but freeswitch has<br>
&gt; to transcode between the two.<br>
&gt;<br>
&gt; In an attempt to see inherit_codec work, I then commented out the<br>
&gt; ringback line from the above dialplan.  With only this one change,<br>
&gt; freeswitch now waits until the b-leg negotiation, and passes that back<br>
&gt; to the a-leg.  The call completes and both handsets are using ulaw and<br>
&gt; no transcoding is required.  The problem being that the calling party<br>
&gt; never gets a ring while waiting.<br>
&gt;<br>
&gt; I can&#39;t imagine that the only way to use inherit_codec=true is with<br>
&gt; all ringing turned off.  Can someone tell me if there is an additional<br>
&gt; option I am missing?  All documentation I read seems to indicate that<br>
&gt; just adding &quot;inherit_codec=true&quot; will fix things, but even the<br>
&gt; default.xml provided as an example uses ringback and therefore fails.<br>
<br>
_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a>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>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.free</a></blockquote></div></div>