Hi there,
i do have a strange experience and would like to hear your opinion.
Perhaps i’m just blind on one eye
I have an energy meter in my house which is giving an absolute reading of kWh.
- i defined a template sensor, that is getting it’s absolute value every minute
- i defined three utility meters (daily, monthly, yearly) to get these data (that’s my main goal)
The template sensor works fine and is giving me the correct value that i’m seeing at the hardware meter as well:
- name: "zähler_einspeisung_powerfox"
unique_id: "zahler_einspeisung_powerfox"
state: "{{ state_attr('sensor.powerfox_alle_werte', 'A_Minus') }}"
unit_of_measurement: "kWh"
device_class: "energy"
state_class: "total_increasing"
The utility meters are (and also working):
utility_meter:
haus_einspeisung_daily_kwh:
source: sensor.zahler_einspeisung_powerfox
cycle: daily
haus_einspeisung_monthly_kwh:
source: sensor.zahler_einspeisung_powerfox
cycle: monthly
haus_einspeisung_yearly_kwh:
source: sensor.zahler_einspeisung_powerfox
cycle: yearly
But, what happens is:
- i take the reading from the template sensor at 00:00 (for instance 946,937)
- then i take a reading at say 15:15 with a value of 952,228)
→ the difference is 5,291
→ the daily utility meter shows 5,242
The difference is even bigger (and still getting bigger) in the monthly and yearly meters.
As the real meter was installed two months ago, at least the value of my yearly utility meter should be exactly the same as the actual reading at the hardware meter, right? But it’s not. It’s off by somewhat 20 kWh and keeps getting bigger (as does daily and monthly).
This happens also in between reboots, so rebooting should not be the cause of any miscalculation.
The only thing that could happen is, that the api calls fail and deliver “unavailable” for a minute or two.
Am i missing something here?
Thanks!
PS: i did “calibrate the meter sensors” from time to time. Then they show the correct values, but as time goes by the values start to drift away again.