<div dir="ltr">I just had a talk about this with our carrier and the problems seems on their side.<div>This will not be fixed anytime soon, so they said it would be best, if we use T.38 inside and t38-to-g711 when connecting to them.</div><div><br></div><div>I tried to set this in the incoming dialplan:</div><div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br><include><br> <extension name="public_did"><br> <condition field="destination_number" expression="^\+(\d+)$|\d+$"><br> <action application="set" data="domain_name=$${domain}"/><br> <action application="t38_gateway" data="peer"/><br> <action application="bridge" data="sofia/internal/${<a href="mailto:destination_number%7D@192.168.31.11">destination_number}@192.168.31.11</a>"/><br> </condition><br> </extension><br></include><br> </blockquote></div><div class="gmail_extra"><div><div class="gmail_signature"><div dir="ltr"><div><br></div><div>IP 192.168.31.11 is an asterisk machine, connecting the T.38 ATAs at various locations.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.128433 [DEBUG] switch_ivr_bridge.c:1614 (sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a>) State Change CS_CONSUME_MEDIA -> CS_EXCHANGE_MEDIA<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.128433 [DEBUG] switch_core_state_machine.c:584 (sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a>) Running State Change CS_EXCHANGE_MEDIA (Cur 2 Tot 2)<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.128433 [DEBUG] switch_core_state_machine.c:653 (sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a>) State EXCHANGE_MEDIA<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.128433 [DEBUG] mod_sofia.c:631 SOFIA EXCHANGE_MEDIA<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.148489 [DEBUG] sofia.c:7084 Channel sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> entering state [received][100]<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.148489 [DEBUG] sofia.c:7094 Remote SDP:<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 v=0<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 o=- 1512309774 1512309778 IN IP4 192.168.31.11<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 s=Asterisk<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 c=IN IP4 192.168.31.11<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 t=0 0<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 m=image 4663 udptl t38<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxVersion:1<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38MaxBitRate:14400<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxTranscodingMMR<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxTranscodingJBIG<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxRateManagement:transferredTCF<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxMaxDatagram:784<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxUdpEC:t38UDPRedundancy<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.148489 [DEBUG] switch_core_media.c:4028 sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> T38 REFUSE on request<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.148489 [DEBUG] sofia.c:8007 Reinvite resulted in codec negotiation failure.<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.168441 [DEBUG] sofia.c:7077 Channel sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> skipping state [ready][488]<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.168441 [DEBUG] sofia.c:7084 Channel sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> entering state [received][100]<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.168441 [DEBUG] sofia.c:7094 Remote SDP:<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 v=0<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 o=- 1512309774 1512309779 IN IP4 192.168.31.11<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 s=Asterisk<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 c=IN IP4 192.168.31.11<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 t=0 0<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 m=image 4663 udptl t38<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxVersion:1<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38MaxBitRate:14400<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxTranscodingMMR<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxTranscodingJBIG<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxRateManagement:transferredTCF<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxMaxDatagram:784<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 a=T38FaxUdpEC:t38UDPRedundancy<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.168441 [DEBUG] switch_core_media.c:4028 sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> T38 REFUSE on request<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.168441 [DEBUG] sofia.c:8007 Reinvite resulted in codec negotiation failure.<br>ac858869-5320-48fb-b100-1a4a9c3d0851 2017-12-03 23:43:49.188433 [DEBUG] switch_rtp.c:7271 Correct audio ip/port confirmed.<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.188433 [DEBUG] sofia.c:7077 Channel sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> skipping state [ready][488]<br>ac858869-5320-48fb-b100-1a4a9c3d0851 2017-12-03 23:43:49.208437 [DEBUG] sofia.c:7084 Channel sofia/external/<a href="mailto:anonymous@87.234.1.183">anonymous@87.234.1.183</a> entering state [ready][200]<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:43:49.208437 [DEBUG] switch_rtp.c:7271 Correct audio ip/port confirmed.<br>7fb3d04b-31f4-4539-a13e-aeaea7a194e8 2017-12-03 23:44:33.188445 [NOTICE] sofia.c:1012 Hangup sofia/internal/%<a href="mailto:2B491122334455@192.168.31.11">2B491122334455@192.168.31.11</a> [CS_EXCHANGE_MEDIA] [NORMAL_CLEARING]<br> </blockquote><div dir="ltr"><br></div><div>What I need is:</div><div><br></div><div>FAX ATA (T.38) -> Asterisk (T.38) -> FreeSWITCH (T.38 to audio GW, refuse T.38 on A-leg) -> Carrier (audio)</div><div><br></div><div>Carrier (audio) -> FreeSWITCH (audio to T.38, refuse T.38 on B-leg) -> Asterisk (T.38) -> FAX ATA (T.38)</div><div><br></div><div>Asterisk is sending Re-INVITES as seen in the log above. Seems like I miss some settings in my dialplan?</div><div dir="ltr"><br>Kevin</div></div></div></div>
<br><div class="gmail_quote">2017-12-02 16:36 GMT+01:00 Kevin Olbrich <span dir="ltr"><<a href="mailto:ko@sv01.de" target="_blank">ko@sv01.de</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">I need to note that all components are SIP based, no other tech involved.<div class="gmail_extra"><span class="gmail-HOEnZb"><font color="#888888"><br clear="all"><div><div class="gmail-m_2135769695358497393gmail_signature"><div dir="ltr"><div><div dir="ltr">Kevin</div></div></div></div></div></font></span><div><div class="gmail-h5">
<br><div class="gmail_quote">2017-12-02 13:41 GMT+01:00 Kevin Olbrich <span dir="ltr"><<a href="mailto:ko@sv01.de" target="_blank">ko@sv01.de</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>thanks for the link but I was unable to find information on how to configure my installation of FreeSwitch 1.6 to make things work.</div><div><br></div><div>I think I need to explain a little bit more on what I am planning to do:</div><div>FreeSwitch will be used as a SBC to the carrier. It's firewall is limited to the carriers network on the first interface.</div><div>The second interface is a local subnet where an Asterisk 13 server (PBX) is located, connecting the phones and ATAs (last with T.38 support).</div><div>For asterisk it is only necessary so set (FAXOPT(gateway)=yes) to have it detect CNG on audio and query both legs for T.38 (or receive a request in advance).</div><div>It then decides if it goes to passthru mode or transcode.</div><div><br></div><div>As far as I understand the FreeSwitch docs, there are these options (located in dialplan default before bridge):</div><div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><action application="set" data="fax_enable_t38=true"/> <!-- Enable t.38 for this call --><br><action application="set" data="fax_enable_t38_request=t<wbr>rue"/> <!-- Enable t38_gateway to send a t.38 reinvite when a fax tone is detected. If using t38_gateway peer then you need to export this variable instead of set --><br><action application="set" data="execute_on_answer=t38_ga<wbr>teway self"/> <!--Execute t38_gateway on answer. self or peer. self: send a reinvite back to the a-leg. peer reinvite forward to the b-leg --></blockquote></div><div><div class="gmail_extra"><br clear="all"><div><div class="gmail-m_2135769695358497393m_2764706872542973847gmail_signature"><div dir="ltr"><div dir="ltr"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><action application="export" data="fax_enable_t38=true"/> <!-- Required as of v1.6 --><br><action application="export" data="t38_passthru=true"/></blockquote><div dir="ltr"><br></div><div><b><u>What I would like to accomplish is getting as much as T.38 I can get.</u></b> The ATA should always be able to negotiate T.38 with Asterisk (which seems to work atm), FreeSwitch should then negotiate T.38 if Asterisk or the carrier asks for it (no CNG detection).</div><div>I am not sure if I can just enable t38_gateway and passthru, this case is not listed on confluence or the old wiki. Even if I do, it does not work.</div><div><br></div><div>FreeSwitch might need to transcode T.38 to audio for our backup carrier who does not support T.38.</div><div dir="ltr"><br></div>Kind regards,<br>Kevin</div></div></div></div><div><div class="gmail-m_2135769695358497393h5">
<br><div class="gmail_quote">2017-12-02 9:20 GMT+01:00 Raúl Alexis Betancor Santana <span dir="ltr"><<a href="mailto:rbetancor@gmail.com" target="_blank">rbetancor@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Some carriers gateways doesn't like a T.38 invite on advance, usually the order that gives better results for faxing are first invite on PCMU/PCMA (or any other supported codec) and then re-invite to T.38.<div><br></div><div>Take a look at how gonicus gofaxip do-it (<a href="https://github.com/gonicus/gofaxip" target="_blank">https://github.com/gonicus/go<wbr>faxip</a>)</div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="gmail-m_2135769695358497393m_2764706872542973847gmail-h5">On Fri, Dec 1, 2017 at 10:21 PM, Kevin Olbrich <span dir="ltr"><<a href="mailto:ko@sv01.de" target="_blank">ko@sv01.de</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div class="gmail-m_2135769695358497393m_2764706872542973847gmail-h5"><div dir="ltr">Hi!<div><br></div><div>Our carrier supports T.38 for outgoing faxes. I am trying to send faxes like this:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">originate {origination_caller_id_name='k<wbr>evin',origination_caller_id_nu<wbr>mber='+49123456789',ignore_ear<wbr>ly_media=true,absolute_codec_s<wbr>tring='PCMA,PCMU',fax_use_ecm=<wbr>true,fax_enable_t38=true,fax_e<wbr>nable_t38_request=true}sofia/g<wbr>ateway/carrier_1/+4912121212 &txfax(/opt/faxout.tif)</blockquote><div><br></div><div><br></div><div>Log:</div><div><br></div><div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">668fd128-f2f5-4af5-9536-678076<wbr>2c2efa 2017-12-01 21:38:57.513164 [DEBUG] sofia_glue.c:1295 sofia/external/+4912121212 sending invite version: 1.6.19 -36-7a77e0b 64bit<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa Local SDP:<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa v=0<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa o=FreeSWITCH 1512130268 1512130270 IN IP4 123.123.123.123<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa s=FreeSWITCH<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa c=IN IP4 123.123.123.123<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa t=0 0<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa m=image 30466 udptl t38<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxVersion:0<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38MaxBitRate:14400<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxFillBitRemoval<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxRateManagement:transfe<wbr>rredTCF<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxMaxBuffer:2000<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxMaxDatagram:400<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa a=T38FaxUdpEC:t38UDPRedundancy<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa 2017-12-01 21:38:57.533158 [DEBUG] sofia.c:7084 Channel sofia/external/+4912121212 entering state [calling][0]<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa 2017-12-01 21:38:57.673120 [DEBUG] sofia.c:6294 sofia/external/+4912121212 T38 invite failed<br>668fd128-f2f5-4af5-9536-678076<wbr>2c2efa 2017-12-01 21:38:57.673120 [DEBUG] sofia.c:7077 Channel sofia/external/+4912121212 skipping state [ready][488]</blockquote></div><div><div><div class="gmail-m_2135769695358497393m_2764706872542973847gmail-m_-4014305031428489647m_-8563254385554287724gmail_signature"><div dir="ltr"><div dir="ltr"><br><br></div><div>Carrier confirmed that T.38 is possible... What could be the cause for this? How can I enforce T.38 instead of falling back to g711a (hangup on failed invite)?</div><div><br></div><div>Thanks.</div><div dir="ltr"><br></div><div dir="ltr">Kind regards,<br>Kevin</div></div></div></div>
</div></div>
<br></div></div>______________________________<wbr>______________________________<wbr>_____________<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" rel="noreferrer" target="_blank">http://www.freeswitchsolutions<wbr>.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.o<wbr>rg</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" target="_blank">FreeSWITCH-users@lists.freeswi<wbr>tch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/ma<wbr>ilman/listinfo/freeswitch-user<wbr>s</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.frees<wbr>witch.org/mailman/options/free<wbr>switch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br></blockquote></div><br></div>
<br>______________________________<wbr>______________________________<wbr>_____________<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" rel="noreferrer" target="_blank">http://www.freeswitchsolutions<wbr>.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.o<wbr>rg</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" target="_blank">FreeSWITCH-users@lists.freeswi<wbr>tch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/ma<wbr>ilman/listinfo/freeswitch-user<wbr>s</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.frees<wbr>witch.org/mailman/options/free<wbr>switch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br></blockquote></div><br></div></div></div></div></div>
</blockquote></div><br></div></div></div></div>
</blockquote></div><br></div></div>