Utility meter - both peak and off-peak are tracked

I followed some guides to setup utility meter. All appears well, I have created two tariffs for peak and off-peak (here they are called daily and nightly rate) and I have created an automation via node-red to switch from one to the other at a given time with the help of BigTimer node.

In the main select helper, everything seems fine, the switch from night to day happens at 06:00 am. However, after that both night and day continue to track the energy, it is as if only day tariff was turned on at 6, but night was not turned off. Any ideas?

Here is my main electricity select, it switched fine at 06:00:

Here is how my energy dashboard looks like, only night tracked until 6 am and after that both are tracked at the same time:

Here are my node red settings in BigTimer. “Day” message is sent at 06:00 AM, “Night” message is sent at 22:00

Here is the call service that changes the select from day/night/day based on a trigger from big timer. I have used this thread for inspiration: Utility Meter integration nodered automation

Any help will be appreciated.

There’s nothing wrong with that.

The night tariff sensor is not increasing during the day. Though it is hard to see as you blocked most of the graph with the tool-tip box.

It stays at the value it was just before the day tariff started accumulating.

Were you expecting it to reset to zero?

That only happens when the cycle period you defined for your utility meter occurs - daily by the looks of it as it reset at midnight.

The night tariff sensor is not increasing during the day. Though it is hard to see as you blocked most of the graph with the tool-tip box.
It stays at the value it was just before the day tariff started accumulating.

I don’t think you’re reading that right, the bars in the energy graph is the consumption during that hour. So there shouldn’t be any night bars visible during the daytime hours.

1 Like

It is increasing, in fact night tariff doubles the day one. The total consumption is also doubled on what it should be.

I have monthly reset of the utility meter (though, I don’t know where can I check that, but this is what I remember during the setup), the change at midnight was me manually testing the node red node.

Can you show a history plot of both utility meter sensors for this day?

Oops. yeah, you’re right. Something definitely not right there.

My guess is they are feeding the utility meter with a power sensor, not energy.

The feed is from energy. Shelly EM reports total active energy.

1 Like

Did you maybe set detta_values option as true in the utility meter configuration?

Yeah that night sensor just looks wrong… you’re sure you’ve got the correct sensor?

Can you screenshot this from devtools/states?

Cant remember :frowning: Is there anyway I can check that?

I guess I can delete the helpers and start from scratch, but I am afraid some orphaned entities will be left out.

Yeah I dunno that all looks good to me. :confused:

Thinking we’re in report a utility_meter bug territory here.

Thanks, will scratch my head a bit and report it as a bug if I can’t find the source of the issue.

Mine is still switching correctly, the difference being I use an automation, not Node Red.

I have restarted home assistant just in case. To my surprise, it seems to have resolved the problem. I did the restart at 4:20 my time and after that the night tariff flatlined, the day tariff is much larger in the Energy dashboard and I am pretty confident that in the next hour the night one will drop to 0.

Mystery not really solved, but problem resolved.