# OTA HDTV, TVheadend port, cards etc



## PacketMan (Apr 27, 2016)

So I stumbled upon this port:

multimedia/tvheadend, and found a page with screenshot:
https://tvheadend.org/boards/5/topics/10512?r=14541

Anyone have a nice setup going involving an OTA (Over The Air) HDTV tuner card, and have it streaming to remote devices? While web browsers are nice on the viewing, I would really be interested to read if anyone has this running where it it streams out via DLNA, or as a multimedia/plexmediaserver channel.

Any other ports I should be looking at? And please tell me what specific hardware you are using on the tuner. Thanks again.

EDIT: looks like I can stream to multimedia/kodi.  And should I be considering other forms of input instead of using a PC tuner card directly?


----------



## wblock@ (Apr 28, 2016)

I would like answers to that also.  Even an answer like "which tuner card works?" is difficult to find.  More specific questions like "which one works on FreeBSD" or like how to set up a tuner card with a current version of Kodi, are pretty hard to find.


----------



## PacketMan (Apr 28, 2016)

Yeah. I am thinking it might be better to find external type tuner devices, get the audio/video output in some sort of format that TVheadend will accept.  I'll try to do some research on this, but hopefully someone else has the instant gratification answers. 

Found this:
https://lists.freebsd.org/pipermail/freebsd-multimedia/2011-January/011532.html


----------



## SirDice (Apr 28, 2016)

I think the last time I had a working TV card was one that used the bktr(4) driver (that's for cards based on the BT848 chipset). And that was many years ago.



PacketMan said:


> EDIT: looks like I can stream to multimedia/kodi. And should I be considering other forms of input instead of using a PC tuner card directly?


Kodi should be able to stream from a remote MythTV, it just requires the MythTV tuner plugin. If you can set up a Windows or Linux machine with a working card you should be able to stream TV to any Kodi client.


----------



## PacketMan (Apr 29, 2016)

And it looks like it can receive IPTV streams.  I installed the port, tried adding some IPTV streams but could not get any to work, so more reading there.  But I'm not sure these streams are even valid so more research there too.  Does anyone know of a web site or two that references good quality programming/streams that are useable in Canada, meaning not blocked?


----------



## tingo (May 1, 2016)

It is not a OTA setup (I have cable, DVB-C), but you can read about my experience with the tvheadend port here: https://sites.google.com/site/tingox/digitaltv_tvheadend_freebsd
Unfortunately, current status is "not working". FWIW, it works under Linux: https://sites.google.com/site/tingox/digitaltv_tvheadend_xubuntu
I use a HDHomeRun 4DC as tuner: https://sites.google.com/site/tingox/silicondust_hdhomerun_4dc
HTH


----------



## PacketMan (May 9, 2016)

tingo said:


> It is not a OTA setup (I have cable, DVB-C), but you can read about my experience with the tvheadend port here: https://sites.google.com/site/tingox/digitaltv_tvheadend_freebsd
> Unfortunately, current status is "not working".



Tuner card (hardware) issue?  I've been looking to see if anyone makes a lower cost (i.e. non professional grade) HDTV rf multi-channel receiver processor with MPEG-TS IP output. In other words let an external box do the tuning/receiving and output it as IP MPEG-TS. The let TVheadend 'subscribe' to that. No luck finding non professional grade stuff.  Is there a Kijiji for this kind of stuff?


----------



## PacketMan (May 19, 2016)

Anyone using SAT>IP configuration with TVheadend? If yes can you tell me/us about it? 

Thanks in advance,
PM


----------



## PacketMan (May 22, 2016)

Or maybe there is another better port I should be using?


----------



## PacketMan (May 27, 2016)

Hmmmm.  It looks like this combo might work, and has been reported to work:

multimedia/tvheadend

multimedia/libhdhomerun
http://www.silicondust.com/hdhomerun/

As per comment made by a fellow named Middling:
https://forums.freenas.org/index.php?threads/tv-tuner-support.34463/

Does anyone know for sure, before I go out and buy more stuff?


----------



## fossette (Jun 16, 2016)

At this time, *I use an HD Homerun device.*  I set its parameters via it own web page.  I use a multimedia/mplayer command to select and watch a channel.  My device has 2 channels, so I can launch two of those commands at the same time.  The 'm' key is useful to mute.  To record, I click the 'c' key (capture on/off).

I'm still looking for a solution to record on a schedule.  I haven't been very successful with the TV stuff ports that I tried at first...  If anyone has a simple tool, I'm interested.  If not, I'm about to try something with `cron` and `mencoder`.  The trick is setting up the recording duration where I think it works better when specifying a maximum file size instead.  Weird euh?

Before, I had bought a Hauppauge USB device seeing that they were promoting Linux support, but sadly, my particular model never was supported.  It appears that this model must receive a firmware upload from a Windows driver on each power-up... dead in the water.  *Don't buy Hauppauge!*

Dominique.


----------



## Phishfry (Jun 16, 2016)

What Hauppauge USB  stick are you referencing? I have an HVR-950Q I have been trying to get working under multimedia/webcamd.
I got to exactly the same place as this guy:
http://lists.freebsd.org/pipermail/freebsd-multimedia/2015-June/016273.html
`w_scan` hangs for me as well in the same spot.
_Info: using DVB adapter auto detection.
_
Linux/Kodi/tvheadend works well but device runs hot.

I also have Hauppauge HVR1250 and 2250 for testing..


----------



## Phishfry (Jun 16, 2016)

This page seems to suggest HVR-950Q works with the dvb-fe-xc5000-1.6.114.fw firmware
https://wiki.freebsd.org/WebcamCompat

Got my firmware from here:
https://www.linuxtv.org/wiki/index.php/Xceive_XC5000/XC4000

What is required to load this firmware besides placing it in the /boot/modules folder? Is that the correct location for firmware?

Would i need a loader.conf entry to load the firmware, like on some wifi blobs?


----------



## fossette (Jun 16, 2016)

Phishfry said:


> What Hauppauge USB  stick are you referencing?


I got the WinTV-HVR-1955 about 18 months ago.  At that time, I was in talk with Hauppauge's Support to bring my humble contribution for a FreeBSD implementation.  I signed a non-disclosure agreement, but never heard back, even after some follow-up emails.  But I just visited their website now, and they list my model supported under Ubuntu.  So thank you very much, Phishfry.  I'll sink my teeth into this tarball they provide on their website when I'll have the time.



Phishfry said:


> What is required to load this firmware besides placing it in the /boot/modules folder? Is that the correct location for firmware?
> 
> Would i need a loader.conf entry to load the firmware, like on some wifi blobs?


Oh!  I don't know what is the process exactly, but I really don't think it goes through the /boot directory.  The firmware uploaded onto the USB device, the file, goes through a memory transfer via the USB port, then the activation using the device's hardware registers (via USB strings acting as commands).  It's completely unrelated.

I love the HD Homerun because it uses standard Internet protocols.  As one says, it's plug and play.

Dominique.


----------



## fossette (Jun 17, 2016)

I installed multimedia/tvheadend.  At first, it wouldn't build because of missing functions during the linking phase.  For example, the missing inotify_init1() function called in fsmonitor.c.  This error is addressed by deinstalling devel/libnotify.

Tvheadend detects my HDHomerun device and its two tuners, but I can't get it to detect the ATSC channels, perhaps just because of my lack of understanding of the numerous possible options...

I started a topic here:
https://tvheadend.org/boards/4/topics/21362
and will report back any new findings.

PS: Is this topic still off-topic?  ;-)
Dominique.


----------



## fossette (Jun 18, 2016)

I've got all my OTH stuff working now, both the player and the recorder.  To answer PacketMan's original question, here's what works for me.  The *HDHomeRun* devices are already streaming servers compatible with DLNA TVs, and computers via http.  Warmly recommended!!!

What I use to configure the HDHomeRun on FreeBSD:
Any web browser.  It's the simplest thing.  I did set the *Default Transcode Profile* to *internet540* because a 960x540 pixels TV is big enough for me, and it doesn't consume too much computer resources.

What I use as a TV player on FreeBSD:
I like multimedia/mplayer because of its command line options.  I can record what I see using the 'c' key.  multimedia/vlc is good too.

What I use to record TV on FreeBSD:
multimedia/ffmpeg  Now why didn't I think about it before?  Maybe because its options are scary?  So here is what works with the HDHomeRun.  My overall bitrate is about 2 Mbps, but since it could reach 12 Mbps, I use the `-bufsize 12000000` output parameter. I also force a MPEG-2 Transport Stream container using `-c copy -f mpegts` output parameters.  For the recording duration, simply use the `-t` parameter, but make sure you use it as an *OUTPUT* parameter.  It doesn't always work as an input parameter, and I don't know why.  I guess that `cron` will be my friend after all (for the TV recording schedule).

Now that it's over, I can finally deal with other stuff!  

Dominique.


----------



## Phishfry (Jun 19, 2016)

I want a compact ATSC tuner for notebook use and don't want a separate box.
I bought the MCE version of the HVR950Q USB stick so it's either open source usage or in the junk drawer.
I generally liked their WinTV app as I have used Hauppauge products a long time.

I am currently using Xubuntu with Me TV and HVR950Q and it works well. Hard to believe Me TV is unmaintained it works so well for OTA.


----------



## fossette (Jul 16, 2016)

I have some issues with multimedia/ffmpeg recorded files, perhaps some missing command line options, so I started a topic here if you are interested:
http://ffmpeg.gusari.org/viewtopic.php?f=11&t=2998

Dominique.


----------



## PacketMan (Jul 29, 2016)

Thanks guys. I'll give this a good read through this autumn after sport fishing season cools down.  Hoping to get something slick up and running, and of course will share with the community.


----------



## PacketMan (Dec 18, 2016)

I'm tempted to buy a HDHomerun device for my OTA, my finger is on the trigger. But I am also considering FTA satellite. Anyone know if drivers for this company products are available? Any other company products have drivers available in ports tree?

http://www.tbsdtv.com/products/tbs6908-professional-dvb-s2-quad-tuner-pcie-card.html


Anyone having much success with USB based receivers and using multimedia/webcamd?


----------



## ekingston (Dec 19, 2016)

PacketMan said:


> I'm tempted to buy a HDHomerun device for my OTA, my finger is on the trigger. But I am also considering FTA satellite. ...



I don't know about the products. A long time ago (before digital TV) I had a freebsd box that used a Hauppauge card for TV capture.

Recently I've been looking at OTA options for capture/streaming and I've come to the decision that I will get a Tablo appliance. It appears to me to be a network attached OTA HD PVR. Plug in antenna and USB HDD, program it like a VCR, it captures. Then use the web interface (or Roku/ATV/etc. device) to watch the recorded shows.

I've confirmed it works find with both Canadian and US terrestrial broadcast (anything clear QAM, I believe).

Let me know how the HDHomerun works. I haven't got the Tablo yet.


----------



## PacketMan (Dec 20, 2016)

ekingston said:


> ...... A long time ago (before digital TV) I had a freebsd box that used a Hauppauge card for TV capture.
> 
> ..... I will get a Tablo appliance. It appears to me to be a network attached OTA HD PVR. Plug in antenna and USB HDD....



As soon as a I learned I need an external HDD to make a Tablo work that was the killer for me. No longer interested.  If someone could show me that a certain tuner card will work with FreeBSD 10.3-RELEASE for 11.x-RELEASE. That would be ideal for me, but I can't be buying a dozen cards hoping to get one to work. I suppose I could break down and build a Linux machine, but I'm holding out. I've been writing vendors cards asking them to provide native FreeBSD support.


----------



## ekingston (Dec 23, 2016)

PacketMan said:


> As soon as a I learned I need an external HDD to make a Tablo work that was the killer for me. No longer interested. If someone could show me that a certain tuner card will work with FreeBSD 10.3-RELEASE for 11.x-RELEASE. That would be ideal for me,



I understand the reluctance when you realize you need an external HDD too. I had that same thought until I realize that it meant I could start with the old USB hard drives I've got kicking around and "upgrade" the storage in the future. Something I can't do with the PVR the cable company wants to give me if I would only sign up for cable again. But that's me, not you.

I'm very much with you on the tuner card issue. Otherwise I would still have one in my FreeBSD system and not be looking at the Tablo.

Have you seen the FreeBSD wiki page on HTPCs? https://wiki.freebsd.org/HTPC It needs some love.


----------



## PacketMan (Oct 29, 2017)

So I bought the HDHomeRun Extend (Canadian version).  I am running multimedia/plexmediaserver Version 1.9.4.4325 and it took me every bit of 5 minutes to get Plex features DVR and Live TV working flawlessly with HDHomeRun. Scheduling your recordings in the DVR is well layed out and well done.  Watching live TV, equally well done, and both features are working flawlessly.

FreeBSD + Plex + HDHomeRun is the best thing since sliced bread. Simply joyfully easy. Its how technology should work together.

As for TVHeadEnd, I pretty much got it all done, the HDHomeRun device is recognized, the muxes build and channels are successfully scanned and tuned.  But try and get it to stream to a media playing device (browser, vlc, etc). I have been at it for hours and no joy yet. TVHeadEnd seems like a decent product, but there seems to be an expectation you are more well versed in manually building TV services in a processing machine. I'll keep at it, but Plex Media Server kinda makes it a moot point, unless you are also trying to do stuff like satellite TV as well. Assuming I get it working, I will update in here.


----------



## PacketMan (Nov 1, 2017)

Still trying to get TVHeadEnd working with HDHomeRun Extend.  Looks like I am getting transport and continuity errors. Researching trying to determine what the cause is.


----------



## Phishfry (Nov 2, 2017)

PacketMan said:


> device is recognized, the muxes build and channels are successfully scanned and tuned. But try and get it to stream to a media playing device (browser, vlc, etc). I have been at it for hours and no joy yet.


Your not alone. I only got to the same spot. Does the 'Watch TV' button work for you?
Basically I have it tuning and EPG working. That's it. I tried my Fusion HDTV7 again with the same results.

I reverted to Debian to see how tvheadend is supposed to work and I can say that I had to build from source there because of problems.
I am thinking of trying VDR instead on FreeBSD.


----------



## PacketMan (Nov 2, 2017)

Phishfry said:


> Your not alone. I only got to the same spot. Does the 'Watch TV' button work for you? ........   I am thinking of trying VDR instead on FreeBSD.



Nope. When I try the "Watch TV" it just sits there, eventually times out saying "an error occurred". I kinda got the impression it was a streaming issue so I tried my hand at building some stream profiles.  I ended up building almost a dozen of them but it made no difference. Then I noticed the transport and continuity errors. I did a fair bit of reading last night, but no joy yet.  The TVHeadEnd forum and documentation is weak at best.  Really can't see that software and user base surviving beyond 2020. But I hope am wrong. I am not interested in it primarily as a DVR, but its capabilities of ingesting a wide variety of video sources. I'm hoping, mostly for fun and learning, to get SAT>IP up and running (need to find a SAT>IP receiver that will work in my part of Canada), and get IPTV streams up and running from legitimate sources. I think TVHeadEnd has great potential, but the support doesn't seem to be quite there.  Wish I was a coder, this would be a 2nd opportunity where I could see myself contributing.

I'll keep at it. Stay tuned.  If you make any progress let us know please and thanks in advance.


----------



## Phishfry (Nov 2, 2017)

I really can't say tvheadend is bad as it works fine on Linux. We just need to get the port whipped into shape.
It does seem like a very small group of developers though. I figured out how to install it on Stretch from repos now too..


----------



## PacketMan (Nov 5, 2017)

Still no joy in getting TVHeadEnd working, but I ended up trying multimedia/emby-server too. Got it up and running in just a couple minutes without any issues, with HDHomeRun Extend (Canadian version).  I'll keep trying to get it working on TVHeadEnd.  Wish its forum was a little more responsive, at least to point me in a direction.


----------



## PacketMan (Nov 10, 2017)

I've given up on trying to get TVHeadEnd working with HDHomeRun Extend for now. Maybe someday with satellite or something else.


----------

