Latest release can be downloaded from releases
usage: e2m3u2bouquet.py [-h] [-m M3UURL] [-e EPGURL] [-n PROVIDERNAME]
[-u USERNAME] [-p PASSWORD] [-i] [-sttv STTV]
[-stvod STVOD] [-M] [-a] [-P] [-q ICONPATH] [-xs]
[-b BOUQUETURL] [-bd] [-bt] [-U] [-V]
e2m3u2bouquet.e2m3u2bouquet -- Enigma2 IPTV m3u to bouquet parser
Copyright 2017. All rights reserved.
Created on 2017-06-04.
Licensed under GNU GENERAL PUBLIC LICENSE version 3
Distributed on an "AS IS" basis without warranties
or conditions of any kind, either express or implied.
USAGE
optional arguments:
-h, --help show this help message and exit
-i, --iptvtypes Treat all stream references as IPTV stream type.
(required for some enigma boxes)
-sttv STTV, --streamtype_tv STTV
Stream type for TV (e.g. 1, 4097, 5001 or 5002)
overrides iptvtypes
-stvod STVOD, --streamtype_vod STVOD
Stream type for VOD (e.g. 4097, 5001 or 5002)
overrides iptvtypes
-M, --multivod Create multiple VOD bouquets rather than single VOD
bouquet
-a, --allbouquet Create all channels bouquet
-P, --picons Automatically download of Picons, this option will
slow the execution
-q ICONPATH, --iconpath ICONPATH
Option path to store picons, if not supplied defaults
to /usr/share/enigma2/picon/
-xs, --xcludesref Disable service ref overriding from override.xml file
-b BOUQUET_URL, --bouqueturl BOUQUET_URL
URL to download providers bouquet - to map custom
service references
-bd, --bouquetdownload
Download providers bouquet (use default url) - to map
custom service references
-bt, --bouquettop Place IPTV bouquets at top
-U, --uninstall Uninstall all changes made by this script
-V, --version show program's version number and exit
URL Based Setup:
-m M3UURL, --m3uurl M3UURL
URL to download m3u data from (required)
-e EPGURL, --epgurl EPGURL
URL source for XML TV epg data sources
-n PROVIDERNAME, --providername PROVIDERNAME
Host IPTV provider name
Config file based setup
No parameters required
The script will create a default config file
first time it is run, IPTV providers details
need to be entered into this file before
running the script again
EPG-Importer plugin is required. This should be available in the plugin feed or already installed.
N.B. OpenPLi may need additional packages installed. If you attempt to run the script and get an error about missing modules please run
opkg update
opkg install python-image python-imaging python-argparse
cd /etc/enigma2/e2m3u2bouquet
chmod 755 e2m3u2bouquet.py
Run the script passing the url for your m3u file and the url for your providers XML TV data feed
./e2m3u2bouquet.py -m "http://provider_url/get.php?username=YOURUSERNAME&password=YOURPASSWORD&type=m3u_plus&output=ts" -e "http://provider_url/xmltv.php?username=YOURUSERNAME&password=YOURPASSWORD"
NB: you need to replace the username and password values X 2
If you are with a different provider the script should work but you will obviously need the m3u url (1st parameter) and XML TV url (2nd parameter) for your own provider. Please note the m3u file needs to be the "extended" version if you have the option.
No parameters required, just run the script
./e2m3u2bouquet.py
The script will create a default config.xml file in /etc/enigma2/e2m3u2bouquet the first time it is run IPTV providers details need to be entered into this file before running the script again
Note: Multiple IPTV providers can be supported via the config.xml
Add -P and optionally -q /path/to/picon/folder/ if you don't store your picons in the default location. The default location
is /usr/share/enigma2/picon/
(internal flash) other enigma2 picon search location are /media/usb/picon/
& /media/hdd/picon/
.
N.B. If you store the picons on HDD it was spin up whenever they are shown
./e2m3u2bouquet.py "http://provider_url/get.php?username=YOURUSERNAME&password=YOURPASSWORD&type=m3u_plus&output=ts" -e "http://provider_url/xmltv.php?username=YOURUSERNAME&password=YOURPASSWORD" -P
Default is DVB stream types for live channels and IPTV for VOD, all IPTV type streams may be required if you are unable to record channels.
./e2m3u2bouquet.py "http://provider_url/get.php?username=YOURUSERNAME&password=YOURPASSWORD&type=m3u_plus&output=ts" -e "http://provider_url/xmltv.php?username=YOURUSERNAME&password=YOURPASSWORD" -i
./e2m3u2bouquet.py "http://provider_url/get.php?username=YOURUSERNAME&password=YOURPASSWORD&type=m3u_plus&output=ts" -e "http://provider_url/xmltv.php?username=YOURUSERNAME&password=YOURPASSWORD" -s
./e2m3u2bouquet.py -U
./e2m3u2bouquet.py --help
To update the channels simply run this script again. A scheduled script can be set up to automate this process (see below)
opkg install busybox-cron
crontab -e
Once open press i to switch to INSERT mode enter the following (retype or ctrl-v to paste) This will automatically run the script at 06:00 & 18:00 every day
0 6,18 * * * /etc/enigma2/e2m3u2bouquet/e2m3u2bouquet.py -m "http://provider_url/get.php?username=YOURUSERNAME&password=YOURPASSWORD&type=m3u_plus&output=ts" -e "http://provider_url/xmltv.php?username=YOURUSERNAME&password=YOURPASSWORD"
or
0 6,18 * * * /etc/enigma2/e2m3u2bouquet/e2m3u2bouquet.py
Press ESC follwed by :wq to exit the cron editor and save the entry You can check the entry with the command below
crontab -l
(Depending on your box image installing nano opkg install nano
may set it as the default editor
which makes editing the crontab easier)
0 6,18 * * * cd /home/root && ./e2m3u2bouquet.py
provider_name-sort-current.xml
provider_name-sort-current.xml
to your machine and rename it provider_name-sort-override.xml
<category
lines within <mapping> -> <categories>
enabled="true"
to enabled="false"
<channel
lines within <mapping> -> <channels>
enabled="true"
to enabled="false"
tvg-id
attributeserviceRef
attribute
provider_name-sort-override.xml
to your boxVisit https://www.suls.co.uk/enigma2-iptv-bouquets-with-epg/ for further information on the script