[Obsolete] TVheadend 4.0 Setup of IP TV with OSMC and the AVM FRITZ!WLAN Repeater DVB-C

This How To guide is obsolete and replaced by the new thread TVHeadend 4.2 Setup with the Sat>IP Server AVM FRITZ!WLAN Repeater DVB-C on OSMC


This article describes a setup of TVheadend with the OSMC platform and the German AVM FRITZ!WLAN Repeater DVB-C which lets you watch live TV and handle private video recordings. Tested with

HW: Vero + Raspberry Pi 2 B
OS: OSMC 2015.08-1 ... 2016.04-1
SW: TVheadend Server 4.0.5 (OSMC preinstalled), TVheadend HTSP CLient 2.1.16 ... 2.2.14 (OSMC preinstalled)
IPTV tuner: AVM FRITZ!WLAN Repeater DVB-C, FritzOS 06.30 ... 06.32

The AVM FRITZ!WLAN Repeater DVB-C is a popular 2.4 and 5 GHz WLAN repeater in Germany with a Gigabit LAN connector and a dual DVB-C tuner. It can operate in WLAN repeater mode as well as access point and provides IP TV via rtsp (real time streaming protocol).

Get the rtsp information from the DVB-C device

The AVM DVB-C device provides the rtsp IP TV stream information as mu3 files, only. Unfortunately TVheadend is currently not able to process m3u directly. So you need to download the data manually and create the muxes (a mux is to be seen as a carrier signal on which channels are multiplexed) and channels by hand in a web-based graphical user interface.
In the web GUI of the DVB-C device go to DVB-C->Senderliste and create the m3us for HDTV and SDTV on your local PC by using the link “Senderlisten erzeugen” (English: Create sender lists) at the bottom of the web page.

Install, activate and configure TVheadend in OSMC

Tvheadend consists of two parts since it is a client-server model. The server is responsible to transform the source stream (here with the AVM repeater based on RTSP, Real Time Streaming Protocol) to another namely HTSP (Home Tv Streaming Protocol).
The client always understands HTSP and transforms the HTSP data stream for the target device/puropose and implement functions like pvr, network, mux and channel coordination and maintenance.

Install TVheadend server first

In the OSMC desktop GUI goto My OSMC → App Store and install Tvheadend

Configure and activate the preinstalled TVheadend HTSP Client

In the OSMC GUI goto
Settings->Add-ons->My Add-ons->PVR Clients->TVheadend HTSP Client
and configure the Connection Settings by specifying username and password, i.e. osmc/osmc.

Finally Enable the software.

Configure Live TV in the OSMC GUI

Goto Settings-> TV


  • General->Enabled, (I also activated Use Channel numbers from backend)
  • Guide->Prevent Updates during playback
  • deactivate Playback->Start playback minimized

Configure the program channels using the TVheadend HTSP Client web interface

The most TVheadend configuration has to be done via the HTSP web interface, so start a browser to URL

http://<ip or DNS of the OSMC device>:9981

and log in using the credentials you have specified above and choose the Configuration tab.

Choose Configuration->General->Language Settings: Specify your language (in this example it was German)

Choose Configuration->DVB Inputs->Networks and add a new IP TV entry with the settings shown below

The AVM DVB-C device has two tuners but can only provide one stream per device (identified by the IP). Limiting the number of input streams avoids conflicts with parallel playings/recordings, epg grabber and service mapper.
ATTENTION: Be sure to reduce the Max TimeOut value since it is essential to the runtime of the service mapping process, later. One second is a value which works perfect in a Giga-LAN switch network, on problems you can increase it to 2 or 3 but with the costs of doubling or even tripling the service mapping runtime, later. Once the initial service mapping process has finished, you can carefully increase this value in case of TV channel switching problems, default value is 15.

Before setting up the muxes and channels within TVheadend, first correct the configuration of the EPG grabber to prevent continuously running EPG collections.
Go to Configuration-> Channel/EPG-> EPG grabber menu, limit the value EPG scan timeout to 30 and deselect all OTA grabbers modules except the EIT EPG Grabber. Afterwards save the configuration.

Now it is time to create a single mux for each TV channel you want to have available within OSMC. If you look into the AVM DVB-C m3u files, you find that every TV channel has an entry like


where BBC HD is the name of the TV channel and rtsp://…,554 is the related URL of the stream the DVB-C device offers for this channel.
With that information go to Configuration-> DVB Inputs->Muxes and add a new mux for the first TV channel in your previously created network like shown below

Redo the previous step for every TV channel you want to be available for Live TV within OSMC. Every TV channel has afterwards a single mux entry. This step is somewhat painful but as long as TVheadend does not offer the import of m3u files, this cannot be shortened.

TVheadend has meanwhile found several services for each mux. Don’t worry you don’t have to manually find the single service of each mux which really provides the TV channel.
Go to Configuration → DVB Inputs → Services and click on Map All. In the Map Services popup select Check Availability. Now TVheadend tests each found service but only maps a channel to the working ones.
ATTENTION: If you have forgotten to reduce the Max. TimeOut value of the network entry, this could last many hours! You can check the activity of the service mapper also in the Status menu on top.

As last step verify in the menu Configuration->Channel/EPG->Channels that you see the same number of found channels like the number of muxes you created. Otherwise look for phantom channels where the service name and channel name are not the same and delete them. In case you have less channels than muxes go to Configuration->DVB Inputs->Services, sort the column Mux and look for a mux that has no channel assigned. Manually select all entries of this mux and choose Map Selected to repeat the service mapping for those entries.

You are done creating the TV channels within TVheadend. On the OSMC desktop interface you should now see a new entry named Live TV. The collection of the EPG information should have started.

Private Video Recording setup

For PVR you have to configure the location for the recordings and other values. In the TVheadend HTSP web GUI go to
Configuration->Recording->Video Recorder Profiles
and put in your values, here is just an example. Save your changes to make them active.

Here an external hard disk was mounted and TVheadend configured to use directory /mnt/hdd1/pvr/ as the location for recordings.

Tips, current issues, etc.

  • With OSMC 2015-08.1 the playback of recordings in the menu Live TV → Recordings was choppy and stuttering. This improved dramatically with OSM 2015-09.1 but still there micro judders can be seen on heavy movements in the video material. A perfect playback you get in the menu Video – Files of OSMC.

  • The rtsp stream from the AVM device is not always handled correctly by TVheadend when manually switching between the TV channels. TVheadend Bug 2943 describes some possible scenarios but also includes the solution which is expected to be seen in TVheadend 4.2 coming, soon.

  • The AVM FRITZ!WLAN Repeater DVB-C has two tuners and for sure you can use both at the same time for your Raspberry Pi but this requires a second IP (an IP alias) on the Pi to be configured, so the DVB-C repeater thinks to serve two different devices. This is just the idea but should followed up by someone else in another article.

  • The German forum http://ip-phone-forum.de is visited by a very active AVM product community and is an excellent source for questions and help regarding the AVM DVB-C.

  • Automatic deletion of old recordings
    In the HTS TVheadend menu Configuration->Recording you can set
    DVR Log Retention Time (days)
    but this only cleans the related EPG information after the configured amount of days instead of deleting the recorded TV film.
    If you want to have the both (information and recording) automatically deleted after a specific time (in example 14 days, recording path is /mnt/nas1/tv_recordings/), you can implemented it in the HTS TVheadend menu Configuration->Recording this way:

DVR Log Retention Time (days): 14


Post-Processor Command:
find /mnt/nas1/tv_recordings/ -mtime +15 -or -type d -and -empty -exec rm -r {} ;

which automatically cleans the EPG information of all recorded TV recordings older 14 days and purges any files with a modification date older than 15 days and all empty directories out of the recording path. This will be executed after every recording.


Thanks for this great guide for the AVM DVB-C Tuner in combination with TVHeadend!
I followed your Instructions and mangaged to get full working Live TV with my TV Headend Installation.

The only Problem I encountered so far is, that every time I try to record a stream I get a message like this in TVHeadend System Log:
2015-11-01 13:28:11.000 subscription: 0001: No input source available for subscription “DVR: Mit Herz und Hammer” to channel “ZDF”
And it wont record… :frowning:

Do you have any idea or hint for me what I can do to make recording streams working?
THX in advance

BTW: System is Ubuntu 14.04 and TvHeadend Version is 4.0.7


unfortunately, I’ve not too many ideas how this issue could be caused in your environment.
The only issue I could image is a too small IPTV network timeout.
In the instructions I set it down to 1 second to speed up the service mapping setup. But as I told there, if you have switching issues, set it back to higher or even the default of 15 seconds. It only hurts while the service mapping setup which is already done with your environment.

Give this a try. I think you already have tested to record an already running live TV stream, so you know recording is working at all?

Another root cause could be if two other devices already exhausted the maximum amount of rtsp streams on different tuners from the DVB-C which is 2. This can be checked in the web interface of the DVB-C of cause in the moment the recording should start.

Hi, sorry for my lat reply. Didn’t had much time this week.
Thanks again for you help.

Didn’t know why, but after I changed the drive path for the recordings from /mnt (Btrfs Drive Pool) to /dev/sda (Main HDD with EXT4) the recording worked.
Maybe it is not possible for TVHeadend to handle BTRFS filesystems?

In this case, the error message would however have been misleading.
Maybe the problem was caused by an other issue? :smirk:
But only one tuner was in use all the time and switching the IPTV network timeout to something higherr made no difference for me …

Small update, the error occured not because of the btrf Filtersystem.
It seems that during my trial and error I also set the MaxTimeout to a higher value.
After I set this value to “15” the Problem disapeared and everything seems to work eine now. Even with a btrf Filtersystem AS recording path.

… i installed the Tv headend on OSMC with kodi, konfigured it in the web ui mapprd the channels and all channels found… but i get only the tv.sound and no tv-picture. i use the avm D-VBT… pls help/ any idea?

You installed mpeg2 codec?

I dont know… I used this tutorial. Thx for your support

You need to purchase the mpeg2 codec from Raspberry Pi foundation.

No, i didnt

… ok, well done- good support. I take these 2 codecs and now ive no probs anymore. how can i use these 2 tuners in one kodi? any idea? ive a rasberry and the tvh is installed at an asustor homeserver. my server cant get 2 ipadresses.

4 posts were split to a new topic: Off topic and uninformed

With OSMC’s July 2017 and TVHeadend 4.2.0-2 the method to use the AVM DVB-C as single IPTV tuner isn’t state of the art anymore.

Currently I managed to run the AVM DVB-C with the new OSMC stack as real dual DVB-C SAT>IP tuner with excellent performance, parallel recording and no need anymore to manually transfer TV channel information using the M3U export mechanism.

Unfortunatelly writing such article is very time consuming but I will try to find time in next weeks. Might be other users have this environment running already and gets interested to provide the required information in an easy-to-understand technical article …

I would appreciate that guide! :slight_smile:

This How To guide is obsolete and replaced by the new thread TVHeadend 4.2 Setup with the Sat>IP Server AVM FRITZ!WLAN Repeater DVB-C on OSMC.