Browse Source

palabota enigma2

Ivars 6 years ago
parent
commit
b41c8ec912
2 changed files with 10 additions and 1 deletions
  1. 9
    1
      sources/enigma2.py
  2. 1
    0
      sources/streams.cfg

+ 9
- 1
sources/enigma2.py View File

@@ -129,7 +129,15 @@ Accept-Language: en-US,en;q=0.5
129 129
         if not m:
130 130
             raise Exception("No streams found!")
131 131
         data2 = m.group(1)
132
-        title, img, desc = self.get_title_desc(r["events"][0])
132
+        if "stream.m3u" in data:
133
+            data3 = data.replace("stream.m3u?ref=","epgservicenow?sRef=")
134
+            r2 = self.call(data3)
135
+            event = r2["events"][0]
136
+        else:
137
+            data3 = "getcurrent"
138
+            r2 = self.call(data3)
139
+            event = r2["now"]
140
+        title, img, desc = self.get_title_desc(event)
133 141
         stream = util.item()
134 142
         stream["name"] = title
135 143
         stream["url"] = data2

+ 1
- 0
sources/streams.cfg View File

@@ -21,6 +21,7 @@ MTG|config::mtg|mtg.png|Other countries MTG media portals content
21 21
 cinemalive.tv|cinemalive::home|cinemalive.png|Filmas latviski
22 22
 SerialGURU.ru|serialguru::home|http://serialguru.ru/images/xlogo_new.png.pagespeed.ic.0sre2_2OJN.png|Serialguru.ru portāla satura skatīšanās
23 23
 MoviePlace.lv|movieplace::home|movieplace.png|Movieplace.lv - filmas latviesu valodā
24
+Engima2|enigma2::home|enigma2.png|Get streams from engima2 sat receiver
24 25
 
25 26
 [my_tv]
26 27
 My Tv