如何将G722改为PCMA编解码器?

时间:2016-09-06 08:49:09

标签: webrtc sip freeswitch

我正在使用FreeSWITCH-mod_sofia / 1.6.9~64bit + SIPJS库(http://sipjs.com/)+ Chrome版本52.0.2743.116(64位)。

当我拨打电话时,日志显示编解码器G722。如何将webrtc首选项更改为PCMA?

这是来自浏览器和pbx的日志:

v=0
o=FreeSWITCH 1473140673 1473140674 IN IP4 46.101.211.231
s=FreeSWITCH
c=IN IP4 46.101.211.231
t=0 0
a=msid-semantic: WMS bq8r7nsrBp8WZadawhiSfNUqsNZvBk2D
a=end-of-candidates
m=audio 20640 UDP/TLS/RTP/SAVPF 9 126
a=rtpmap:9 G722/8000
a=rtpmap:126 telephone-event/8000
a=ptime:20
a=fingerprint:sha-256 55:88:C7:12:0B:4C:68:25:0F:24:10:49:CE:B6:C7:3F:26:1B:DA:7D:3D:F9:CE:F9:83:BE:7D:85:77:CD:D9:CB
a=setup:active
a=rtcp-mux
a=rtcp:20640 IN IP4 46.101.211.231
a=ice-ufrag:EqTJ3DZmgPHIZAbp
a=ice-pwd:sWOwZt3i8mqMIyNcOwMI0BV6
a=candidate:4112214570 1 udp 659136 46.101.211.231 20640 typ host generation 0
a=ssrc:2815440288 cname:A1UyedPGsOthOwha
a=ssrc:2815440288 msid:bq8r7nsrBp8WZadawhiSfNUqsNZvBk2D a0
a=ssrc:2815440288 mslabel:bq8r7nsrBp8WZadawhiSfNUqsNZvBk2D
a=ssrc:2815440288 label:bq8r7nsrBp8WZadawhiSfNUqsNZvBk2Da0

sip-0.7.5.min.js:36 Tue Sep 06 2016 14:28:33 GMT+0300 (EEST) | sip.dialog | ivnr8mmnv402egp0rirsng7rg9apkhyZp6ag8m93gve | new UAC dialog created with status EARLY
sip-app-abd8abe655.js:259 Call status: Calling...
application-3c30b3ee30.js:2853 Timer.start();
application-3c30b3ee30.js:2853 Timer.reset();
sip-0.7.5.min.js:36 Tue Sep 06 2016 14:28:33 GMT+0300 (EEST) | sip.transport | received WebSocket text message:

SIP/2.0 488 Not Acceptable Here
Via: SIP/2.0/WSS e3j3u9l0okm1.invalid;branch=z9hG4bK1519134;received=79.142.124.66;rport=63166
Max-Forwards: 70
From: "S S1" sip:C1-U30@CP1.sip.tech.com;tag=ng7rg9apkh
To: sip:867207276@CP1.sip.tech.com;tag=yZp6ag8m93gve
Call-ID: ivnr8mmnv402egp0rirs
CSeq: 8719 INVITE
User-Agent: FreeSWITCH-mod_sofia/1.6.9~64bit
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY
Supported: path, replaces
Allow-Events: talk, hold, conference, refer
Reason: Q.850;cause=88;text="INCOMPATIBLE_DESTINATION"
Content-Length: 0
Remote-Party-ID: "867207276" sip:867207276@CP1.sip.tech.com;party=calling;privacy=off;screen=no

v=0
o=- 17331602012762722 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE audio
a=msid-semantic: WMS qK3WgAq68b2Mu9e80AUclmR3NG02WYNQiSUf
m=audio 61461 UDP/TLS/RTP/SAVPF 111 103 104 9 0 8 106 105 13 126
c=IN IP4 79.142.124.66
a=rtcp:53127 IN IP4 79.142.124.66
a=candidate:555938122 1 udp 2122260223 192.168.88.186 61461 typ host generation 0 network-id 1
a=candidate:555938122 2 udp 2122260222 192.168.88.186 53127 typ host generation 0 network-id 1
a=candidate:3987721945 2 udp 1686052606 79.142.124.66 53127 typ srflx raddr 192.168.88.186 rport 53127 generation 0 network-id 1
a=candidate:3987721945 1 udp 1686052607 79.142.124.66 61461 typ srflx raddr 192.168.88.186 rport 61461 generation 0 network-id 1
a=candidate:1872825786 1 tcp 1518280447 192.168.88.186 9 typ host tcptype active generation 0 network-id 1
a=candidate:1872825786 2 tcp 1518280446 192.168.88.186 9 typ host tcptype active generation 0 network-id 1
a=ice-ufrag:TagGNVyjjTVGdD0Y
a=ice-pwd:KjWwT6coB1eEBJJUW7LszseM
a=fingerprint:sha-256 80:33:0A:04:F4:ED:88:FF:08:A7:E2:A3:CF:89:56:17:FF:39:B8:D0:EC:D3:91:33:CE:A4:65:E5:BE:1A:D1:17
a=setup:actpass
a=mid:audio
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=sendrecv
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=rtcp-fb:111 transport-cc
a=fmtp:111 minptime=10;useinbandfec=1
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:9 G722/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:106 CN/32000
a=rtpmap:105 CN/16000
a=rtpmap:13 CN/8000
a=rtpmap:126 telephone-event/8000
a=ssrc:3472270343 cname:W3v1/RPNLku0GWlP
a=ssrc:3472270343 msid:qK3WgAq68b2Mu9e80AUclmR3NG02WYNQiSUf 39017066-29e8-4452-85a1-f0f92b66f0c6
a=ssrc:3472270343 mslabel:qK3WgAq68b2Mu9e80AUclmR3NG02WYNQiSUf
a=ssrc:3472270343 label:39017066-29e8-4452-85a1-f0f92b66f0c6

1 个答案:

答案 0 :(得分:0)

第一个SDP看起来像从FS服务器到浏览器。在FS拨号计划中桥接之前,请尝试setting inherit_codec

如果启用了延迟协商,并且您在A支路上设置了inherit_codec = true,则B支路的协商编解码器将被强制转移到A支路上。