VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
klaus.teller at gmx.net Guest
|
Posted: Tue Dec 02, 2008 10:18 pm Post subject: [Freeswitch-users] Bridging from Event Socket API |
|
|
Hi Folks,
so far i could understand how to bridge calls with Javascript. I'm trying to do the same with Java via the Socket Interface. My first trials weren't successful. maybe you can help me understand what is goin on.
What i want to do is to bridge an existing leg (Unique-ID is known) to a party that wasn't yet dialed (Unique-ID unknown). With javascript it is something like:
session.bridge("sofia/internal/1002");
How do i do this using the event socket interface? what application/command would i use with which arguments?
One way i tried to do this is to orginate a call to 'sofia/internal/1002' and bridge the two existing legs using uuid_bridge. Unfortunately, it wasn't successful. The only message i had on the FS console is:
2008-12-02 16:57:34 [DEBUG] switch_core_session.c:693 switch_core_session_queue_private_event() Send signal sofia/internal/1001@192.168.1.121 [BREAK]
Any idea what i'm missing?
Thanks,
Klaus.
--
Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
_______________________________________________
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 |
|
Back to top |
|
|
msc at freeswitch.org Guest
|
Posted: Tue Dec 02, 2008 11:41 pm Post subject: [Freeswitch-users] Bridging from Event Socket API |
|
|
You probably have several options depending upon your needs. Could you elaborate a bit on what the big picture is? Also, what exactly were you doing when you established the second call leg? Did the second call let get created and a valid uuid assigned, etc.? Just checking.
Let us know,
MC
On Tue, Dec 2, 2008 at 7:15 PM, Klaus Teller <klaus.teller@gmx.net (klaus.teller@gmx.net)> wrote:
Quote: | Hi Folks,
so far i could understand how to bridge calls with Javascript. I'm trying to do the same with Java via the Socket Interface. My first trials weren't successful. maybe you can help me understand what is goin on.
What i want to do is to bridge an existing leg (Unique-ID is known) to a party that wasn't yet dialed (Unique-ID unknown). With javascript it is something like:
session.bridge("sofia/internal/1002");
How do i do this using the event socket interface? what application/command would i use with which arguments?
One way i tried to do this is to orginate a call to 'sofia/internal/1002' and bridge the two existing legs using uuid_bridge. Unfortunately, it wasn't successful. The only message i had on the FS console is:
2008-12-02 16:57:34 [DEBUG] switch_core_session.c:693 switch_core_session_queue_private_event() Send signal sofia/internal/1001@192.168.1.121 (1001@192.168.1.121) [BREAK]
Any idea what i'm missing?
Thanks,
Klaus.
--
Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (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
|
|
|
Back to top |
|
|
dave at 3c.co.uk Guest
|
Posted: Wed Dec 03, 2008 6:19 am Post subject: [Freeswitch-users] Bridging from Event Socket API |
|
|
Hi Klaus,
Some Perl code snippets - we use:
call_command("bridge", "sofia/gateway/bt/$ntd");
which, in turn, is:
sub call_command($$) {
my $cmd = shift;
my $arg = shift;
print $sock "sendmsg\ncall-command: execute\nexecute-app-name:
$cmd\nexecute-app-arg: $arg\n\n";
}
Cheers --
Dave
Quote: | Hi Folks,
so far i could understand how to bridge calls with Javascript. I'm trying to do the same with Java via the Socket Interface. My first trials weren't successful. maybe you can help me understand what is goin on.
What i want to do is to bridge an existing leg (Unique-ID is known) to a party that wasn't yet dialed (Unique-ID unknown). With javascript it is something like:
session.bridge("sofia/internal/1002");
How do i do this using the event socket interface? what application/command would i use with which arguments?
One way i tried to do this is to orginate a call to 'sofia/internal/1002' and bridge the two existing legs using uuid_bridge. Unfortunately, it wasn't successful. The only message i had on the FS console is:
2008-12-02 16:57:34 [DEBUG] switch_core_session.c:693 switch_core_session_queue_private_event() Send signal sofia/internal/1001@192.168.1.121 [BREAK]
Any idea what i'm missing?
Thanks,
Klaus.
|
--
David Knell, Director, 3C Limited
T: 020 8114 8901 F: 020 3002 7257 M: 001 415 630 3031
http://www.3c.co.uk
_______________________________________________
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 |
|
Back to top |
|
|
klaus.teller at gmx.net Guest
|
Posted: Wed Dec 03, 2008 9:58 am Post subject: [Freeswitch-users] Bridging from Event Socket API |
|
|
Hi All,
Thanks for your feedback. I must be doing something fundamentally wrong. Inbound socket is working without problems. But the exact things that i do on inbound socket, i'm not able to replcate them on outbound socket.
The global picture: I have on Xlite registered at extension 1002 and another one at extension 1003. Then i have an extension 8998 in the default context. Here is the extension definition:
<extension name="outbound-test">
<condition field="destination_number" expression="^8998$" >
<action application="socket" data="192.168.50.56:10000 full" />
</condition>
</extension>
I use Xlite-1003 to call this extension (8998) and the call is properly notified to the remote Java server.
Then on the Java side, after receiving the event, i send a CONNECT command: "Connect\n\n"
The answer from Freeswitch is the state of the channel ( a set of variable, value pair).
Up to this point everything seems normal to me. But then, i try to send an answer command:
sendmsg b30a2d2e-c146-11dd-9b99-07347b46e4ea
call-command: execute
execute-app-name: answer
execute-app-arg:
Freswitch replies with:
Content-Type: command/reply
Reply-Text: +OK
But the call is still not answered. Nothing happens on the freeswitch console (Log level DEBUG) and the dialing XLite is still in calling modus.
Then i try bridging the call to 1002:
sendmsg b30a2d2e-c146-11dd-9b99-07347b46e4ea
call-command: execute
execute-app-name: bridge
execute-app-arg: sofia/internal/1002%192.168.50.94
Again Freeswitch does answer with:
Content-Type: command/reply
Reply-Text: +OK
And yet again, nothing is really happening.
What am i missing here?
Thanks,
Klaus.
-------- Original-Nachricht --------
Quote: | Hi Klaus,
Some Perl code snippets - we use:
call_command("bridge", "sofia/gateway/bt/$ntd");
which, in turn, is:
sub call_command($$) {
my $cmd = shift;
my $arg = shift;
print $sock "sendmsg\ncall-command: execute\nexecute-app-name:
$cmd\nexecute-app-arg: $arg\n\n";
}
Cheers --
Dave
Quote: | Hi Folks,
so far i could understand how to bridge calls with Javascript. I'm
| trying to do the same with Java via the Socket Interface. My first trials
weren't successful. maybe you can help me understand what is goin on.
Quote: |
What i want to do is to bridge an existing leg (Unique-ID is known) to a
| party that wasn't yet dialed (Unique-ID unknown). With javascript it is
something like:
Quote: |
session.bridge("sofia/internal/1002");
How do i do this using the event socket interface? what
| application/command would i use with which arguments?
Quote: |
One way i tried to do this is to orginate a call to
| 'sofia/internal/1002' and bridge the two existing legs using uuid_bridge. Unfortunately, it
wasn't successful. The only message i had on the FS console is:
Quote: |
2008-12-02 16:57:34 [DEBUG] switch_core_session.c:693
| switch_core_session_queue_private_event() Send signal sofia/internal/1001@192.168.1.121
[BREAK]
Quote: |
Any idea what i'm missing?
Thanks,
Klaus.
|
--
David Knell, Director, 3C Limited
T: 020 8114 8901 F: 020 3002 7257 M: 001 415 630 3031
http://www.3c.co.uk
_______________________________________________
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
|
--
Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
_______________________________________________
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 |
|
Back to top |
|
|
dave at 3c.co.uk Guest
|
Posted: Wed Dec 03, 2008 11:39 am Post subject: [Freeswitch-users] Bridging from Event Socket API |
|
|
Hi Klaus,
There's two differences that I can see between what you're doing and what we do:-
1. We're using the socket in async mode (shouldn't make any difference)
2. You don't need to send the UUID in after the sendmsg - FS already knows which call you're controlling.
Cheers --
Dave
Quote: | Quote: | Hi All,
Thanks for your feedback. I must be doing something fundamentally wrong. Inbound socket is working without problems. But the exact things that i do on inbound socket, i'm not able to replcate them on outbound socket.
The global picture: I have on Xlite registered at extension 1002 and another one at extension 1003. Then i have an extension 8998 in the default context. Here is the extension definition:
<extension name="outbound-test">
<condition field="destination_number" expression="^8998$" >
<action application="socket" data="192.168.50.56:10000 full" />
</condition>
</extension>
I use Xlite-1003 to call this extension (8998) and the call is properly notified to the remote Java server.
Then on the Java side, after receiving the event, i send a CONNECT command: "Connect\n\n"
The answer from Freeswitch is the state of the channel ( a set of variable, value pair).
Up to this point everything seems normal to me. But then, i try to send an answer command:
sendmsg b30a2d2e-c146-11dd-9b99-07347b46e4ea
call-command: execute
execute-app-name: answer
execute-app-arg:
Freswitch replies with:
Content-Type: command/reply
Reply-Text: +OK
But the call is still not answered. Nothing happens on the freeswitch console (Log level DEBUG) and the dialing XLite is still in calling modus.
Then i try bridging the call to 1002:
sendmsg b30a2d2e-c146-11dd-9b99-07347b46e4ea
call-command: execute
execute-app-name: bridge
execute-app-arg: sofia/internal/1002%192.168.50.94
Again Freeswitch does answer with:
Content-Type: command/reply
Reply-Text: +OK
And yet again, nothing is really happening.
What am i missing here?
Thanks,
Klaus.
-------- Original-Nachricht --------
Quote: | Hi Klaus,
Some Perl code snippets - we use:
call_command("bridge", "sofia/gateway/bt/$ntd");
which, in turn, is:
sub call_command($$) {
my $cmd = shift;
my $arg = shift;
print $sock "sendmsg\ncall-command: execute\nexecute-app-name:
$cmd\nexecute-app-arg: $arg\n\n";
}
Cheers --
Dave
Quote: | Hi Folks,
so far i could understand how to bridge calls with Javascript. I'm
| trying to do the same with Java via the Socket Interface. My first trials
weren't successful. maybe you can help me understand what is goin on.
Quote: | What i want to do is to bridge an existing leg (Unique-ID is known) to a
| party that wasn't yet dialed (Unique-ID unknown). With javascript it is
something like:
Quote: | session.bridge("sofia/internal/1002");
How do i do this using the event socket interface? what
| application/command would i use with which arguments?
0 Datum: Wed, 03 Dec 2008 11:15:57 +0000
Von: David Knell <dave@3c.co.uk> (dave@3c.co.uk)
An: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Betreff: Re: [Freeswitch-users] Bridging from Event Socket API
| 1 3 5 Datum: Wed, 03 Dec 2008 11:15:57 +0000
Von: David Knell <dave@3c.co.uk> (dave@3c.co.uk)
An: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Betreff: Re: [Freeswitch-users] Bridging from Event Socket API
| 6 Datum: Wed, 03 Dec 2008 11:15:57 +0000
Von: David Knell <dave@3c.co.uk> (dave@3c.co.uk)
An: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Betreff: Re: [Freeswitch-users] Bridging from Event Socket API
| 7 |
|
Back to top |
|
|
klaus.teller at gmx.net Guest
|
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|