Hi. Im having trouble setting variables in channel dialplan and re-using them in Extension dialplan... Im using the following call file: Channel: Local/210332450 at ZonNew-Outbound CallerID: ZonNew-Outbound:49:210332450: MaxRetries: 5 RetryTime: 10 WaitTime: 60 Account: Outbound210332450 Context: agents Extension: 888210332450 Set: __PARTNER=ZonNew-Outbound Set: NUMBER=210332450 - In "Local/210332450 at ZonNew-Outbound" I Set(bla='blabla'); It seems I cannot re-use this var in extension _888XXXXXXXXX in context agents... Basically the Channel dialplan has a Queue() and in _888XXXXXXXXX I would like to know the peer (or interface) that answered it... What can I do? Thanks in advance -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20110423/177a7e68/attachment.htm>
Hi, Using DumpChan(); Seems that Channel (where the call goes first) is a sub-channel of Context/Extension (where the call goes on CONNECT) ?? first I have: Dumping Info For Channel: Local/210332450 at ZonNew-Outbound-66c7;2: Then after: Dumping Info For Channel: Local/210332450 at ZonNew-Outbound-66c7;1: Help ? On 23 April 2011 17:20, Tiago Geada <tiago.geada at gmail.com> wrote:> Hi. > > Im having trouble setting variables in channel dialplan and re-using them > in Extension dialplan... > > Im using the following call file: > > Channel: Local/210332450 at ZonNew-Outbound > CallerID: ZonNew-Outbound:49:210332450: > MaxRetries: 5 > RetryTime: 10 > WaitTime: 60 > Account: Outbound210332450 > Context: agents > Extension: 888210332450 > Set: __PARTNER=ZonNew-Outbound > Set: NUMBER=210332450 > > > - > > In "Local/210332450 at ZonNew-Outbound" I Set(bla='blabla'); > > It seems I cannot re-use this var in extension _888XXXXXXXXX in context > agents... > > > Basically the Channel dialplan has a Queue() and in _888XXXXXXXXX I would > like to know the peer (or interface) that answered it... What can I do? > > Thanks in advance >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20110423/5c434265/attachment.htm>
On Sat, Apr 23, 2011 at 11:20 AM, Tiago Geada <tiago.geada at gmail.com> wrote:> Hi. > > Im having trouble setting variables in channel dialplan and re-using them > in Extension dialplan... > > Im using the following call file: > > Channel: Local/210332450 at ZonNew-Outbound > CallerID: ZonNew-Outbound:49:210332450: > MaxRetries: 5 > RetryTime: 10 > WaitTime: 60 > Account: Outbound210332450 > Context: agents > Extension: 888210332450 > Set: __PARTNER=ZonNew-Outbound > Set: NUMBER=210332450 > > > - > > In "Local/210332450 at ZonNew-Outbound" I Set(bla='blabla'); > > It seems I cannot re-use this var in extension _888XXXXXXXXX in context > agents... > > > Basically the Channel dialplan has a Queue() and in _888XXXXXXXXX I would > like to know the peer (or interface) that answered it... What can I do? > > Thanks in advance > >I'm a little confused by "It Seems I cannot re-use this var in extension _888XXXXXXXXXX in context agents"....Of course you can use it...but if you set bla to a different value in your code where your callfile is processed, Asterisk will (rightfully so) just set bla = to whatever you set it to.... Now, if the callfile doesn't send a channel "through" the context that you're trying to set blah, that's a little odd... Now, as far as retrieving the information about the interface that answered the call....look in queues.conf.sample....there's a nifty configuration option: *setinterfacevar=no ; (the default is no)* That option, when set to yes, causes several variables to be created *just*prior to the caller being bridged with the queue member... -- Sherwood McGowan Telecommunications and VOIP Consultant -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20110423/852df608/attachment.htm>