Hello community, I migrated all my Xiaomi sensors on conbee/raspbee, and now I have to move every automations from Xiaomi GW to HA. One basic automation I have to export is:
Trigger: detected motion
Condition: Dark = true
Action: Turn on light
Actually I tried with the Lux value (need to test it anyway), but I prefer to use Dark True/false,
condition:
- condition: state
entity_id: binary_sensor.dark_outside
state: 'on'
The advantage of the 2nd option is a simpler condition and that the template only gets evaluated once (not in every automation you use it in) and you can add it to the front end as a Lovelace entity to see what is going on. None of these are huge advantages. There’s a custom card to display attributes and as the template is in a condition it is only evaluated when the automation runs. Up to you which you use.
So, the above code means:
IF DARK = TRUE THEN ACTION
So this is the TRUE condition, and what about if I have to check the FALSE one?
I mean if in another condition I have something like:
IF DARK = FALSE THEN ACTION