Can't add new Leviton Matter devices, existing devices work

I have the following working Matter devices that I added to Home Assistant using the Android app approximately August 20th, 2023:

  • Leviton D26HD 2nd Gen Dimmer with Matter Firmware: 2.1.0 and Hardware: 1.0
  • tp-link Tapo P125M(US) Ver: 1.6 (Firmware: 1.0.0 Build 220930 Rel.143947, Hardware: 1.0 shown in HA Device info)

My home network is running OpenWRT on a couple of Linksys routers (one as an AP) using the latest release of firmware (23.05). This was likely at version 23.05.0-rc2 when I added the two above devices and is now at the 23.05.2 release with no changes in the behavior of the two above devices during the OpenWRT firmware and Home Assistant updates.

I do not know what version of the Matter Server Add-on was running at the time these first two devices were added, but I have been installing updates as they appear in Home Assistant. I have not seen any problems with the two existing devices through Home Assistant and OpenWRT updates over the last three months.

I now have several new Leviton D26HD dimmers and D215S switches, and am (with one exception - more on that later) not able to add any of them to Home Assistant.

With both Ethernet and Wi-Fi enabled on Home Assistant running on a Raspberry Pi 4 with 4GB memory, I get the following failures in the log:

-----------------------------------------------------------
 Add-on: Matter Server
 Matter WebSocket Server for Home Assistant Matter support.
-----------------------------------------------------------
 Add-on version: 4.10.2
 You are running the latest version of this add-on.
 System: Home Assistant OS 11.1  (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2023.11.2
 Home Assistant Supervisor: 2023.11.3
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
s6-rc: info: service banner successfully started
s6-rc: info: service matter-server: starting
s6-rc: info: service matter-server successfully started
s6-rc: info: service legacy-services: starting
[11:36:08] INFO: Starting Matter Server...
s6-rc: info: service legacy-services successfully started
[11:36:09] INFO: Successfully send discovery information to Home Assistant.
[1700595373.495589][126:126] CHIP:CTL: Setting attestation nonce to random value
[1700595373.495835][126:126] CHIP:CTL: Setting CSR nonce to random value
[1700595373.497779][126:126] CHIP:DL: ChipLinuxStorage::Init: Using KVS config file: /tmp/chip_kvs
[1700595373.498265][126:126] CHIP:DL: writing settings to file (/tmp/chip_kvs-moGzzJ)
[1700595373.498467][126:126] CHIP:DL: renamed tmp file to file (/tmp/chip_kvs)
[1700595373.498695][126:126] CHIP:DL: ChipLinuxStorage::Init: Using KVS config file: /data/chip_factory.ini
[1700595373.499013][126:126] CHIP:DL: ChipLinuxStorage::Init: Using KVS config file: /data/chip_config.ini
[1700595373.499215][126:126] CHIP:DL: ChipLinuxStorage::Init: Using KVS config file: /data/chip_counters.ini
[1700595373.499635][126:126] CHIP:DL: writing settings to file (/data/chip_counters.ini-UZiQoH)
[1700595373.500157][126:126] CHIP:DL: renamed tmp file to file (/data/chip_counters.ini)
[1700595373.500208][126:126] CHIP:DL: NVS set: chip-counters/reboot-count = 19 (0x13)
[1700595373.501017][126:126] CHIP:DL: Got Ethernet interface: end0
[1700595373.501525][126:126] CHIP:DL: Found the primary Ethernet interface:end0
[1700595373.502034][126:126] CHIP:DL: Got WiFi interface: wlan0
[1700595373.504325][126:126] CHIP:DL: Found the primary WiFi interface:wlan0
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vetha5e3f38 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vetha1a5f65 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on veth3a884b5 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on veth0e245dd for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vethb77ca94 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vethcc09953 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vethce01624 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 11:36:13 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on veth94328c3 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
/usr/local/lib/python3.11/site-packages/matter_server/server/helpers/paa_certificates.py:46: CryptographyDeprecationWarning: The parsed certificate contains a NULL parameter value in its signature algorithm parameters. This is invalid and will be rejected in a future version of cryptography. If this certificate was created via Java, please upgrade to JDK16+ or the latest JDK11 once a fix is issued. If this certificate was created in some other fashion please report the issue to the cryptography issue tracker. See https://github.com/pyca/cryptography/issues/8996 for more details.
  pem_certificate = x509.load_pem_x509_certificate(certificate.encode())

With Wi-Fi disabled on Home Assistant (only using Ethernet) the logs were almost identical with a few differences following the line containing Got Ethernet interface: end0.

[1700600158.009961][126:126] CHIP:DL: Found the primary Ethernet interface:end0
[1700600158.010534][126:126] CHIP:DL: Got WiFi interface: wlan0
[1700600158.010642][126:126] CHIP:DL: Failed to reset WiFi statistic counts
2023-11-21 12:55:58 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on wlan0 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
2023-11-21 12:55:58 core-matter-server chip.DL[126] ERROR MDNS failed to join multicast group on vetha5e3f38 for address type IPv4: src/inet/UDPEndPointImplSockets.cpp:777: Inet Error 0x00000110: Address not found
...

Numbers on veth group changed, and the log ended with the same ppa_certificates.py error.

The one exception to all these failures was one of the new D26HD dimmers.

While trying to get these devices added, was trying everything I could think of, including disabling the SSID on the 5GHz radios on both Linksys devices (one router and one router configured as access point). I also tried factory resetting the Leviton devices occasionally (and reconnecting to Wi-Fi using the Leviton app before trying to add with the HA app), rebooting the Home Assistant on the Raspberry Pi, restarting the Matter Server, physically moving the device upstairs where it was closer to the router than the AP, force closing the Android app and / or rebooting my Android Pixel 7 OS version 14, unplugging our Alexa devices, and anything else I could think of.

During one try the add device succeeded and that device is now usable in Home Assistant with no problems. I can’t tell you what phase of the moon / magical incantation (or swear words) did the trick. and I have not been able to reproduce this one success.

This leads me to believe timing may have changed somewhere in the “system” and is just barely off enough to make the add device fail almost always.

BTW, the number of devices on our network has not changed substantially between adding the first two devices in August and today, and did not change at all between the several attempts with this D26HD (same firmware and hardware version as the one in August). I’ve now tried to add three dimmers and two switches (many tries for some) with only this one success.

Any suggestions for fixing and/or further debugging? TIA

I have an RPI4 w/*gig of ran running supervised. I only had one of those dimmers so maybe this step is too drastic - I deleted the matter integration and the add-on and started over completely.

However I still had issues. Below are the steps that resolved it…

I have the same dimmer. This happened to me and I had a long conversation with Leviton about it. The below resolved the issue.

  1. Completely factory reset the Leviton. You do this by holding in the “On” portion of the button for 30 seconds and then letting go. Then just foir good measure, the brightness bar on the right side - put your forefinger nail under the bottom of it an pull it out - way out. It will stick away from the wall - that is how you cut the power from it (very clever!)
  2. Delete it completely from your Leviton App (this is improtant) - then push the plastic dimmer bar back in place to re-power the switch.
  3. Restart HA
    (If the switch is already blinking green, skip #4 and 5)
  4. Once the light is up and running, hold the power ON button in for 7 seconds until the boittom starts blinking orange.
  5. Let go of it, it will be flashing green.
  6. in HA go into Settings->Integrations->Devices and then from the corner click add device, pick a matter device, follow instructions.
  7. Only after the dimmer switch is added back into HA using matter - only then - then add it into the Leviton app.

Hope this help s- good luck!

1 Like

Tad late in a response, I would select new/factory reset. I tried resets, power cycle at the breaker, rebooting HA, trying with a switch closer to the Matter dongle and nothing so I gave up and reverted back to Wifi firmware.I had the issue with a mix of around 15 of the D215S and D26HD switches.

I finally got decided to give it another go and got them working. For the Matter router I am using a HA Skyconnect. When adding the device to Home Assistant through Matter instead of “New” select “Yes. It’s already in use.”, then select Other controllers and last type in the Matter pairing code.

For me it connected right away. The only thing is HA sees them as light entities not switches. You would have to type or copy from the interwebs a switch template.

If you’re passing them through to Homekit you would need the switch template because they would also been recognized as lights.

I’ll just throw in that I was stuggling to connect a Leviton D26HD via matter and when I tried “Yes. It’s already in use.” it didn’t work (the switch never came out of pair mode, and HA just went back to the “enter pairing code” screen).

That said I then tried the new device pairing again and it did work (detecting the switch on the network almost immediately). I’ve had issues in the past with pairing matter devices to HA and the answer to pairing issues has consistently been “try, try, try again”. I’ve got two more D26HDs to install, so we’ll see if they are as tempermental to pair as this one.