Smart Home Automation,  Apple Watch Home Control,  Home Assistant

Control Home Assistant with an Apple Watch

It's pretty nifty and also surprisingly useful to be able to control your smart home from your wrist.

Control Home Assistant with an Apple Watch

Photo by Luke Chesser on Unsplash

It’s pretty nifty and also surprisingly useful to be able to control your smart home from your wrist. What you control depends on your use cases but I get to show you how to control it and maybe inspire you with how I use it. We will work based on the following use cases

  • Get Dustbin Bieber busy
  • Set lounge lights to a relaxed mode
  • Set lounge lights to max brightness
  • Turn off all the lights

Dustbin Bieber is our trusty Roborock S6 Pure robot vacuum.

First, you will need to set up actions from the Home Assistant iOS app. Open the app, navigate to settings -> Actions, and there you will be able to add actions. You will need to specify a name for your action, which will be used as a tag, and a text description, which will be displayed on the watch, and optionally you can specify an icon and a color for both the text and icon.

screenshot

screenshot

screenshot

You should then see something like the following when opening the Home Assistant app on your Apple Watch.

screenshot

Executing Actions

So now we have actions showing up on our Apple Watch, but they do not do anything, well not much at least. Clicking on these actions will currently trigger an event in Home Assistant but because that event has no listener and action attached to it that is all it does. I prefer to use Node Red to execute custom actions in Home Assistant and that is how I have set up my actions.

I have set up a flow as shown in the screenshots below to execute the following.

  1. Capture all ios events
  2. Branch on the event name
  3. On the clean action trigger the vacuum to start a clean session
  4. On the relax action toggle the lounge scene between a cool dim mode and a warm dim mode
  5. On the bright action set the lights in the lounge to full brightness and reset the color
  6. On the all-off action switch off all the lights

screenshot

To capture all ios events I use the events: all nodes with the event type filtering on ios.actions_fired.

screenshot

To branch on the event name, I use a switch node with an exit for each action name as defined in the Home Assistant app.

screenshot

To trigger the cleaning I use the xiaomi_miio service specific to Roborock and specify the rooms to clean as segments.

screenshot

To set the light scene first I use a switch to determine the current scene by checking a global variable I control, lounge.scene, then toggle the scene by calling the Home Assistant light.turn_on service with a call service node for the desired light/light group. I set the color_name and brightness_pct as desired. After setting each scene I then set the lounge.scene value accordingly between relax.warm and relax.cool.

screenshot

screenshot

To set the full brightness I use the Home Assistant light.turn_on service with a call service node for the desired light/light group. I set the color_name to white brightness_pct to 100.

screenshot

To turn off all the lights I use the Home Assistant light.turn_off service with a call service node for the desired light/light group.

screenshot

I use the Conbee II Zigbee stick and have deCONZ setup. There I have defined light groups, for instance, I have multiple lights in the lounge set under one group so that from automation I only call the group name and not individual light names. Light groups can also be set up in Home Assistant.

While I prefer Node Red, this entire setup is achievable using Home Assistant automations and capturing the events from there and creating actions.