Codec negotiation issue (no audio format found to offer)

Home » Asterisk Users » Codec negotiation issue (no audio format found to offer)
Asterisk Users 1 Comment

Running build 1.8.5.0 (compiled from source) I seem to be having an issue
with codec negotiation. I have a Grandstream HT503 FXO port connected to a
pstn line, a Polycom SP501, and a SIP trunk with callwithus.

What I’m essentially looking to accomplish is for ulaw or g729 (preferably
ulaw) to be used to the Grandstream FXO or any other internal endpoint, and
for g729 only to be used outbound to my SIP trunk.

Here are the basics of my config, showing the codec list from “sip show peer “:

Polycom SP501 (desk phone):

One thought on - Codec negotiation issue (no audio format found to offer)

  • Thanks for the reply David,

    I guess I don’t understand an issue in implementing the offer/answer model
    (rfc3264). If asterisk receives an invite and knows the egress peer’s
    capabilities, why not respond to the sdp in the initial invite with modified
    sdp containing only g729?

    So asterisk knows that it is going to dial a peer that supports only g729
    when it gets an invite from a peer that supports both ulaw and g729. Using
    the offer / answer model it would look like this:

    Peer -> Invite (SDP:ulaw,g729) -> Asterisk
    Peer < - 100 Trying (w/ SDP -- g729 only) <- Asterisk
    Peer -> 200 OK (w/ SDP g729) -> Asterisk

    I understand your point about not knowing what may happen after initial call
    setup, but the same implementation would apply in the event of a reinvite.

    Maybe this could be an option (allow_rfc3264=yes or something of that
    nature).

    Thanks again,

    -Ryan