172
172
if find_library("usb-0.1") is not None or find_library("usb-1.0") is not None:
173
173
print("[LCD4linux] libusb found :-)", getEnigmaVersionString())
174
174
USBok = True
175
- elif ARCH in ("aarch64"):
176
- get_backend(find_library=lambda x: "/lib64/libusb-1.0.so.0")
177
- print("[LCD4linux] libusb found :-)", getEnigmaVersionString())
178
- USBok = True
179
- Version = "V5.0-r25"
175
+ Version = "V5.0-r27"
180
176
L4LElist = L4Lelement()
181
177
L4LdoThread = True
182
178
LCD4enigma2config = resolveFilename(SCOPE_CONFIG) # /etc/enigma2/
233
229
OSDdontshow = ["LCD4linux Settings", "Virtual Zap", "InfoBar", "Infobar", "SecondInfoBar", "FanControl2", "Mute", "LCD Text", "UnhandledKey", "QuickZap", "Volume", "PVRState"]
234
230
OSDdontskin = ["LCDdisplayFile", "VirtualZap", "InfoBar", "Infobar", "InfoBarSummary", "PictureInPicture", "SimpleSummary", "ScreenSummary", "TimeshiftState", "InfoScreen", "Standby", "EMCMediaCenter", "InfoBarMoviePlayerSummary", "PVRState", "ResolutionLabel", "WidgetBackground", "camodogFSScreen2", "camodogFSmini"]
235
231
wwwWetter = ["", ""]
236
- WetterType = ["", ""]
237
- WetterZoom = [0, 0]
232
+ WetterType = ""
233
+ WetterZoom = 0
238
234
OldTemp_c = -88
239
235
OldFeel = -88
240
236
OldHum = -88
1745
1741
LCD4linux.MPCover = ConfigSelection(choices=ScreenSelect, default="0")
1746
1742
LCD4linux.MPCoverLCD = ConfigSelection(choices=LCDSelect, default="1")
1747
1743
LCD4linux.MPCoverPath1 = ConfigText(default="/tmp", fixed_size=False, visible_width=50)
1748
- LCD4linux.MPCoverPath2 = ConfigText(default="/tmp ", fixed_size=False, visible_width=50)
1744
+ LCD4linux.MPCoverPath2 = ConfigText(default="/media/hdd/movie/ ", fixed_size=False, visible_width=50)
1749
1745
LCD4linux.MPCoverFile = ConfigText(default="/tmp/lcd4linux.jpg", fixed_size=False, visible_width=50)
1750
1746
LCD4linux.MPCoverFile2 = ConfigText(default="/tmp/lcd4linux.jpg", fixed_size=False, visible_width=50)
1751
1747
LCD4linux.MPCoverSize = ConfigSlider(default=240, increment=10, limits=(10, 1024))
@@ -9821,17 +9817,17 @@ def downloadWetter(self, ort, wetter):
9821
9817
lang = "&lang=%s" % ort.split(".")[0] if "." in ort else ""
9822
9818
city = LCD4linux.WetterCity.value if wetter == 0 else LCD4linux.Wetter2City.value
9823
9819
if "." in city: # e.g. 'de.ZIPccode'
9824
- self. feedurl = "http://api.weatherunlocked.com/api/current/%s%s%s " % ( city, apkey, lang)
9820
+ feedurl = "http://api.weatherunlocked.com/api/current/%s" % city
9825
9821
else:
9826
- self. feedurl = "http://api.weatherunlocked.com/api/current/%s,%s%s%s " % (self.Long[wetter], self.Lat[wetter], apkey, lang )
9827
- L4logE("WU-getcurrentweather%s: %s" % (wetter, self. feedurl))
9828
- callInThread(getPage, self. feedurl, boundFunction(self.downloadWUcallback, wetter), self.downloadListError)
9829
- if "." in city : # e.g. 'de.ZIPcode'
9830
- self. feedurl = "http://api.weatherunlocked.com/api/forecast/%s%s%s " % ( city, apkey, lang)
9822
+ feedurl = "http://api.weatherunlocked.com/api/current/%s,%s" % (self.Long[wetter], self.Lat[wetter])
9823
+ L4logE("WU-getcurrentweather%s: %s" % (wetter, feedurl))
9824
+ callInThread(boundFunction( getPage, feedurl, params=params) , boundFunction(self.downloadWUcallback, wetter), self.downloadListError)
9825
+ if "." in ort : # e.g. 'de.ZIPcode'
9826
+ feedurl = "http://api.weatherunlocked.com/api/forecast/%s" % city
9831
9827
else:
9832
- self. feedurl = "http://api.weatherunlocked.com/api/forecast/%s,%s%s%s " % (self.Long[wetter], self.Lat[wetter], apkey, lang )
9833
- L4logE("WU-getforecastweather%s: %s" % (wetter, self. feedurl))
9834
- callInThread(getPage, self. feedurl, boundFunction(self.downloadWUcallback, wetter), self.downloadListError)
9828
+ feedurl = "http://api.weatherunlocked.com/api/forecast/%s,%s" % (self.Long[wetter], self.Lat[wetter])
9829
+ L4logE("WU-getforecastweather%s: %s" % (wetter, feedurl))
9830
+ callInThread(boundFunction( getPage, feedurl, params=params) , boundFunction(self.downloadWUcallback, wetter), self.downloadListError)
9835
9831
L4log("Wetter%s: downloadstart %s:%s %s %s" % (wetter, LCD4linux.WetterApi.value, ort, language.getLanguage(), la))
9836
9832
else:
9837
9833
if self.NetworkConnectionAvailable is not None:
@@ -10596,8 +10592,7 @@ def MoonPosition(now=None):
10596
10592
10597
10593
10598
10594
def MoonPhase(pos):
10599
- index = (pos * float(8)) + float("0.5")
10600
- index = floor(index)
10595
+ index = int(floor(pos * 8 + 0.5))
10601
10596
return {
10602
10597
0: _("New Moon"),
10603
10598
1: _("First Quarter"),
@@ -11015,8 +11010,8 @@ def putWetter(workaround, draw, im):
11015
11010
UseWetterPath = WetterPath
11016
11011
if len(LCD4linux.WetterPath.value) > 2 and isfile(join(LCD4linux.WetterPath.value, "0.png")):
11017
11012
UseWetterPath = LCD4linux.WetterPath.value
11018
- WetterType[ConfigWWW] = ConfigType
11019
- WetterZoom[ConfigWWW] = ConfigZoom
11013
+ WetterType = ConfigType
11014
+ WetterZoom = ConfigZoom
11020
11015
POSX, POSY = 1, 0
11021
11016
Wmulti = ConfigZoom / 10.0
11022
11017
largesize = not ConfigType.startswith("3")
@@ -11049,7 +11044,7 @@ def putWetter(workaround, draw, im):
11049
11044
MAX_W = int(55 * 5 * Wmulti)
11050
11045
MAX_Wc = int(50 * 2 * Wmulti) - MAX_Wr
11051
11046
elif ConfigType == "22":
11052
- MAX_W = int(554 * 2 * Wmulti)
11047
+ MAX_W = int(55 * 2 * Wmulti)
11053
11048
MAX_Wc = int(50 * 2 * Wmulti) - MAX_Wr
11054
11049
elif ConfigType == "3":
11055
11050
MAX_W = int(48 * 2 * Wmulti) - MAX_Wr
@@ -11062,16 +11057,19 @@ def putWetter(workaround, draw, im):
11062
11057
MAX_Wc = MAX_W
11063
11058
POSX = int(54 * 2 * Wmulti)
11064
11059
POSY = int(40 * 2 * Wmulti)
11065
- imageMode = "RGBA" if LCD4linux.WetterTransparenz.value == "true" else "RGB"
11066
- self.im[Wim] = Image.new(imageMode, (MAX_W, MAX_H), (0, 0, 0, 0))
11067
- if LCD4linux.WetterTransparenz.value == "crop":
11068
- POSXs = getSplit(ConfigSplit, ConfigAlign, MAX_Wi, MAX_W)
11069
- image_Back = self.im[im].crop((POSXs, ConfigPos, POSXs + MAX_W, ConfigPos + MAX_H))
11070
- self.im[Wim].paste(image_Back, (0, 0))
11060
+ if LCD4linux.WetterTransparenz.value == "true":
11061
+ self.im[Wim] = Image.new('RGBA', (MAX_W, MAX_H), (0, 0, 0, 0))
11062
+ else:
11063
+ self.im[Wim] = Image.new('RGB', (MAX_W, MAX_H), (0, 0, 0, 0))
11064
+ if LCD4linux.WetterTransparenz.value == "crop":
11065
+ POSXs = getSplit(ConfigSplit, ConfigAlign, MAX_Wi, MAX_W)
11066
+ image_Back = self.im[im].crop((POSXs, ConfigPos, POSXs + MAX_W, ConfigPos + MAX_H))
11067
+ self.im[Wim].paste(image_Back, (0, 0))
11071
11068
self.draw[Wim] = ImageDraw.Draw(self.im[Wim])
11072
11069
if ConfigType != "3" and not ConfigType.startswith("4"):
11073
11070
i = 0
11074
11071
for curr in self.WWeek[ConfigWWW]:
11072
+ L4logE(str(curr))
11075
11073
if (i < 4 and ConfigType in ["1", "2", "5"]) or (i < 5 and ConfigType in ["11", "21", "51"]) or (i < 2 and ConfigType in ["12", "22"]):
11076
11074
i += 1
11077
11075
High = curr.get("High", "0")
@@ -11233,7 +11231,7 @@ def putWetter(workaround, draw, im):
11233
11231
else:
11234
11232
xx = yy = 20
11235
11233
if isfile(join(UseWetterPath, Icon)):
11236
- pil_image = Image.open(join(UseWetterPath, Icon)).convert(imageMode )
11234
+ pil_image = Image.open(join(UseWetterPath, Icon)).convert("RGBA" if LCD4linux.WetterTransparenz.value == "true" else "RGB" )
11237
11235
xx, yy = pil_image.size
11238
11236
if ConfigType.startswith("5"):
11239
11237
y = int((int(LCD4linux.WetterIconZoom.value) + 5) * Wmulti / xx * yy)
0 commit comments