Hello,
I am currently using a pulse meter sensor to monitor the reed switch of a gas meter. The setup is functioning quite well; however, I am encountering an issue with the Total Daily Energy Sensor component. It is returning a value that is significantly lower than expected. I suspect this is due to the fact that I am measuring in cubic meters (m³) rather than watts (W), so I am actually recording watt-hours (Wh) and not watts, which might be causing incorrect unit dimensions in the measurements. Could you provide any guidance on how to configure this correctly?
Additionally, I am experiencing a time discrepancy of over an hour between Home Assistant and ESPHome. Do you have any suggestions on how to resolve this issue?
sensor:
- platform: pulse_meter
name: 'Gaszaehler 1'
id: sensor_pulse_meter # Optional ID, necessary if you want to calculate the total number of pulses.
unit_of_measurement: 'm3'
device_class: gas
state_class: measurement
internal_filter: 50ms # Assuming maximum load of 16 kW and 10000 impulses per kWh, any pulses faster than 22.5 ms would exceed load. -10% ~= 20 ms.
accuracy_decimals: 0
pin:
number: GPIO13
inverted: true
mode:
input: true
pullup: true
total:
name: "Gaszähler 1 Total"
unit_of_measurement: "kWh"
device_class: energy
state_class: total_increasing
accuracy_decimals: 3
filters:
- multiply: 10.88 # (1/10000 pulses per kWh)
# - throttle_average: 10s
# - filter_out: NaN
- platform: total_daily_energy
name: 'Gaszähler Täglicher Verbrauch'
id: sensor_total_daily_energy
power_id: sensor_pulse_meter
unit_of_measurement: 'kWh'
state_class: total_increasing
device_class: energy
accuracy_decimals: 3
filters:
- multiply: 10.88
time:
- platform: homeassistant
id: homeassistant_time