I have a CC2530 with ZNP firmware connected over UART. I am able to start a coordinator and devices join the network (I receive ZDO_END_DEVICE_ANNCE messages). A number of devices (a light and a thermostat) join the network and I can send AF_DATA_REQUEST commands to get and set attributes. These devices remain on the network forever.
I have ZHA motion sensors that I need to connect to the coordinator too. When I power on the sensors I see a ZDO_END_DEVICE_ANNCE and I can get the active end points and the simple descriptor, however after a few seconds the sensors will issue a ZDO_LEAVE_IND and leave the coordinator. After a few more seconds the sensor re-joins the network. This happens with 2 door sensors and 1 motion sensor, so I assume this is an expected behavior
My questions are:
Why are these devices joining and leaving? Do I need to bind a cluster on the device to tell it to stay?
Here is the info on one of the motion sensors:
mtZdoActiveEpRspCb
SrcAddr: 0xA304
Status: 0x00
NwkAddr: 0xA304
ActiveEPCount: 0x02
ActiveEPList[0]: 0x01
ActiveEPList[1]: 0x02
mtZdoSimpleDescRspCb
SrcAddr: 0xA304
Status: 0x00
NwkAddr: 0xA304
Len: 0x18
Endpoint: 0x01
ProfileID: 0x0104
DeviceID: 0x0402
DeviceVersion: 0x00
NumInClusters: 0x07
InClusterList[0]: 0x0000 <- Basic
InClusterList[1]: 0x0001 <- Power config
InClusterList[2]: 0x0003 <- Identify
InClusterList[3]: 0x0020 <- Poll?
InClusterList[4]: 0x0402 <- Temperature measurement
InClusterList[5]: 0x0500 <- Attributes and commands for IAS security zone devices.
InClusterList[6]: 0x0B05 <- Diag?
NumOutClusters: 0x01
OutClusterList[0]: 0x0019 <- OTA?
mtZdoSimpleDescRspCb
SrcAddr: 0xA304
Status: 0x00
NwkAddr: 0xA304
Len: 0x14
Endpoint: 0x02
ProfileID: 0x0104
DeviceID: 0x0107
DeviceVersion: 0x00
NumInClusters: 0x05
InClusterList[0]: 0x0000 <- Basic
InClusterList[1]: 0x0001 <- Power config
InClusterList[2]: 0x0003 <- Identify
InClusterList[3]: 0x0406 <- Occupancy sensing
InClusterList[4]: 0x0B05 <- Diag?
NumOutClusters: 0x01
OutClusterList[0]: 0x0003 <- Identify