SAT2IP players as capture cards

From MythTV Official Wiki
Revision as of 10:01, 27 March 2017 by Stevegoodey (talk | contribs) (Using more than one tuner of the SAT>IP player: Added trac ticket link.)

Jump to: navigation, search

This document describes how to connect a SAT>IP player as IP TV capture card to a MythTV backend using customized M3U playlists.


SAT>IP is a protocol and IP-based architecture for receiving and distributing satellite signals (see [1] and [2] for more details). Depending on manufacturer and device not just only DVB-S/S2 but DVB-T and DVB-C may be supported as well.

By default a SAT>IP player publishes its playlist and capabilities (eg. number of satellite tuners) via UPnP. After setup for the satellite (DVB-T/C respectively) and the local IP network the SAT>IP player should be auto discoverable in the local network. On Android or Linux boxes devices with VLC installed watching live TV using VLC works via UPnP like a charm.

With MythTV autodiscovery of SAT>IP players does not work. It is simply not implemented yet (MythTV version 0.28.1).

By manual setup of the SAT>IP player MythTV is able to access SAT>IP channels for recording and for watching live TV.

Playlist Files

Unfortunately the M3U playlist which is downloadable from the SAT>IP player can not be used unmodified with MythTV. The reason lies in the structure of the MPEG-TS stream the SAT>IP player sends via RTP protocol to the MythTV backend. The SAT>IP player sends the full satellite transponder structure which consists of several TV programs - but only with the tuned programs media streams filled in - in the MPEG-TS stream to the receiving backend.

Output of ffprobe:

Input #0, mpegts, from 'SAT-IP.ts':
  Duration: 00:01:01.54, start: 50868.372100, bitrate: 14046 kb/s
  Program 10301 
    Stream #0:0[0x492]: Unknown: none ([5][0][0][0] / 0x0005)
    Stream #0:1[0x498]: Unknown: none ([12][0][0][0] / 0x000C)
    Stream #0:2[0x87b]: Unknown: none ([11][0][0][0] / 0x000B)
    Stream #0:3[0x13ed]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 1280x720 [SAR 1:1 DAR 16:9], 50 fps, 50 tbr, 90k tbn, 100 tbc
    Stream #0:4[0x13ee](deu): Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo, s16p, 256 kb/s
    Stream #0:5[0x13ef](mis): Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo, s16p, 256 kb/s
    Stream #0:6[0x13f0](deu): Subtitle: dvb_teletext ([6][0][0][0] / 0x0006)
    Stream #0:7[0x13f1](deu): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006) (hearing impaired)
    Stream #0:8[0x13f2](deu): Audio: ac3 ([6][0][0][0] / 0x0006), 48000 Hz, stereo, fltp, 448 kb/s
    Stream #0:9[0x13f4]: Data: bin_data ([6][0][0][0] / 0x0006)
    Stream #0:10[0x1434]: Unknown: none ([11][0][0][0] / 0x000B)
  Program 10302 
  Program 10303 
  Program 10304 

The ffprobe output above shows the structure of the MPEG-TS stream the SAT>IP player sends to the MythTV backend. The MythTV backend requires the program number (in the above example 10301) to finalize its tuning to the desired program. MythTV backend extracts the sub-streams of the program from the original MPEG-TS stream and saves them in a newly created similar but simpler MPEG-TS stream to the recording file.

These program numbers are unique per satellite and its transponders. They have to be added utilizing MythTV proprietary entries to the M3U playlist downloaded from the SAT>IP player.

For the Astra 19.2° East satellite the free TV program numbers can be found following the URL [3] column SID.

To make use of XMLTV TV program listings a second MythTV proprietary entry may be added to each M3U playlist entry.

The SAT>IP player M3U playlist to be used for the MythTV backend then looks like following example:

#EXTINF:0,9901 - Das Erste HD
#EXTINF:0,9902 - Das Erste
#EXTINF:0,9903 - ZDF HD
#EXTINF:0,9904 - ZDF

The MythTV proprietary entry #EXTVLCOPT:program=XXXX adds the satellite transponder SID XXXX as program number to the playlist entry. This entry is required to enable MythTV backend to tune to the desired TV program in the MPEG-TS stream send by the SAT>IP player to MythTV backend.

The MythTV proprietary entry #EXTMYTHTV:xmltvid=ZZZZ adds the XMLTV program identifier ZZZZ to the playlist entry. This one is optional, but useful for the mythfilldatabase tool when run with external XMLTV TV program listings.

Adding a Capture Card for SAT>IP players


To add a SAT>IP Player for MythTV start mythtv-setup and choose 2. Capturecards -> (New capture card). Then please fill in the following fields on the screen:

  • Card type: PTV recorder
  • M3U URL: absolute file path to M3U-Playlist file prepared as described earlier in this article (Example: file:///home/mythtv/Playlist/PlayList-MythTV.m3u)
  • Tuning Timeout: 10000ms is a good choice
  • Max recordings: 1 (since the Transponder bouquet the SAT>IP Player sends as MPEG-TS stream to the MythTV backend consists of several programs, but just the tuned to program is filled in with media data)

Finish saves the settings, Esc-Key returns to main screen.


Select 4. Videosources -> (New video source) and fill in the screen mask appropriate for the MythTV backend location. The following example shows a typical setup in Germany:

  • Video source name: no grabber
  • Listings grabber: No Grabber
  • Channel frequency table: default
  • Network ID: -1

Finish saves the settings, Esc-Key returns to main screen.

Input connections

Select 5. Input connections and select new [FREEBOX : absolute playlist path] (None) -> (None) to connect the SAT>IP capture card to an input structure and fill in as follows:

  • Input name: MPEG2TS
  • Display name: SAT>IP 1 (just an example)
  • Video source: no grabber (from the Video sources step before)
  • Use quick tuning: Never

Now the Scan for channels button has to be selected. With no changes in the next screen it can directly be proceeded by selecting Next > to import the M3U playlist file into the database.

Selecting OK then Finish buttons returns to the previous screen. Choosing Next > then Finish and Esc-Key returns to the myth-setup main screen.

Channel Editor

To verify the M3U playlist import select 6. Channel Editor and then the channel to verify.

Channel Name, Channel Number, Callsign, ServiceID, and XMLTV ID should have been set by the respective entries from the SAT>IP M3U playlist.

Using more than one tuner of the SAT>IP player

Depending on make and configuration SAT>IP players may provide more than one DVB-S2 (and/or S/C/T) tuners which can be used in parallel. Unfortunately a patch to MythTV backend (MythTV version 0.28.1 or lower) is required to enable parallel recordings from multiple tuners of one and the same SAT>IP player.


diff -Naur a/mythtv-0.28.1/mythtv/libs/libmythtv/iptvtuningdata.h b/mythtv-0.28.1/mythtv/libs/libmythtv/iptvtuningdata.h
--- a/mythtv-0.28.1/mythtv/libs/libmythtv/iptvtuningdata.h      2017-02-01 09:49:25.000000000 +0000
+++ b/mythtv-0.28.1/mythtv/libs/libmythtv/iptvtuningdata.h      2017-03-11 16:15:26.076839980 +0000
@@ -97,7 +97,7 @@
         const QUrl u = GetDataURL();
         if (IsHLS())
             return QString("%1(%2)").arg(u.toString()).arg(GetBitrate(0));
-        if (IsHTTPTS())
+        if (IsHTTPTS() || IsRTSP())
             return QString("%1").arg(u.toString());
         return QString("%1:%2:%3")

At own risk: the above patch is not tested with other capture cards than SAT>IP players and M3U multicast playlists for Deutsche Telekom Entertain IP TV setup as IP TV capture cards. Therefore there is no guarantee that it does not break MythTV for anything else.

See Trac ticket 12999 now fixed in master and fixes 0.28 by paulh.

Remaining tuners of the SAT>IP players have to be added like described above in SAT2IP players as capture cards#Adding a Capture Card for SAT>IP players.

External links