<div dir="ltr"><div>I tried the settings for late negotiation without success (before I mailed the list!). I had an action application="answer" statement in my dialplan. This seems to override the whole negotiation process! After I removed that, the negotiation is done properly.<br></div>Thank you Ahmed for the suggestion, even if it did not really solve the problem.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Apr 1, 2015 at 11:48 PM, Ahmed Sboor <span dir="ltr"><<a href="mailto:ahmed@netelsat.net" target="_blank">ahmed@netelsat.net</a>></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 class="gmail_default"><font style="background-color:rgb(255,255,255)" face="verdana, sans-serif" color="#0000ff">Hi Andries ,</font></div><div class="gmail_default"><font style="background-color:rgb(255,255,255)" face="verdana, sans-serif" color="#0000ff">You should again look on <a href="https://wiki.freeswitch.org/wiki/Codec_Negotiation" target="_blank">https://wiki.freeswitch.org/wiki/Codec_Negotiation</a></font></div><div class="gmail_default"><font style="background-color:rgb(255,255,255)" face="verdana, sans-serif" color="#0000ff"><br></font></div><div class="gmail_default"><font style="background-color:rgb(255,255,255)" face="verdana, sans-serif" color="#0000ff">And i think easiest way is using <span style="font-size:12.8000001907349px;line-height:1.3em"><b>absolute_codec_string </b>before briding to "G729" only PABX</span></font><span style="color:rgb(0,0,0);font-family:monospace,Courier;font-size:12.8000001907349px;line-height:1.3em;background-color:rgb(249,249,249)">.</span></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,255)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,255)">Ahmed</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,255)"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Wed, Apr 1, 2015 at 7:51 PM, Andries Venter <span dir="ltr"><<a href="mailto:apventer@gmail.com" target="_blank">apventer@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">
<p>I am using Freeswitch (1.4.8) as an SBC between our
company PABX and our ISP's Trunk (also terminating on an SBC).</p>
<p>My problem is that I need G729 in some cases and PCMA in
others (the majority).</p>
<p> </p>
<p>The setup looks more or less like this:</p>
<p>Our PABX (192.168.102.215)=>(192.168.102.102)Our SBC
(10.17.159.10)=>(10.17.159.9)ISP SBC=>Rest of the world</p>
<p> </p>
<p>Since we use private addresses, Freeswitch must do RTP
proxying.<span> </span>No transcoding must be done!!!</p>
<p> </p>
<p>I have set global_codec_prefs to
"PCMA,G729".<span> </span>Then everything
to destination supporting PCMA works.<span>
</span>When trying to connect to a G729-only PABX, the call fails.<span> </span>Leg A is setup as follows</p>
<p> </p>
<p><span>
</span>192.168.102.215.5060 > 192.168.102.102.5090: SIP, length: 933</p>
<p><span> </span><span> </span>INVITE <a>sip:0873611337@192.168.102.102:5090;transport=udp</a>
SIP/2.0</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>></p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_iFGEOrlLLf</p>
<p><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-9lz36fM4mXAo</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>Contact:
<<a>sip:anonymous@192.168.102.215:5060;maddr=192.168.102.215</a>></p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-5nUh73XkOk</p>
<p><span> </span><span> </span>Content-Type: application/sdp</p>
<p><span>
</span>Content-Length: 288</p>
<p><span>
</span>X-Siemens-Call-Type: ST-insecure</p>
<p><span>
</span>Accept-Language: en;q=0.0</p>
<p><span> </span>Allow:
REGISTER, INVITE, ACK, BYE, CANCEL, NOTIFY, REFER, INFO</p>
<p><span> </span>Date: Wed,
01 Apr 2015 14:30:15 GMT</p>
<p><span> </span><span> </span>Max-Forwards: 69</p>
<p> </p>
<p><span> </span>v=0</p>
<p><span> </span>o=MxSIP 0
105140472 IN IP4 10.11.32.226</p>
<p><span> </span>s=SIP Call</p>
<p><span> </span>c=IN IP4
10.11.32.226</p>
<p><span> </span>t=0 0</p>
<p><span> </span>m=audio
5014 RTP/AVP 8 0 18 101</p>
<p><span> </span>a=rtpmap:8
PCMA/8000</p>
<p><span> </span>a=rtpmap:0
PCMU/8000</p>
<p><span> </span>a=rtpmap:18
G729/8000</p>
<p><span>
</span>a=rtpmap:101 telephone-event/8000</p>
<p><span>
</span>a=silenceSupp:off - - - -</p>
<p><span> </span>a=fmtp:18
annexb=no</p>
<p><span> </span>a=fmtp:101
0-15</p>
<p> </p>
<p><span>
</span>192.168.102.102.5090 > 192.168.102.215.5060: SIP, length: 396</p>
<p><span> </span>SIP/2.0 100
Trying</p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-5nUh73XkOk</p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_iFGEOrlLLf</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>></p>
<p><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-9lz36fM4mXAo</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>User-Agent:
FreeSWITCH-mod_sofia/1.4.18+git~20150312T185523Z~4eed221b69~64bit</p>
<p><span>
</span>Content-Length: 0</p>
<p> </p>
<p><span>
</span>192.168.102.102.5090 > 192.168.102.215.5060: SIP, length: 1201</p>
<p><span> </span>SIP/2.0 200
OK</p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-5nUh73XkOk</p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_iFGEOrlLLf</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>>;tag=BytX6X1t7HytF</p>
<p><span> </span><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-9lz36fM4mXAo</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>Contact:
<<a>sip:0873611337@192.168.102.102:5090;transport=udp</a>></p>
<p><span> </span>User-Agent:
FreeSWITCH-mod_sofia/1.4.18+git~20150312T185523Z~4eed221b69~64bit</p>
<p><span> </span>Accept:
application/sdp</p>
<p><span> </span>Allow:
INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER,
NOTIFY, PUBLISH, SUBSCRIBE</p>
<p><span> </span>Supported:
timer, path, replaces</p>
<p><span>
</span>Allow-Events: talk, hold, conference, presence, as-feature-event,
dialog, line-seize, call-info, sla, include-session-description,
presence.winfo, message-summary, refer</p>
<p><span>
</span>Content-Type: application/sdp</p>
<p><span>
</span>Content-Disposition: session</p>
<p><span>
</span>Content-Length: 226</p>
<p><span>
</span>Remote-Party-ID: "0873611337" <<a>sip:0873611337@192.168.102.102</a>>;party=calling;privacy=off;screen=no</p>
<p> </p>
<p><span> </span>v=0</p>
<p><span>
</span>o=FreeSWITCH 1427881297 1427881298 IN IP4 192.168.102.102</p>
<p><span>
</span>s=FreeSWITCH</p>
<p><span> </span>c=IN IP4
192.168.102.102</p>
<p><span> </span>t=0 0</p>
<p><span> </span>m=audio
17318 RTP/AVP 8 101</p>
<p><span> </span>a=rtpmap:8
PCMA/8000</p>
<p><span>
</span>a=rtpmap:101 telephone-event/8000</p>
<p><span> </span>a=fmtp:101
0-16</p>
<p><span> </span>a=ptime:20</p>
<p> </p>
<p> </p>
<p>When I change my global_codec_prefs to
"G729,PCMA", G729 is offered to our PABX by Freeswitch, then to the
ISP and then it works to destinations supporting G729.<span> </span>It fails to destinations not supporting
G729.<span> </span>Now Leg A is setup as follows:</p>
<p> </p>
<p><span>
</span>192.168.102.215.5060 > 192.168.102.102.5090: SIP, length: 934</p>
<p><span> </span>INVITE <a>sip:0873611337@192.168.102.102:5090;transport=udp</a>
SIP/2.0</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>></p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_8NZMvB3KNA</p>
<p><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-k6bGtU73W2Vm</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>Contact:
<<a>sip:anonymous@192.168.102.215:5060;maddr=192.168.102.215</a>></p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-ZO003uQGh0</p>
<p><span>
</span>Content-Type: application/sdp</p>
<p><span>
</span>Content-Length: 289</p>
<p><span>
</span>X-Siemens-Call-Type: ST-insecure</p>
<p><span>
</span>Accept-Language: en;q=0.0</p>
<p><span> </span>Allow:
REGISTER, INVITE, ACK, BYE, CANCEL, NOTIFY, REFER, INFO</p>
<p><span> </span>Date: Wed,
01 Apr 2015 14:27:51 GMT</p>
<p><span>
</span>Max-Forwards: 69</p>
<p> </p>
<p><span> </span>v=0</p>
<p><span> </span>o=MxSIP 0
1224193414 IN IP4 10.11.32.226</p>
<p><span> </span>s=SIP Call</p>
<p><span> </span>c=IN IP4
10.11.32.226</p>
<p><span> </span>t=0 0</p>
<p><span> </span>m=audio
5014 RTP/AVP 8 0 18 101</p>
<p><span> </span>a=rtpmap:8
PCMA/8000</p>
<p><span> </span>a=rtpmap:0
PCMU/8000</p>
<p><span> </span>a=rtpmap:18
G729/8000</p>
<p><span>
</span>a=rtpmap:101 telephone-event/8000</p>
<p><span>
</span>a=silenceSupp:off - - - -</p>
<p><span> </span>a=fmtp:18
annexb=no</p>
<p><span> </span>a=fmtp:101
0-15</p>
<p> </p>
<p><span>
</span>192.168.102.102.5090 > 192.168.102.215.5060: SIP, length: 396</p>
<p><span> </span>SIP/2.0 100
Trying</p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-ZO003uQGh0</p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_8NZMvB3KNA</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>></p>
<p><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-k6bGtU73W2Vm</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>User-Agent:
FreeSWITCH-mod_sofia/1.4.18+git~20150312T185523Z~4eed221b69~64bit</p>
<p><span>
</span>Content-Length: 0</p>
<p> </p>
<p><span>
</span>192.168.102.102.5090 > 192.168.102.215.5060: SIP, length: 1224</p>
<p><span> </span>SIP/2.0 200
OK</p>
<p><span> </span>Via:
SIP/2.0/UDP
192.168.102.215:5060;branch=z9hG4bKSEC-a64a8c0-1e64a8c0-1-ZO003uQGh0</p>
<p><span> </span>From: "JGD Winson" <<a>sip:anonymous@anonymous.invalid</a>>;tag=snl_8NZMvB3KNA</p>
<p><span> </span>To: <<a>sip:0873611337@192.168.102.102;user=phone</a>>;tag=g2eKXDUB6y4Hr</p>
<p><span> </span>Call-ID:
SEC11-a64a8c0-1e64a8c0-1-k6bGtU73W2Vm</p>
<p><span> </span>CSeq: 1235
INVITE</p>
<p><span> </span>Contact:
<<a>sip:0873611337@192.168.102.102:5090;transport=udp</a>></p>
<p><span> </span>User-Agent:
FreeSWITCH-mod_sofia/1.4.18+git~20150312T185523Z~4eed221b69~64bit</p>
<p><span> </span>Accept:
application/sdp</p>
<p><span> </span>Allow:
INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER,
NOTIFY, PUBLISH, SUBSCRIBE</p>
<p><span> </span>Supported:
timer, path, replaces</p>
<p><span>
</span>Allow-Events: talk, hold, conference, presence, as-feature-event,
dialog, line-seize, call-info, sla, include-session-description,
presence.winfo, message-summary, refer</p>
<p><span>
</span>Content-Type: application/sdp</p>
<p><span>
</span>Content-Disposition: session</p>
<p><span>
</span>Content-Length: 249</p>
<p><span>
</span>Remote-Party-ID: "0873611337" <<a>sip:0873611337@192.168.102.102</a>>;party=calling;privacy=off;screen=no</p>
<p> </p>
<p><span> </span>v=0</p>
<p><span>
</span>o=FreeSWITCH 1427866745 1427866746 IN IP4 192.168.102.102</p>
<p><span>
</span>s=FreeSWITCH</p>
<p><span> </span><span> </span>c=IN IP4 192.168.102.102</p>
<p><span> </span>t=0 0</p>
<p><span> </span>m=audio
31726 RTP/AVP 18 101</p>
<p><span> </span>a=rtpmap:18
G729/8000</p>
<p><span> </span>a=fmtp:18
annexb=no</p>
<p><span>
</span>a=rtpmap:101 telephone-event/8000</p>
<p><span> </span>a=fmtp:101
0-16</p>
<p><span> </span>a=ptime:20</p>
<p> </p>
<p>I have tried various (hopefully all) combinations of
inbound-codec-negotiation (generous, greedy and scrooge) and
inbound-late-negotiation (true, false).<span>
</span>Nothing does what I want.</p>
<p> </p>
<p>I believe Freeswitch needs to negotiate the codecs with
the endpoint and choose one from my list.<span>
</span>However, it seems to grab the first one in my list before checking the
endpoint.<span> </span>Then it offers only that codec
to the endpoint, which of course ignores / rejects it!</p>
<p> </p>
<p>What can I do?</p>
<p>Regards</p><span><font color="#888888">
<span style="font-size:11pt;font-family:"Calibri","sans-serif"">Andries</span></font></span></div>
<br></div></div>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.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://confluence.freeswitch.org" target="_blank">http://confluence.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" target="_blank">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></blockquote></div><br></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>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" target="_blank">http://confluence.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></blockquote></div><br></div>