Zigbee curtain switch enters unrecoverable deep sleep

(this is a guess but an educated one)

I have this 220V powered curtain switch (TS130F _TZ3210_ol1uhvza)


and I have a serious problem with it. I tested both ZHA and Zigbee2MQTT and Z2M mostly fixes the problem.

The device is 220V constantly powered.

ZHA: After I pair it everything is ok, instant response. However if I leave it idle for a few minutes, the device becomes unresponsive to commands (it does however continue to communicate one-way with HA sending state/link quality info). Once that happens there’s no actual way to reactivate it, not even powering it off. I have to re-pair it and once I do that it becomes responsive again (until I let it idle again)

Zigbee2MQTT: It seems Z2M correctly keeps the device awake (different reporting system?) as long as the router/coordinator is available. I have a zigbee dongle repeater nearby (they are far from the coordinator) and with the repeater they have 180 LQI, very good link, this is not the problem. However I tried turning the repeater off and if the switches don’t manage to connect to another nearby router fast they enter the same deep sleep mode and must be re-paired.

This definitely sounds like a switch firmware problem, but have you guys encountered such situation before? Any thoughts?

How does the rest of your zigbee network look like, do you have enough routers, the coordinator on an extension cable and so on?

Yes, I have a lot of routers placed strategically between devices spread among the whole house.

But I don’t think this is relevant as signal/link quality is not a problem… for what it’s worth all other devices work flawlessly, includig other devices nearby the curtain switches

Same problem here, with days of investigations and no clear conclusion.

The only way to restore a stable state is to power-off the curtainn-switch, wait 6 seconds, power-on.
And then everything is fine.

Configuration: HA on raspberry Pi 5 + SONOFF DUALR3 LITE

I also have a lot of routers, and very good LQi for the TS130F.
The zigbee coordinator is even in the same room than the curtain switch.
When OK, it has 4 neighbours.

No known WiFi interference: Zigbee channel is 11, WiFi is on 11 and 6, which is OK according to ZigBee and Wi-Fi Coexistence | MetaGeek

The Zigbee module is connected to the Pi over a USB-2 port with a 50cm cable,
and far (8m) from any 2.4 GHz source.

However, the Zigbee Curtain switch “goes off” from time to time:
does not answer to zigbee messages, including interview messages, and a building a map shwos all routes with LGI 0

All tips in Improve network range and stability | Zigbee2MQTT have been tested.

Changing zigbee channel to 26 does not improve the stability.

Please note that the 5 power plugs work perfectly.

I tend to believe that the problem is not with zigbee networking, but with the devices, which are TUYA TS130F and Moes ZTS-EUR-C.

It would be OK to purchase other ones, but the issue is that MANY devices are actually the same one, white labelled with a different brand.

Switching to Z2M solved the problem for me as long as I have at least 1 router nearby with strong signal so the switches stay connected to the router with strong signal… it seems Z2M forces the device to stay awake