Native Homekit integration & HSM?

That's what I was hoping! Great news!

I am not sure how the community integration worked but I don't seem to get the option to share a Presence sensor using the new built-in integration. Presence is not one of the categories and I don't see the Virtual Presence device that I had for my wife in any other category. I could setup a virtual switch to change the virtual presence and then share the virtual presence to Homekit.

@stephen_nutt, I do the same as @dJOS. It’s the only rock solid reliable presence method I’ve ever found. Works great.

I still wonder, though, if Apple’s presence can be integrated with HE directly via this new HomeKit Integration, then I could move the automation logic to RM and have it all in one place.

2 Likes

I seem to remember somebody created a device driver that was a switch AND presence sensor. Using that would probably allow it to be exposed to Homekit in new integration. I think the person used it for Alexa but I can't find it.

EDIT: This one isn't the one I remember; it's a lot more in-depth. I tried it and device still isn't available to use in Homekit integration.

You set your presence in homekit and have a rule in home kit that turns on or off a virtual switch exposed from hubitat. When hubitat sees that virtual switch on/off it HE does it's thing that you set

@ogiewon created a virtual presence with switch driver

I was hoping to skip a step and use a virtual device that was both a switch and a presence sensor so that I didn't have to have both a virtual switch; a virtual presence; and create a Rule, but that doesn't seem to work.

I use the Virtual Presence Plus driver by @Cobra. Works great.

1 Like

Is there such a thing as a vitual lock and switch driver? How would that even work bi-directionally which is different than presence?

This might help

metadata {
definition (name: "Virtual contact with Switch and lock", namespace: "cwilson08", author: "cwwilson08 and modified by rlithgow1") {
capability "Sensor"
capability "Contact Sensor"
capability "Switch"
capability "lock"
}
}

def on() {
sendEvent(name: "contact", value: "closed")
sendEvent(name: "switch", value: "on")
sendEvent(name: "lock", value: "lock")
}

def off() {
sendEvent(name: "contact", value: "open")
sendEvent(name: "switch", value: "off")
sendEvent(name: "lock", value: "unlock")
}

def installed() {
}

I might suggest a small change to your driver to closer match the Lock capability:

lock - ENUM ["locked", "unlocked with timeout", "unlocked", "unknown"]

If you change your sendEvent’s to send “locked” or “unlocked” it will be more inline with what the dashboard, RM, and other apps will be expecting.

2 Likes

Thanks but i was reading that the integration is not bi-directional so when you manually unlock the state in hubitat would not update? Or is there a way around this? Want to make sure it works before i dump a couple of hundred bucks on it. Also how would i add the device to homekit without an iphone or ipad? Just a mini?

HSM does NOT show up. Wondering myself if it ever will. Sticking with Homebridge just for that!

1 Like

The state will update the virtual switch that both hubitat and home kit reads. To trip on HomeKit you have it watch the virtual switch on hubitat for the change. When home kit sees that change it runs its own rule (such as if switch off, lock lock). This status is updated in the virtual switch. It's much the same in reverse. If device attached to HomeKit does X turn on virtual switch on hubitat. Hubitat sees that virtual came on and does a rule on itself.

And that's why you're a programmer and I'm not lol

2 Likes

Thanks for the Info everyone, I already use some of these work arounds with homebridge ie. Door locks so I don't have to confirm. My main reason for wanting HSM in the built in app is for notifications. Not for me but for other family members. HomeKit gives me its own notifications of HSM status or alarm triggers in a really easy to know what's happening way. Alarm gets set off HomeKit sends an actual alert message stuff like that, that I don't have to setup Also when manually setting the alarm with an iPhone and HomeKit it's really straight forward. Just figured if we can get HSM built in with homebridge integration it would be pretty easy to have this with a built in app. It's also pretty cool to get HSM alerts and status on the TV's without having to use workarounds You can also use Siri HomePods all that stuff to set alarm with away mode home mode night mode all that jazz.


1 Like

In Home app, HSM appears under "Security" as Alarm

When tapped, it presents the HSM modes as off, home, away

And when you go to settings you see some basic rules you can turn on

You have a few options for controlling HSM with HomeKit. If all your presence sensors are iPhones, then you can simply let HomeKit manage HSM for you. But if you have additional presence sensors, then you will have to decide on a solution that works best for you. This can manifest as rules that turn switches on/off when certain people leave/arrive, and use a Hubitat rule to manage presence based on the state of those switches, or some other variation that works similarly.

At this time, there is not way for Hubitat to import HomeKit managed devices, and I don't know if that is even possible with HomeKit. If you create a virtual presence sensor, and expose it via Make API, you can even create rules that make API calls to Hubitat directly to sync them with the HomeKit presence devices via HomeKit rules. This is quite a bit more complex, and I don't recommend it unless you really want to dig deep into complex HomeKit automations. But with all the options available due to the flexible nature of HomeKit, I am sure you can find a solution that works well for you.

I’ve bridged HSM to HomeKit via a custom app and homebridge, but it would be really nice if I could scrap those and get HSM via the official HomeKit integration

The HSM Alarm is not automatically added to the Hubuitat HomeKit bridge, in fact, I don't see anyway to toggle it on for HomeKit. I'm running 2.3.4.134 version and there isn't a way to enable this. If there is a way, please let me know. I, like the others, have kept Homebridge up and running for HSM integration.
I do like the native implementation without keeping my server running 24/7....even though I have it on all the time, but one more failure item I want to remove.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.