timeofday has same values - everytime
Posted: Tuesday 20 June 2017 22:08
Hi Forum,
Probably a stupid question, but since I cannot figure it out...
I'm using:
and this always returns:
2017-06-20 21:56:07.977 LUA: Sunset in minutes = 1317
regardless of the time of the day; it is always 1317
I printed the table contents using some table-print function, which always gives:
{
SunriseInMinutes= 321,
SunsetInMinutes= 1317,
Daytime= "true",
Nighttime= "false",
}
Also checked the time on my RPI:
pi@raspberrypi:~ $ date
Tue Jun 20 22:02:33 CEST 2017
which seems to be OK
As well as the time in Domoticz:
2017-06-20 22:03:23 ☀▲05:21 ▼21:57
There must be something obvious I overlooked. Any tip for me?
Probably a stupid question, but since I cannot figure it out...
I'm using:
Code: Select all
print("Sunset in minutes = " .. timeofday['SunsetInMinutes'])
2017-06-20 21:56:07.977 LUA: Sunset in minutes = 1317
regardless of the time of the day; it is always 1317
I printed the table contents using some table-print function, which always gives:
{
SunriseInMinutes= 321,
SunsetInMinutes= 1317,
Daytime= "true",
Nighttime= "false",
}
Also checked the time on my RPI:
pi@raspberrypi:~ $ date
Tue Jun 20 22:02:33 CEST 2017
which seems to be OK
As well as the time in Domoticz:
2017-06-20 22:03:23 ☀▲05:21 ▼21:57
There must be something obvious I overlooked. Any tip for me?