How to replicate "Things Quiet Down"

On my other platform, I was able to setup something so that if there was no motion for 30 minutes after 11pm, it would turn off all the lights. Can someone give me some pointers on how to set that up with Hubitat?

Using Rule Machine

3 Likes

If you're opposed to Rule Machine or new enough to the platform that you don't feel comfortable using it, here's another idea: create a virtual motion sensor using the built-in Zone Motion Controllers app. Choose "Motion Aggregation" as the zone type, include all sensors that you want to monitor for inactivity, and choose either the "30 minute" timeout option here or a short timeout and do the 30-minute delay logic elsewhere. Then use a stock app like Hubitat Simple Lighting to turn off the desired lights when this virtual/aggregate sensor goes inactive (either right away or with the 30-minute delay if you didn't build that into the Zone Motion Controller). Set a Restriction on the Simple Lighting app so it doesn't do this outside of your desired time frame.

The advantage of doing it this way is that now you have one sensor you can use in other automations if desired. A disadvantage is that logic is spread across two apps, but there is nothing wrong with that--as people used to say (when Rule Machine was simpler and multiple rules were often needed to achieve a single goal), "rules are free," but that applies to regular apps, too. :slight_smile: It's also probably a bit easier to set up, though either isn't bad if you're familiar with Rule Machine.

As with many things in Hubitat, there are often multiple ways to achieve the same outcome. Good luck with whichever path you choose, and feel free to ask anything if you have more questions!

2 Likes

If I want two actions to happen after the 30 minutes of inactivity, (let's say set HSM to arm) doI create an action below it that is also delayed 30 minutes? or does a second action happen right after the first delayed one is executed?

In that case, I'd use an actual Delay action, rather than the delay switch on an action.

Does this look right?

ya the problem with this implementaiton is the same as mine.. Its not truly things quiet down becuase if there was no motion to trigger a change.. ie already quiet nothing fires

the new rule machine requires a trigger where previously you could just have a rule without a trigger that would say just fire between certain times,, I guess it was inefficient.

the closest i can come is something like putting the triger being a huge or .. ie if time is this or time = this + 15 minutes etc.. so it runs every 15 minutes.. not ideal..

maybe i will have a rule like this and a drop dead rule that say at 3 am if still in home switch to night...

i already have a further rule if night and stuff is not locked at a certain time.. try again to lock and turn off lights

This is what mine looks like now:
image

i have done a new one a little different that tries every 15 minutes after a fixed time

ie

Rather than repeating x number of times etc..
and reduce the number of times it is triggerred..
I did it a little diffrently..
I have two triggers.. (1) when all the sensors in the mzone-Night mode Zone become inactive
or when it is 10 pm.. when everyone should be in bed.

So if all the motions sensors change to inactive during the day.. it will get triggered, but I added a condition in the action to only run it when it is past bedtime ( 10 pm .. to 6 am)
and I also check if the multi sensor zone is inactive..