What controls daily rollover of "Power to kWh/d"?

Hi,
As per the subject, I have noticed my feeds that use a process “Power to kWh/d” rollover back to zero, but only do so at 1 AM and not midnight.
Time zone of my user account is set to “Europe/London”, which is now using DST since the weekend. Previous to this, feeds rolled over correctly at midnight, but since the change-over, it seems any process of the type “Power to kWh/d” is still internally referencing UTC.

I have a schedule setup to flag day an night rates, and this works fine and as expected, accounting for DST. in this graph, I show my night rate cost, which starts increasing at midnight (per my schedule and is correct), but then at 1 AM it resets to zero, and starts counting up again…

Any tips/advice here?

That graph looks like it comes from HomeAssist ? So you might need to check the time/zone/settings and or synchronisation between your EmonCMS system and your HA system ?? Maybe?
Given your sending feed data across ? Just a suggestion

Hi @muzza , it did come from HA yes, it was just easier to screenshot it there. The “Power to kWh/d” processing is still done in my emonPI and then pushed out to via MQTT. The exact same reset at 1am pattern can be seen in the native graphs in emon…and to confirm, both my emonpi and my HA box are set to “Europe/London”. The resetting is being done in the emonpi somewhere…but I cant find exactly where or why yet…

OK, so try this:
ssh into your emonpi
and issue: timedatectl status
What do you see?
For example I get this…

pi@emonpi:~ $ timedatectl status
               Local time: Thu 2024-04-04 10:48:59 AEDT
           Universal time: Wed 2024-04-03 23:48:59 UTC
                 RTC time: n/a
                Time zone: Australia/Melbourne (AEDT, +1100)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no

I set my timezone on the emonpi with:
sudo raspi-config
then select: Option 5 (Localisation)
and then: L2 TimeZone

i get:

pi@emonpi:~ $ timedatectl status
               Local time: Thu 2024-04-04 01:34:44 BST
           Universal time: Thu 2024-04-04 00:34:44 UTC
                 RTC time: n/a
                Time zone: Europe/London (BST, +0100)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no

and here is a portion of one of my input/feed processing chains. Any feed that is created via the Power to kWh/d processor is resetting at 1AM BST / Midnight UTC:

Hmm sorry I’m out of ideas for now … you need to sleep on it :joy:

1 Like

You’re seeing the correct time in emonCMS → Admin → System Info?

If you are, this sounds like one that got away from @TrystanLea.

To confirm, I am on daylight saving time and my kWhd feeds are resetting ok at midnight here (Aus).
And next Sunday we return to ‘standard’ time … so will keep an eye on this … :face_with_monocle:

I have been reading the troubleshooting guide here…

docs.openenergymonitor.org/emoncms/troubleshooting.html

towards the bottom of that section is some timezone information.

If you go to EmonCMS → My Account → Profile

what is the Timezone set to there?

I was afraid of that :smile:

And yes, admin/system-info is also set to Europe/London, and showing right now as BST, which is correct.

Here are all the places where I can find TZ references:

image

image

image

image