Set up Tvheadend on a RaspberryPi for streaming over DSL (speak: low bandwidth)

When streaming over a connection with low bandwidth we need to compress and resize (=transcode) the video while streaming. Tvheadend provides us with options for that but only in the "build it yourself"-version available on Github and not the one available in the Apt repositories.
If you don't care about transcoding check this tutorial for the Apt repositories version.

Install Tvheadend

  1. Get the Tvheadend sourcecode:
    git clone https://github.com/tvheadend/tvheadend.git
  2. Enable transcoding:
    cd tvheadend nano src/plumbing/transcoding.c
    Press Ctrl+w then type transcoding_enabled and press Enter. Set it to 1.
  3. Install the dependancies: [src]
    sudo apt-get install build-essential git pkg-config libssl-dev bzip2 wget
  4. Install the recommended additional packages: [src]
    sudo apt-get install libavahi-client-dev zlib1g-dev libavcodec-dev libavutil-dev libavformat-dev libswscale-dev
  5. Install Tvheadend:
    sudo ./configure sudo make && sudo make install

Set up Tvheadend

  1. Start Tvheadend in configuration mode. This means everyone who can reach the webfrontend (including you) has administrative capabilities:
    tvheadend -C
  2. Open the webfrontend e.g. raspberrypi:9981/.
  3. Set your default language:
    Configuration -> General
    Select your language then hit Save.
  4. Set up the DVB-S network:
    Configuration -> DVB-Inputs -> Networks
    Click Add then enter a title and select your Pre-defined Muxes (e.g. Astra_19_2E - play around if you don't know).
  5. Now go to Configuration -> DVB-Inputs -> TV adapters, expand all folders and select the inner most item. Then on the right under Network select the network you previously set up. Hit save.
  6. Enable the DVB-S device:
    Configuration -> DVB-Inputs -> TV adapters
    Open the folder directly beneath the one with the name of your DVB-S device. (If you cannot expand the folder unplug/plug your DVB device) and check Enabled. Hit save.
  7. Now it takes a while until Tvheadend scans all the available channels. Check your terminal/the syslog area at the bottom or the Configuration -> DVB-Inputs -> Muxes area to see whats going on.
  8. When satisfied select the TV channels that should be available here:
    Configuration -> DVB Inputs -> TV Adapters -> General -> Services
    Best order the list by Service name.
    Highlight the channels you want and click Map selected.
    When done selecting click Save.
  9. Go to the Electronic Programm Guide. There are your channels! Note the Watch TV in the top right.
The author

Written by Per

Free software enthusiast and transhumanist residing in Stuttgart, Germany.


comments powered by Disqus