Hauppauge HVR 900 tuner and Ubuntu Hardy
This is a follow up on my previous attempts to get the Em2880 based Hauppauge HVR-900 USB tuner working.
First a word of warning. There appears to be a new model of the HVR-900 labeled the HVR-900H. This is a new hardware revision and uses a totally different chipset, and as such won’t work with the Em2880 drivers. Work is believed to be underway on a driver, but it would be worth checking the linux-dvb mailinglist.
Updated useful reference docs for the empia driver can now be found here -
Whilst my previous posts have focused on building from source, Markus has now released a kernel package for Ubuntu Hardy kernel version 2.6.24-16, which can be made to work on later kernels providing you remove any conflicting kernel modules.
These tips should work for all supported em28xx based cards under Ubuntu Hardy and Mythbuntu 8.04.
- Install appropriate firmware for your device.
- Download and install the pre-built driver package.
- Copy the modules to your current kernel and clean up any conflicting modules by running the following script as root -
# First backup the existing kernel modules cd /lib/modules tar -zcf `uname -r`.orig.modules.tgz `uname -r`# Then copy over the empia driver from 2.6.24-16-generic cp -a /lib/modules/2.6.24-16-generic/empia `uname -r` # Then delete any conflicting packages cd `uname -r`/kernel ls ../empia/ | while read i; do find . -name $i -exec rm -f {} \; ; done # Them make sure our modules will load correctly depmod -aOn the recently released 2.6.24-18 kernel the script will remove the following conflicting packages from the Ubuntu kernel install.
./drivers/media/video/em28xx/em28xx.ko ./drivers/media/dvb/frontends/qt1010.ko ./drivers/media/video/tvp5150.ko ./drivers/media/dvb/frontends/zl10353.ko
- Plug in your device and check the kernel messages are similar to the following
[ 330.299346] Linux video capture interface: v2.00 [ 330.304618] em28xx v4l2 driver version 0.0.1 loaded [ 330.304829] em28xx new video device (2040:6500): interface 0, class 255 [ 330.304833] em28xx: device is attached to a USB 2.0 bus [ 330.305238] em28xx #0: Alternate settings: 8 [ 330.305240] em28xx #0: Alternate setting 0, max size= 0 [ 330.305242] em28xx #0: Alternate setting 1, max size= 0 [ 330.305244] em28xx #0: Alternate setting 2, max size= 1448 [ 330.305246] em28xx #0: Alternate setting 3, max size= 2048 [ 330.305248] em28xx #0: Alternate setting 4, max size= 2304 [ 330.305250] em28xx #0: Alternate setting 5, max size= 2580 [ 330.305251] em28xx #0: Alternate setting 6, max size= 2892 [ 330.305253] em28xx #0: Alternate setting 7, max size= 3072 [ 330.348854] i2c-adapter i2c-2: SMBus Quick command not supported, can't probe for chips [ 330.537728] trying to set disabled gpio? (00) [ 330.539442] tuner 6-0061: chip found @ 0xc2 (em28xx #0) [ 330.539645] attach inform (default): detected I2C address c2 [ 330.542825] attach_inform: tvp5150 detected. [ 330.543509] attach_inform: eeprom detected. [ 330.558049] em28xx #0: i2c eeprom 00: 1a eb 67 95 40 20 00 65 50 12 5c 03 82 1e 6a 18 [ 330.558056] em28xx #0: i2c eeprom 10: 00 00 24 57 66 07 00 00 60 00 00 00 02 00 00 00 [ 330.558062] em28xx #0: i2c eeprom 20: 46 00 01 00 f0 10 02 00 b8 00 00 00 5b 00 00 00 [ 330.558068] em28xx #0: i2c eeprom 30: 00 00 20 40 20 6e 02 20 10 01 01 01 00 00 00 00 [ 330.558074] em28xx #0: i2c eeprom 40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 330.558080] em28xx #0: i2c eeprom 50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 330.558085] em28xx #0: i2c eeprom 60: 00 00 00 00 00 00 00 00 00 00 18 03 34 00 30 00 [ 330.558091] em28xx #0: i2c eeprom 70: 32 00 36 00 39 00 30 00 39 00 39 00 39 00 30 00 [ 330.558097] em28xx #0: i2c eeprom 80: 00 00 1e 03 57 00 69 00 6e 00 54 00 56 00 20 00 [ 330.558103] em28xx #0: i2c eeprom 90: 48 00 56 00 52 00 2d 00 39 00 30 00 30 00 00 00 [ 330.558108] em28xx #0: i2c eeprom a0: 84 12 00 00 05 50 1a 7f d4 78 23 f0 fd d0 18 85 [ 330.558114] em28xx #0: i2c eeprom b0: ff 00 00 00 04 84 0a 00 01 01 20 77 00 40 26 c5 [ 330.558120] em28xx #0: i2c eeprom c0: 05 f0 74 02 01 00 01 79 78 00 00 00 00 00 00 00 [ 330.558126] em28xx #0: i2c eeprom d0: 84 12 00 00 05 50 1a 7f d4 78 23 f0 fd d0 18 85 [ 330.558132] em28xx #0: i2c eeprom e0: ff 00 00 00 04 84 0a 00 01 01 20 77 00 40 26 c5 [ 330.558138] em28xx #0: i2c eeprom f0: 05 f0 74 02 01 00 01 79 78 00 00 00 00 00 00 00 [ 330.558144] EEPROM ID= 0x9567eb1a [ 330.558145] Vendor/Product ID= 2040:6500 [ 330.558147] AC97 audio (5 sample rates) [ 330.558148] 500mA max power [ 330.558149] Table at 0x24, strings=0x1e82, 0x186a, 0x0000 [ 330.590328] tvp5150 6-005c: tvp5150am1 detected. [ 331.369015] successfully attached tuner [ 331.371002] em28xx #0: V4L2 VBI device registered as /dev/vbi0 [ 331.380375] em28xx #0: V4L2 device registered as /dev/video0 [ 331.380568] em28xx #0: Found Hauppauge WinTV HVR 900 [ 331.386799] analog tv open() [ 331.386804] modelock active! [ 331.386800] usbcore: registered new interface driver em28xx [ 331.388502] em2880-dvb.c: DVB Init [ 331.415417] vbi open() [ 331.415423] modelock active! [ 331.555256] DVB: registering new adapter (em2880 DVB-T) [ 331.555263] DVB: registering frontend 1 (Zarlink ZL10353 DVB-T)... [ 331.555449] Em28xx: Initialized (Em2880 DVB Extension) extension
- Now try the digital tuner using scan or w_scan.
- Check analogue tuning, for example using tvtime. In order to get working audio with tvtime you will currently need to install the project’s patched version.
Analogue Samples
These were taken from NZ analogue channels TV2 and Maori TV. As you can see the analogue reception in my office is less than perfect. The linked images are the original unmodified PNG screen captures.
Digital Samples
Here is a mix of samples pulled from New Zealand’s freeview|HD service. The images below have been re-scaled, but you can click through to the PNGs from the original screen captures. All of the freeview|HD broadcasts are in H.264.
Sadly none of the broadcasters were showing native HD content whilst I was performing these tests so any HD video was upscaled prior to broadcast.
The picture issues shown in the TV 3 1080i sample are due to missing support for PAFF interlaced spatial direct video in FFMPEG’s H.264 decoder.
Using HVR 900 with MythTV
Recent builds of MythTV will detect both the analogue and digital tuners of the HVR 900. The device can only operate a single tuner at a time, and MythTV already has the required patches to understand this.
When setting up the V4L based analogue tuner you need to make sure you select the correct audio device as the driver exposes its own DSP interface.
At the moment the support for New Zealand’s H.264 terrestrial service freeview|HD is rather limited, but you can scan for the 3 active multiplexes. For other countries you might have more luck.





