Thanks for releasing this tonesto7, it's a tremendous bit of kit. I have the majority of my Hubitat devices available under Homekit and working well. Everything except fans.
I'm using the Haiku Fan driver to control my fan. This works great using Hubitat. The fan comes with a light and the driver controls both by supporting capabilities "FanControl", "SwitchLevel" and "Switch". Switch and SwitchLevel are for the light while FanControl is for the fan.
I've added the driver twice to Hubitat and associated one with Lights and one with Fans (3 Speeds) in Homebridge Hubitat. They both appear in Apple Home and have the correct button assigned. The behaviour I'm seeing with Homebridge is that regardless of which button is used, only the light can be controlled.
In the logs I see this when the fan is turned on:
dev:272021-01-17 12:06:26.715 debug parse response: (Balcony Fan;LIGHT;LEVEL;ACTUAL;16)
app:592021-01-17 12:06:26.698 info Homebridge (v2.2.2) | | Balcony Fan Homebridge | Command [setLevel()] | Process Time: (30ms)
app:592021-01-17 12:06:26.688 info Homebridge (v2.2.2) | Command Successful for Device Balcony Fan Homebridge | Command [setLevel(100)]
dev:27 2021-01-17 12:06:26.668 debug parse response: (Balcony Fan;LIGHT;PWR;ON)
app:59 2021-01-17 12:06:26.658 info Homebridge (v2.2.2) | Plugin called Process Command | DeviceId: 27 | Command: (setLevel) | Param1: (100)
app:59 2021-01-17 12:06:26.290 info Homebridge (v2.2.2) | | Balcony Fan Homebridge | Command [on()] | Process Time: (213ms)
app:59 2021-01-17 12:06:26.271 info Homebridge (v2.2.2) | Command Successful for Device Balcony Fan Homebridge | Command [on()]
app:59 2021-01-17 12:06:26.194 info Homebridge (v2.2.2) | Plugin called Process Command | DeviceId: 27 | Command: (on)
setLevel() and on() are both commands that only apply to lights. For fans both of these should be translated to setSpeed().
I'm also not sure why Fans (3-Speeds) and Fans (4-Speeds) are required? In Hubitat all drivers that support FanControl capability can handle 5 speeds: low, medium-low, medium, medium-high and high. I believe Homebridge Hubitat should be translating the percentage level into one of these five speeds and letting the driver handle the rest. The device categories Fans and Fans (Multi-speed) should be all that's required.
The Haiku fan driver is the only multi-speed fan I have, so I'm not sure if the existing code works to support other fan drivers? If not, I can make these changes if you'd like and submit a pull request?