View Full Version : [VU+ Duo2] 10088 min left
46114
amazing isn't it?
now, the reason for that probably is the fact that inconsistent epg data are used to calculate the remaining time.
due to soccer the program changed... but the current/next epg for some reason still had the old program.
amazing isn't it?It's out by exactly 1 week.
but the current/next epg for some reason still had the old program.
This data is provided by the broadcaster - its nothing to do with the image. Also it is provided differently from the epg data that is downloaded via crossepg etc.
The now/next data is transmitted live and if the broadcaster doesn't update it when a programme changes then it will be wrong.
well, the point was not that the current/next epg is wrong. i know that this data is provided by the broadcaster.
the point was that the duration is not calculated correctly.
47570
happend again with 4.0.
the info bar shows the correct remaining duration of 44 mins.
Might be something in the LCD display code, rather than any generic EPG handler code.
yes, i think so too. is this lcd4linux or where do we find the culprit?
just happened again... lcd only.
The code for it is in plugin.py in LCD4linux. At line 1991:
event_begin, event_end, duration, event_name = getServiceInfo(self,0)
if event_begin != 0:
now = int(time())
event_run = now - event_begin
if ConfigType == "2":
remaining = "%+d min" % int((event_end - now)/60)getServiceInfo() get its data from NowNext data.
If you change the display to ConfigType == 3 (whatever that is in your options) you'll get event_run displayed as a percentage of duration, which might(?) shed some light on which figure is wrong.
well, looking at the code... now should be correct... remaining = envent_end - now... so, event_end should be a week off (and the event_begin probably as well)
have you also found the code for getServiceInfo?
the info bar code might also be helpful because on the info bar the remaining duration is shown correctly.
have you also found the code for getServiceInfo?It's in plugin.py too.
The relevant part is:
sref = self.session.nav.getCurrentlyPlayingServiceReferen ce()
if sref is not None:
event = self.epgcache.lookupEvent(['IBDCTSERNX', (sref.toString(), NowNext, -1)])
event_begin = 0
if event:
if event[0][4]:
t = event[0][1]
duration = event[0][2]
event_name = event[0][4]
event_begin = t
event_end = event_begin + duration
else:
service = self.session.nav.getCurrentService()
info = service and service.info()
event = info and info.getEvent(NowNext)
if event:
event_name = event.getEventName()
event_begin = event.getBeginTime()
duration = event.getDuration()
event_end = event_begin + duration
the info bar code might also be helpful because on the info bar the remaining duration is shown correctly.That might be skin-based. For the skin I use this is:
<widget source="session.Event_Now" render="Progress" position=......
<convert type="EventTime">Progress</convert>
</widget>That all gets a bit deep into C++ code, which might not be al that helpful to look at.
I could provide a simple patch to plugin.py so that the first time it finds that "remaining" is > 1 day it dumps some variable values into the debug log.
that might be a good start...
what i also found is that the remaining time is always 1 minute off for all events.
clock shows 21:30, event ends 22:00, remaining time is 29 mins.
sref = self.session.nav.getCurrentlyPlayingServiceReferen ce()
if sref is not None:
event = self.epgcache.lookupEvent(['IBDCTSERNX', (sref.toString(), NowNext, -1)])
event_begin = 0
if event:
if event[0][4]:
t = event[0][1]
duration = event[0][2]
event_name = event[0][4]
event_begin = t
event_end = event_begin + duration
else:
service = self.session.nav.getCurrentService()
info = service and service.info()
event = info and info.getEvent(NowNext)
if event:
event_name = event.getEventName()
event_begin = event.getBeginTime()
duration = event.getDuration()
event_end = event_begin + duration
to me it looks like in some cases the wrong path is taken... the if path instead of the else???
also: shouldn't first the now/next be checked???
or the cause is in the event.getDuration function.
@birdman: where do i find the lcd4linux that is used in vix 4.0?
this one?
https://github.com/OpenVuPlus/openvuplus_3.0/blob/master/meta-openvuplus/recipes-vuplus/duo2lcd4linux/files/LCD4linux.tar.gz
@birdman: where do i find the lcd4linux that is used in vix 4.0?
this one?
https://github.com/OpenVuPlus/openvuplus_3.0/blob/master/meta-openvuplus/recipes-vuplus/duo2lcd4linux/files/LCD4linux.tar.gzYes. Although you also need the duo2lcd4linux.patch (but not the duo2lcd4linux-fix-standby.patch) from files (one level up) as well. And apply it.
At least that's what gets downloaded for an OpenVix build (since I don't have a VU Duo2 it doesn't actually get built for me?).
to me it looks like in some cases the wrong path is taken... the if path instead of the else???In what way "wrong"?
It first checks the NowNext data, and uses it if the event_name is defined.
Otherwise it gets the info for the current service.
also: shouldn't first the now/next be checked???Checked for what?
or the cause is in the event.getDuration function.Until we know which of the two paths is used when it goes wrong it's all just guessing.
what i also found is that the remaining time is always 1 minute off for all events.
clock shows 21:30, event ends 22:00, remaining time is 29 mins.So, time is actually 21:30:xx (xx non-zero). time remaining is 29:yy (xx+yy == 60). Time displayed is whole minutes left.
that's what i suspected... but to me it's not logical...
i swapped the lookup of now/next with epgcache and will test starting tonight... I think the info bar uses now/next as well.
def getServiceInfo(self,NowNext):
self.epgcache = eEPGCache.getInstance()
event_begin = 0
event_end = 0
duration = 0
event_name = ""
if self.epgcache is not None:
sref = self.session.nav.getCurrentlyPlayingServiceReferen ce()
if sref is not None:
service = self.session.nav.getCurrentService()
info = service and service.info()
event = info and info.getEvent(NowNext)
if event:
event_name = event.getEventName()
event_begin = event.getBeginTime()
duration = event.getDuration()
event_end = event_begin + duration
else:
event = self.epgcache.lookupEvent(['IBDCTSERNX', (sref.toString(), NowNext, -1)])
event_begin = 0
if event:
if event[0][4]:
t = event[0][1]
duration = event[0][2]
event_name = event[0][4]
event_begin = t
event_end = event_begin + duration
return event_begin, event_end, duration, event_name
that might be a good start...
Here's a debug version to print (once) when it goes wrong (you'll have to be running with debug logs on).
Extract the plugin.py file and install it to /usr/lib/enigma2/python/Plugins/Extensions/LCD4linux/ - take a backup copy of the plugin.pyo file which is already there. Then restart enigma2.
47745
I've added this code:
--- plugin.py.orig 2016-04-11 12:58:29.378320817 +0100
+++ plugin.py 2016-04-11 13:18:12.567481517 +0100
@@ -1479,6 +1479,9 @@
return number
return None
+#GML
+Oddity_Reported = False
+
def getServiceInfo(self,NowNext):
self.epgcache = eEPGCache.getInstance()
event_begin = 0
@@ -1490,14 +1493,17 @@
if sref is not None:
event = self.epgcache.lookupEvent(['IBDCTSERNX', (sref.toString(), NowNext, -1)])
event_begin = 0
+ method = 0 # GML
if event:
if event[0][4]:
+ method = 1 # GML
t = event[0][1]
duration = event[0][2]
event_name = event[0][4]
event_begin = t
event_end = event_begin + duration
else:
+ method = 2 # GML
service = self.session.nav.getCurrentService()
info = service and service.info()
event = info and info.getEvent(NowNext)
@@ -1506,6 +1512,12 @@
event_begin = event.getBeginTime()
duration = event.getDuration()
event_end = event_begin + duration
+#GML
+ now = int(time())
+ if ((event_end - now) > 86400) and not Oddity_Reported: # > 1 day
+ Oddity_Reported = True
+ print "[LCD4Linux ODDITY] at %d: method %d, event_begin %d, duration %d, event_name %s" % (now, method, event_begin, duration, event_name)
+
return event_begin, event_end, duration, event_name
def getResolution(t):
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.