Stop Constant Notifications

I have a rule that I have just transcribed from Rule 4 to Rule 5.1 in the hope that I might be able to stop receiving notifications every time the Rule is Triggered. The rule is working perfectly, other than I get a notification if either of us is 'Away', or two notifications if both of us are 'Away'. Also of course, returning triggers two notifications.

What I would like to happen is to only get a single notification if a condition has been met that will cause a change of state to occur; i.e. both 'Away', either arrives home, or 8:00 or 22:00.

I was hoping that I might find something in the new documentation for Rule 5 that might help me to achieve that, but I couldn't find anything.

Would appreciate any wise words that might point me in the best direction.
Dave

A couple of things you could do.

To stop two notifications when you both arrive or leave simultaneously. Add a wait for event elapsed time of say a minute. If the rule triggers twice within that time it will stop the wait and restart the rule, You only get one notification.

After that add conditions that you don't want a notification for and exit the rule. %device% will tell you what triggered the rule. For example if one person is already home and the other person arrives exit rule. Someone arrives and security is already off exit rule, etc.

Also this is all stuff you could do in RM legacy, so you could just edit that rule.

1 Like

OK, thanks 'terminal3'. So it's still not possible to put a GOTO END-IF if a condition has been met.
I was hoping that something equivalent to that might have been possible in RM5. Or indeed that modifying the code might avoid the issue.

"Exit Rule" will stop running additional actions, if that is helpful, though you can achieve the same by wrapping whatever you don't want to run inside another condition (likely the opposite of the one you'd use on Exit Rule). There are no GOTOs per se in RM, though there are many ways to control flow.

2 Likes

What @bertabcd1234 said, basically a exit rule is a goto, it will stop the rule at that point. You don't have to use an exit rule you can put the IF around the statements and accomplish the same thing, but the exit rule is more efficient IMO.

1 Like

OK. Thanks to all. I'll work on that using an Exit Rule.