[asterisk-users] strange delay behaviour in SIP call with same codec

Terry Wilson twilson at digium.com
Wed Oct 19 12:59:37 CDT 2011


> Hello,
> I have a strange audio delay behaviour when placing a call between two
> SIP devices using the same codec.
> In my example, I have two devices forced to use GSM codec.
> When placing a call, the first ~9sec have no audio, then the audio
> starts trasmitting.
> If I force one phone to use GSM and the other ULAW/ALAW, everything
> works fine.

If I had to guess, I'd say that you don't have canreinvite/directmedia=no in sip.conf and there is possibly a NAT between the phones and Asterisk. When they have the same codec and directmedia is enabled, the phones will try to communicate directly to each other. It sounds like it is taking a while for firewalls to allow this traffic through (since both phones have to send packets out to the other before the whole is opened up in many setups). When the codecs are forced to be different, the media will go through Asterisk to get to the phones instead, alleviating your issue.

Terry



More information about the asterisk-users mailing list