Presence Central
I created this SmartApp for my own use but thought I’d share it in case anyone else finds it useful.
I have been testing it for a while and it seems to work fairly consistently.
The reason I wrote this is because I had lots of separate apps controlling different presence actions.
I just wanted to bring everything together in on Parent/Child app
First of all I have to credit Brian Gudauskas (@bridaus -Reliable Presence) & Eric Roberts (@baldeagle072 - Everyone’s Presence) for stealing some of their code for multiple presence sensor determinations.
Without their great work this app would not have been possible to create.
This is a Parent/Child app to control presence sensor actions. Once installed you can setup any number of ‘child’ apps.
You need to install & publish the Parent in the IDE but there should be no need to publish the Child app
Inputs for events:
-
Single Presence Sensor – arrived/departed
-
Group Presence1 – This sets presence to ‘home’ if ANYONE arrives and sets presence to ‘away’ if ANYONE leaves
-
Group Presence 2 – This sets presence to ‘home’ if ANYONE is present and sets presence to ‘away’ only once EVERYONE leaves.
-
Group Presence 3 – This sets presence to ‘home’ if EVERYONE is present and sets it to away if ANYONE leaves
-
Check for presence at a certain time - Useful if you want to do something at a certain time but only if someone is present
Actions:
-
Control a Switch – Configurable for arrival or departure to turn on/off a switch
-
Speak a Message – Using ‘Sonos’ or equivalent speakers to play a message when someone arrives/departs
This has the ability to create a ‘quiet’ time so different volumes can be used at night/in the evening -
Send A Message – on arrival or departure (Push or SMS)
Will use ‘Contacts’ if enabled on your account -
Change Mode – on arrival or departure
-
Run A Routine – on arrival or departure
-
Control a Door - open on arrival, closed on departure
-
Control a Lock - Unlock on arrival, lock on departure
-
Flash Lights - on arrival or departure
Each child app can be configured to be enabled/disabled via an optional switch.
There are also optional restrictions for mode, within a certain time period, sunrise to sunset & sunset to sunrise.
Latest Parent here: (Current Version: 1.0.0)
https://github.com/CobraVmax/SmartThings/blob/master/smartapps/cobra/presence-central.src
Latest Child here: (Current Version: 1.4.0)
https://github.com/CobraVmax/SmartThings/blob/master/smartapps/cobra/presence-central-child.src
This is integrated with GitHub if you want to use this to keep up-to-date with any changes I make.
Owner: CobraVmax
Name: SmartThings
Branch: master
Breaking News!
Presence Central is now included in the brilliant “Community SmartApp Installer”
So, it’s even easier to install and keep up to date