Now that I have some devices set up with Apple HomeKit, I’d like to be able to set up some basic rules, like making sure my front door is locked and garage door is closed at 11pm. How do you set up automation rules in HomeKit?
Congrats on joining the world of home automation and smarthomes. It’s up to us to put the “smart” in “smart home”, however, so you’re right to start exploring automation and programming rules, and Apple HomeKit makes it easy to do so. They’re not super sophisticated rules and there are some interesting safety issues that can arise, but let’s go through the basics first.
And first step is to add the device or devices to HomeKit, then to name them as you desire and make sure they’re assigned to the right rooms. Not sure how to do that? Check out my tutorial on “Moving HomeKit devices out of Default Room” to get started.
Once you’ve done that, in the Home app you’ll want to tap on the “Automation” button on the bottom. It takes you here:
You can see that I already have a programmed rule, actually. At 10pm my front door Schlage Sense deadbolt automatically locks. Just in case I forget or my children have come in and neglected to lock the door. Your display will be empty since you haven’t set up any rules yet, but we’ll fix that problem!
Tap on the big orange “Create new Automation” button.
With the HomeKit accessory I have, there are only a subset of trigger events available. With others, you’ll have access to “a sensor detects something” and “an accessory is controlled”. My deadbolt has two options: My Location Changes or A Time of Day Occurs.
Since I already have a trigger event at 10pm every evening, let’s set up a new rule that says if I drive away from the house, lock the front door. Seems reasonable!
To proceed, I’ll tap on “My Location Changes” in the Home (HomeKit) app on my Apple iPhone.
You can see it shows my Home location as a red pushpin, and the blue circle indicates what’s know in the biz as the geofence, the region defined as nearby. I can stretch that out if I have a farm, for example, and need it to encompass the back forty, or narrow it down if I want to be really anxious.
I can also trigger events based on other addresses, including three that Apple’s conveniently pre-loaded into the program that I’ve visited recently. Imagine, every time I go to the Toyota dealership my garage light mysteriously turns on! Weird.
More importantly, notice the pair of options in the middle: “When I Arrive” and “When I Leave“. So you can in fact have your front door unlock automatically whenever you enter the geofence area, or, perhaps a bit more safe, have my thermostat switch from away mode to home mode when I drive up to the house.
I’m going to use “When I Leave” and the location “Home” and that’s my trigger event.
Now, what should happen when that trigger event happens?
There’s only so much you can do with a deadbolt, so let’s choose it …
I specify that I want the deadbolt to LOCK and because it’s related to home security, an interesting message appears:
In reality it’s not allowing entry because it’s a lock event, but if it were to fail, then the message is accurate and my reliance on my home being “smart” could prove to be, well, dumb.
Looks good nonetheless, so I’ll tap on “Done” in the top right to set up this rule on my system. And now it shows up in the Automation area:
In practice the confirmation is actually pretty annoying: a reminder pops up for just a few seconds on my iPhone 7 as I depart the geofence area and if I don’t see it in time, the event isn’t triggered. Honestly, not very useful at all. The timed one, however, that’s better and I am glad to know that the chances of me leaving my door unlocked overnight has gone to zero.
Geolocation-based trigger events and home automation rules are much more useful when it’s not a security event. If you think about it, having someone walk up to your front door with your stolen phone should not be sufficient for the door to just unlock and invite them in for more mayhem, so maybe it’s not too crazy after all.
Now to smarten up my home with more HomeKit compatible devices…
Well, what you describe is how it should work, but here is the problem. When I select “Home” as the location, it does not allow you to define a radius. If I put in my home address, or any other address or map location, it shows a vicinity location radius that can be reduced or expanded. I have read on the Web that the “Home” location has a small fixed radius that cannot be modified. If that is the case, it is a stupid restriction that should be changed. You may say that I can put in my address and then I will be able to adjust the radius That is certainly true, but what happens is that the automation title then becomes “when I arrive at… my address”… instead of what you really want,”when I arrive Home”.
Is there something I am missing here or is this a bug in the Homekit geofensing software?