Garage Open/Close Alerts

I know this is covered extensively but I can't find anything on multiple doors.
I have one rule to change inovelli switch LEDs to red if either door 1 or 2 is open, that works.
The problem is changing back to blue when BOTH doors are closed.
I made a rule called "Garage Closed Alert", and select Garage 1 and 2 contact sensors set to closed.
How do I make the rule only run when BOTH doors close? RM specifically states (ANY will trigger), but I want both doors closed to change my LED's back to blue.

Trigger for both closed events. => OR

In the actions check again that both are closed. => AND

thanks for your help.
In RM I don't see any option to set OR/AND. On my trigger page my only options are select capability for new trigger event, and then edit/delete

You can specify more than one Trigger for a Rule: All those triggers are combined by OR (aka ANY).

The first action should be a Conditional Statement, where you can add more than one expression. For each of these expressions you can choose AND/OR/XOR... :wink:
If the devices are from the same type and you want to check for the same state, you can even choose all those devices in one expression (aka ALL).

This might help ..

test

There is a subtle distinction between a rule "running" and the actions taken. The trigger of a rule is when the rule needs to be looked at .. in other words, when things might be different and your criteria for actions now met.

You use a conditional in the actions to determine whether the situation requires the actions you want. In my example, I used a Simple Conditional, but you could also use a full conditional construct (with IF/THEN/maybe ELSE/ENDIF) to do more actions or do alternative things.

I'm sure I'm just missing something simple here...
I don't see where or how I can change the "OR" to "AND"

Clicking the trigger brings me here, again I don't see how to change the OR to AND

You don't AND triggers as they are the point in time events that cause the rule to be evaluated. Notice it says the door closed, not the door is closed. There's no way that both doors will close at exactly the same time.

You've got your triggers set up fine. Now move on to the actions which you will conditionalize on both doors being closed.

1 Like

You might find this app handy too.

Not sure if those are the switches you are using or not.

If you use Inovellis Child Notification devices and the Simple Automation Rules app instead of rule machine you can accomplish this very easily. I have 2 doors, each with their own contact sensor and when either of the doors (or both) are open all my inovelli switches flash red. Only once both doors are closed does it revert back to its normal color.

2 Likes

See what I've already written:

So just add an Conditional Statement action (by clicking on "Select Actions to Run") where you can verify, that both sensors are closed.

That's exactly what I did. This is my SAR (using the child notification device on that Red dimmer). The selection for "Any opened" and the checkbox for "turn off when all closed" are key.

(what is even more amazing to me is the two garage door contact sensors are still on ST and exposed to Hubitat via Hubconnect, since I haven't moved that part of my Zigbee mesh over to Hubitat yet. The color names on the doors match the cars)

1 Like

TRIGGER: Garage Door 1 OR Garage Door 2 changes
ACTIONS:
If (Garage Door 1 OR Garage Door 2 are opened) THEN turn on red light
ELSE turn on blue light
END-IF

I went this route, thanks. Great app, One of my favorite things about Hubitat is all the new apps the community continues to develop.

Yeah..and one of the hard things is knowing what's already written!

1 Like