[Asterisk-Users] Codec problems (SIP)
Jorge Mendoza
mendoza at tcc.com.pe
Wed Jan 14 12:56:23 MST 2004
Terence Parker wrote:
> Hi again,
>
> Thanks for your help. Unfortunately that did not seem to solve the
> problem. After a bit of fiddling around, this is what i've managed to
> achieve with my asterisk setup so far.
>
>
> 1. With "allow=all" in sip.conf, nothing seems to work - not even
> voicemail. The following is sample output:
>
> Executing Ringing("SIP/TerenceParker-1af0", "") in new stack
> -- Executing Wait("SIP/TerenceParker-1af0", "2") in new stack
> -- Executing VoiceMailMain("SIP/TerenceParker-1af0", "") in new stack
> -- Playing 'vm-login' (language 'en')
> WARNING[278546]: File app_voicemail.c, Line 2707 (vm_execmain): Couldn't
> read username
> == Spawn extension (sip, 86, 3) exited non-zero on 'SIP/TerenceParker-1af0'
>
> - Why should this happen? Surely with everything enabled, any coded
> should work!
>
This log is not relate to codec problem.
>
> 2. With disallow=all ; allow=alaw ; allow=ulaw ; allow=g729 ; allow=gsm
> (and i've also tried without some of those and various combinations):
>
> Executing Ringing("SIP/TerenceParker-af02", "") in new stack
> -- Executing Wait("SIP/TerenceParker-af02", "2") in new stack
> -- Executing VoiceMailMain("SIP/TerenceParker-af02", "") in new stack
> -- Playing 'vm-login' (language 'en')
> NOTICE[278546]: File channel.c, Line 1478 (ast_set_read_format): Unable
> to find a path from G729A to ULAW
> NOTICE[278546]: File channel.c, Line 1448 (ast_set_write_format): Unable
> to find a path from GSM to G729A
> WARNING[278546]: File chan_sip.c, Line 1182 (sip_write): Asked to
> transmit frame type 4, while native formats is 256 (read/write = 4/2)
> WARNING[278546]: File file.c, Line 521 (ast_readaudio_callback): Failed
> to write frame
> NOTICE[278546]: File channel.c, Line 1448 (ast_set_write_format): Unable
> to find a path from ULAW to G729A
> WARNING[278546]: File file.c, Line 170 (ast_stopstream): Unable to
> restore format back to 4
> WARNING[278546]: File app_voicemail.c, Line 2707 (vm_execmain): Couldn't
> read username
> == Spawn extension (sip, 86, 3) exited non-zero on 'SIP/TerenceParker-af02'
>
> - I don't understand this as, surely, I have already enabled g729a and
> ulaw ... how can it complain that it can't transmit in that format, or
> that it can't find a path?
>
How do you got the g729 codec? * does not include it. You must to pay
for that.
> 3. With the default settings (i.e. no allow OR disallow clause) normal
> IP to IP calls work fine. Calls to voicemail also works fine with no
> problems. However, PSTN calls through my Voicetronix card or calls
> routed through FWD fail to work. This is what happens when I dial out
> with my voicetronix card:
>
> Executing Dial("SIP/TerenceParker-22f3", "vpb/1-1/18501") in new stack
> Read_channel ## vpb/1-1: Setting record mode, bridge = 0
> -- 1-1 requested, got: [vpb/1-1]
> -- Calling 1-1/18501 on vpb/1-1
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> -- VPB Calling 1-1/18501 [t=0] on vpb/1-1 returned 0
> -- Called 1-1/18501
> WARNING[278546]: File chan_sip.c, Line 1182 (sip_write): Asked to
> transmit frame type 8, while native formats is 4 (read/write = 4/4)
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> -- vpb/1-1 is ringing
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> Read_channel vpb/1-1 (state=0), res=0, bridge=1
> Read_channel ## vpb/1-1: Setting record mode, bridge = 0
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> Read_channel vpb/1-1 (state=5), res=0, bridge=1
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> Read_channel vpb/1-1 (state=5), res=0, bridge=1
> -- Event [12=>[00] Loop Drop
> ] on vpb/1-1
> -- vpb/1-1 handle_owned got event: [12=>0]
> -- handle_owned: putting frame: [-1=>0], bridge=(nil)
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> Read_channel vpb/1-1 (state=5), res=0, bridge=1
> WARNING[278546]: File app_dial.c, Line 279 (wait_for_answer): Unable to
> forward frame
> Read_channel vpb/1-1 (state=5), res=0, bridge=1
> -- Event [102=>[00] Dial End
> ] on vpb/1-1
> -- vpb/1-1 handle_owned got event: [102=>0]
> -- handle_owned: putting frame: [4=>4], bridge=(nil)
> -- vpb/1-1 answered SIP/TerenceParker-22f3
> -- hangup on vpb (vpb/1-1)
> Read_channel vpb/1-1 (state=5), res=0, bridge=1
> Read_channel vpb/1-1 (state=6), res=-1, bridge=1
> Read_channel vpb/1-1 terminating, stopreads=1, owner=yes
> -- Hungup on vpb/1-1 complete
> == Spawn extension (sip, 918501, 1) exited non-zero on
> 'SIP/TerenceParker-22f3'
>
> - again, it complains about codecs. So, at the moment, I am utterly
> confused!
>
> Any help would be gratefully appreciated.
>
Verify if you sip phone has codec alaw as preferred codec.
The conf below works for me.
> Terence
>
>
>
> On 13 Jan 04, at 1:39 AM, Jorge Mendoza wrote:
>
> Try in sip.conf:
>
> disallow=all
> allow=alaw
> allow=ulaw
> allow=gsm
>
> (in that order)
> I never tried with FWD
>
> Jorge
>
More information about the asterisk-users
mailing list