[Freeswitch-users] originating a call from an outbound socket app
Hector Geraldino
Hector.Geraldino at ip-soft.net
Mon Jun 13 20:37:33 MSD 2011
Hi Michael,
I finally figure out how to connect both calls using the command 'intercept'. From the inbound call (handled by the OB socket) I just do an execute intercept legB uuid, and both calls are bridged perfectly. Thanks very much.
So the only thing that stills concerns me is why the event CHANNEL_ANSWER is always generated on the outbound call (legb), even if the user doesn't pick up the call. Also I can't find any differences on the CHANNEL_CALLSTATE or CALL_UPDATE events that allows me to determine when an outbound call generated from FS is actually answered or not.
BTW, I bought the FS 1.0.6 book on Amazon last week and I want to congratulate you and Anthony/Darren for the excellent work you've done, it has been really helpful. My only complaint is that it doesn't have an eBook format so I can read it on my Kindle. Besides that, great work.
From: freeswitch-users-bounces at lists.freeswitch.org [mailto:freeswitch-users-bounces at lists.freeswitch.org] On Behalf Of Michael Collins
Sent: Friday, June 10, 2011 6:27 PM
To: FreeSWITCH Users Help
Subject: Re: [Freeswitch-users] originating a call from an outbound socket app
On Fri, Jun 10, 2011 at 7:00 AM, Hector Geraldino <Hector.Geraldino at ip-soft.net<mailto:Hector.Geraldino at ip-soft.net>> wrote:
Thanks for your response Michael.
Finally I found the way of dialing to an external extension. What I did was just open a shell, listen in a port using nc and tried to originate a call. It worked using the syntax:
originate sofia/internal/5562 at 192.168.23.104<mailto:5562 at 192.168.23.104> &park
As this is an outbound call (not managed by the socket application) I had to use a new inbound socket connection to connect to FS, make the call, query for the uuid and receive some events (like DTMF among others). Everything was going great, until I found two issues:
- The CHANNEL_ANSWER event is always triggered, no matter if the call is actually picked up or not on my phone. I thought that maybe I can use some other event to determine if the call have been answered or not (like CHANNEL_CALLSTATE or CALL_UPDATE), but the additional information on the event headers is the same no matter if it's answered or not.
- When the call is answered, and the user presses a key to accept the call, the function returns the UUID of this session to the main method. Then I tried to make the bridge between the two calls (the legA call handled by the socket application, and the legB outbound call generated in the application using an inbound connection). I using the command
api uuid_bridge <incoming_uuid> <outbound_uuid>
but this didn't work. Am I missing something here?
You're missing the debug log on the pastebin. ;)
Yeah, let's take a look at the debug log of this happening. Capture from the beginning of the a leg all the way through to trying the uuid_bridge.
-MC
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20110613/06ef5be8/attachment.html
More information about the FreeSWITCH-users
mailing list