Total Daily Energy Sensor¶
So this component allows you to convert readings in
kW to readings of the total
daily energy usage in
# Example configuration entry sensor: - platform: total_daily_energy name: "Total Daily Energy" power_id: my_power # The power sensor to convert, can be any power sensor - platform: hlw8012 # ... power: id: my_power # Enable time component to reset energy at midnight time: - platform: sntp id: my_time
power_id (Required, ID): The ID of the power sensor to integrate over time.
name (Required, string): The name of the sensor.
id (Optional, ID): Manually specify the ID used for code generation.
min_save_interval (Optional, Time): The minimum time span between saving updated values to storage. This is to keep wearout of memory low. Defaults to
method (Optional, string): The method to use for calculating the total daily energy. One of
right. Defaults to
All other options from Sensor.
Converting from W to kW¶
Some sensors such as the HLW8012 expose their power sensor with a unit of measurement of
W. To have your readings in
kW, use a filter:
sensor: # The power sensor to convert, can be any power sensor - platform: hlw8012 # ... power: id: my_power filters: # Multiplication factor from W to kW is 0.001 - multiply: 0.001 unit_of_measurement: kW