[RELEASE] Home Assistant Device Bridge (HADB)

So guys...

I went nuclear -- deleted everything and started from scratch. I rebuilt two HADB instances, one with 7 HA entities and the other with 5. So not a lot, right?

Despite this, pretty much immediately my log was getting spammed with LimitedExceededException errors. As if the devices I've selected are sending a jillion events. The devices are (mostly) Ecowitt devices integrated into HA -- temp, humidity, lux, soil moisture. I wonder if it's possible that the Ecowitt integration changed in a way that created much more frequent events.

Any other theories about what could be going on from folks?
And can I throttle the volume coming across HADB somehow?

EDIT: And, to make things more mysterious, a lot of additional HA entities that I did NOT select in HADB are showing up in HE as child devices yet again. Something very weird is going on. Would love to try to troubleshoot if anyone has ideas.

So, what I do is two helpers (switches) in home assistant. I use one to turn on and one to turn off. I create them in home assistant vs HE and use HADB to talk to bring the switches into HE.

In Home Assistant, I have the routine that does two things when the switch in question turns on: first, turn the switch itself off, second, perform the action (on/off) that I want. This gets around the sync issue, albeit a bit messier. I am asssuming (and that could be an issue as I HATE assuming anything) that HomeKit allows simliar virtual switches and routines?

I prefer using the hub that has the actual entity doing the routine. My theory is that the switch won't visually turn off unless it actually communicated with the host hub. That way, you know it at least sent the message to trigger if you see it go off if done manually. But, you could probably also have HE routine do the auto off if that is your preference.

HA_Virt_SwitchTV_On -> HA Routine turns off HA_Virt_SwitchTV_On, HA Routine Turns On TV

HA_Virt_SwitchTV_Off -> HA Routine turns off HA_Virt_SwitchTV_Off, HA Routine Turns Off TV

3 Likes

The suggestion from @tray_e is sound and will work if you cannot get the entities in, and I often just go this route for simple ON/OFF, because I get what I need and I get it fast. You can also use the HE>HA integration and share Hubitat virtual switches with HA as I suggested above for @mluck

2 Likes

It is not possible to throttle the event stream. Usually in a case like that a device on HA is missbehaving.

As for the unselected devices showing up, is this option turn off in the advance section of the app?

1 Like

Adding to this, make sure to click all the way though to Done in the app. If you just close it or click a link to elsewhere on the last config page, some of the settings might not be properly saved.

If those suggestions don't help, please post a screenshot of the config page for the app (click the gear icon).

I simplified the setup to a single instance of HADB with only ~6 entities that rarely change (it took a few hours for the entities to start showing up in HE). Despite the now trivial setup, I'm still seeing issues. I suspect something on the HA side.

No, it is toggled to ON.

Check.

See below. A couple other tidbits. According to my Hub Info, I'm running a CPU Load on the hub of 50.25 with over 95% of hub busy time being attributed to both the HADB device and the HADB app. I also noticed that strangely 6 of the 7 child devices under HADB have no states shown on the device details view even though the corresponding entities in HA have states and events. Odd. The log continues to spew to the error "com.hubitat.app.exception.LimitExceededException: Device 2269 generates excessive hub load on line 51 (method parse)". Device 2269 is the HADB device.

I'm not sure the above picture is the most effective way to share the screenshot -- LMK if I can do it better/differently. Also I didn't bother to include the full entity list as there are hundreds of entities in HA.

Thanks for looking at this.

I'm going to PM you to gather some more info.

Yeah essentially virtual switches... I have that going through homekit. Was just hoping I could bring it directly in :frowning:

Yeah, have a rule that shuts down the house and it's ok but direct control even through HA would be preferable to the vswitches.

1 Like

I just looked at the logs on the hub I have HADB on and it’s using 40.9% of busy. For me this only works out to around 0.3% of the hubs cpu time, but I only have a few lan and cloud integrations on this particular hub, and have kept my HA setup small. I think that the high number of events is everything that is being filtered from HA. This isn’t causing any alerts for me and I wouldn’t have known if I hadn’t looked in the logs.

1 Like

Thanks, this is the case for most people who see that alert, whether it is from HADB or otherwise.

I advise people to not worry about the "% of busy" statistic unless it is causing a noticeable impact. But a high "% of total" typically warrants a further look.

(Though there are caveats to that, for example drivers that do a lot in Initialize will typically show up as a high % of total after a hub restart and then reduce over time).

2 Likes

Agreed. But did "% of total" go away on the app and device views of the log? I don't see it any more in the checkboxes at the top.

1 Like

Yes. I believe it was deemed not helpful and possibly misleading or inaccurate. Best to look at the device or app percentages in light of the hub’s total processing time (which is listed) which is where I drew my conclusion that while HADB is using 40% of the busy time, my hub is only busy 0.8% of the time.
EDIT: I should have said the hub spends 0.8% of its time processing apps and 1.0% of its time processing devices, leaving it idle 98.2% of the time; possibly more since some of that busy time might be spent waiting for a response.

1 Like

Interesting cuz I find % of Busy to be equally misleading — if not more so

2 Likes

But it’s accurate as far as I know. I think the dev thought the other percentage was more misleading.
Found the quote:
Those absolute values are not results of true profiling. They shouldn't be taken as gospel.

That’s why.

1 Like

Hey guys I’m stuck and I think I missed some steps, I installed the driver and the app…y select my Roborock vacuum to use it in hubitat and it shows capabilities to share but nothing appear in devices, only home assistant parent
Thanks in advance.

From the documentation

5 Likes

Thanks for you answer, but I already use this device in home assistant. Like I said in my previous post I think I missed something



You have to start the vacuum (and have activity logged in Home Assistant) before it will show up in Hubitat.

Hubitat must have drivers that map to the HA capabilities (see first post above for the possibilities). The drivers are installed as part of the Package Manager install process. If you need more of the drivers go back to Hubitat Package Manager and Modify the 'HE-HA control' package to choose the drivers you need.

6 Likes

The entities on that vacuum integration look a little bit non-standard, so you should make sure that you have the "Generic Component Unknown Sensor" driver. It's installed by default by HPM, but if you installed manually then you should add it and then manipulate the device in HA to cause some events, as @bill.d described.

3 Likes

So since i updated to 2.3.7.xxx i cant control any of the input booleans i have set up in HA and bring into HE as switchs i get this error. Any ideas?

com.hubitat.app.exception.LimitExceededException: Device 3931 generates excessive hub load on line 51 (method parse)

dev:50182023-12-29 18:58:02.953infoHot Water 45DegC was turned off [digital]