[asterisk-users] Per DID Codec Negotiation
Thomas Kenyon
digium at sanguinarius.co.uk
Thu Aug 31 10:36:02 MST 2006
Damien Gabrielson wrote:
> Hi Everyone,
>
> From my research I believe I am asking the impossible but perhaps I am
> missing something. Any help would be greatly appreciated.
>
> I receive many DIDs from the same SIP provider coming from the same IP.
> I have a peer setup in sip.conf for this provider and this is where the
> codec negotiation happens. The problem comes in when I have to send a
> given SIP call to a device that only accepts g729. I have to accept ulaw
> from the provider so that fax will work and transcoding to g729 is not a
> good option because it takes up CPU resources and costs extra money.
> Since the provider supports g729, I would like to receive calls for some
> DIDs as g729 and the rest as ulaw. Is there any possible way to have
> this kind of configuration when all the DIDs come from the same IP and
> there is no SIP registration? As a side note, if I accepted the calls
> through IAX from the provider and sent them out as SIP, would this help?
>
I could be wrong, but I believe this is being addressed soon. (not in
1.4 release).
Assuming the SIP provider supports this, you would offer both codecs,
and then the terminating device would only accept one type, then there
will be a renegotiation so that all the traffic uses the same codec.
ie. call comes in from provider as G.711u, G.711a, G.726, G.729a, iLBC
Your asterisk box allows G.711u and G.729.
The call is terminated to a SIP device that only supports G.729.
Then the call gets renegotiated as G.729 all the way from provider to
device.
(And the same with G.711u).
This way you make the fax ATA G.711u only and the SIP handsets G.729
only and allow both.
This doesn't work yet, but is apprently in the pipeline.
In the meantime, I'd suggest using 2 sets of credentials in sip.conf
from the SIP provider and change the SIP address the provider terminates
to accordingly.
More information about the asterisk-users
mailing list