On Sun, Apr 6, 2014 at 4:08 PM, <
mser...@gmail.com> wrote:
> Let's start with the problem. The outgoing SDP packet doesn't differ at all
> when choosing sendrate=63 or sendrate=53, what differs though is the actual
> RTP packet sent from the Asterisk box once call is connected. In my case
> when connecting to a carrier in this case, I will see incoming 6.3 packets,
> but outgoing 5.3 packets - is that a bug in the Asterisk version I'm using
> (Asterisk 12.1.1), or a known case with no fix?
I would say there is no fix.
1. Asterisk codec API is 'codec_to_linear(binary): binary' and
'linear_to_codec(binary): binary' in nutshell. There is no way for
codec to participate in negotiation or influence session setup. Also,
no per-peer settings are possible thus global flag.
2. Incoming and outgoing legs of the call knows nothing about each
other. I.e. the coder and decoder are allocated independently by
Asterisk, so the codec cannot match peer settings.
3. IIRC, independently of chosen rate the SDP is the same. Is it different?
4. IIRC again, the peer must decode both codecs if it claims G.723.1 support.
For API details see Asterisk sources include/asterisk/translate.h.
> The other questions are VAD/SamplingRate etc... related - is it possible to
> play with the outgoing SDP a-line configurations? Such as removing the
> annexa line, manipulating the silencesupp line, chaning the codecs' sampling
> rate etc...?
That would be Asterisk SIP stack facilities, not the codec -
consequence of (1) above.