Hi all, I'm trying to do this in LUA: A call B and I'd like to setup a new call to C with eavesdrop of A conversation with B. I have no idea how to do this if someone can help. I switched to LUA cause I see no way to achieve this with dialplan (snippets are welcome). regards, rod
Hi all, I have an incomplete solution for those interested. I did it like this in dialplan: <action application="set" data="api_on_answer=originate sofia/internal/2000@10.10.10.10 &eavesdrop(${uuid})"/>--> <action application="bridge" data="{ecoute=${caller_id_number}}sofia/gateway/${caller_id_number}/${destination_number}"/> so when a call is setup, FS initiate a new call to 2000 and eavesdrop the call. But I have a small problem, the callee receives no sound until the eavesdropper send a SIP reply, so there is a 2-3 seconds delay before caller and callee can talk each other. rod rod a écrit :
Hi all,
I'm trying to do this in LUA: A call B
and I'd like to setup a new call to C with eavesdrop of A conversation with B.
I have no idea how to do this if someone can help. I switched to LUA cause I see no way to achieve this with dialplan (snippets are welcome).
regards, rod
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I had a similar problem. I solved it by first making bridging the call between A and B. Then originate C with a LUA script, the last line of which is: session:execute("eavesdrop", uuid_of_a_leg) The down side here is that A and B can talk while C is ringing, but in my case that is not a problem. -p -----Original Message----- From: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] On Behalf Of rod Sent: Thursday, January 14, 2010 8:10 AM To: freeswitch-users@lists.freeswitch.org Subject: Re: [Freeswitch-users] Eavesdrop in LUA Hi all, I have an incomplete solution for those interested. I did it like this in dialplan: <action application="set" data="api_on_answer=originate sofia/internal/2000@10.10.10.10 &eavesdrop(${uuid})"/>--> <action application="bridge" data="{ecoute=${caller_id_number}}sofia/gateway/${caller_id_number}/${destin ation_number}"/> so when a call is setup, FS initiate a new call to 2000 and eavesdrop the call. But I have a small problem, the callee receives no sound until the eavesdropper send a SIP reply, so there is a 2-3 seconds delay before caller and callee can talk each other. rod rod a écrit :
Hi all,
I'm trying to do this in LUA: A call B
and I'd like to setup a new call to C with eavesdrop of A conversation with B.
I have no idea how to do this if someone can help. I switched to LUA cause I see no way to achieve this with dialplan (snippets are welcome).
regards, rod
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@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@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Hi Pete, to get the beginning of the communication, I find this: use the pre-answer/ringback command before bridging the call, this will issue a 183 with ringback in RTP. Doing this, eavesdrop application can listen the caller A talking in the phone (and the ringback tone) even if the call is not connected to B :o in the dialplan I did this: <action application="set" data="ringback=$${fr-ring}"/> <action application="pre_answer"/> <action application="sleep" data="500"/> <actionapplication="bridge"data="{ecoute=${caller_id_number}}sofia/gateway/${caller_id_number}/${destination_numbe\ r}"/> A colleague wrote a perl script using mod_event that looks for when a call that should be eavesdrop is connecting and originate a call to C using eavesdrop on A leg. I will ask my colleague/boss if he's okay to share his script on the wiki. I think, he'll be okay, but prefer asking before. Give a try to pre-anwer with lua, and let me know if you could eavesdrop to a call before the call is exchanging media. Are you ok to share your lua script, so that we could document the eavesdrop page ? regards, rod Pete Mueller a écrit :
I had a similar problem. I solved it by first making bridging the call between A and B. Then originate C with a LUA script, the last line of which is:
session:execute("eavesdrop", uuid_of_a_leg)
The down side here is that A and B can talk while C is ringing, but in my case that is not a problem. -p
-----Original Message----- From: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] On Behalf Of rod Sent: Thursday, January 14, 2010 8:10 AM To: freeswitch-users@lists.freeswitch.org Subject: Re: [Freeswitch-users] Eavesdrop in LUA
Hi all,
I have an incomplete solution for those interested.
I did it like this in dialplan: <action application="set" data="api_on_answer=originate sofia/internal/2000@10.10.10.10 &eavesdrop(${uuid})"/>--> <action application="bridge" data="{ecoute=${caller_id_number}}sofia/gateway/${caller_id_number}/${destin ation_number}"/>
so when a call is setup, FS initiate a new call to 2000 and eavesdrop the call. But I have a small problem, the callee receives no sound until the eavesdropper send a SIP reply, so there is a 2-3 seconds delay before caller and callee can talk each other.
rod
rod a écrit :
Hi all,
I'm trying to do this in LUA: A call B
and I'd like to setup a new call to C with eavesdrop of A conversation with B.
I have no idea how to do this if someone can help. I switched to LUA cause I see no way to achieve this with dialplan (snippets are welcome).
regards, rod
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@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@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@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
participants (2)
-
Pete Mueller
-
rod