[RELEASE] Homebridge Hubitat v2.0

I can't see why not. I'll get back to you shortly.

BTW: I went into Homebridge settings to "single cached accessory" and discovered duplicates of 15 devices.

Then I went back to the Homebridge app in HE and deleted all of the devices that had duplicates while watching the Homebridge logs. Once the logs said they were removed, I went back into cached accessories and removed the duplicates that were still there. Then I re-added them from Hubitat. I thought that maybe it was caused by initially adding some devices in the wrong category, but some of the dups were lights.

EDIT: now I'm not seeing the error, but it's not the same instance of Homebridge that had the duplicate devices, so I'll keep watching for it.

I have to say that this was probably the EASIEST and most trouble-free app install and configuration I've done yet. Granted, I've gained experience in installing and configuring stuff via Hubitat and Homebridge over the past year, but this one worked like a charm on the FIRST ATTEMPT. I was able to move over all of my devices from Maker API a few at a time and everything just works!

Bravo! Thanks, @tonesto7 !

1 Like

Just checked it out. Works a treat. Thanks for that.

Found it! It’s any light or group that can be (and is) set below 2000K. The error was staying the same earlier due to a lightstrip under the bed that I had left on at 1600K. I forgot that there are a few lights I don’t change because of working nightshift.

Wanted to post this here for anyone wanting to mess around with the child instances in HB v1.3.xx.

You can use separate HE hubs or multiple Homebridge V2 apps or whatever... This assumes that you already have HE Homebridge V2 running..


Adding another config and starting child instances.

To add child instances to HB, add another Homebridge App (or add app on a different hub) and copy the generated HB config:

When done, in HB Plugins click on the wrench icon and select JSON Config:

then in JSON Config. Click ADD PLATFORM:

Paste the second config there and save - note: you can change the "name" field to make it more distinguishable:

Next "activate" the child instances - go to the "wrench icon" and select "Bridge Settings" - turn on each instance:

Restart HB and see if the selected devices appear in Accessories:

To add to HomeKit go to the plugin / wrench / "Bridge Settings" and if things are configured correctly QR Codes should appear for each instance:

You can add as many instances as you want via the JSON Config menu. Be sure to activate them in the bridge settings as needed. Also this should work for the HE Homebridge Maker plugin as well.

Additional NOTES:

  • When adding multiple platform entries make sure you include "direct_port" and make it different for each instance.
    "direct_port": 8000,
  • After adding each platform make sure you TURN ON each child instance in "Bridge Settings" - if you do not you will get errors.
5 Likes

Child bridges work well with the majority of other plug-ins too.

1 Like

NEW RELEASE V2.3.2

  • [FIX] Tweaks colorTemp conversion logic.
  • [NEW] Added support for HomeKit's new Adaptive Lighting (Only works with Bulbs supporting ColorTemp and Brightness) Adaptive Lighting

NOTICE:
Adaptive lighting requires Homebridge 1.3.0+ for it to activate.
Please note that the Adaptive Lighting feature is new and you may not see the temps transitioning correctly for certain bulbs. You may be required to make some tweaks to the config file option for the offset. (See: adaptive_lighting_offset in the readme)

4 Likes

Just a word of caution... Adaptive Lighting initially has a negative impact on Hubitat lighting groups.

I suppose it could cause some conflicts with existing automations... When you enable for the device It takes over the lights color temp control and slowly changes it throughout the day to feel like natural light.

I don't have any lights that support adaptive lighting, but apparently when you create a Hubitat lighting group and pass it through homebridge it thinks the group is a colored bulb. When I applied this release all of my lights that are part of group turned on and wouldn't turn off. Even if I manually turned them off at the switch they would come back on.

To resolve this I ended up disabling all of the groups and then rebooted Hubitat. After the hub rebooted I had to manually turn off each light at the switch and then I re-enabled each of the groups. I'm not sure which of these steps actually fixed the issue but everything settled down and started working again.

Here's a screenshot of one of my groups that shows the adaptive lighting feature. None of the individual lights in this group support adaptive lighting.

Ok Sorry about that. I guess I didnt think that through so I will need to create a second input in the app the allows you to define which lights will be exempt from being included in Adaptive lighting.

No problem, I appreciate your efforts!

Hi Ken
Thanks for the suggestions. I thought that the name of the devices could have been too long a while ago. So shortened them with no success. Tried this again based on your suggestion after the recent software upgrades. Still no luck.
I have started to look at the App Code. Turned on debug and Dev mode.
The logs show that the offending devices are registered for the events they are capable of, but they never make it across to Homebridge.
Cheers
Dominic

Have you tried removing the cached devices (under Homebridge settings)

1 Like

Looks like I spoke too soon! I'm now seeing a warning in the Homebridge logs:

[2/28/2021, 1:07:02 PM] [homebridge-hubitat-tonesto7] This plugin generated a warning from the characteristic 'Current Ambient Light Level': characteristic was expected valid number and received NaN. See https://git.io/JtMGR for more info.

I'm assuming that the glitch is coming from one of my Hue motion sensors as the other sensors don't report ambient light levels.

I'm still learning all of this, so please let me know if this is safe to ignore. I can also provide any logs if you're interested.

It's safe to ignore but I will try to add code to handle those empty values

2 Likes

I've noticed that once the lights are available for Adaptive Lighting, it doesn't matter what you do (including remove and re-add), or turn off the feature in the Homebridge app, the lights continue to be available for Adaptive Lighting. I also tried adding bulbs to the section without adaptive lighting in HE and the lights didn't register anywhere as being selected. I don't know if I'm doing something wrong, but once I change the CT for a light manually in Apple Home it stops changing automatically, just like the Hue lights do, so not a big deal. I also am not able to exclude CT and Color from group devices, even if I remove them and re-add. Everything else has been perfect and faster then ever on 1.3.1

That's interesting... When Adaptive Lighting is disabled via plugin it should be removing the Adaptive Lighting Service Controller... I need to test this.

I'm a new Hubitat user migrating from Smartthings, where I also used Homebridge. It was a smooth conversion except that I'm also seeing a couple of issues that others are reporting.

I have one light (a Sengled Element bulb) that just won't show up in Homekit. I have a total of 28 items (7 lights) and only 27 items get passed to Homekit. My other Singled bulbs come over fine.

I also see any Hubitat lighting groups show up as adaptive lighting.