Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[(large) feature] TVHeadend HTSP support #92

Open
rubdos opened this issue Aug 3, 2017 · 1 comment

Comments

Projects
None yet
2 participants
@rubdos
Copy link

commented Aug 3, 2017

I just asked this on IRC; I'll just post it here too.

About TVHeadend

TVHeadend is a TV streaming server and recorder for Linux, FreeBSD and Android supporting DVB-S, DVB-S2, DVB-C, DVB-T, ATSC, ISDB-T, IPTV, SAT>IP and HDHomeRun as input sources.

On top of those input sources, anything that's streamable (without DRM, usually) TV or radio can get into TVHeadend.

Tvheadend offers the HTTP (VLC, MPlayer), HTSP (Kodi, Movian) and SAT>IP streaming.

Multiple EPG sources are supported (over-the-air DVB and ATSC including OpenTV DVB extensions, XMLTV, PyXML).

TL;DR: TVHeadend streams radio, TV, from any source over the network.

What's currently possible with mpd and TVHeadend

I'm currently listening to "Radio 1" (Belgian national radio) using the .m3u playlist that TVHeadend generates (http[s]://[tvheadend]/playlist). This playlist contains a randomized session key, such that the player client does not have to authenticate with TVHeadend over HTTP AUTH.

An image as example (note that the first four songs are from a CD):

Example of the current setup in ncmpcpp

As you see, no channel name is available, nor the current programme name, although TVHeadend has this information. It is simply not transferred over this https stream.

Actual feature request

Note that I am willing to develop the feature myself; I just need confirmation that it would eventually be mainlined

TVHeadend has a proprietary protocol called htsp (home theatre system streaming protocol, afaik), which can be queried for channels, EPG information, and can be used to stream the actual audio.

I suggest to have mpd have a configuration item, e.g.,

tvheadend {
  host "localhost:9982"
  user "mpd"
  pass "pass_mpd"
}

so it connects/tries to connect on MPD startup, and queries for channels, which it makes available for playback.

Things to consider

  • There will not be a clear mapping from (channel name, playing programme) -> (artist, album, genre, title) any more. I just saw there's an Icecast plugin; I'll have a look what they do.
  • More things I didn't think about.
@rubdos

This comment has been minimized.

Copy link
Author

commented Aug 3, 2017

There is currently an implementation of htsp (afaik, the only current one, and the only one that's 100% likely to be up to date) here, in the kodi hts addon. It's GPLv2'd.

A while ago, I started implementing htsp myself in Rust (mostly as exercise, and to use it in a SalifishOS app), which is mostly working now.


I suppose you guys rather have me use libhts from kodi?

@rubdos rubdos referenced this issue Aug 3, 2017

Closed

WIP HTSP #93

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.