Join existing Zigbee network with light bulb example


I flashed the light_bulb example(NRF5 SDK v.4.2.0) hex to an nRF52840 Dongle using nRF Connect.

After reset, LED2 lights blue.

I do have an existing Zigbee network using Zigbee2Mqtt and I want do connect the example bulb to it. But Zigbee2Mqtt does not show any join attempts from the light bulb example.

So my question is:

Is this example not intended to join a Zigbee network? Are there ohter examples that can connect to an existing network in this case? Or is something wrong?

Thank you!

  • Hi,

    The light bulb will start trying to join a network using network steering as soon as the Zigbee stack has been initialized and started. This might be caused by the light bulb not scanning the channel of the Zigbee network. If you look towards the top in main.c of the light bulb example you will find the following line:

    #define IEEE_CHANNEL_MASK                 (1l << ZIGBEE_CHANNEL) 

    This makes the device only scan on one predefined channel, which is defined in sdk_config.h. In the examples in the nRF5 SDK this is set to channel 16 by default. If you know which channel your network is on and want the dongle to only scan that one, you can go to examples/zigbee/light_control/light_bulb/pca10059/mbr/config/sdk_config.h and change ZIGBEE_CHANNEL to your channel. You can also change IEEE_CHANNEL_MASK to 0x07FFF800UL to scan all channels.

    Best regards,