[RELEASE] Homebridge Hubitat v2.0

[RELEASE] Homebridge Hubitat v2.0

I'm happy to release the new version of my homebridge-hubitat-tonesto7

Upgrade Notice:

Due to the changes in the plugin API (switching from legacy to dynamic) you can not directly update the plugin, you will need to add as a new accessory and setup your devices/automations/scenes again.
On a positive note, you can use the same Hubitat app instance as long as you update it to the latest code.

Changes

Plugin

  • [NEW] Completely rewrote the entire plugin from the ground up using modern javascript structure.

  • [NEW] The code is much cleaner, easier to maintain, and easier for others to follow.

  • [NEW] The plugin is also faster, leaner, and more stable than the previous versions.

  • [NEW] The plugin uses the Homebridge Dynamic platform API, meaning it no longer requires a restart of the Homebridge service for device changes to occur.

  • [NEW] The plugin utilizes the new device cache on service restart to prevent losing all of your devices when the plugin fails to start for an extended period of time.

  • [NEW] Plugin can now remove devices from HomeKit without requiring a restart when they are no longer selected under Hubitat App.

  • [NEW] Logging system was rewritten to provide more insight into issues and status, as well as write them to a file.

  • [NEW] Switched web request library from Request-Promise to Axios.

  • [NEW] StatusActive characteristic now reports correctly.

  • [NEW] Added support for bringing acceleration sensors into HomeKit as motion sensors.

  • [NEW] Lot's of fixes for device state updates and device commands.

  • [NEW] Added support for AirPurifier & AirQuality (@danielskowronski)

  • [NEW] Thermostat Mode fixes (@torandreroland)

  • [NEW] Many, many other bug fixes for devices, commands, and many other items.

App

  • [NEW] The app now detects duplicate devices and cleans up the data so Homekit doesn't try to create duplicate devices and throw an error.

  • [NEW] Added support for bringing acceleration sensors into HomeKit as motion sensors.

  • [NEW] Define devices as a garage door, thermostat, or heat-only thermostat under defined device types options.

  • [NEW] Device/Location Events and Commands history page to review events and commands sent and received by the plugin.

  • [NEW] Device data viewer where you can select a device and see all available attributes, capabilities, commands that will be sent to HomeKit as well as the last 30 device events.

  • [NEW] Expanded capability filters to include more capabilities.

  • [UPDATE] Restructured and cleaned up the app UI so it's more organized and easier to manage.

  • [UPDATE] Optimized the command/event streaming system to perform faster and more reliably.

  • [NEW] Added timeouts to all Groovy app HTTP commands (this was the cause of the progressive hub slowdowns in the previous version).

  • [UPDATE] Added option to validate the appId and token on all commands/requests made to the Hubitat app so if you have more than one instance of the Homebridge app it doesn't start sending events to the wrong plugin.

  • [UPDATE] Modified the event subscription logic to ignore many of the non-standard attributes to increase performance and reduce timeouts on subscription.

  • [FIX] Minor fixes to provide better Window Shade support in the plugin.

  • [FIX] Dozens of other bug fixes, tweaks, optimizations, and cleanups from v1.

  • [REMOVED] Energy and Power capabilities have been removed (they are not natively supported by HomeKit).

Instructions

Issues:

Note:

I've been using this with 145 devices and haven't seen any hub platform issues once on my C7 hub.
Since Hubitat is my primary hub now I can devote more time to fixing issues with this version

Known Issues

  • Buttons: I haven't fully added support for buttons on Hubitat yet (They work differently on HE than ST so it will take some effort).
  • Fans: I've noticed an issue with the GE Smart Fan Control driver and it's reporting of the level (75% is as high as the level will go) There is a community driver available that will correct the issue.

Slow Command: I've noticed that if I don't send any commands for awhile from home kit that the first time I do there is a 1-2 second delay. Then after that, it's fast again. I'm not sure if it's home kit, homebridge plugin, or the hubitat app. I will continue to watch for clues.

Please report any issues here: Issues · tonesto7/homebridge-hubitat-tonesto7 · GitHub

46 Likes

[Placeholder]

[another placeholder]

can this be used with the Eufy Doorbell?

I'm not sure what you mean? I'm not to familiar with Eufy...
This allows for basic devices, sensors to interface. It does not support video devices (That's a whole other level of work)

What do you intend on doing regarding button devices?
Button devices (e.g. Lutron Pico) aren't really supported in Homekit (I think).
Perhaps they are supported with Eve or some other app available on the IPad?

P.S. I'm going to try using this - thanks very much for putting this together.

This is awesome! Congrats on the huge release.
For someone who already has Hubitat + Homebridge enabled, do you have guidance on the best way to "test this out" before migrating over (e.g. could you technically connect twice without making a mess of Homekit)?

Want to make sure all my devices work before abandoning the current setup I have.

Are you using my old plugin and app? or the maker API version?

Cool. As an FYI, I also recently ported my homebridge - HomeSeer plugin to the Hubitat platform. From what I can tell from a brief look at your code, mine takes a different approach on coding in which I first sets up a Hubitat System Object class to control interactions with Hubitat, and then use an event-emitter model to generate Javascript emitter events interfacing with HomeKit services and characteristics. I mention it as it may benefit both of us to learn from each other's implementations. If you're interested, see: homebridge-hubitat - npm

2 Likes

When I have some time I will definitely take a look...
I do know that it took me awhile to find the right code structure to use, once I did I haven't regretted it yet.
This code runs really solid as it's been in use on ST for over a year (I can't believe a year has passed already)

1 Like

The Maker API version.

you can run both side by side

1 Like

Is there a limit to the number of devices you can have in a single instance? I currently have about 250 devices running across 3 different instances of Maker API.

There is a homebridge limit of 150 accessories per bridge

Thanks, I'll pair this down to two instances and see how it goes.

1 Like

not looking for video, but just if motion is detected or if the doorbell rings, instead of going through something like Alexa -> HE, just have it trigger right in HE

Just to note - the capability filters aren't working for me. I have about a half-dozen devices that use Markus' Xiaomi/Aqara/Opple drivers, which use the presence attribute to track if they've dropped off. Homekit treats them as occupancy sensors because of this, so I'm trying to filter out the capability. I have them checked off, but it has no effect.

I've also got an Iris V2 motion sensor with a bad temp sensor that I'm trying to filter out. No luck there, either.

2 Likes

I will try to duplicate this in the morning... I haven’t used the filters on my new install so maybe I broke something.

Can you share a screen shot of the selected devices page and the filters page?

Here you go:

1 Like

Thank you @tonesto7 for this great app.

Some quick feedback:
Hubitat Safetly Monitor is not working correctly. It controls the modes but doesn’t update with the correct status in HomeKit.

Capability excludes aren’t working for me either.

I’m also seeing this although I don’t have any duplicates:

Keep up the amazing work!

1 Like