HDHomeRun Prime across a VPN

Help and support with third-party TV software.
Windows Media Center, J River Media Center, Next PVR, MythTV, InstaTV, etc.
Post Reply
Posts: 5
Joined: Sun Aug 13, 2017 2:37 pm

HDHomeRun Prime across a VPN

Post by MushyMiddle »

I've tried various things to try and get HDHomeRun Prime to work from a remote location (don't want to pay for cable twice), and have finally achieved some level of success, after many frustrating failures. Fundamentally, if SD would just allow you to enter an IP address instead of doing discovery, this would likely be unnecessary, but in lieu of that, here's what I have so far - it's a work in progress.

Objective: be able to watch cable on FireTV-equipped remote TVs.

I'll list my failures below, but what seems to work, mostly, is using stream support built into Kodi (and other similar apps). I use Kodi to watch my DVD rips, so it's a convenient place to also watch live TV. VLC also seems to work, but I'm less familiar with organizing things there, and don't generally use it on FireTV anyway.

So, I downloaded lineup.json from HDHomeRun Prime (http://ip-of-hdhr/lineup.json), and converted it to CSV using an online JSON to CSV converter. I was lazy, and didn't have my dev machine available, so was doing this all on an old Mac with no dev tools installed - just Office.

With the now tabular version of my channel lineup, I wrote a couple of Excel formulas and a VBA subroutine to mash the channel # and channel description together into a filename: e.g. "004 - WRC.strm". The VBA code takes the filename and the channel URL (e.g. http://ip-of-hdhr:5004/auto/v4), and writes the URL to the .strm file. I now have a folder with several hundred .strm files, one per channel, each of which has one line - the channel URL.

Next, created a folder on my NAS, put all the .strm files there, and pointed Kodi to it. Kodi sucked-in the .strm files, and now I can open them from Kodi. Voila! SD channels, at least, work great. HD is another matter - I'm on a relatively slow Internet connection, and this is going over a VPN, so it's hard to sustain the necessary 20Mb/s or so bandwidth for HD channels. But, SD is better than nothing, and I may upgrade my bandwidth to see if that helps, now that I at least have a semi-functional setup.

Work remains to spiff things up and add .nfo, .jpg, etc. files for channel meta-data. But, I can live with this for now.

Hope this helps, and I'm still open to trying other things that aren't quite so ugly.

  • It would have been nice if I could have simply opened-up a port on my firewall, but for some reason, that doesn't seem to allow streaming to happen. I've confirmed the port is open and can reach the HDHomeRun Prime, but for some reason it just doesn't work.
  • Of course, HDHomeRun should support non-local hardware in some fashion, directly. But, it doesn't, and I don't have time to muck with the code to see if I can get something working. If I *know* the IP address of my Prime, that should be enough - I don't generally buy the need for discovery prototcols, which aren't VPN-friendly.
  • My Prime was originally on another subnet, indirectly routed to the VPN. This, too, didn't work, so I had to move it to my main subnet so it could reach the VPN directly.
  • I suspect my ISP (out in the sticks) blocks lots of ports, so I tried to use port 80 with SNAT - no joy. I could reach the Prime, but port 5004 (SNAT from/to 80) wouldn't respond properly.

Posts: 15247
Joined: Sun Oct 28, 2007 9:23 pm

Re: HDHomeRun Prime across a VPN

Post by jasonl »

This is pretty much what Emby and Plex are designed for. They've already solved all your issues, and since they can transcode the video you can get optimal video quality for whatever bandwidth you have available.

Posts: 70
Joined: Tue Aug 16, 2011 4:02 pm

Re: HDHomeRun Prime across a VPN

Post by hotshot2k3 »

No need for a VPN to accomplish this


Works with Kodi and basically any app that supports .m3u + xmltv

I prefer this method because you are not locked into a certain software

Posts: 169
Joined: Wed Sep 19, 2018 8:25 am

Re: HDHomeRun Prime across a VPN

Post by tonywagner »

Here's someone who got direct access working over the internet with some firewall rules:

If you don't want to pay for Plex or Emby, there's also Jellyfin which is a free open-source fork of Emby.

Finally, another free alternative (if you're not afraid to tinker) is TVHeadend. You can set up transcoding profiles for remote clients. Then allow the TVHeadend port through your firewall and you should be able to access it from remote clients (I use Kodi, although not remotely).

Posts: 3
Joined: Sat Mar 21, 2020 2:58 pm

Re: HDHomeRun Prime across a VPN

Post by romeo87 »

Hi guys,

I’m trying to have it working over a VPN (remote location scenario as well).
Is there any clear guide to do this?
I don’t want to go for setting up additional devices for transcoding or used as a server.
I’d just need the fireTV stick to intercept the streams of my Prime. I’m currently doing this through VLC but it is quite hard to change channel - is there a way to create a playlist of channels to select from?
Or, any guide to implement the json procedure + Kodi here described?


Posts: 1156
Joined: Mon Dec 10, 2018 12:38 pm

Re: HDHomeRun Prime across a VPN

Post by NedS »

A playlist can be created. Tell me your Device ID and I can throw one together for you. The basic gist of it is this:

Code: Select all

#EXTINF:0,4.3 Escape
#EXTINF:0,4.5 Grit

"" is the local IP address of my HDHomeRun

"vX.X" is the channel number

Everything after "#EXTINF:0," is the displayed name for the channel

The "#EXTINF:0," line and the address in the next line are a single channel

Post Reply