
Re: TV-Tuner/Capture
Given what is known about the R-pi, can Anyone take a guess as to whether You can attach a usb tv-tuner / capture card? I believe I read somewhere on the site that the gpu is a x264 encoder as well as a decoder. Can't find the encoder post to save My life though, was that just wishful thinking on My part? 

Re: TV-Tuner/Capture
My guess is out limiting factor will be finding a good TV tuner that is compatible with Linux
Dear forum: Play nice 

Re: TV-Tuner/Capture
Take a look at http://linuxtv.org/wiki/index....../Main_Page and in particular http://linuxtv.org/wiki/index......SB_Devices
Re: TV-Tuner/Capture
Quote from amiga65 on August 12, 2011, 02:30
Given what is known about the R-pi, can Anyone take a guess as to whether You can attach a usb tv-tuner / capture card? I believe I read somewhere on the site that the gpu is a x264 encoder as well as a decoder. Can't find the encoder post to save My life though, was that just wishful thinking on My part?
Yes, the GPU can encode 1080p30 H264. I'm not sure of the state of the drivers required in Linux to do this though - the data needs to be transferred to the GPU to be encoded, then sent back to the Arm via these drivers. I really need to get to grip with all this Linux driver stuff!!
Given what is known about the R-pi, can Anyone take a guess as to whether You can attach a usb tv-tuner / capture card? I believe I read somewhere on the site that the gpu is a x264 encoder as well as a decoder. Can't find the encoder post to save My life though, was that just wishful thinking on My part?

Yes, the GPU can encode 1080p30 H264. I'm not sure of the state of the drivers required in Linux to do this though - the data needs to be transferred to the GPU to be encoded, then sent back to the Arm via these drivers. I really need to get to grip with all this Linux driver stuff!!
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.
Re: TV-Tuner/Capture
I'd be saying that this would make a pretty nifty MythTV head-end machine when combined with a slightly beefier ARM or Atom based backend, combined with something like Silicon Dust's HomeRun HD system. You'll need at least 100Mbit/1Gbit or N level wireless to pull it off, but past that...
Re: TV-Tuner/Capture
Tv-tuner is a quite demanding piece of hardware, so it probablywon't run very smooth.
I've also found the Linux software very limited and of a disappointing quality.
I've also found the Linux software very limited and of a disappointing quality.
-
- Posts: 3
- Joined: Wed Aug 17, 2011 1:15 pm
Re: TV-Tuner/Capture
I plan on picking up a raspberry pi to pair with the above mentioned HD HomeRun from Silicon Dust. If I can get a working MythTV system out of it, I would end up wanting to do one Raspberry Pi as a dedicated back end with a Raspberry Pi at each TV for the front end. I think they would be perfect for that sort of thing, unless I am missing the load that the HD HomeRuns would put on the backend.
Re: TV-Tuner/Capture
Quote from kevlar2010 on August 17, 2011, 16:14
I plan on picking up a raspberry pi to pair with the above mentioned HD HomeRun from Silicon Dust. If I can get a working MythTV system out of it, I would end up wanting to do one Raspberry Pi as a dedicated back end with a Raspberry Pi at each TV for the front end. I think they would be perfect for that sort of thing, unless I am missing the load that the HD HomeRuns would put on the backend.
You might be missing that. I can't say the CPU is/isn't going to handle it- but if you're having to peel it off of a USB NIC and then push it to an HD, the overhead may be a bit much. My general inclination would be to use a bit more aggressive ARM board or an el-cheapo Atom or AMD APU board for the backend- at least until we see what throughput you can manage over a USB hub.
I plan on picking up a raspberry pi to pair with the above mentioned HD HomeRun from Silicon Dust. If I can get a working MythTV system out of it, I would end up wanting to do one Raspberry Pi as a dedicated back end with a Raspberry Pi at each TV for the front end. I think they would be perfect for that sort of thing, unless I am missing the load that the HD HomeRuns would put on the backend.
You might be missing that. I can't say the CPU is/isn't going to handle it- but if you're having to peel it off of a USB NIC and then push it to an HD, the overhead may be a bit much. My general inclination would be to use a bit more aggressive ARM board or an el-cheapo Atom or AMD APU board for the backend- at least until we see what throughput you can manage over a USB hub.
-
- Posts: 36
- Joined: Sun Aug 28, 2011 11:03 pm
Re: TV-Tuner/Capture
Quote from kevlar2010 on August 17, 2011, 16:14
I plan on picking up a raspberry pi to pair with the above mentioned HD HomeRun from Silicon Dust. If I can get a working MythTV system out of it, I would end up wanting to do one Raspberry Pi as a dedicated back end with a Raspberry Pi at each TV for the front end. I think they would be perfect for that sort of thing, unless I am missing the load that the HD HomeRuns would put on the backend.You'd be hard pushed to run one of these as a MythTV master backend complete with DB server etc. I have a dual core atom doing that and it's really the bare minimum (although I used to use a VIA SP1300 which just about managed it...)
If these will decode mpeg as well as h264 in hardware though they'll make awesome frontends and allow me re-purpose my little ion boxes.
I plan on picking up a raspberry pi to pair with the above mentioned HD HomeRun from Silicon Dust. If I can get a working MythTV system out of it, I would end up wanting to do one Raspberry Pi as a dedicated back end with a Raspberry Pi at each TV for the front end. I think they would be perfect for that sort of thing, unless I am missing the load that the HD HomeRuns would put on the backend.You'd be hard pushed to run one of these as a MythTV master backend complete with DB server etc. I have a dual core atom doing that and it's really the bare minimum (although I used to use a VIA SP1300 which just about managed it...)
If these will decode mpeg as well as h264 in hardware though they'll make awesome frontends and allow me re-purpose my little ion boxes.
Re: TV-Tuner/Capture
I don't have an hd tv. yet just standard def. I know I need to get out of the stone age.
My original thoughts where more along the lines of recording a program while I'm at work type of deal, any other htpc features that will run is just a big plus.
My original thoughts where more along the lines of recording a program while I'm at work type of deal, any other htpc features that will run is just a big plus.
Re: TV-Tuner/Capture
I have used both PCI cards (DVB-T & DVB-S/S2) and USB DVB-T tuners with MythTV. I currently use an Acer Revo as my main 'Front End'. I use a PC with an Intel 945 CPU to record programmes. The Rasp -pi may well be able to fulfill both these roles. You certainly don't need a fancy PC for a MythTV backend and the main limitation for front ends is the video side and that seems to be a goer with the Rasp Pi.
In answer to amiga65. MythTV has a web interface that permits setting of TV recordings as well as downloading of already recorded programmes - so remote setting of programmes is facilitated. On my MythTV box I can record 2 terrestrial programmes and 1 satellite at the same time whilst watching a playback. I don't suggest that the rasp pi will be up to that but you never know.
In answer to amiga65. MythTV has a web interface that permits setting of TV recordings as well as downloading of already recorded programmes - so remote setting of programmes is facilitated. On my MythTV box I can record 2 terrestrial programmes and 1 satellite at the same time whilst watching a playback. I don't suggest that the rasp pi will be up to that but you never know.

Re: TV-Tuner/Capture
dont know about dvb, but for SD there are USB tuners that encode straight to mpeg2
I use one with openwrt tuner
Hauppauge WinTV PVR USB 2.0
you can just cat /dev/video to a file, it will save nice mpeg2 stream
I use one with openwrt tuner
Hauppauge WinTV PVR USB 2.0
you can just cat /dev/video to a file, it will save nice mpeg2 stream
-
- Posts: 178
- Joined: Sun Oct 02, 2011 3:05 pm
Re: TV-Tuner/Capture
Quote from Rasz on October 14, 2011, 05:37
dont know about dvb, but for SD there are USB tuners that encode straight to mpeg2
I use one with openwrt tuner
Hauppauge WinTV PVR USB 2.0
you can just cat /dev/video to a file, it will save nice mpeg2 stream
It's likely not that the USB device encodes to mpeg2. The ATSC(?) stream is already mpeg2 and doesn't require any encoding.
Could you tell us more about your setup?
If OpenWRT can handle a tuner, surely raspberry pi can.
dont know about dvb, but for SD there are USB tuners that encode straight to mpeg2
I use one with openwrt tuner
Hauppauge WinTV PVR USB 2.0
you can just cat /dev/video to a file, it will save nice mpeg2 stream
It's likely not that the USB device encodes to mpeg2. The ATSC(?) stream is already mpeg2 and doesn't require any encoding.
Could you tell us more about your setup?
If OpenWRT can handle a tuner, surely raspberry pi can.
Re: TV-Tuner/Capture
"Hauppauge WinTV PVR USB 2.0" is normal SDTV, not DVB. It has hardware mpeg2 encoder
-
- Posts: 178
- Joined: Sun Oct 02, 2011 3:05 pm
Re: TV-Tuner/Capture
Quote from Rasz on October 14, 2011, 11:36
"Hauppauge WinTV PVR USB 2.0" is normal SDTV, not DVB. It has hardware mpeg2 encoder
Ah, You mean its for analog broacasts? Sorry I didn't consider this since the usa doesn't have these anymore.
"Hauppauge WinTV PVR USB 2.0" is normal SDTV, not DVB. It has hardware mpeg2 encoder
Ah, You mean its for analog broacasts? Sorry I didn't consider this since the usa doesn't have these anymore.
-
- Posts: 17
- Joined: Fri Sep 16, 2011 11:28 pm
Re: TV-Tuner/Capture
@amiga65 What country are you in? Most countries in the developed world are moving or have moved to digital TV broadcasts.
Basically a digital TV tuner is just an NIC device which receives an MPEG2/4 stream, depending on country and whether SD or HD.
As such, to 'record' a program all that happens is the received stream is just saved to disk. It takes very little processing power as there's no encoding going on. You get an exact copy of the stream as it's received and the quality is amazing. The limiting factor is how fast you can save the stream. For high bitrate HD broadcasts the rPis' storage/USB subsystem may not be able to keep up.
If you're wanting to record analogue broadcasts that's a whole different kettle of fish. There's a bit of an art to doing it without a hardware based encoder of the type pointed out previously (highly recommended).
In the past I've done it in Windows, not in linux though, and found you have to make a trade off between all sorts of things, eg codec(used MJPEG as it's fast in software), filesize/bitrate, CPU usage, others. I've always been a bit disappointed with the results really.
It's a bit of a nightmare really. If the encoding can be off-loaded to the GPU it would help matters a lot.
Of course the other thing that might be a problem is drivers. Sticking to tuners from big companies will probably be easier to get drivers for is always easier, but it's also whether they're ARM compatible.
So, yeah, definitely possible, much easier with DVB, let's just hope we can get drivers.
Basically a digital TV tuner is just an NIC device which receives an MPEG2/4 stream, depending on country and whether SD or HD.
As such, to 'record' a program all that happens is the received stream is just saved to disk. It takes very little processing power as there's no encoding going on. You get an exact copy of the stream as it's received and the quality is amazing. The limiting factor is how fast you can save the stream. For high bitrate HD broadcasts the rPis' storage/USB subsystem may not be able to keep up.
If you're wanting to record analogue broadcasts that's a whole different kettle of fish. There's a bit of an art to doing it without a hardware based encoder of the type pointed out previously (highly recommended).
In the past I've done it in Windows, not in linux though, and found you have to make a trade off between all sorts of things, eg codec(used MJPEG as it's fast in software), filesize/bitrate, CPU usage, others. I've always been a bit disappointed with the results really.
It's a bit of a nightmare really. If the encoding can be off-loaded to the GPU it would help matters a lot.
Of course the other thing that might be a problem is drivers. Sticking to tuners from big companies will probably be easier to get drivers for is always easier, but it's also whether they're ARM compatible.
So, yeah, definitely possible, much easier with DVB, let's just hope we can get drivers.
Re: TV-Tuner/Capture
GPU doesn't support MJPEG, because it sucks. MJPEG, not the GPU.
UK analogue broadcast are being turned off countrywide in 1 year and 10 days, as announced today.
As to storing a bitstream, the usual limitation is the speed of the SD card, rather than the connection to it. So if you are using a USB HD there should be no issue.
UK analogue broadcast are being turned off countrywide in 1 year and 10 days, as announced today.
As to storing a bitstream, the usual limitation is the speed of the SD card, rather than the connection to it. So if you are using a USB HD there should be no issue.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.
Re: TV-Tuner/Capture
What country are you in? Most countries in the developed world are moving or have moved to digital TV broadcasts.
And most get their TV signal via cable where analog is still offered. A lot of people has skipped the MPEG2 generation when that was introduced as it already was announced that signals would switch to MPEG4 in 2014 - and you couldn't get any MPEG4 TV sets at that time (two years ago).
I do dare to call Denmark a part of the developed world...
And most get their TV signal via cable where analog is still offered. A lot of people has skipped the MPEG2 generation when that was introduced as it already was announced that signals would switch to MPEG4 in 2014 - and you couldn't get any MPEG4 TV sets at that time (two years ago).
I do dare to call Denmark a part of the developed world...
-
- Posts: 17
- Joined: Fri Sep 16, 2011 11:28 pm
Re: TV-Tuner/Capture
@jamesh Yeah. MJPEG does suck. But it's faster to encode to in software than MPEG2/4. If MPEG4/h264 hardware can be done then that will be good. But it still remains to be seen as to whether it can.
What I was trying to get at with they subsystem/USB bit is that, as the TV tuner and storage device, HDD or SDcard are all connected to the same USB root hub, your overhead is effectively doubled as the stream travels from the tuner over USB to the cpu and then back out over the USB to the storage device. Shouldn't be a problem with SD broadcasts but HD can use quite high bitrates.
@kme You'll notice I said 'Most countries in the developed world'. All countries have differing approaches to how they are implementing the move to digital standards. TBH the codec used and whether it's cable/terrestrial/satellite makes little difference to the way the underlying system works. You're still just receiving a network stream after the signals been demodulated/demuxed. Only difference is quality/bitrate when you get down to it.
What I was trying to get at with they subsystem/USB bit is that, as the TV tuner and storage device, HDD or SDcard are all connected to the same USB root hub, your overhead is effectively doubled as the stream travels from the tuner over USB to the cpu and then back out over the USB to the storage device. Shouldn't be a problem with SD broadcasts but HD can use quite high bitrates.
@kme You'll notice I said 'Most countries in the developed world'. All countries have differing approaches to how they are implementing the move to digital standards. TBH the codec used and whether it's cable/terrestrial/satellite makes little difference to the way the underlying system works. You're still just receiving a network stream after the signals been demodulated/demuxed. Only difference is quality/bitrate when you get down to it.
-
- Posts: 178
- Joined: Sun Oct 02, 2011 3:05 pm
Re: TV-Tuner/Capture
Quote from The Cageybee on October 14, 2011, 14:48
What I was trying to get at with they subsystem/USB bit is that, as the TV tuner and storage device, HDD or SDcard are all connected to the same USB root hub, your overhead is effectively doubled as the stream travels from the tuner over USB to the cpu and then back out over the USB to the storage device. Shouldn't be a problem with SD broadcasts but HD can use quite high bitrates.
I am worried about the same thing.
I'm wondering if there is a way to connect a real hard drive to the SD slot. AFAIK the SD card slot uses MMC directly to the chip. I am not sure what the bitrate of this is.. but it'd be nice if we could use this rather than usb for the disk.
What I was trying to get at with they subsystem/USB bit is that, as the TV tuner and storage device, HDD or SDcard are all connected to the same USB root hub, your overhead is effectively doubled as the stream travels from the tuner over USB to the cpu and then back out over the USB to the storage device. Shouldn't be a problem with SD broadcasts but HD can use quite high bitrates.
I am worried about the same thing.
I'm wondering if there is a way to connect a real hard drive to the SD slot. AFAIK the SD card slot uses MMC directly to the chip. I am not sure what the bitrate of this is.. but it'd be nice if we could use this rather than usb for the disk.
Re: TV-Tuner/Capture
Quote from jamesh on October 14, 2011, 14:17
UK analogue broadcast are being turned off countrywide in 1 year and 10 days, as announced today.
So, what is the BBC using for the UK? ATSC or DVB-T? (I'm guessing DVB-T...)
As to storing a bitstream, the usual limitation is the speed of the SD card, rather than the connection to it. So if you are using a USB HD there should be no issue.
The main problem with the USB HD sticks is one of the gear being supported by the DVB drivers under Linux. Many of them aren't supported right at the moment, with at least a third of the vendors making a minefield by switching out chips on a product line and calling it the same model number, letting the drivers sort out which to talk to. For example, ASUS had a nice one that had Linux drivers and all that came out for the eeePC in Taiwan- but as time progressed, they changed out chipsets and didn't bother telling anyone or warning some that the new ones wouldn't work with the Linux eeePC's.
UK analogue broadcast are being turned off countrywide in 1 year and 10 days, as announced today.
So, what is the BBC using for the UK? ATSC or DVB-T? (I'm guessing DVB-T...)
As to storing a bitstream, the usual limitation is the speed of the SD card, rather than the connection to it. So if you are using a USB HD there should be no issue.
The main problem with the USB HD sticks is one of the gear being supported by the DVB drivers under Linux. Many of them aren't supported right at the moment, with at least a third of the vendors making a minefield by switching out chips on a product line and calling it the same model number, letting the drivers sort out which to talk to. For example, ASUS had a nice one that had Linux drivers and all that came out for the eeePC in Taiwan- but as time progressed, they changed out chipsets and didn't bother telling anyone or warning some that the new ones wouldn't work with the Linux eeePC's.
-
- Posts: 17
- Joined: Fri Sep 16, 2011 11:28 pm
Re: TV-Tuner/Capture
Quote from nullstring on October 14, 2011, 18:13
I am worried about the same thing.
I'm wondering if there is a way to connect a real hard drive to the SD slot. AFAIK the SD card slot uses MMC directly to the chip. I am not sure what the bitrate of this is.. but it'd be nice if we could use this rather than usb for the disk.
I doubt that's possible, but thinking about things more, USB bandwidth might not be too much of a problem.
Again, all countries use different systems and bitrates. I can't detail them all here (and can't be arsed to either) so am basing this on the UK freeview transmissions.
So, first off, USB high speed has a theoretical maximum throughput of 480mbps though real world is more like 240mbps (a little higher actually but better to go lower than higher for these purposes as then we don't have to worry about overhead which on USB is quite high).
The highest bitrate freeview SD channel in the UK is BBC1 which uses a bitrate of 4mbps (all the others use much lower bitrates), freeview HD uses max 10mbps. So if you want to record an SD stream it should only take roughly 8mbps of total USB throughput, HD about 20mbps.
So the USB bus should be able to use and record from multiple tuners. However, USB transfers can be quite CPU intensive when using multiple devices so that might be a restricting factor.
So, on to tuners that can be used in linux. A list can be found here: http://www.linuxtv.org/wiki/in.....SB_Devices.
It seems that DVB-T2, which the UK uses for HD, is only supported by one dongle at the moment and requires a 3.0 kernel. I'm not sure when/if the rPi will get 3.0.
As for drivers, it may be necessary to build a kernel with the drivers from scratch according to this page: http://www.plugcomputer.org/pl......php/DVB-T. (not sure if it all applies as it's for the sheevaplug which uses ubuntu, but the modules needed should be the same)
All of this is blue sky thinking until we can actually get our hands on some rPis' and have a play.
I really hope it can be done, the thought of an uber cheap, low power, networked, customisable and expandable HD PVR really appeals to me.
I am worried about the same thing.
I'm wondering if there is a way to connect a real hard drive to the SD slot. AFAIK the SD card slot uses MMC directly to the chip. I am not sure what the bitrate of this is.. but it'd be nice if we could use this rather than usb for the disk.
I doubt that's possible, but thinking about things more, USB bandwidth might not be too much of a problem.
Again, all countries use different systems and bitrates. I can't detail them all here (and can't be arsed to either) so am basing this on the UK freeview transmissions.
So, first off, USB high speed has a theoretical maximum throughput of 480mbps though real world is more like 240mbps (a little higher actually but better to go lower than higher for these purposes as then we don't have to worry about overhead which on USB is quite high).
The highest bitrate freeview SD channel in the UK is BBC1 which uses a bitrate of 4mbps (all the others use much lower bitrates), freeview HD uses max 10mbps. So if you want to record an SD stream it should only take roughly 8mbps of total USB throughput, HD about 20mbps.
So the USB bus should be able to use and record from multiple tuners. However, USB transfers can be quite CPU intensive when using multiple devices so that might be a restricting factor.
So, on to tuners that can be used in linux. A list can be found here: http://www.linuxtv.org/wiki/in.....SB_Devices.
It seems that DVB-T2, which the UK uses for HD, is only supported by one dongle at the moment and requires a 3.0 kernel. I'm not sure when/if the rPi will get 3.0.
As for drivers, it may be necessary to build a kernel with the drivers from scratch according to this page: http://www.plugcomputer.org/pl......php/DVB-T. (not sure if it all applies as it's for the sheevaplug which uses ubuntu, but the modules needed should be the same)
All of this is blue sky thinking until we can actually get our hands on some rPis' and have a play.
I really hope it can be done, the thought of an uber cheap, low power, networked, customisable and expandable HD PVR really appeals to me.
- Burngate
- Posts: 6401
- Joined: Thu Sep 29, 2011 4:34 pm
- Location: Berkshire UK Tralfamadore
- Contact: Website
Re: TV-Tuner/Capture
Why more than one tuner on the RasPi? Surely you could have one RasPi per tuner, feeding a NAS?
Then you can record as many channels as you want (as long as the bandwidth of the network feeding the NAS can handle it)
This is just an inversion of the problem - we're trying to use the Raspi as the basis of a PVR with the tuner as an add-on component, but it's so cheap it can be used as a component, so the tuner is the basis of the PVR, with the RasPi as an add-on.
Then you can record as many channels as you want (as long as the bandwidth of the network feeding the NAS can handle it)
This is just an inversion of the problem - we're trying to use the Raspi as the basis of a PVR with the tuner as an add-on component, but it's so cheap it can be used as a component, so the tuner is the basis of the PVR, with the RasPi as an add-on.
-
- Posts: 178
- Joined: Sun Oct 02, 2011 3:05 pm
Re: TV-Tuner/Capture
So, does anyone know of a USB TV tuner for ARM linux?
We heard earlier from someone who was using one from an OpenWRT box (probably MIPS?), so I have hope that we can find one for ARM.
Here's hoping the Mygica line works well
http://www.mygica.com/blog/pos.....uners.html
These devices are very cheap.
We heard earlier from someone who was using one from an OpenWRT box (probably MIPS?), so I have hope that we can find one for ARM.
Here's hoping the Mygica line works well
http://www.mygica.com/blog/pos.....uners.html
These devices are very cheap.
-
- Posts: 125
- Joined: Fri Aug 19, 2011 2:02 pm
Re: TV-Tuner/Capture
I thought a large number of DVB-T cards worked under Linux (given the card is identified correctly and the firmware is uploaded to them)?