Project

General

Profile

tvheadend on DLNA/UPNP enabled devices

Added by Niels Hüsken over 10 years ago

I've been spending hours to find information on how to setup tvheadend in a way that I can watch DVB-S2 streams on my UPNP Enabled devices (e.g. smart TVs, Android based Mediaplayers etc). I still cannot believe noone is looking for such an easy solution. Everbody seems to be happy with their xmbc-headends. I find this pretty inconvinient because you need another PC just to watch TV. After hours of fiddling around I finaly got it to work. I wanted to share with you how I did it. Its actualy quite easy once I found out the details how TVH configures the DVB-S Stream.

I used mediatomb to do the upnp-part. I assume your TVH is already setup/ configured and running. I am running TVH-version 3.9.1164~g10558cc~trusty. I also assume you have no problems to install mediatomb and know how to access its configuration

First, go to the Configuration->Channel/EPG/Channels tab of TVH. Open the "Play"-Link in VLC. In VLC go to "Tools"->"Media information". On the bottom of the window it tells you the URL VLC is using to play back the stream. Copy that URL.

Next, go to the mediatomb-configuration frontend, click "add item".

Choose "External Link" from the drop-down combobox.
Title: <thechannelname>
URL: <paste in the URL you copied before here>
protocol: http-get
class: object.item.videoItem
Description: <something, any text>
mimetype: video/x-matroska

Click "save" and thats it. Unfortunatly you need to do this for every channel you want to have available on your devices.

So far it seems to be working for me on my Android-Mediaplayer, LG SmartTV and my "older" Sony TV. I haven't checked my PS3 yet...


Replies (5)

RE: tvheadend on DLNA/UPNP enabled devices - Added by Eric Valette over 10 years ago

This has been discussed in lenght with adam on various occasion and we basically ended up with this conclusion:

  1. It is not tvheadend job to implement a full DLNA stack because its becoming more and more complex as the DLNA standard requires more and more things,
  2. There are various DLNA DMS available including minidlna that is able to automatically reindex the PVR content each time a new recording is available, so no specific things to do for PVR,
  3. Remains live content that basically could be handled two way
  1. Via a m3u play list for all the channels that could be saved manually in the PVR content location or anything that is indexed automatically by the DMS. Tvheadend is now able to expose all channels as a m3u list, im not sure the way it is donne is correct for a DMS (you need special format for each entry to indicate is should be streamed and not wait for a full download before starting. This is the most simple way for tvheadend,
  2. If the DMS support the primitives to dynamically create object and insert it in the CDS tvheadend could use that to create the objects for live channels. But the support for the dynamic creation primitive is optionnal and seldom implemented in opensource code (and minidlna does not implement it)

So the only missing point is to check the channel list exposed as m3u file has the right format and you DMS support coversion of M3U play list to DLNA playlist.

RE: tvheadend on DLNA/UPNP enabled devices - Added by Niels Hüsken over 10 years ago

I personly think it's noones job to implement anything in the opensource galaxy where the programmers are not getting payed for the software they are creating and giving it away for free. Its absoluty fine with me and I am thankful for what has been done so far. The people who work on the project have done a great job.

I switched to tvheadend because last week my home windows server died in a head crash. It ran dvbviewer (software, I happily payed for) with a plugin called recordingservice. This recodingserves has a full featured DLNA/UPNP-Stack which is used to broadcast DVB-(S/S2) Live-TVContent and recorded Shows. I was able to watch TV on basicly ANY device in my house and it made things really cool. Instead of having multiple, hunderts coax-cables for each television set, I just need one network cable (or even no cables using wifi).

I was looking for a comparable solution in the linux world because I still have this other machine of mine running asterisk PBX setup and finaly ended up using TVH. Its not as good as dvbviewer because it lacks a few features and it's a bit more of a hassle to set it up. But for the moment it's good enough.

I want to say thank you for giving this piece of good software away for free.

RE: tvheadend on DLNA/UPNP enabled devices - Added by Niels Hüsken about 10 years ago

One question:

I just briefly looked at the code in muxer.c. It makes me believe that tvheadend is actualy able to enclose the livestreams into a mepeg2TS-Container via http. That would make it even more compatible with an even broader selection of devices. I believe there are more front-end devices supporting mpeg2ts than matroska. Is there a way to force it to use it for live streams? If so, how?

RE: tvheadend on DLNA/UPNP enabled devices - Added by Tobias Graf about 10 years ago

Niels, your post saved me an awful lot of time and grief when I set this up on my home server this morning. So thank you very much for your post! In case you haven't figured this out already, you can stream channels in mpeg2TS containers by appending "?mux=pass" to the URL and specifiying the corresponding MIME type (video/mpeg) in MediaTomb. See here: https://tvheadend.org/projects/tvheadend/wiki/Tvheadend-32 .Works like a charm for me on a Sony Blu Ray player!

RE: tvheadend on DLNA/UPNP enabled devices - Added by Patrick Gaubatz almost 10 years ago

Hi,

I'd like to make you aware of a little plugin that exactly solves your problem: https://tvheadend.org/boards/5/topics/14146

Cheers,
Patrick

    (1-5/5)