Using the platform integration sensor sensor.energy_import (se below) as input sensor in the Energy Dashboard causes failure of the sensor Energy Import Cost - when HA is rebooted. The power input is from the Huawei Solar integration. and my own two sensors for energy and costs do not crash?
The sensor crashing is created automatically by HA.
The energy sensor used as input in the Energy Dashboard.
- platform: integration
source: sensor.power_import
name: "Energy Import"
unique_id: energy_import
round: 6
unit_prefix: k
unit_time: h
method: left
The power sensor used as input to the energy sensor.
- name: "Power Import"
unique_id: power_import
unit_of_measurement: W
device_class: power
state_class: measurement
state: >
{{ (
states('sensor.power_meter_active_power') | float(0)
, 0 ) | min | abs }}
UPDATE: Apparently not…“The way”. I created a utility meter Energy Import UM in stead of the sensor. Teste with and without periodically_resetting: and with both values true and false . No effect what so ever.
The strange thing is that the consumption in the Energy Dashboard does not reflect the value of the sensor that HA has created Energy Import UM Cost? It seams to add all the delta values up. Sorry but this does not make any sense to me.