[RELEASE] Matter Advanced Bridge (limited device support)

Excellent work @kkossev! I was able to easily pair my Aqara E1 and get my Aqara U100 lock into habitat using your code.

What would be needed to be able to lock/unlock the U100? Does something need to be done by Hubitat? Aqara?

1 Like

Currently, there are no Matter locks known to work in Hubitat. In this custom driver I was able to successfully receive the locked/unlocked status, but the lock/unlock commands sent to the bridge return unknown error.

When HE releases ann inbuilt driver for native Matter locks, I should be able to make it work also for bridged locks in this driver.

2 Likes

@kkossev - Very nice work! I purchased an Aqara M3 Hub during the recent Amazon Prime Day sale, as it was on sale for $42 off its normal price. I have tended to avoid Aqara devices, due their history of having issues with standard Zigbee HA networks. I due have an Aqara Vibration sensor and a Temp/Humid sensor that I tested with Home Assistant a while back. So, I figured why not pick up the M3 hub and see just how well the Aqara platform works, especially as a Matter Bridge.

I was able to quickly pair both Aqara Zigbee sensors to the M3 Hub, and then connected the M3 hub to Apple Home via Matter (not the HomeKit integration.) That went smoothly, so I then shared the M3 Hub from Apple Home to Home Assistant via Matter. Again, that went very smoothly.

This afternoon, I loaded up your Matter Advanced Bridge integration on my C8-Pro HE hub. I was then able to share the M3 hub via Apple Home as a Matter device. Hubitat promptly discovered the device, however it assigned it a Driver Type of "Device". I manually changed the driver type to your Matter Advanced Bridge driver, and then clicked "Discover All". The Aqara Temp/Humid device showed up as three Hubitat devices - Temperature, Humidity, and Battery. The Aqara Vibration sensor showed up as a Motion sensor. I did not see a "Battery" device created for the Aqara Vibration sensor. Not sure if that is to be expected or not? I do see a battery level in Apple Home and in Home Assistant for the Vibration sensor.

I just wanted to say Thank You! Your work on this integration is very much appreciated, and is working well thus far!

4 Likes

I'm curious if anyone has updated the Zemismart M1 firmware without issue for the Matter Advanced Bridge connectivity to Hubitat. Any success stories? Or does the firmware update break the expectations of the bridge? Thanks.

1 Like

I have pushed version 1.1.0 for update via HPM.

The main change is a new custom component driver for Matter Locks - thanks @dds82 for the merge request and the contribution! The bridged locks still can not be controlled (can not be locked/unlocked) in HE, but there is some more detailed information on their state.

This version also handles some exceptions better (thanks @iEnam for the tests!), so please update first to v.1.1.0 of this package and then update the Zemismart M1 firmware.

1 Like

@jbasen

Can you run some tests with this package?
I don't expect the Aqara U200 lock/unlock commands to work, but it may help find the problem.

If your lock is successfully discovered, please click on the created child device 'Refresh All' button and post a screenshot of the Current States. I expect U200 to have more supportedOperatingModes than my Nuki Lock 4.0.... The most important is the 'actuatorEnabled' attribute :
image

Thanks. Sorry for the slow reply. I've been on the road all day and will be traveling tomorrow as well.

The Aqara U200 has direct Matter support built into the lock itself. Unlike other devices from Aqara, it isn't a child device to the hub that uses the hub to provide Matter support.

So, please correct me if I'm wrong. But, I don't think the Matter Advanced Bridge is used for integrating this lock with a Hubitat. The Hubitat firmware simply needs to have a Generic Matter Lock as a device type.

Thanks
;

Undoubtedly, a HE inbuilt Matter driver for locks will be the best solution, when available.

Using this Matter Bridge package for ‘native’ matter devices is of course a workaround. It works because both the ‘true Matter’ and the bridged Zigbee devices are exposing the clusters in one and the same way. Matter is a much better defined standard than Zigbee in my opinion.

1 Like

Thanks.
Are there instructions for installing the Matter Bridge? I'll give it a try with the lock.
Thanks again

1 Like

These instructions could be improved, but they are a start :

Implementing a second workaround (a virtual switch exposed via HE inbuilt HomeKit integration) now allows fully local lock/unlock control from Hubitat via Apple Home . The trick is to expose the lock device to Apple Home as a switch (not as a lock!) :

image


Two simple Automations must be added in Apple Home :
image

Summary:

  • Locking and unlocking is performed using HE switch capability, exposed via HE inbuilt HomeKit integration. Hubitat 'lock' command turns the switch attribute on, 'unlock command' turns the switch off. Then the Home Kit automation controls the lock.
  • Updating the lock status and the battery percentage is performed instantly, via the Matter interface.

The lock can be controlled from the EZ dashboard as well :
image

I will publish the new version later tonight.

Well, actually, the same local control can be achieved using a Virtual Lock in Hubitat and two more automations in Apple Home to sync back the lock status... The only benefit of the Matter Bridge workaround is the battery level reporting.

Thanks. I'll give it a try.

I have pushed version 1.1.1 for an update via HPM.

Make sure the 'Enable Switch Capability' preference is turned on.

image


Help needed - Ask Tuya on Tuya forum to make their mmWave devices less spammy!

Hi @kkossev

Thanks for your help. I have installed the Advanced Matter Bridge. I then went to devices->Aqara U200 Smart Lock, which I had linked from apple home, and changed the device type to Matter Advanced Bridge. Next I pressed _Discover All. When I did that the status reported the following error:

ERROR during the Matter Bridge and Devices discovery : ERROR during the Matter Bridge and Devices discovery (state BRIDGE_GLOBAL_ELEMENTS_WAIT)

After a short period of time, the status changed to clear.
Thoughts?
Thanks again for all your help

1 Like

I missed seeing this. How can I get back to the preferences for the Matter Advanced Bridge. I have looked all over and can't find it.
Thanks again

It happens with me sometimes, mainly with Thread devices. I think that's a Hubitat problem, not the driver... for some reason, Hubitat can't find or connect with the devices sometimes.

To fix that, I reboot HA

1 Like

I have occasionally seen such errors during the discovery phase also, that are due to communication timeouts between the HE hub and the Matter device, As Vitor mentioned, try rebooting the HE hub when this is possible.

If you go to Settings -> Matter Details do you see a red cross against the Aqara U200 lock?

Settings -> Matter Details

You need to successfully complete the Matter device discovery process first.
Then, refresh the web page - at the bottom you should see created a new child device. The lock specific preferences will be seen when you open the web page for this child device.

Progress!
I've now successfully completed the Matter device discovery. I have the following:

Aqara U200 Smart Lock - Type Matter Advanced Bridge

Bridge#652 Device#01 - Matter Generic Component Door Lock
Bridge#652 Device#02 - Matter Generic Component Battery

Unfortunately, when I press the lock or unlock buttons on the Matter Generic Component Door Lock card, nothing happens. However, if I manually unlock or lock the U200, the current state shown on the card updates properly to show the state of the U200!

Also, in the Setting -> Matter Details I have a check mark with the Aqara U200 Lock.

What can I do to provide more information?

Thanks

1 Like

I went back through prior posts to see if I missed anything.
I have now gone to the child lock device and pressed refresh all. Below are what is displayed for current states:

Current States

  • lock : locked
  • switch : on
  • lockType : deadLatch
  • actuatorEnabled : disabled
  • supportedOperatingModes : Normal, NoRemoteLockUnlock

Let me know what else I can do to help

Thanks

1 Like