So since WC now supports Socket stuff.. I take it we can build a peer to peer WebRTC app using WCs socket stuff to handle signaling? I made a Video/Chat App using node for the signal server... I'd rather have it in my WC/IIS stuff... I'd just use WC sockets to handle signaling and not the actual chat.. Would use WebRTC to handle Video and chat.. Has anyone tried to do anything like this in WC yet?
I think so yes. Both ends need to be able to use WebSockets for this to work though with the WC server as the hub in the hub and spoke model.
We've been able to do this for some time, if you previously wanted to use some alternate technology for the server bit - (ie. .NET with a SignalR server, or Node for as you're doing). Now you can use Web Connection too... but it's a less flexible model. You don't have as much control as a full solution like SignalR or SocketIO, but still it works for many common scenarios. Before you jump in with production work (especially if you come from an existing framework) make sure you test your scenarios out first.
+++ Rick ---
I only need to Send / Receive SDP "Session Description Protocol" it's just a few hundred chars of text describing what each peer is capable of.. so I think it will work fine... This new socket stuff in WC opens up many new features I can add to my existing apps...
Thanks Rick!!!
When you first came out with this latest Version 7.20.. Seems like the Chat demo wasn't working right... looks like it is working fine now.. I'm going to play with that code to send / receive SDP messages.. Once local and remotes have each others information.. it should be as easy as send the video streams.. When will you have a sample on this.. lol.. joking..
-- Jim --
Yeah when I pushed the demos up, I forgot to enable WebSockets on the site. Duh 😄
The chat demo is very rudimentary of course, basically just demonstrates the broadcast mode - doesn't show previous message or chat room groupings etc. so very simplistic, although it's possible to do all that if you track users through their sessions.
Be interesting to see what people build on top of this.
+++ Rick ---
Hi Jim,
Just wondering if you ever got Signaling to work in Web Connection? I'm in the process of trying to create a Raspberry Pi WebRTC host and trying to figure out what the easiest way to setup the SDP conversation that needs to take place.
Any suggestions or thoughts about what you learned would be appreciated.
Best,
There are .NET libraries that provide these clients and you can probably hook up to those from Foxpro using wwDotnetBridge...
Here's one:
There are also various .NET Web Sockets implementations available (including the native System.Net.WebSockets
) that let you communicate across desktop -> Web app and then perhaps handle the WebRTC stuff in JavaScript with the many tools and examples available there.
+++ Rick ---
Ah... this will make for an interesting Q&A next week at SWF where a beer at the bar will give me a chance to hear more! Looking forward to your VFP Session on .NET interface.
BTW - I looked at the link you provided, I am trying to keep the JavaScript application as simple as possible and from what I have read so far introducing SIP into the project will only add functionally I really don't need.
The final project will be a Raspberry Pi, that when it received a switch closure on a GIO pin a Node-Red application will kick in. The event will trigger an MQTT message to be published with the body of the message providing a link to the RPi where a static html page will include a WebRTC client that is connected to the RPi's microphone, speaker and camera. Once the video and audio are active the user will be able to receive the video and send and receive audio from the RPi (the RPi will not get display video).
The Node-Red application will also be able to control other functionally on the RPi such as opening relay(s) and selection local audio files to be played through the local speaker. At the end of the day, the application will make up a very configurable doorbell/access control device.
Yeah I have no idea about WebRTC, so don't ask me about that. All I'm saying is that perhaps you can send WebSocket connections to something on the device and then proxy the messages from the with whatever the easiest WebRTC interface is.
I'm pretty sure though that if you want to control WebRTC directly there's gotta be a .NET client that can do that and then you can use wwDotnetBridge to interface with it (or write some .NET code and then interface that with FoxPro).
+++ Rick ---