I have been using HA for a few weeks now and am currently expanding my SmartHome with various sensors.
But I despair of the integration of the WaterMeter in combination with the UtilityMeter (Energy and Gas seems working fineā¦)
the problem:
the sensor (ESPHome) gets one pulse per liter
HA also receives the correct number of impulses via ESPHome integration
UtilityMeter seems to arbitrarily not count all data (for example, the daily consumption is 21 liters, 4 liters are newly transmitted, the new daily consumption is 24 liters)
Am I too stupid for the config? Am I thinking wrong?
20.8 L consumed by the end of Tuesday - displayed as 21 L
3.6 L consumed on Wednesday - displayed as 4 L
Total is now 20.8+3.6 = 24.4 - displayed as 24 L
how can I sum the liter for today manually?
all the data is in the history of the sensor, but I still havenāt figured out how to sum up these valuesā¦
so I can compare these values with the utility meterā¦
is there a log, where I can see what the utility meter do? what values it uses for the Calculation ?
The utility meter platform expects as input a number that goes up over time, much like the number visible on the meter does.
What you are providing it is a number that indicates a count of liters in the last minute.
The reason this seems to almost work, is that if the utility meter platform sees its input value go down, it assumes the input must have wrapped around, or otherwise been reset. It assumes the maximum value reached was whatever it last saw. It then adds in the new lower value.
But what happens if the number reported is 1 for one minute, and 2 the next? Well that would actually be a total of three liters, but the utility meter platform would count it as only two, because the number only went up.
What you want to do here is in the esphome config, you want to add the Total daily energy sensor using your pulse counter as the input, along with configuring the time component to enable its auto-reset. Despite the name, this sensor works just fine for non-energy inputs like water.
The result of that new esphome āsensorā output would be a value that only counts upward over time, except when it resets each day at midnight. That fits the model that the utility meter platform expects for its input just fine.