How can I have an automation condition that passes when a condition is NOT satisfied?
Background: I have an automation that runs AC in Dry mode when humidity exceeds X percent. Issue: this runs even when I previously set mode to Cool. I don’t want this. Question: how do I limit my automation so it does not run when already in Cool mode? The editor only lets me pick “AC is set to a specific HVAC mode”. I’d basically like an “AC is NOT set to a specific HVAC mode” option.
aha! I thought the NOT was to “Test multiple conditions in one condition statement. Passes if all embedded conditions are not valid.” as per documentation. I didn’t know it could be used for a single condition as well. Thanks!
This is the resulting automation. It still engages the Dry mode even when other modes are already running. I’m obviously bad with boolean logic because I can’t figure it out.
Even with the Action - hvac_mode above changed to “cool”, it always turns on the Dry mode. It looks like it’s how I originally thought - the NOT condition is only for two or more conditions, as stated in the documentation. But I don’t know.
I just want the automation to NOT run when Cooling mode is already enabled.
EDIT: for the time being I just changed the second condition to “AC is set to mode: OFF” which prevents it to go to Dry when already in some else active mode.
Although it don’t see why not to use device-conditions, it does make checking for me harder. But, if you don’t want it to turn on when it is set to Cool, you should check for it Cool. Do you make the automation with the UI?
The documentation does not state that Little Red Riding Hood and all her apples, even if she at all but one.
Because if you ever have to replace the device you are in for a lot of work. You cant change the new device id to match the old one in one place like you can do with entity ids. So you have to edit all your scripts and automations.
Okay, the first sentence is indeed misleading. But I think the doc does that for all instances where you can use multiple things (triggers, conditions etc). But really, you can use a single condition. Heck, you can even use a single condition for an OR or an AND although there it really does not make sense…
But did you make the automation in the UI? If not, do so. And be sure to always post the latest version of an automation as a whole.
So it isn’t complete then Please don’t make us guess about changes, just post the most up to date version.
Okay, the device-condition does make debugging harder. Just switch to a state-condition. For that, can you post a screenshot of the entity id (with all of it’s attributes and set to the state you don’t want) in the development tools?