View for Linux?

Help and support for HDHomeRun DVR and HDHomeRun software for Windows 10, Mac, Android, XBox, etc.
nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Sun Jun 02, 2019 9:10 am

Our HDHomeRun hardware APIs are open for everyone to use.

For example, you can do a 1 hour recording of channel 5.1 with wget:
wget http://<ip address>:5004/auto/v5.1?duration=3600 -O recording.ts

(Linux guy myself)

Nick

rpcameron
Posts: 818
Joined: Fri Mar 25, 2016 9:55 am

Re: View for Linux?

Post by rpcameron » Sun Jun 02, 2019 10:53 am

speedingcheetah wrote:
Sun Jun 02, 2019 8:25 am
GGRussell wrote:
Sun Jun 02, 2019 7:17 am
speedingcheetah wrote:
Sat Jun 01, 2019 8:51 pm
Especially since this is a paid, for profit, software and devices.
That could be debated. The software is free. Anyone can download and install it. What you 'pay for' is the DVR service and TV Guide data.
:roll:
Anyone can downloaded it, but not anyone can use it.

...you have to pay for the SD hardware....in oder to use the "free" software....that only works on this exact, proprietary hardware...don't forget.
The larger point however is that you can use the tuners without SD's software. If your browser and file-type associations are properly setup, you can navigate to the device's lineup on its internal web UI, click on a channel number, and it will play in your media player of choice.

(Also, considering that many users find SD's "slice guide" to be quite annoying/difficult to use, a pair of browser windows opened to Zap2It and your tuner's lineup might offer a better UX.)

It has already been explained that if you want a first-party solution using a Linux desktop, your only option is to use their add-on through Kodi; SiliconDust does not provide a different first-party solution for Linux. If this solution is not to your liking, you can either return your hardware and look for a vendor that provides what you are looking for, or you can pursue many of the other options that exist for using SD's hardware on your Linux desktop.

jake21
Posts: 8
Joined: Fri Jul 29, 2016 12:40 pm

Re: View for Linux?

Post by jake21 » Sat Jun 15, 2019 8:37 pm

What is the URL for obtaining the lineup (does it show what is currently playing like the app?). I understand the issue is like DRM for providing an app for linux but even if only DRM channels were not watchable with the the app on linux would be great as most channels do not have DRM (at least with comcast). While I normally use vlc to watch tv the app is nice for seeing what is currently playing (you can get this from comcast but they like to list a lot of channels for which you do not have access which make their listing annoying.

gtb
Expert
Posts: 3906
Joined: Thu Oct 06, 2011 1:00 pm
Location: Sunnyvale, CA USA

Re: View for Linux?

Post by gtb » Sat Jun 15, 2019 9:18 pm

jake21 wrote:
Sat Jun 15, 2019 8:37 pm
What is the URL for obtaining the lineup (does it show what is currently playing like the app?)
Channel lineup for a tuner is available based on the response to the http://tuner-ip/discover.json request (the element is LineupURL), but always seems to be http://tuner-ip/lineup.json . Guide data is only available to SD apps per viewtopic.php?f=92&t=20545

nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Sat Jun 15, 2019 10:31 pm

The recommended approach is to add "?DisplayGroupID=root" to the recorded_files URL to get the top level information needed for a typical UI.

When the user selects a series to go into use the URL in the returned data to get the list of recordings available for that series.

Nick

jake21
Posts: 8
Joined: Fri Jul 29, 2016 12:40 pm

Re: View for Linux?

Post by jake21 » Sun Jun 16, 2019 6:07 am

Can you provide some examples - I knew about the lineup.{xml,json} library but they don't provide guide information. The link indicates that is just for sd usage but that is the primary advantage of the app which is not available for linux.
-
I'm not sure what ?DisplayGroupID=root is providing with regards to information. When I try it in the browser (i.e, myip/lineup.xml?DisplayGroupID=root )it doesn't seem to do much. Also is there a work around for lack for style sheet for xml?
--
For watching tv i normally use vlc [provided url which is myip:5004/auto/vXXX]; to see what is playing i check comcast website but wouldn't mind scripting something to pull my favorite channels - but i have no clue how ot get guide info.
nickk wrote:
Sat Jun 15, 2019 10:31 pm


The recommended approach is to add "?DisplayGroupID=root" to the recorded_files URL to get the top level information needed for a typical UI.

When the user selects a series to go into use the URL in the returned data to get the list of recordings available for that series.

Nick

nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Sun Jun 16, 2019 7:47 am

Ah, sorry, I read your post thinking DVR rather than Tuner.

For HDHomeRun tuners simply request http://<ip address>/lineup.json
The HDHomeRun will return the list of channels including the URLs for each one.

To play live in VLC simple drop the channel URL into VLC. (VLC doesn't support sender-pacing so isn't ideal but will usually play).

Nick

jake21
Posts: 8
Joined: Fri Jul 29, 2016 12:40 pm

Re: View for Linux?

Post by jake21 » Sun Jun 16, 2019 8:59 am

But can we get the channel guide for personal use ?
nickk wrote:
Sun Jun 16, 2019 7:47 am
Ah, sorry, I read your post thinking DVR rather than Tuner.

For HDHomeRun tuners simply request http://<ip address>/lineup.json
The HDHomeRun will return the list of channels including the URLs for each one.

To play live in VLC simple drop the channel URL into VLC. (VLC doesn't support sender-pacing so isn't ideal but will usually play).

Nick

nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Sun Jun 16, 2019 10:18 am

jake21 wrote:
Sun Jun 16, 2019 8:59 am
But can we get the channel guide for personal use ?
It depends on the use.
Reqesting guide as needed to display in a UI is fine. Grabbing / exporting / storing in a database is not.
Likewise images can be cached following the cache information but can't be otherwise stored.

1) Request /discover.json from the HDHomeRun to get the DeviceAuth string.
If you have multiple HDHomeRun devices you concatenate the DeviceAuth strings together (any order, no separator).

2) Request https://api.hdhomerun.com/api/guide?DeviceAuth=xxx
This will return the guide across all channels of all your devices for the next 4 hours.
Please include a meaningful UserAgent string identifying your application and version when making the request.

Nick

jake21
Posts: 8
Joined: Fri Jul 29, 2016 12:40 pm

Re: View for Linux?

Post by jake21 » Sun Jun 16, 2019 12:18 pm

Is this an ok use:

I small program that will list the current shows for only those channels that interest myself. Basically wget but grepping for hd channels with a few channels. I'd run it in an xterm and use less to scroll through the current list. I don't care about the images - i might have to write something a bit more complex depending on the format of the data returned.
nickk wrote:
Sun Jun 16, 2019 10:18 am
jake21 wrote:
Sun Jun 16, 2019 8:59 am
But can we get the channel guide for personal use ?
It depends on the use.
Reqesting guide as needed to display in a UI is fine. Grabbing / exporting / storing in a database is not.
Likewise images can be cached following the cache information but can't be otherwise stored.

1) Request /discover.json from the HDHomeRun to get the DeviceAuth string.
If you have multiple HDHomeRun devices you concatenate the DeviceAuth strings together (any order, no separator).

2) Request https://api.hdhomerun.com/api/guide?DeviceAuth=xxx
This will return the guide across all channels of all your devices for the next 4 hours.
Please include a meaningful UserAgent string identifying your application and version when making the request.

Nick

nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Sun Jun 16, 2019 4:52 pm

That usage shouldn't be an issue.

The data format is json so you probably want to use a scripting language that can import json - PHP, JavaScript, Python, Perl, etc.

My preference is PHP for this kind of work.

Nick

jake21
Posts: 8
Joined: Fri Jul 29, 2016 12:40 pm

Re: View for Linux?

Post by jake21 » Mon Jun 17, 2019 3:13 am

Ok thanks. Didn't realize the data came from silicondust - thought the device was pulling it from the vendor (in my case the hdhomerun device was pulling it from comcast - like a comcast tv box). right now i'll play with curl/wget but if i write a custom program will throw in a custom header - will never pull the images - mentioning this if someone check their server logs. If I were to speculate that auth number is a value passed back to the vendor (comcast in my case) by your server. If this is true then there should be a way to get the data directly from comcast ?

Something like this gets 90% of what I am looking for:
curl https://api.hdhomerun.com/api/guide?DeviceAuth=XXX | grep -i -e guidenumber -e guidename -e '"title":' | less
nickk wrote:
Sun Jun 16, 2019 4:52 pm
That usage shouldn't be an issue.

The data format is json so you probably want to use a scripting language that can import json - PHP, JavaScript, Python, Perl, etc.

My preference is PHP for this kind of work.

Nick

nickk
Silicondust
Posts: 15424
Joined: Tue Jan 13, 2004 9:39 am

Re: View for Linux?

Post by nickk » Mon Jun 17, 2019 8:55 am

Our servers maintain full guide data, imported each day from Gracenote.

Comcast does not make guide data available and is not involved.

Nick

Post Reply