Stream ESP32 cam via web sockets

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
OutoftheBOTS_
Posts: 847
Joined: Mon Nov 20, 2017 10:18 am

Stream ESP32 cam via web sockets

Post by OutoftheBOTS_ » Wed Jun 08, 2022 10:33 pm

I know people have made custom firmwares for ESP32 cam. I have seen on the net people streaming ESP32 cam using Ardunio and I have seen people sending a single frame with micropython.

Has anyone manged to stream a lower res video stream from ESP32 cam at a reasonable frame rate??

My use case is: I run courses teaching high school kids robotics and coding using python. I have a project where we 3D design a set of animatronic eyes and use a plug and play AI on a PC that tracks peoples faces so that we can program the eyes to follow peoples faces. see here https://youtu.be/XjF5WrlLWhE

My current design uses a USB cam on the PC that runs the AI then sends the position to the ESP32 that controls the servos. It would be good if I could cut the cable with the USB cam and use an ESP32 cam and stream the video.

KJM
Posts: 158
Joined: Sun Nov 18, 2018 10:53 pm
Location: Sydney AU

Re: Stream ESP32 cam via web sockets

Post by KJM » Fri Jun 10, 2022 1:20 am

I've only ever tried single frames with upython but the author https://github.com/lemariva/uPyCam of the python firmware for ESP-32 CAM boards claims python streaming is possible https://lemariva.com/blog/2020/08/micro ... e-extended

OutoftheBOTS_
Posts: 847
Joined: Mon Nov 20, 2017 10:18 am

Re: Stream ESP32 cam via web sockets

Post by OutoftheBOTS_ » Sat Jun 11, 2022 7:43 am

Thanks for your response.

I think it is definitely possible but I will have to spend a little time to work out how to hack it.

I am not wanting to stream it by hosting a webpage but rather just send it to python on my PC via websocket.

KJM
Posts: 158
Joined: Sun Nov 18, 2018 10:53 pm
Location: Sydney AU

Re: Stream ESP32 cam via web sockets

Post by KJM » Sat Jun 11, 2022 10:17 am

The python tutorial @ https://github.com/Freenove/Freenove_Ul ... ter/Python doesn't mention websockets specifically but might serve as a starter?

Post Reply