[asterisk-users] AGI script fails on IAX channels (from call file).
Jonas Arndt
jonas_arndt at comcast.net
Sat Sep 15 11:04:57 CDT 2007
Tony Mountifield wrote:
> In article <46EAF68B.6070505 at comcast.net>,
> Jonas Arndt <jonas_arndt at comcast.net> wrote:
>
>> Call File
>> =================== Call File ==========================
>> channel: Local/3455 at internal
>> maxretries: 3
>> retrytime: 60
>> waittime: 60
>> callerid: "Test" <*66>
>> application: AGI
>> data: test.agi|670507
>> ================= End Call File ========================
>>
>
> Instead of calling the application directly from the call file, make a
> special extension for it, and call that extension instead:
>
> [foo]
> exten => _X.,1,Answer(0.5)
> exten => _X.,2,AGI(test.agi|${EXTEN})
>
> And then have the call file like this:
>
> Channel: Local/3455 at internal
> Maxretries: 3
> Retrytime: 60
> Waittime: 60
> CallerId: "Test" <*66>
> Context: foo
> Extension: 670507
> Priority: 1
>
> The Answer line may or may not be necessary, but if you find it is, that
> would explain why calling the AGI directly didn't work. In that case,
> perhaps you could put the Answer within the AGI.
>
> Cheers
> Tony
>
>
Hi Tony,
So the idea here is that the parameter, which I am calling the
application with, will be dynamic. I am therefore struggling a bit with
how your solution would work in the long run. It could be a good test
though. Your Extension line in the call file (670507) will match that in
the extensions.conf, right? What I have tried is
================ Call File ========================
channel: Local/3455 at internal
Context: internal
Extension: *66
Priority: 1
================================================
Then in the extensions.con
============= extensions.conf =====================
exten => *66,1,Answer
exten => *66,2,AGI(test.agi|670507)
exten => *66,3,Hangup
================================================
This is also not an elegant solution as I have hard coded the parameter.
However, it is just for test. As you can see I am also answering the
channel here. I have exactly the same problem here. On SIP phones it
work great and on IAX (iaxy) phones it fails. I can't get the AGI script
to see the DTMF even if pushing the keys generates events in an iax2
trace. So:
============================== Conclusions ================================
IAX Phone => Dial Plan => AGI script
"Works with DTFM"
Call File => IAX Phone + AGI script
"Fails, not DTMF communication"
Call File => IAX Phone + Extension in dial plan => AGI Script
"Fails, not DTMF communication"
SIP => Work always
============================== Conclusions ================================
Unfortunately I am heading out for a week long Europe trip on Monday.
I'll try to play with this a bit more on Sunday and see if I can make
some progress.
Thanks for you help,
// Jonas
More information about the asterisk-users
mailing list