Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Esp32 streaming video and data over websocket

Status
Not open for further replies.

dr pepper

Advanced Member level 1
Joined
Mar 15, 2010
Messages
420
Helped
34
Reputation
68
Reaction score
40
Trophy points
1,308
Location
lancs
Activity points
4,128
I have an Esp32 that streams video data from a camera to a browser.
I also want to transmit data to the browser, but quicker than ajax, maybe 10 - 20 updates per second.
Can I open 2 websockets on the Esp32?
 

Websockets are a software construct so in theory yes if programmed to do so but you will probably run into problems when sharing the WiFi bandwidth with additional packets. Video streaming generally doesn't like interruptions!

Brian.
 

I tried defining 2 webosckets:

webSocketServer (81);
webSocketServer (82);

Only one socket opened, on port 82.
But there was no errors compiling and the chip didnt crash.
So I guess the Esp opened a socket on port 81, then closed that and opened another on port 82.
That tells me its possible to close one socket and open another on a diffrent port in the program cycle, so I might just see if that will work.
 

Websockets are a software construct, thus in principle, yes if implemented correctly, however you will most likely have issues when sharing WiFi bandwidth with extra packets.
 

It was easy in the end.
Request a frame, send a frame, and repeat 10 times a second, looking for other comms inbetween.
The comms inbetween doesnt even noticeably affect the video.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top