This is compared only by stete load_output_run which theoretically should be ok, but in my case YORK this bit don't change most of the time. So this is better to add checking also by PUMP_I and fan speed > 0 -pump_i is internal which works mostly when heat pump works. Pump_o status very often is set to on even heatpump don't heat/cool so isn't good choice:
Original part of code
# Active State
- platform: template
name: "Active State"
id: "${devicename}_active_state"
icon: mdi:power
entity_category: "diagnostic"
lambda: |-
if (id(${devicename}_load_output_run).state) {
Modified code:
# Active State
- platform: template
name: "Active State"
id: "${devicename}_active_state"
icon: mdi:power
entity_category: "diagnostic"
lambda: |-
int fan_speed = id(${devicename}_fan_speed).state;
if (id(${devicename}_load_output_run).state or id(${devicename}_load_output_water_pump_pump_i).state or fan_speed > 0) {
This is compared only by stete load_output_run which theoretically should be ok, but in my case YORK this bit don't change most of the time. So this is better to add checking also by PUMP_I and fan speed > 0 -pump_i is internal which works mostly when heat pump works. Pump_o status very often is set to on even heatpump don't heat/cool so isn't good choice: Original part of code
Modified code: