Codec help!!

inbound call pass through lua file for bridge to another number, Looks one channel picks PCMU and the other took G729. 

Is this because of misconfiguration (or) is this normal? And my call quality is not okay. 

This happens to rtmp calls too.

Please advice me to setup properly.


DID call :

"Unavailable","+16613804913","+19840483100","public","2012-10-01 14:39:21","2012-10-01 14:39:29","2012-10-01 14:41:39","138","130","NORMAL_CLEARING","c9841afa-0bd5-11e2-8266-292d0bf811c2","","","G729","G729"
"Unavailable","+16613804913","+19665108963","public","2012-10-01 14:39:21","2012-10-01 14:39:29","2012-10-01 14:41:39","138","130","NORMAL_CLEARING","c9818a10-0bd5-11e2-8262-292d0bf811c2","c9841afa-0bd5-11e2-8266-292d0bf811c2","","PCMU","PCMU"

RTMP call :

"","0000000000","+19884730340","rtmp","2012-10-01 14:06:56","2012-10-01 14:07:11","2012-10-01 14:07:39","43","28","NORMAL_CLEARING","42246f00-0bd1-11e2-8245-292d0bf811c2","","","G729","G729"
"","0000000000","+OG90000956","rtmp","2012-10-01 14:06:56","2012-10-01 14:07:11","2012-10-01 14:07:39","43","28","NORMAL_CLEARING","422253be-0bd1-11e2-8241-292d0bf811c2","42246f00-0bd1-11e2-8245-292d0bf811c2","","SPEEX","SPEEX"


Thanks,
Bala