aboutsummaryrefslogtreecommitdiff
path: root/mytest.py
diff options
context:
space:
mode:
authorghost <andreas.monzner@multimedia-labs.de>2009-03-05 00:12:40 +0100
committerghost <andreas.monzner@multimedia-labs.de>2009-03-05 00:12:40 +0100
commit690b1b1a235752794a92e99bf513a6db01f42748 (patch)
tree613f590aa918db11f5d3da0a4afe9f589ed7f26c /mytest.py
parent8ca7a05ca454eafdeb43cbbc68384af56dd9e153 (diff)
downloadenigma2-690b1b1a235752794a92e99bf513a6db01f42748.tar.gz
enigma2-690b1b1a235752794a92e99bf513a6db01f42748.zip
mytest.py: set RTC Time on e2 shutdown when not dvb transponder time update is used
add debug output
Diffstat (limited to 'mytest.py')
-rwxr-xr-xmytest.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/mytest.py b/mytest.py
index 261ff2a6..b58ec2df 100755
--- a/mytest.py
+++ b/mytest.py
@@ -466,8 +466,8 @@ def runScreenTest():
runReactor()
profile("wakeup")
- from time import time
- from Tools.DreamboxHardware import setFPWakeuptime, getFPWakeuptime
+ from time import time, strftime, localtime
+ from Tools.DreamboxHardware import setFPWakeuptime, getFPWakeuptime, setRTCtime
#get currentTime
nowTime = time()
wakeupList = [
@@ -479,11 +479,16 @@ def runScreenTest():
wakeupList.sort()
recordTimerWakeupAuto = False
if wakeupList:
+ from time import strftime
startTime = wakeupList[0]
if (startTime[0] - nowTime) < 330: # no time to switch box back on
wptime = nowTime + 30 # so switch back on in 30 seconds
else:
wptime = startTime[0] - 300
+ if not config.misc.useTransponderTime.value:
+ print "dvb time sync disabled... so set RTC now to current linux time!", strftime("%Y/%m/%d %H:%M", localtime(nowTime))
+ setRTCtime(nowTime)
+ print "set wakeup time to", strftime("%Y/%m/%d %H:%M", localtime(wptime))
setFPWakeuptime(wptime)
recordTimerWakeupAuto = startTime[1] == 0 and startTime[2]
config.misc.isNextRecordTimerAfterEventActionAuto.value = recordTimerWakeupAuto