Digital TV

linuxtv-dvb-apps from might not be necessary but you get lots of small programs to help configuring the dvb.

Hauppauge WinTV Nova T USB

Hauppauge WinTV Nova-T USB is on the market with different chips inside. Type lsusb (usbutils package) and when you get 2040:7070 inside the string Bus 001 Device 004: ID 2040:7070 Hauppauge Nova-T Stick 3 then the following tells you how to install it.

It requires the firmware is downloaded into the usb device plus the kernel driver dvb-usb-dib0700. This rises a GPL problem since the firmware is not open source. The firmware has to be put in /lib/firmware.

The firmware can be download from that points to (and finds nothing since it has an url bug . instead - in the filename) or or as part of the complete tar


For gentoo to not get the firmware from all devices add to /etc/portage/make.conf


and then verify what emerged would do by emerge -pv linuxtv-dvb-firmware and when happy do it.

The kernel driver is Support for Various DVB devices => DiBcom DiB0700 USB DVB (This shows that Hauppauge WinTV Nova-T uses inside)


The kernel driver can just be selected if Remote Controller Support is selected

Since you do not want to restart the computer now, check with lsmod if the driver not already is loaded and if not try to load the driver with modprobe dvb-usb-dib0700

Check if /dev/dvb/adapter0 got created.

Check dmesg to see if it is happy and the firmware gets loaded.

What is missing now is a media player that can show dvb-t.

DVB-T comes with EPG, make sure that the timezone is set correctly on your computer.


This dvb receiver has an internal infrared receiver (even when not shipped with a IR controller). It is not visible from the outside. When evdev runs it is reported and it even works on the fly. When you set up LIRC with an self made receiver, then you might wonder why everything key comes up twice (and even correctly converted due to evdev as the number keys).

Configuring digital terrestrial tv

Many application can not scan for channels and rely on a channel file that holds all the channels. There are programs that can create the a channel file themselves. However for command line tools to be used in applications as totem the official media player for gnome it has to be done separately.


For gentoo there are various useflags that need to be set on a package base or globally such as: dvb v4l zvbi

The simples way for a dvb-t device is emerge w_scan. Unfortunately there are different formatting standards for the channel file, so if you are in Switzerland (CH) and use a dvb-t make sure no other application uses the dvb-T device and run:

w_scan -ft -M -c CH >> ~/.mplayer/channels.conf for mplayer

w_scan -ft -X -c CH >> ~/.xine/channels.conf to get a channel file compatible with tzap, xine

w_scan -ft -c CH >> ~/channels.conf for vdr

Copy or link the channels.conf file to ~/.mplayer (or/and ~/.xine for xine and totem).

DVB and mplayer

After having the channels.conf file for mplayer type mplayer dvb:// to show the first dvb-t channel. Press h or k to zap through the channels or add the channel name mplayer dvb://SRF1 and when the channel name has some spaces then mplayer "dvb://<channel name>". You might manually edit the file to give the channels shorter names. The key F goes to full screen and back. In case of having more than one card mplayer dvb://2@SRF1 selects the second card

If you run into difficulties, you might do it in two steps to determine where the problem is.

  1. Open one console and after emerge linuxtv-dvb-apps run tzap to tune: tzap<channel name>. The dvb-t tuner should be able to tune to that channel. If not you have a problem with the receiver or the channel file.

  2. Open an other console window and start: mplayer /dev/dvb/adapter0/dvr0 . You should see the tv station. If not mplayer has a problem

Mplayer can also record mplayer -dumpfile r1.ts -dumpstream dvb://R1 or encode and record mencoder -o r1.avi -ovc xvid -xvidencopts bitrate=800 -oac mp3lame -lameopts cbr:br=128 -pp=ci dvb://R1

Mplayer works well but it is a command line tool, therefore gui tools are desired. Unfortunately those gui tools often have difficulties with the channels.conf and therefore fail and additionally it seems that they always change the way how they handle channels.conf.


kaffeine works well with dvb-t and has even a channel search and record schedule.


In VLC the easiest way is opening the file channels.conf (maybe it is in the hidden .mplayer directory, so it needs to be moved, linked to a non hidden directory or just type .mplayer as file name and hit enter). After that the first channel pops up, the other channels can be selected via View > Playlist.

View > Advanced Controls give a record button to record the video in ts format and a snapshot button for png files. *.ts files can be converted and compressed (e.g to 128kbit/s video bit rate) using ffmpeg -i <input file>.ts -b:v 128k <output file>.mpg

Under Subtitle > Sub Track appears Teletext or Subtitles

Tools > Program Guide shows you the program of the selected channel

Other DVB tools

To get dvb for gnome see, set the totem useflag if you want to use it with totem. Consider to set the vala useflag since the gnome-dvb-daemon is written in vala. After unmasking lots of packages emerge gnome-dvb-daemon.

There is smplayer a gui that does not depend on the desktop environment.

In xine the channel.conf needs to be loaded as playlist and then play should do the work. There is a snapshot (camera) icon in the control gui.

Measuring signal

Watch your dvb-t channel then

femon -c 3 -H in an other console window. Something as:

status SCVYL | signal 72% | snr 0% | ber 0 | unc 0 | FE_HAS_LOCK

comes back.

signal is the signal strength (should be high but is not that important)

snr is signal-to-noise ratio (should be high, but might not be supported by the card)

ber is bit error rate (should be near 0) can be corrected if low

unc is uncorrected blocks (should be 0)

FE_HAS_LOCK means the channel is tuned in

Record compressed video

Many tools as vlc record *.ts files that are very big and therefore need to be converted to compressed video in an second step using tools as ffmpeg.

There is also a direct way to compress and record video with ffmpeg from dvb. However ffmpeg can not tune a dvb receiver to a channel. Therefore something as the following needs to be done to tune the dvb receiver. Create a channels.conf file w_scan -ft -A1 -X > ~/.tzap/channels.conf and then tune to a channel tzap -r "<complete channel name as appears in channels.conf>" After that ffmpeg can record: ffmpeg -f mpegts -i /dev/dvb/adapter0/dvr0 out.mp4

DVB-T Antennas

However signal strength is not the only thing, the signal quality must also be good enough, amplifying noisy signal makes it strong, but if there is too much noise, it will be still useless. Different elements influence the signal strength:

  1. Gain of the antenna

  2. Amplifier in the antenna, when having an active antenna

  3. Sensitivity of the receiver

If you have a bad signal you might end up with an outdoor antenna with integrated amplifier.

If you have good signal you might even consider to build your own antenna.

Just take a coaxial cable and take off about 12.5cm from the outer plastic coat. Bend back the metallic screen and fix it with a tape to the cable. That's it. It might work better than a commercial antenna.

Figure 12.5. DVB antenna

DVB antenna

Background information: The 12.5 cm come from the formula:

Speed of light / dvb frequency /4 * k.

The factor k (=0.95) considers that the signal on the antenna itself is lower than the speed of light (Thanks to Mr. Einstein). The dvb signal has a frequency around 600MHz.

Linurs Servernest startpage