One more thing…

Wow, what a birthday week it has been! We’ve had a new supervisor release, one of the largest and most user-driven core releases, thanks to the month of What The Heck?!. We even got RFID tags right into the heart of Home Assistant, but we’re not done yet! We have “One more thing…”

Introducing Home Assistant Companion for macOS

Home Assistant Companion is a new application for Mac to control your Home Assistant instance, exposing your Mac sensors to Home Assistant and to receive notifications.

Like many recent updates to the iOS app, we have @zacwest to thank for this. Zac has ported the iOS app over to Mac and added some great new features specifically for the Mac.

If you’re a Windows user, don’t worry, you can integrate your PC with the great IOT Link tool.

Home Assistant Companion running on a 16-inch Mac Book Pro

Trigger automations with your Mac

Home Assistant Companion for macOS adds several new binary sensors for your Mac, showing whether it is active and whether a particular microphone or webcam is in use.

Each camera and microphone has its own binary_sensor showing whether it is active or not. These can enable some really useful automations, especially for those home working at the moment. You could automatically turn off the radio when answering a call or close the blinds behind you to improve your video quality. To see just how useful this can be in the real world, check out this video of how our very own Frenck is using these sensors in his streaming set up.

The “active” sensor reports whether the Mac is being actively used. In other words that it is not sleeping, not showing a screensaver, not locked and not just sat idle. You can configure the “Time Until Idle” in one-minute steps from a minimum of 1 minute. You’ll find this option in the Sensors section of Preferences.

One huge advantage of running on a Mac compared to a mobile device is the much larger battery. This means we are not constrained by battery-saving measures and can address one of the most common gripes with the iOS app, update intervals. On a Mac, entity updates are immediately triggered when something changes. You will see this reported by the sensor.DEVICE_NAME_last_update_trigger reporting Signaled.

Home Assistant Widgets (Big Sur only)

Home Assistant Companion for macOS already supports widgets in Big Sur. Right now, we have an Actions Widget where you can have up to eight actions. You can also create multiple widgets with different sets of actions. If you have an idea for other widgets you’d like to see, pop over to the community forums and let us know.

The large Home Assistant Actions widget in Big Sur.

Interface

The Mac app is definitely a Mac app. The App Configuration page has been removed from Home Assistant’s sidebar. Instead, the configuration options and preferences are on the menu bar right where you’d expect to find them for any other app and all the standard shortcuts work too (like ⌘, for Preferences). You can even open multiple Lovelace windows via File > New.

You can have multiple Home Assistant Companion windows open.

In the menu bar, you will also find an option to manually send an update to Home Assistant and a new Actions menu where you can see all your actions and fire them.

Notifications

Just like the iOS app, you can send notifications to your Mac with services like notify.mobile_app_DEVICE_NAME. One small difference is that critical notifications are not yet available for the Mac app. However, all our other notifications features like actionable notifications work on the Mac app. To see what is possible, take a look at the docs.

Documentation and Support

We are updating the Companion App docs with details for the Mac app. You can also pop over to the Discord channel. If you find a bug or have an idea for a feature, please open up an issue on the GitHub repository.

Getting the beta

You can get the beta right now from the home-assistant/ios repository: download the home-assistant-mac.zip file from the latest release, unzip and drag it over to your Applications folder. Done!

That’s it. All that’s left is to wish Home Assistant Happy Birthday one last time and to wait and see what amazing developments the next year brings.

Tom


This is a companion discussion topic for the original entry at https://www.home-assistant.io/blog/2020/09/18/mac-companion/
15 Likes

Oh hell yes. I can use this to automatically disable motion lighting in the office when on the computer, automatically disable TTS broadcasts when on a call, oooh popup notifications when a person is detected outside. Yes this is good.

3 Likes

Any app as IOT Link for linux users?

Oh gosh this is awesome. Now I have sensors for my mic/camera, which means I can toggle certain things if I’m in a call!

2 Likes

Don’t really need an app: Pulling hardware sensor data from Linux servers and posting them to MQTT

:slight_smile:

I’d really love to see an official Home Assistant companion for Windows. I’ve been using IOTLink for a few months but it can be pretty unpredictable and stop working all together at times

2 Likes

The Mac app is seriously awesome, I’ve had a lot of fun playing with these sensors. Here’s some automation ideas for inspiration:

  • Use “Active” sensor to get super reliable room presence in your office
  • Use “Active” sensor to set the proper mood for when you work. Turn on desk light strip, play some music, etc. Then turn off when it goes inactive.
  • Use “Active” sensor as an alarm system of sorts. If you’re not home and someone tries to snoop on your computer by lifting the laptop lid or something, flash the lights red and play a “Hands Off!” TTS :stuck_out_tongue:
  • Use the “Battery Level” sensors in your wakeup routine to notify if you’ve forgotten to charge your laptop before leaving for your commute.
  • Use “BatteryHealth” attribute of battery sensor to notify when your laptops battery health changes from “Good” to something worse.
  • Use the “Camera” binary sensor to turn on a bright light or open the automated shades to increase natural lighting in the room.
  • Use the Camera & Microphone sensors to turn on a red light in your hallway so family members know not to disturb you while on an important meeting or recording a podcast (quick plug for the Home Assistant Podcast).
  • Using the History Stats integration you can track the state of the camera/mic binary sensors to determine how many hours you’ve spent in meetings.

Curious to see what other cool ideas people think up in terms of automations. Please share them here if you do.

Great job Zac and Robbie!

6 Likes

I love the computer snooping one. I trust my cleaning lady and my kids with my life, but…

We’ll we all make mistakes I suppose. So much of my personal life is in here. Especially given once logged in, just about everything is accessible without a password. I use preshared keys for ssh, my browser stays logged into HA, etc. Yeah I’m screwed if someone cracks my MacBook login.

1 Like

Awesome work guys!
I’d also like to make a suggestion, I didn’t know about IOT Link so I made my own app, its similar but I think the UX for creating flows is better with my approach, on top of supporting A LOT of different utterances with the custom skill, I’m planning to add google assistant support soon as well (works now with alexa)


HA thread here:

1 Like

Awesome! Linux/Windows companion next? Would love to be able to trigger things directly with shortcuts and system sensors. When I open a game, I run a certain script/scene something like that for example also (gaming mode)

Before we get too many more questions about a Windows companion app, I wanted to share why one doesn’t yet exist and probably won’t for a while…

1 Like

Scratch that, I should read the article! :joy: https://iotlink.gitlab.io/index.html

Ahh cross-platform would be the best thought though right so something in python or (I know it’s got a rep) electron and ts? Or something in .net even so long as it uses mono

Python feels better in my eyes. One of these framworks might be an option:

Thanks for this Mac app, but…

But I’m on High Sierra (10.13.x) since my iMac is a late 2009… I know it’s quite “old” but it runs very well

Any chance to get it works with previous MacOS versions?

Thanks

1 Like

That’s a great idea! I always forget to move enough when working

1 Like

Ok now I want an “on-air” sign outside

4 Likes

Sadly no chance as the app is built with Apple’s Catalyst which only supports Catalina and newer.

Already working on one :smiley:

1 Like

Very sad… :cry:

If you’re Windows user you can use this great app https://github.com/PiotrMachowski/Home-Assistant-Taskbar-Menu

3 Likes