[RELEASE] Home Assistant Device Bridge (HADB)

Do you intend to filter down from the devices in HA and only allow a subset to pass through and be handled in HE? If so, you don't need the app at all. You can just create the parent device manually yourself.

It looks like some comms error between the HADB app and HA for some reason. I find it odd that this ever worked and now is failing. Did you change anything else in the meantime on HE, HA, or your network setup (IP addresses and that sort of thing)?

In the app there is an advanced configuration options page. Go there and de-select the option that is labeled Only pass through user-selected and manually-added entities?. Do the child devices start to be created and updated again?

1 Like

Hmm, thats interesting.
@tomw
Previously, I tried adding some entities manually via the selector, then changing their state in HA. Didnt work. I do not want all devices to come into hubitat, only a select few. When i disabled the setting to only pass through user-selected devices, some frequently-updated temp sensors immediately showed up, along with some switches that I turned on or off. Then, I turned the only pass through switch back on, added the devices I wanted to use manually to the entity list (the drop down still didn't work), and after turning on/off the devices, it showed up!

Well, I'm glad it is working, though it is still curious why the query that populates the drop down isn't working. I'll keep an eye on it to see if anyone else runs in to the same issue. Thanks for the update and detailed testing notes.

1 Like

Hello,
Sorry for the late reply.. got busy with other things.. anyways.. Luckily, since this was just starting point for me.. I wasn't using the devices in any of the apps/RMs etc.. so rather than having anyone waste any time for troubleshooting...for now I uninstalled the HADB app.. and re-installed..
Will test it again for a few days.. and if the high loading starts happening again.. will post the debug logs.
Thanks

Hello,
just for kicks, I turned the debug logging to ON, But now it is NOT turning OFF !
another thing that I observed is that during the debug logging.. even the devices that I had not selected, I was getting a literally a ton of messages like this one
**
[dev:2959] (http://192.168.xxx.xxx/logs#) 2022-10-22 09:01:55.278 PMdebugparse(): description = {"id":1,"type":"event","event":{"event_type":"state_changed"," "

**
looking at it closely.. I realized that.. I have added emporia energy integration in HA... where emporia energy sends all these electricity measurements to HA..
and all those are showing up in hubitat hub.. for parsing...
is that expected behaviour.. if yes, then it might be that HADB will bog down my hubitat trying to keep up with the parsing of literally thousands of data per second...

I dont know ... is it possible to "subscribe" to only the events related to the selected devices ?
or maybe filter those out on HA side ? I am just throwing it out there ..

Since my HA-hub has lots of devices, but I only need maybe 40 of those devices to send info to hubitat.. all the rest I dont care in hubitat...

Thanks for your help

The way HADB works is that it subscribes to HA event stream. Meaning ALL events occurring in HA are sent to HE regardless of what is being selected in the app. The app just flag witch ones are ignored and witch are going to be processed.

I'm not familiar with Emporia but does it really has to send thousands of data per second?

4 Likes

HADB is intended for those who wants to use HE as their main system and supplement it with a few services imported from HA. Keeping in mind the Emporia load, if you are still set on importing these 40 devices into HE, I would look into putting them on a secondary instance of HA (witch can be linked to your primary one) and would only report event from said devices.

2 Likes

Hello,
I was looking at the HA event stream docs..
Here

And there are two functions

async_track_state_change Track specific state changes
async_track_state_change_event Track specific state change events indexed by entity_id

Would it be possible for you to take a look at those docs and functions?..

The second one seems extremely promising..
In that, once a limited set of list of specific Entities that have been selected in HE ..are the ones whose state change is tracked .. then it would work perfectly.. and it would also reduce the parsing/processing that needs to be done on HE considerably.. ( especially if the selected entities percentage is small compared to total entities).

i have not taken a look at your code in terms of which functions are used... If i get time.. i will also take a look ..But, it would take me a while to understand it.. i would highly appreciate it..if you could.. thank you!!

This is related to integration to be developed on HA side. HADB does not rely on any integration installed on that platform. It would require the developement of new programs on two distinct platforms.

1 Like

I agree with @ymerj. HADB already subscribes to the minimal set of events to get updates from HA.

What you really need is a way for the HA integration for your device to send less events. That is a request/question for that integration developer, not something that HADB can help with unfortunately.

2 Likes

Ah.. I see..
Thanks for such a quick response..

obviously you guys are way more knowledgeable than me in this topic....
but it feels that subscribing to the event bus for all state changes, sends more events than needed.

so I am just throwing this out there...something I found

Under Entities Heading

"You can subscribe to the entities of Home Assistant. Your callback will be called when the entities are first loaded and on every change to the state of any of the entities after that. The callback will be called with a single object that contains the entities keyed by entity_id."

Thanks again for all your help.

HADB aims at being a user friendly integration so, therefore avoid the usage of man-in-the-middle that require extensive configuration and possibly an external device to run on to.

HADB try to be a solution for as many as possible but cannot answer all particular situations. I think you should look at other solutions or workarounds. We gave you alternative path to follow. Maybe going the MQTT route would be more appropriate in your case.

1 Like

yes, I understand..
thanks for our explanations. I agree, this app might not be a proper use case for me
thanks again

I was not sure where to open an issue for new devices support, so I opened it here:

Let me know if that's no the right place.

I’m having a weird issue where all of my devices in HA are being imported in to the device list in hubitat. This is causing duplicate hubitat devices. I share my hubitat devices with Home Assistant via Maker API. Those devices are automatically showing up as child devices under the home assistant device bridge even though I haven’t selected them for import. It’s almost like the device import selection isn’t working and it’s importing them all. Any ideas?

I also can’t find the Advanced Options

Please PM me a screenshot of the App data page for the HADB parent app.

Just checking, did you manually create the HADB child driver, or was it created automatically by the app when you configured it? The filtering will only work if the child device was created using the app.

Screenshot sent. Ive been using this for quite some time and have never had any issue at all like this. So its kind of odd.

The child device was automagically created via the app. I didnt manually create it.

1 Like

Any luck here? I'd love to be able to wire up my Simplisafe alarm through HA to HE.

I have the HA Simplisafe integration connected to HE using the HE Home Assistant Device Bridge. I ended up writing some connector rules in HA so HE saw switches for arm/disarm. but other than that it has been working for me

Overall:

  • Arm/disarm alarm in HE has been working for me OK. I have these connected to a HE dashboard tile.
  • Getting simplisafe device status works, although this is polled in HA so there may be a delay in seeing state change.
  • Devices are only detected in the HA integration when Simplisafe sends an event for them. This can be a bit disconcerting when trying to setup devices as they may not appear for some time.

In short, although this works, the solution has enough complexity and gotchas that I wouldn't depend on it in a critical situation. I still keep the Simplisafe app on my phone so I can arm/disarm reliably.

1 Like

I am getting the following errors in the logs:

Parsing error: com.hubitat.app.exception.UnknownDeviceTypeException: Device type 'Generic Component Illuminance Sensor' in namespace 'community' not found

dev:462022-11-03 07:29:07.823errorParsing error: com.hubitat.app.exception.UnknownDeviceTypeException: Device type 'Generic Component Pressure Sensor' in namespace 'community' not found

It seems like the installation is missingsome drivers ?