Control an Apple Home Kit device (Koogeek)

That's how I configured it atm, since there is no Koogeek device.

No this is wrong.

You need to change it to a Virtual Switch.

Oh, got it.
Now I can toggle the switch via homekit and it updates in the dashboard, but when I toggle it through the dashboard, it doesn't change in homekit.

That change will all be dependant on your homekit automations.

You need both ways setup.

KooGeek Switch Turns On, turn On Virtual Switch
KooGeek Switch Turns Off, turn Off Virtual Switch
Virtual Switch Turns On, Turn On KooGeek Switch
Virtual Switch Turns Off, Turn Off KooGeek Switch

That's not what I meant, but I fixed it by rebooting the HE.

Now, I just need to get my hands on an iPad 3+ to get the automation running. :sweat_smile:

Thanks a lot for your help.

Get yourself an apple tv. :slight_smile:

I have three in my house.

I already have a Firestick 4k since it's way cheaper than a 4th gen Apple TV.

And I can use the iPad as a wall dashboard for the HE ^^

Although not complete, Homeassistant is capable of being a Homekit Hub, no Apple required. When I had a Honeywell thermostat, I was able to get it connected with HA as a Homekit device. I was working on building a websocket app in HE to connect the thermostat but gave up. The MQTT app could allow Homekit devices connected to HA to be brought into HE.
As far as I know, there isn't support for Bluetooth devices but most other Homekit devices should be automatically be discovered in Homeassistant.

2 Likes

I would be so grateful, not for me as I have most of the solution (with the exception of HomeKit temp/humidity sensor values), but for those that are not Apple iOS users and don't want an iPad, Apple TV or HomePod, to have a way to track the state of HomeKit devices and get them back into HE to automate would be tremendous.

I'm almost certain it can be done, but I have no knowledge of how to do it. When I look at the terminal in on my MacBook Pro where Homebridge is running, I can see every single result from HomeKit devices, including temp and humidity levels from sensors. If those states could be brought into HE with an event listener, that would be half the battle.

Setting up MQTT and Home Assistant is an interesting option, but something simpler is what I'm after. Even just being able to get temp and humidity values, and active/inactive states from sensors would be a huge step forward.

My understanding is that Homebridge (vs a homebridge Plug-In) is what is conversing on the Apple side.. that it is telling Apple that it's an Appliance. I think that defines what Apple is telling Homebridge. Appliances get nothing, I suspect :frowning:

@dan.t has created a couple of Homebridge Plug-In's. I don't think he's ready to rewrite all of Homebridge to be another class/category of HomeKit. :slight_smile: but you can ask :smiley:

1 Like

Ah nuts! Yeah I wasn't looking closely enough. It's only the stuff I've shared from HE via the plugin. Probably have posted the same thing before too. :crazy_face:

Of course, there's this Homebridge Config UI X plugin...and if it's possible to control devices and get their state from a webpage with this Homebridge plugin, without an Apple device, then there must be a way to create an app to get HomeKit device state and control it from Hubitat.

I think Hoobs has a similar capability. The execution of such as task is where I'm of absolutely no help. :wink:

Could you elaborate a bit on how you did that?
I tried it with the help of another thread, but couldn't manage to get it connected.

@Raylands I was trying to build a Websocket app to bring my Thermostat in Homeassistant to HE. I am not a programmer and I only got as far as being able to turn it on and off. I decided it wasn't worth the struggle and just replaced the thermostat.
I did look at [BETA] MQTT app beta1 and pre beta2 when it was in pre alpha stage but it didn't support bringing in my thermostat but I did have it bringing in some other device although I can't remember what. You might want to check out that thread since it is well on its way and should be able to help get your devices connected.
I do think that Homeassistant would be a great way to bring lots of unsupported devices and services into HE.

Doesn’t HE support a ton of devices already ?

People often come to HE from other services and it doesn't have support for lots of cloud only or unusual devices, especially ones available in countries other than the US. As mentioned in my earlier post, HA directly supports Homekit devices. I don't think any hub supports as much as HA. Have a look at what devices and services it supports.
I used it for four plus years and I wouldn't want to go back to using HA for automations. but it is trivial to set up and most of the devices and services don't require a lot of configuration to make devices available. MQTT is only one way to connect HE to HA. It has an API, supports websockets, and several others. I have a number of devices I know connect to HA when I used it.

So you use HE for rule automations only? And use HA for device support?

I am no longer using HA other than four high temperature probes. I moved all my devices over to HE a year ago. My point was that HA does have a very extensive list of supported devices and services including as a Homekit server. It could be very helpful, especially for things that HE does not and can not support. Unfortunately, other than MQTT there hasn't been any efforts to combine the two platforms. Having something like Hubconnect could allow offloading all those various community apps for unsupported devices, and HE for all the good things it supports.

Something I've found with doing this is a bounce condition where a transmission delay can result in switches being infinitely toggled on and off every couple of seconds. This happens when a switch is toggled on but doesn't respond quickly enough. It is asked to turn on, reads as off (automation is triggered), then switches on (automation is triggered again). Commence infinite bounce!

I think this can be fixed using WAIT and another IF to double-check the switch status, though I haven't implemented this yet. It also results in a lot of automations for latching switches.

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