[Freeswitch-users] Distorted sound with JsSIP WebRTC and latest freeswitch

Jayesh Nambiar jayesh1017 at gmail.com
Fri Mar 7 14:07:50 MSK 2014


Hi,
I've been working on Freeswitch and WebRTC applications for quite some
time. I was working on Freeswitch version *(git c811580 2013-09-06
00:55:50Z)* and the voice quality was always good with that version.
Today I upgraded to the latest master version *(git f9f3699 2014-03-07
04:32:56Z 64bit)* and suddenly the sound that goes out of the WebRTC client
is always distorted/choppy. I also tried with few versions which got
committed in February but they also had choppy sound.

The call scenario is as follows:
Normal SIP Endpoint calls a WebRTC endpoint. I have enforced PCMU for the
leg going towards WebRTC as I had read about some problems using OPUS codecwith
freeswitch here https://code.google.com/p/webrtc/issues/detail?id=2768.
My outgoing dial-string looks as below:
{sip_invite_domain=${context},absolute_codec_string=PCMU,media_webrtc=true}sofia/
abc.com/${sip_req_uri}

Sofia parameters are as follows:
<param name="sip-trace" value="off"/>
<param name="log-auth-failures" value="true"/>
<param name="sip-ip" value="203.XXX.123.57"/>
<param name="rtp-ip" value="203.XXX.123.57"/>
<param name="sip-port" value="5000"/>
<param name="context" value="abc.com"/>
<param name="dtmf-type" value="rfc2833"/>
<param name="rfc2833-pt" value="101"/>
<param name="dtmf-duration" value="2000"/>
<param name="caller-id-in-from" value="true"/>
<param name="caller-id-type" value="pid"/>
<param name="suppress-cng" value="true"/>
<param name="inbound-codec-prefs" value="OPUS,G722,PCMU,PCMA"/>
<param name="outbound-codec-prefs" value="PCMU,PCMA"/>
<param name="rtp-timeout-sec" value="300"/>
<param name="rtp-hold-timeout-sec" value="300"/>
<param name="outbound-use-uuid-as-callid" value="true"/>

I generally encountered such distorted quality with WebRTC when CN was
advertised in SDP going towards JS-SIP. This is the reason I added suppress-
sng as true in the profile. My outgoing SDP is as follows:

v=0.
o=FreeSWITCH 1394161698 1394161699 IN IP4 203.XXX.123.57.
s=FreeSWITCH.
c=IN IP4 203.XXX.123.57.
t=0 0.
a=msid-semantic: WMS lBMrtzG9kpA0bTRb2XqCeNEeEVGsBGsM.
m=audio 17482 RTP/SAVPF 0 101.
a=rtpmap:101 telephone-event/8000.
a=fingerprint:sha-256
A2:DD:5A:FE:03:98:BB:59:A5:67:EE:D2:B1:DF:B9:E7:84:7C:D0:1D:C2:68:39:EF:60:E6:5B:48:E9:72:CB:5B.
a=rtcp-mux.
a=rtcp:17482 IN IP4 203.XXX.123.57.
a=ssrc:2871096156 cname:744rtBqDQQuSAcTt.
a=ssrc:2871096156 msid:lBMrtzG9kpA0bTRb2XqCeNEeEVGsBGsM a0.
a=ssrc:2871096156 mslabel:lBMrtzG9kpA0bTRb2XqCeNEeEVGsBGsM.
a=ssrc:2871096156 label:lBMrtzG9kpA0bTRb2XqCeNEeEVGsBGsMa0.
a=ice-ufrag:09V4Nq9hcFADbSg9.
a=ice-pwd:Maq6BHzioU0OWK7M.
a=candidate:5046006301 1 udp 659136 203.XXX.123.57 17482 typ host generation0.
a=candidate:5046006301 2 udp 659136 203.XXX.123.57 17482 typ host generation0.
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:
sV6KRgjWRIajcY4QqbNBQeUxxjh90KbdtfAwdmo2.
a=silenceSupp:off - - - -.
a=ptime:20.

Is there anything that I can add or remove to fix this quality problem or
any new channel variable related to webrtc that has been added but not
documented anywhere. The sound going towards JS-SIP sounds acceptable
butthe sound going outside JS-SIP is distorted. Any help here will be
appreciated as this quality problem doesn't allow me to move to new
versions and stay updated !!


Thanks,

--- Jayesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20140307/ef9fc69b/attachment.html 


Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users mailing list