This link may be helpful to OP - 
http://www.the-asterisk-book.com/unstable/funktionen-callerid.html#ftn.id2546149
 :  When you look for DNID on an incoming call, life is generally good.  On 
outgoing calls it’s a crap shoot.  Another “out of the box” suggestion;  run an 
‘asterisk –rx “core show channels verbose”’ and match the caller ID from that 
output.  Since you are already in an AGI,  it shouldn’t be more than 10-20 more 
lines of code. 

 

From: [email protected] 
[mailto:[email protected]] On Behalf Of Mikhail Lischuk
Sent: Thursday, March 29, 2012 2:17 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] AGI variables being wrong

 

Warren Selby писал 29.03.2012 20:20:

 I'd be really curious to see the entire CLI log of the call, with verbose set 
to 6 and AGI debug enabled, from when the call first comes in to when it's hung 
up, including the execution of the *9 feature code.  Also, knowing which 
version of Asterisk and DAHDI we're dealing with here couldn't hurt

The output is pretty same. I can enable DTMF debugging, but can't imagine how 
could it help us:

-- Launched AGI Script /etc/asterisk/agi/map.pl
AGI Tx >> agi_request: /etc/asterisk/agi/map.pl
AGI Tx >> agi_channel: Zap/63-1
AGI Tx >> agi_language: en
AGI Tx >> agi_type: Zap
AGI Tx >> agi_uniqueid: 1333048969.6682
AGI Tx >> agi_callerid: 0442010000
AGI Tx >> agi_calleridname: unknown
AGI Tx >> agi_callingpres: 3
AGI Tx >> agi_callingani2: 0
AGI Tx >> agi_callington: 0
AGI Tx >> agi_callingtns: 0
AGI Tx >> agi_dnid: 408
AGI Tx >> agi_rdnis: unknown
AGI Tx >> agi_context: from_pstn
AGI Tx >> agi_extension:
AGI Tx >> agi_priority: 1
AGI Tx >> agi_enhanced: 0.0
AGI Tx >> agi_accountcode:
AGI Tx >>
AGI Tx >> 200 result=0 (i hang up the call)


To the OP - just trying to think outside the box here, but what if instead of 
calling the AGI directly from the features.conf feature code, you wrote a Macro 
or GoSub that you could then use as your application, and within the Macro / 
GoSub you executed your AGI?

I'd love to, but I need that script to run only when user hits some key combo 
during call. All I was able to find regarding that, was using features.conf and 
dynamic application. If you can advise me some workaround - I would appreciate.

-- 
With Best Regards
Mikhail Lischuk <mailto:[email protected]> 
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
               http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to