ofekp / TinyUPnP

A very small UPnP IGD implementation for your ESP8266 for automatic port forwarding
GNU Lesser General Public License v2.1
104 stars 15 forks source link

Use as client for iptv server, wifi to HDMI tv dongle. #46

Open siliconhippy opened 5 years ago

siliconhippy commented 5 years ago

Hi there !

I am not very technical...but this looks cool 😛

  1. So can I use this as ESP client to stream iptv from a public ( Cloud) server?

That is, IPTV server > home ESP+ mini upnp > WiFi > HDMI dongle on TV set.

Example TV dongle: https://m.aliexpress.com/wholesale/ezcast-dongles.html?spider=y

These cheap dongles do a variation of the Miracast dlna protocol and I have streamed from YouTube on my smartphone to a TV set with such HDMI dongle.

Much cheaper than Firestick or Chromecast !

  1. If not, is there a similar ESP project I might look at.
ofekp commented 5 years ago

Hey there, I am not sure I fully understood the setup. That said, this project does support ESP (many thanks to @GIPdA for that) so you will be able to use it but If you are using the Arduino Library manager then the tag does not yet include the ESP support.

I will update the tag with the new version that supports ESP within 2-3 days. Otherwise, the master branch is already updated with it.

Hope this helps!

GIPdA commented 5 years ago

Hello, UPnP is merely a way to open ports in your router, to save you the troubles of doing it yourself ;) Also, it is considered unsafe (or just is, as anything can modify your NAT without your word, pretty much) and hence may not be available everywhere. Can't see how it would be used in your setup.

siliconhippy commented 5 years ago

Hello, UPnP is merely a way to open ports in your router, to save you the troubles of doing it yourself ;) Also, it is considered unsafe (or just is, as anything can modify your NAT without your word, pretty much) and hence may not be available everywhere. Can't see how it would be used in your setup.

Can you kindly describe why not, and any available alternative?

I am thinking of a xupnpd.org scenario here.

Thanks 😊

GIPdA commented 5 years ago

I simplified a bit, UPnP can do quite a bit more than opening ports, but this library does only that, and I don't see what purpose simply opening ports would serve you. I'm not knowledgeable in what you're trying to do, so I can't help you, sorry. And I don't know of any other resources in that field either.

ofekp commented 5 years ago

@siliconhippy, this library will open ports for you in your router automatically, which will allow you to query your device from outside your network. What you're after seems to be a different thing since I highly doubt you are going to stream media outside your local network. Within your local network there is no need for port forwarding. I think you're more likely after a package that will implement the server side of the SSDP (Simple Service Discovery Protocol) so that your network will discover your device as an iptv. TinyUPnP package uses SSDP to discover the capabilities of a router and use it to open ports, so it is more like a client side of the SSDP. If you wish to get technical, you can read more about SSDP here: https://en.wikipedia.org/wiki/Simple_Service_Discovery_Protocol

I hope this helps.

siliconhippy commented 5 years ago

Ofekp,

That for the update and explanation !

*Here is what I think I need, and any help I would appreciate:

  1. Set up an iptv server in the Cloud ( trivial, with Plex or Emby etc.)

  2. At home, use an HDMI Miracast /EzCast cheap dongle for TV set, to be able to receive this 480/720p iptv streaming as client device:

A. US$6.20 10%OFF | Chromecast Anycast M9 Plus TV Stick 4K M100 Wireless WiFi Display Dongle Receiver Ezcast Airplay HDMI Google Chromecast https://s.click.aliexpress.com/e/Ft2srwfI

As you know, this dongle can receive a WiFi stream from an Android or iPhone for recorded or live streaming ( eg from YouTube.)

The phone also acts as remote control to change channels, and do FF/RW etc.

B. But what I want this dongle to do is receive the IPTV stream over wifi from the Cloud iptv server; and use a regular TV IR remote control, with maybe this kind of an esp8266 cheapo setup?

https://www.instructables.com/id/Easiest-ESP8266-Learning-IR-Remote-Control-Via-WIF/

C. So the idea is:

So here the esp8266 board ( eg nodeMCU with mini USB port) is acting as a WiFi router.

I hope this is a better explanation than the one earlier on your GitHub!

  1. Do you think this will work?

This should be a very flexible and cheap home setup, with the cloud server responsible for all kinds of streaming and updates etc needed over time ( also cheap since the many home devices connected don't need labor intensive updates.)

Cheers, 😋 Shippy.

On Sat, Nov 16, 2019, 4:03 PM Ofek notifications@github.com wrote:

@siliconhippy https://github.com/siliconhippy, this library will open ports for you in your router automatically, which will allow you to query your device from outside your network. What you're after seems to be a different thing since I highly doubt you are going to stream media outside your local network. Within your local network there is no need for port forwarding. I think you're more likely after a package that will implement the server side of the SSDP (Simple Service Discovery Protocol) so that your network will discover your device as an iptv. TinyUPnP package uses SSDP to discover the capabilities of a router and use it to open ports, so it is more like a client side of the SSDP. If you wish to get technical, you can read more about SSDP here: https://en.wikipedia.org/wiki/Simple_Service_Discovery_Protocol

I hope this helps.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ofekp/TinyUPnP/issues/46?email_source=notifications&email_token=AKCL4ELU7JWYYWTYTGYORQTQUBN3XA5CNFSM4JLO5TS2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEEH2P6I#issuecomment-554674169, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKCL4EK5FEJCC7EIVEX2L4DQUBN3XANCNFSM4JLO5TSQ .