Migrating motion detection app from Room Lighting to Rule Machine

I wanted to migrate a rule from room lighting to rule machine, as I find it easier to understand and debug actions in Rule Machine than Room Lighting. Could someone compare the two below to see that I did it correctly, or give advice for improvement? I did change the timeout after no motion to one minute from 4 minutes.

Goals of this rule: don't activate if light manually turned on, turn off light after 1 minute of inactivity, turn off light if no messages from motion detectors for 4 minutes (one of the detectors fails to send an "inactive" message on occasion, so the light would stay on indefinitely).

Room Lighting version:

Rule Machine version:

Looks like I made an error in the wait for expression. As written, looks like it waits for either motion detector to be quiet for 3 minutes, rather than both. Is that correct? I don't see any way to wait for both in a single conditional expression, so I broke it into two tests below, which I believe is now correct.

First, I'd suggest using the Zone Motion Controller app to group your motion sensors. There are 3 types of Zones - here's a Motion Aggregation I have set up, for example:

The Zone with it's own timeout helps to simplify such Rules.

Er. . . I don't have a "second" at this second. . . [Doh]

...bob

Does the timeout also work with detectors that only send "motion" events and not "inactive" events?

I have an Aqara motion sensor in a group along with 3 Hues. I've matched the motion reset to 10s (indicate motion for 10s after being triggered) to copy the Hue sensor reset, and it seems to be working fine. I haven't had cause to look at it closely, the lights still react the same (only, that one dead area ain't dead anymore).

I only just received 2 Aqara motion sensors with that type of motion triggering, so that's about the extent of my experience with that type.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.