[mythtv-commits] Ticket #11487: Exten iptv recorder to support ts streams over http

MythTV noreply at mythtv.org
Mon Apr 15 20:23:21 UTC 2013


#11487: Exten iptv recorder to support ts streams over http
------------------------------------+------------------------
     Reporter:  torbjorn.jansson@…  |      Owner:  danielk
         Type:  Patch - Feature     |     Status:  new
     Priority:  minor               |  Milestone:  unknown
    Component:  MythTV - Recording  |    Version:  0.26-fixes
     Severity:  medium              |   Keywords:
Ticket locked:  0                   |
------------------------------------+------------------------
 hi.

 i have made a patch against 0.26-fixes that extends the iptv recorder to
 support transport streams over http.
 i wrote this primarily to make streaming channels from my dm800 dreambox
 work via the enigma2 web interface but it is generic enough so any ts
 stream over http should work.

 some notes about the changes i did:[[BR]]
 the format of the m3u file is extended to support a new optional line for
 specifying the service id.
 this was needed because the current implementation of the iptv recorder
 was relying on a hard coded value of 1, if you leave out this new option
 it will fall back to the old behavior of using service id=1[[BR]]
 format of the new m3u config option is:[[BR]]
 {{{
 #EXTMYTHTV2:serviceid=1234
 }}}
 where 1234 is your service id.[[BR]]

 "unfortunately" this patch depends on the commoncpp2 library.
 the reason for that is because i was not able to convince the QTs http
 classes to work properly without any event loop used with gui
 applications.
 there is no fancy config check for this since i didn't know exactly how to
 make the new additions conditional depending on a config check.

 i've been running with this for several weeks without any issues.[[BR]]
 [[BR]]
 [[BR]]
 i have also written a little helper php script to generate the correct m3u
 file directly by using the web api in enigma2.
 this allows you to point your iptv recorder to this script and the channel
 list will be dynamically downloaded from your dreabox.

 the script called dbox2m3u.php have a few http get variables you need to
 specify and there is also some default config variables in the php source
 also like your mysql hostname and logon information.

 the script also attempts to fill in the right xmltvid in the m3u file
 based on your existing channels (limiting by sourceid is possible so only
 a specific capture source is used, like the one for the dreambox or
 another card with same channels)

 if you don't specify the needed http get options in the url you get a very
 simple form for testing and specifying the right options.

 the options are:

 {{{
 * host
   this is your ip or hostname to your dreambox.
   this one is mandatory
 * bouquet
   this is the bouquet on your dreambox with the channels, for example
 "Favourites (TV)"
   this one is mandatory too
 * sourceid
   used to limit the lookup of xmltvids to a specific capture card source.
   if you don't specify this option all your existing channels will be
 search by name for a match, and if one is found the xmltv id of that
 channel is used in the m3u file.
 * webifport
   optional, port number of your enigma2 web interface.
 * streamport
   optional, port number used for streaming.
   i don't think you need to change this.
 }}}

 example url:
 {{{
 http://yourserver/dbox2m3u.php?host=yourdreambox&bouquet=Favourites+(TV)
 }}}

 example output:
 {{{
 #EXTM3U
 #EXTINF:0,21 - CNN
 #EXTMYTHTV2:serviceid=1160
 http://yourdreambox:8001/1:0:1:488:3FE:22F1:EEEE0000:0:0:0:
 #EXTINF:0,22 - MTV
 #EXTMYTHTV2:serviceid=940
 http://yourdreambox:8001/1:0:1:3AC:457:22F1:EEEE0000:0:0:0:
 }}}

-- 
Ticket URL: <http://code.mythtv.org/trac/ticket/11487>
MythTV <http://code.mythtv.org/trac>
MythTV Media Center


More information about the mythtv-commits mailing list