Having problems comparing two states in condition section of an automation:
(left the actions part out)
alias: Battery_stop
description: Stop battery when setpoint reached
triggers:
- entity_id:
- sensor.solax_inverter_battery_capacity
not_from:
- unknown
- unavailable
not_to:
- unknown
- unavailable
trigger: state
conditions:
- alias: Are they Equal?
condition: state
entity_id: sensor.solax_inverter_battery_capacity
state:
- input_number.batterij_instelpunt
- condition: state
entity_id: input_boolean.battery_overset
state:
- "on"
After running the automation and switching to tracking, I get this:
result: false
state: ‘69’
wanted_state: ‘69.0’
It looks like HA compares strings, not numbers, So even if 69 and 69.0 have the same value, it compares false. Could it be because of the decimal?
Thanks for any help offered.