[Freeswitch-users] ESL: phpmod
Anthony Minessale
anthony.minessale at gmail.com
Wed Jun 23 11:17:03 PDT 2010
try running the "linger" command.
that tells FS to not disconnect when the channel hangs up and instead wait
for you to disconnect.
On Wed, Jun 23, 2010 at 3:26 AM, Helmut Kuper <helmut.kuper at ewetel.de>wrote:
> Hi again,
>
> I added now an inbound esl socket back to FS through which I execute the
> originate command. And this way it works. When caller hang up during
> originate ringing I get the HANGUP event and I can uuid_kill the
> originate session. :)
>
> hmmm... So bgapi originate seems so stick with the channel's outbound
> socket when it is called via outbound socket.
>
> regards
> helmut
>
> On 23.06.2010 08:57, Helmut Kuper wrote:
> > Hi Michael,
> >
> > On 22.06.2010 20:41, Michael Collins wrote:
> >> On Tue, Jun 22, 2010 at 11:34 AM, Helmut Kuper <helmut.kuper at ewetel.de
> >wrote:
> >>
> >>> Hi,
> >>>
> >>> hm well, yes, indeed that works, too. Maybe even better.
> >>>
> >>> But I still have the problem of a hanging command which doesn't comes
> >>> back until timeout, answer, cancel, ... on callee's side.
> >>>
> >>
> >> Which command doesn't come back? I'm assuming you mean the "originate"
> >> itself and not the bgapi. I don't see how you can avoid a "hang" while
> you
> >> wait for the 2nd channel (the callee) to be contacted since you have to
> wait
> >> for him/her to answer. In any case, this should be quite doable either
> with
> >> api or with bgapi. The difference with bgapi is that you can do other
> stuff
> >> in your script (if you need to) while api will wait for the result of
> the
> >> originate before it returns.
> >
> >
> > What I currently do is this:
> >
> > 1. caller calls in
> > 2. FS calls my deamon via socket app (async full)
> > 3. Deamon connects the call via ESLconnection
> > 4. executing answer
> > 5. executing playback
> > 6. subscribing to all events
> > 7. originate b-leg via bgapi
> > 9. waiting for events (this is a loop using esl->recvEventsTimed(1000))
> > 9.1 replaying caller's playback
> > 9.2 checking for caller's Hangup
> > 9.3 checking for esl->connected=false
> > 9.4 checking for b-leg's result (Answer or deny)
> > 9.4.1 bridge both legs
> > 9.4.2 release esl-socket
> > 9.4.3 done
> >
> >
> > When caller hangs up somewhere after step 7 I got sometimes a HANGUP
> > event but more often nothing. Trying to write into the esl->socket then
> > seems to block until originate has finished.
> >
> > I guess FS has torn down the socket half way or so in this state.
> >
> >
> > regards
> > Helmut
> >
> > _______________________________________________
> > FreeSWITCH-users mailing list
> > FreeSWITCH-users at lists.freeswitch.org
> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> > http://www.freeswitch.org
> >
> >
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
--
Anthony Minessale II
FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/
Twitter: http://twitter.com/FreeSWITCH_wire
AIM: anthm
MSN:anthony_minessale at hotmail.com <MSN%3Aanthony_minessale at hotmail.com>
GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com<PAYPAL%3Aanthony.minessale at gmail.com>
IRC: irc.freenode.net #freeswitch
FreeSWITCH Developer Conference
sip:888 at conference.freeswitch.org <sip%3A888 at conference.freeswitch.org>
googletalk:conf+888 at conference.freeswitch.org<googletalk%3Aconf%2B888 at conference.freeswitch.org>
pstn:+19193869900
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20100623/fe56554b/attachment.html
More information about the FreeSWITCH-users
mailing list