Hello ,
I’m afraid I didn’t fully understand the platform:integration
including the Riemann sum and now I need help with the implementation of my project.
I would like to measure most of my energy consumption and display it in Home Assistant. But i g
For this I have done the following steps.
- measured or calculated all consumers by
a) equipped them with a measuring socket
b) measured them and simulate the consumption in a sensor, f.e.
sensor:
- platform: template
sensors:
current_power_network:
friendly_name: "power (current): network devices"
unit_of_measurement: "W"
value_template: 12
- use
platform:integration
to convert current power (W) to energy (kWh):
sensor:
- platform:integration
source: sensor.current_power_network
name: energy_spent_network
unit_prefix: k
round: 3
- use
utility_meter
as electricity meter
utility_meter:
monthly_energy_network:
source: sensor.energy_spent_network
cycle: monthly
yearly_energy_network:
source: sensor.energy_spent_network
cycle: yearly
Now my problem:
I have big differences in total consumption depending on how I sum them. If I sum up the current power of all consumers and then use it in integration
and utility_meter
, I end up with a total consumption of 30 kWh.
But if I use all consumers individually in
integration
and utility_meter
and then sum up the results, I get 43 kWh.I assumed it didn’t matter when and how I sum everything, but I guess I was wrong. I probably didn’t understand the integration
correctly. Can anyone find my error in thinking and explain it to me?