[asterisk-users] Get calling channel before pickup

Marcus Carlson marcus at mejlamej.nu
Tue Jun 5 16:55:27 CDT 2007


Thanks for your answer, I've now investigated this further and it was 
really easy, it was right in front of my eyes...

Using the java library from asterisk-java.org it was extreamly easy, 
start monitoring on a new channel, check that to is ment for me and add 
a property listener for getDialingChannel() and there it was. The thing 
is I didn't get the original channel (when I make a call with LOCAL I've 
suddenly get four channels) and getDialingChannel returns one of the 
LOCAL ones, I don't think that would be a problem - but I haven't tried 
to redirect or hang it up yet.

Will also check out the dialing event more carefully, thanks.

Marcus

Mojo with Horan & Company, LLC wrote:
> I must be not understanding your question very well, because it seems 
> like an easy answer :)
> 
> In the following Dial event, we have Source and Destination.  Like Eric 
> said, Destination can contain multiple devices, so can't be trusted. But 
> Source should only contain one device....  Does it have data you can use?
> 
> Moj
> 
> Event: Dial
> Privilege: call,all
> Source: SIP/112-09823a58
> Destination: SIP/118-0986d4c0
> CallerID: 112
> CallerIDName: Mojo
> SrcUniqueID: 1181061393.53
> DestUniqueID: 1181061393.54
> 
> P.S.  I think you meant you wanted the channel that is HEARING the 
> ringing, not the channel that is IN the ringing state....?
> 
> Moj
> 
> Marcus Carlson wrote:
>> Hi,
>>
>> Is it possible to get the remote channelname that will be bridged when 
>> the call is answered, only having the channel that is in the Ring(ing) 
>> state? As far as I can see no variable seems to fit when doing the 
>> show channel command.
>>
>> I want to be able to redirect/manipulate an incoming call before it 
>> gets answered/bridged, but to do that I have to now which channel to use.
>>
>> Is there a way? Prefarably using manager API.
>>
>> Thanks,
>> Marcus
>>
>> _______________________________________________
>> --Bandwidth and Colocation provided by Easynews.com --
>>
>> asterisk-users mailing list
>> To UNSUBSCRIBE or update options visit:
>>   http://lists.digium.com/mailman/listinfo/asterisk-users
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
> 
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users



More information about the asterisk-users mailing list