Distorted audio with g722

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You are really "talking" at 16kHz. Please see
http://tools.ietf.org/html/rfc3551#page-14 for an explanation. To
paraphrase: the RTP clock rate for G.722 was incorrectly specified in an
old RFC as 8000. However since it has been around a long time the RFC
has officially /kept/ this error around for compatibility reasons. Cute huh?

As to the distortion problems, unfortunately I have no ideas for you. :-(

Saul Ibarra Corretge wrote:
> Hi!
>
> I was testing g722 codec and I'm facing some distortion when trying the ZipDX demo (sip:wbdemo at conf.zipdx.com) I've gone though the bug tracked and found this issue regarding the clock rate (http://trac.pjsip.org/repos/ticket/486) however PJSUA is telling me that I'm using 16KHz:
>
> Intive is correct:
> INVITE sip:wbdemo at conf.zipdx.com SIP/2.0
> Via: SIP/2.0/UDP 10.10.10.2:5060;rport;branch=z9hG4bKPjbNXyvh9iXDA8cdVGfW63Wq8QEh2zMQUQ
> Max-Forwards: 70
> From: <sip:10.10.10.2>;tag=sk0bfd-EK92bJwKVasEXH1PKLYOKN6sO
> To: sip:wbdemo at conf.zipdx.com
> Contact: <sip:10.10.10.2:5060>
> Call-ID: 2KdBxLWweGZkzXu4b5Vjv6tESipzzgMq
> CSeq: 18006 INVITE
> Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
> Supported: replaces, 100rel, timer, norefersub
> Session-Expires: 1800
> Min-SE: 90
> User-Agent: PJSUA v1.4-trunk/i386-apple-darwin10.2.0
> Content-Type: application/sdp
> Content-Length:   453
>
> v=0
> o=- 3468657952 3468657952 IN IP4 10.10.10.2
> s=pjmedia
> c=IN IP4 10.10.10.2
> t=0 0
> a=X-nat:0
> m=audio 4002 RTP/AVP 103 102 104 113 3 0 8 9 101
> a=rtcp:4003 IN IP4 10.10.10.2
> a=rtpmap:103 speex/16000
> a=rtpmap:102 speex/8000
> a=rtpmap:104 speex/32000
> a=rtpmap:113 iLBC/8000
> a=fmtp:113 mode=30
> a=rtpmap:3 GSM/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:8 PCMA/8000
> a=rtpmap:9 G722/8000
> a=sendrecv
> a=rtpmap:101 telephone-event/8000
> a=fmtp:101 0-15
>
> 200OK also:
> SIP/2.0 200 Ok
> Via: SIP/2.0/UDP 10.10.10.2:5060;received=81.204.182.64;branch=z9hG4bKPjbNXyvh9iXDA8cdVGfW63Wq8QEh2zMQUQ;rport=12528
> From: <sip:10.10.10.2>;tag=sk0bfd-EK92bJwKVasEXH1PKLYOKN6sO
> Call-ID: 2KdBxLWweGZkzXu4b5Vjv6tESipzzgMq
> CSeq: 18006 INVITE
> To: sip:wbdemo at conf.zipdx.com;tag=telStage-39d294b6-4b1506a0
> Content-Length: 205
> Content-Type: application/sdp
> Allow: INVITE, ACK, CANCEL, BYE, REFER, NOTIFY, OPTIONS, INFO, REGISTER, SUBSCRIBE, MESSAGE
> Session-Expires: 1800;refresher=uas
> Contact: <sip:76.74.151.123;transport=udp>
> Server: ZipDX-3.10.4
> Supported: timer
>
> v=0
> o=telStage 1781 3468657952 IN IP4 76.74.151.123
> s=-
> c=IN IP4 76.74.151.123
> t=0 0
> m=audio 12596 RTP/AVP 9 101
> a=rtpmap:9 G722/8000
> a=rtpmap:101 telephone-event/8000
> a=fmtp:101 0-15
> a=ptime:20
>
> But when I see the call quality (dq in pjsua) I see that audio is in 16KHz:
>   
>>>> dq
>>>>         
>  13:06:44.445    pjsua_app.c  
>   [CONFIRMED] To: sip:wbdemo at conf.zipdx.com;tag=telStage-39d294b6-4b1506a0
>     Call time: 00h:00m:52s, 1st res in 322 ms, conn in 328ms
>     SRTP status: Not active Crypto-suite: (null)
>     #0 G722 @16KHz, sendrecv, peer=76.74.151.123:12596
>        RX pt=9, stat last update: 00h:00m:00.068s ago
>           total 2.6Kpkt 416.1KB (520.2KB +IP hdr) @avg=64.0Kbps/80.0Kbps
>           pkt loss=0 (0.0%), discrd=1 (0.0%), dup=0 (0.0%), reord=1 (0.0%)
>                 (msec)    min     avg     max     last    dev
>           loss period:   0.000   0.000   0.000   0.000   0.000
>           jitter     :   0.000   2.863  70.625   5.375   2.654
>        TX pt=9, ptime=20ms, stat last update: 00h:00m:11.333s ago
>           total 1.3Kpkt 222.2KB (277.8KB +IP hdr) @avg 34.1Kbps/42.7Kbps
>           pkt loss=10 (0.7%), dup=0 (0.0%), reorder=0 (0.0%)
>                 (msec)    min     avg     max     last    dev 
>           loss period: 200.000 200.000 200.000 200.000   0.000
>           jitter     :   2.375   2.500   2.625   2.500   0.088
>       RTT msec       :   0.000   0.000   0.000   0.000   0.000
>
> Is it just a "printing bug" or am I really talking at 16KHz? Any clue of what could be causing that distortion? 
>
> Let me know if I can provide more information on this.
>
>
> Thanks in advance,
>
>   


-- 
Jens B. Jorgensen
jbj1 at ultraemail.net




[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux