Why asterisk not properly working with android sip client?

橙三吉。 提交于 2019-12-04 11:58:21

Thanks for every one in this forum for anticipating...I have manged to solve the problem...The two devices "xlite/zoiper" and "android native sip" client uses different default audio codecs.

default codec for xlite is BroadVoice-32

default codec for zoiper is GSM

default codec for android is G.711 uLaw

As these devices should use same codec while communicating with each other..In my scenario these devices were using different codecs which results in one way audio (when calling from android to xlite/zoiper). While creating the SIP accounts in sip.conf while we can enforce two communicating clients to use same audio codec in following manner.

[211]
deny=0.0.0.0/0.0.0.0
secret=123456
dtmfmode=rfc2833
canreinvite=no
context=incoming-calls-wildcard
host=dynamic
nat=yes
type=friend
port=5060
qualify=yes
callgroup=
pickupgroup=
permit=0.0.0.0/0.0.0.0
callcounter=yes
faxdetect=no
disallow=all    (disable default audio codec)
allow=ulaw   (allow uLaw audio codec)



[215]
deny=0.0.0.0/0.0.0.0
secret=123456
dtmfmode=rfc2833
canreinvite=no
context=incoming-calls-wildcard
host=dynamic
nat=no
type=friend
port=5060
qualify=yes
callgroup=
pickupgroup=
permit=0.0.0.0/0.0.0.0
callcounter=yes
faxdetect=no
disallow=all    (disable default audio codec)
allow=ulaw   (allow uLaw audio codec)

We can also configure audio codec settings on client side by selecting the same audio codec on both sides..

Well,

Configuration wise, it appear that your configuration is ok. However, what seems odd to me is the following IP address inside your trace - 115.167.21.82

Can you please elaborate what this IP address is? My assumption is that you are located behind a NAT firewall and this is your external IP address. In that case, look in /etc/asterisk/sip.conf for the "localnet" definition, and define your local network address range.

When working with Elastix, it is able to setup that one automatically - but when doing a manual install, you have to set that one up.

Nir S

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!