Number of direct connections to Zigbee Coordinator (ZHA / ZNP)

For a few months now I have been plagued by zigbee devices dropping after migrating to a Sonoff Zigbee 3.0 USB Dongle Plus. Prior to this migration I was using a ConBee II without device dropping off, but occasionally experiencing network meltdowns, the last of which prompted my migration.

I am currently trying to determine the correct number of zigbee devices connected directly to the coordinator. It appears to top off at 23 devices out of about 90. Based on information I found on KoenKK’s github, the Sonoff coordinator should be able to handle 50 devices. I’ve read elsewhere that ZHA may be limiting it to 24 or so devices but that there is a way to override the default.

For EZSP type coordinators, you can add this to your configuration.yaml :

zha:
    zigpy_config:
        ezsp_config:
            CONFIG_MAX_END_DEVICE_CHILDREN: 32

I can’t find anything similar for ZNP. Is there something?

Right now this is all I have:

zigpy_config:
  source_routing: true

Please note :slight_smile: : The coordinator is connected via an extension cable, with additional ferrite cores on the cable, and I reduced overall output power on all wifi APs. I’ve read the helpful suggestions repeatedly offered on many posts but they have not addressed my issues… and I am just trying to figure out how to tinker with some under-the-hood settings.

Not fun. I do not have a specific answer, just some numbers so you can compare. I have a stable zigbee network, 79 devices in total, 42 being end-devices. The coordinator is the same as yours, Sonoff 3.0 dongle, firmware 20220219. Im using Zigbee2MQTT, which is different from you.

The Coordinator have 28 direct connections to routers and 13 direct connections to end-devices. This is more than the 24 you mention ZHA can handle, however below the 50 also mentioned.

Be aware that the setting CONFIG_MAX_END_DEVICE_CHILDREN: 32 is only in relation to end devices, hence the routers are not part of the number. If ZHA have a total of 24 connections in total, then you might have very few possibilities for end-devices. Do you have a good number of routers for the end devices to connect?

Not a solution, just some numbers and thought’s.

1 Like

Thank you for your post. I now have 21 devices connected directly to my coordinator and they are all routers. Out of 90 zigbee devices, 47 are routers. Last night I installed what I thought was a higher quality / gain wifi antenna on the coordinator and direct connections dropped by 2 but this may be unrelated. The LQI values seem unchanged. Today I will test another one… what I really want to test is a lower gain antenna as I am wondering whether devices try to connect directly to the coordinator because they can receive it with a strong signal but the coordinator doesn’t receive their possibly weaker signal back as well.

Thanks for pointing out the distinction between router and end devices for that setting… I was hoping to test it to both increase and reduce the number of devices connecting to the coordinator.

EDIT: I have a small number of non zigbee 3.0 routers and wonder whether it would be beneficial to update them all to 3.0… can older devices introduce speed or connectivity issues? From the visualization screen does centralite/iris plug in outlets seem to have the highest number and quality of connections…

This is a good theory, discussed in several threads. I have read not about real tests and results. If you conclude something, please post your experience.