cisco ip phone and kurento webrtc

117 views
Skip to first unread message

uri.gree...@gmail.com

unread,
Aug 4, 2016, 10:08:51 AM8/4/16
to kurento

Hello
I streamed audio.mp3 file by using gst-launch-1.0 to cisco ip phone.

gst-launch-1.0 -v filesrc location=~/Videos/audio.mp3 ! mad ! audioconvert ! audio/x-raw, channels=1 ! audioresample ! audio/x-raw, channels=1, rate=8000 ! alawenc ! rtppcmapay ! application/x-rtp, mtu=160, min-ptime=20000000 ! udpsink host=172.20.0.186 port=20500

cisco ip phone address is 172.20.0.186:20500.
cisco ip phone supports g711 codec.
I used WebRtcEndpoint and Rtpendpoint to stream from webbrowser to cisco ip phone and updated hello world app.
 kurentoClient.create('MediaPipeline', function(error, pipeline) {
            pipeline.create('WebRtcEndpoint', function(error, webRtc){
                webRtc.processOffer(sdpOffer, function(error, sdpAnswer){
                    pipeline.create('RtpEndpoint', function(error, Rtp){

                        sdp_rtp = '';
                        sdp_rtp += 'v=0\n';
                        sdp_rtp += 'o=- 2 2 IN IP4 172.20.0.186\n';
                        sdp_rtp += 's=-\n';
                        sdp_rtp += 'c=IN IP4 172.20.0.186\n';
                        sdp_rtp += 't=0 0\n';
                        sdp_rtp += 'm=audio 20500 RTP 0 8 3 101\n';
                        sdp_rtp += 'b=AS:10\n';
                        sdp_rtp += 'a=rtpmap:0 pcmu/8000\n';
                        sdp_rtp += 'a=rtpmap:8 pcma/8000\n';
                        sdp_rtp += 'a=rtpmap:3 gsm/8000\n'
                        sdp_rtp += 'a=rtpmap:101 telephone-event/8000\n';
                        sdp_rtp += 'a=fmtp:101 0-16\n';
                        sdp_rtp += 'a=ptime:20\n';
                        sdp_rtp += 'a=recvonly\n';
                        Rtp.processOffer(sdp_rtp, function(error, sdpAnswer){

                            webRtc.connect(Rtp, function(error){
                                console.log("Loopback established...!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
                            });
                            Rtp.connect(webRtc, function(error){
                                console.log("Loopback established2......");
                            });

                        });
                    });
                });

            });


but I failed.
please help me what I missed

Thank you.
ye.
Message has been deleted
Message has been deleted

Ivan Gracia

unread,
Aug 18, 2016, 12:47:28 PM8/18/16
to Kurento Public
Not sure I understand what you want to achieve...

Ivan Gracia



On Thu, Aug 4, 2016 at 4:09 PM, <uri.gree...@gmail.com> wrote:

--
You received this message because you are subscribed to the Google Groups "kurento" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kurento+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Greg Royal

unread,
Sep 24, 2016, 9:22:02 PM9/24/16
to kurento
Ivan
Cisco IP phones can be "programmed" through a remote URI command to transmit or receive RTP streams from/to a Unicast or Multicast Address.
It is a custom XML structure. you can see it here:
http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cuipph/all_models/xsi/9-1-1/CUIP_BK_P82B3B16_00_phones-services-application-development-notes/CUIP_BK_P82B3B16_00_phones-services-application-development-notes_chapter_0101.html#CUIP_RF_RAF91CE2_00

This is completely (almost) independent of the call "plane" and is used by thousands of cisco customers to do things like broadcasting say in a school rather than over the public address system. 

The upshot is the phone is "dumb" from WebRTC's perspective, it cant negotiate anything.
You need to out-of-band set the phone up to listen/talk and then set up the gstreamer to RTP to/from the phone and then Kurento would just go ahead and RTP to the phone.

The typical way to do this is a native Windows application but since the path forward is Cloud Centric apps, the appropriate way would be using something like Kurento as the media server.

So the question is, I would assume we would need to write a custom RTCEndpoint to do the custom sink and source.
The starting point would be Kurento/gstreamer module development?

Thanks
GR

Ivan Gracia



To unsubscribe from this group and stop receiving emails from it, send an email to kurento+u...@googlegroups.com.

Ivan Gracia

unread,
Sep 26, 2016, 5:31:20 AM9/26/16
to Kurento Public
What are you doing with the sdpAnswer? You need to send that to the phone to finish the RTP negotiation, if you are planning on using bidirectional connections.

Ivan Gracia



To unsubscribe from this group and stop receiving emails from it, send an email to kurento+unsubscribe@googlegroups.com.

Greg Royal

unread,
Oct 2, 2016, 4:18:28 PM10/2/16
to kurento
We need to "spoof" the SDP answer in the endpoint, because the phone has no capability to act as client.
So think about it this way, the RTPEndpoint is a proxy client as well as the pipeline.

This is also our approach for Multicast addressing, we need to proxy the SDP flow along side the pipeline.

The end goal is to create "Push to talk" WebRTC Clients that can talk to various "dumb" devlces; dumb endpoints are endpoints that can cannot act as WebRTC endpoints in and of themselves but readily accept RTP Tx and Rx

Thanks
Reply all
Reply to author
Forward
0 new messages