Normally Im pretty good with rule machine but I'm having a hard time trying to figure out how to write this one because it involves durations and such. I'm hoping someone can lead me down the right path.
This is generally what I am trying to do. Report any of 3 contacts left open for 10 minutes, and then continue to check every hour and report. What do you think is the most efficient way to write something like the following
if any of contact1, contact2, contact 3 left open for 10 minutes
repeat every 60 minutes
if any of contact1, contact2, contact 3 still open
until (contact1, contact2, contact3 all closed)
I use the built-in Notifications app for this. Simple setup and works great.
I cant use use the notifcation app for this as "speak blat" is actually more involved than what I just have here. I may do several things (and some custom actions as well) for each state
This would be a lot easier if there were just one sensor, so a workaround for this awkwardness might be using one of those apps that "combines" multiple sensors into one, making that sensor open if any open and closed otherwise (when all are closed). But-as is, a rule something like this should work:
Here, I'm using Private Boolean to track whether the 10-minute countdown has already started, as I assume you want to start counting with the first sensor and not restart if any become open after that (if not, some of this could be removed and it would be a bit cleaner, too).
okay.. this is what I finally went with. It seems to work.
If my understanding of how the predicate conditions works, I really don't need the "10minutewarningsent" check, as only one instance of this rule should ever run (if a second contact opens after the first one, it will be ignored). also, modified it a bit so that messages are sent by mode
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.