Forcing a Codec on IAX

Hi guys, I’m running A@H with a iax2 trunk connecting to voipjet and was wondering…How do you force all the phones connected to asterisk to use the iLBC codec instead of the G.711 codec?

I’e tried the following in the iax.conf file:

Didn’t work…then in my trunk outgoing settings I added the following:


I’m using XLite and even setting the order of the iLBC codec to no1 doesn’t solve the problem, the call quality suck! When I use my Voipjet account directly without going through the A@H everything works 100% with excellent quality.

Another question…Changing the iax.conf file will not effect the codec’s used on the lan? Where do you set the codec to be used on the internal asterisk network?

This should only allow ilbc codec. Try putting this in the user/friend configuration.
Also when you connect to the asterisk command line interface you will see what codecs are actually used.

Sorry…stupid question…How do I see what codec was used by an extension?

The 'Format' column will show the codec used.

The ‘Format’ column will show the codec used.

Oh Xlite sorry, that’s SIP. Very similar then:

Look in the ‘Form’ column.