• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

Embed RTSP in html

Q&A Forum › Category: ESP8266 › Embed RTSP in html
0 Vote Up Vote Down
alex soriano asked 3 years ago

Does anyone know how to embed a CCTV livestream (RTSP) into a micropython web server? Thanks for any advice.

Question Tags: Micropython Webserver
11 Answers
0 Vote Up Vote Down
Sara Santos Staff answered 3 years ago

Hi.
I think you just need to create a “regular” web server and embed the RSTP URL in an image tag source.
Regards,
Sara

0 Vote Up Vote Down
William Lucid answered 3 years ago

Hi,

I use an RTSP video feed in my project; the webRTC server I use is the “UnrealMediaServer” which will need to run on a Windows pc.  All major web browsers support “webRTC.”

Although not “Micropython”; technigue may be the same, since basically it is just a web page.

Web page for “WebRTC” player to display RTSP “live” video feed

Be sure to #import your "index7.h."

RTSP Video feed project discussed in more detail with resource links here in this forum.

How to stream an ip camera to a website via WebRTC (Free software)

Best Regards,
William


0 Vote Up Vote Down
Sara Santos Staff answered 3 years ago

Hi William.
Thank you so much for sharing this.
But, can you please share your code using GitHub gist? The formatting won’t be messed up.
Regards,
Sara

0 Vote Up Vote Down
William Lucid answered 3 years ago

Sara,
Code posted to “Gist.”
 
First use of “Gist”; will use it often, thank you for suggesting “Gist.”
 
Best Regards,
William

0 Vote Up Vote Down
Sara Santos Staff answered 3 years ago

Can you share the link?
regards,
Sara

0 Vote Up Vote Down
William Lucid answered 3 years ago

Hi Sara,
I edited earlier post here with the link:
Web page for “WebRTC” player to display RTSP “live” video feed
Thanks for all you and Rui do for the RNT Forum Community!
Best Regards,
William

0 Vote Up Vote Down
Sara Santos Staff answered 3 years ago

I’m the one who must thank you.
I’ll close this issue.
Regards,
Sara

0 Vote Up Vote Down
alex soriano answered 3 years ago

William,

This is very informative. Thanks a lot! I was able to follow your instructions and I am now able to get the UMS to stream internally but I cannot stream from outside my network despite opening ports 5119 & 5135 in both my Windows Firewall and router and changing the IP address to my external IP address. Any ideas I am not getting? I am really impressed at how much these small microcontrollers can do. The project I am doing is getting my garage doors to open and close. I have a camera in the garage that is pointing to the doors. With RNT’s Micropython tutorial, I can now do this. Embedding the IP camera feed into theESP8266 webserver will complete the project. As soon as I complete the project and clean up the code (esp the HTML), I can post it if anyone is interested. Really cool (IMHO for a newbie anyway). Thanks again.

0 Vote Up Vote Down
William Lucid answered 3 years ago

Hi Alex,

Congratulations on your project.

Follow the steps listed in the section:  “Test the WebRTC Stream via the Internet,” of the article from:  How to stream an ip camera to a website via WebRTC (Free software)

Opening ports are not without security concerns

Open port for your webserver in your router and open web server port in your firewall; be it Windows Firewall or third-party Firewall provider.

Regards,
William

0 Vote Up Vote Down
alex soriano answered 3 years ago

Thanks, William and Sara. I followed the Unreal Media Server instructions and it worked! I am now able to live stream my garage camera to the ESP8266 server and can open/close my garage doors with a real time video of what I’m doing.
True, opening ports allow nefarious organizations and/or individuals to snoop inside your network and see video feeds. I realized it when I noticed connections from Russia and other places into the ESP server in the Thonny terminal shell. It seems these people troll the more common ports, e.g. ports 80, 8080, etc. I now use OpenVPN to connect to my home network when I’m away. I also open and use less common and random ports. Hope this helps others.

0 Vote Up Vote Down
William Lucid answered 3 years ago

Alex,

Thank you for sharing your WebRTC experience and your project details.

Project approach is interesting.

We all started the learning process as “newbies,” you have an impressive project; keep up the good work!

How would you like to add voice control to your project?  Check out “Sinric Pro” on Github.com.
Specifically their Relay example.

William

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.