Part Number: CC2530
Other Parts Discussed in Thread: Z-STACK
Hey,
We are using Z-Stack 2.6.1.
We have a ZNP Coordinator and 5 routers (All routers are added to 1 group)
One router has the Occupancy sensor and acts as master for the remaining 4 devices
One among the functionalities of Master is Multicasting occupancy value to other routers by group_id
The implementation of Multicast:
slaveAddr_p->addrMode = (afAddrMode_t)AddrGroup;
uint8 groupCount = aps_FindAllGroupsForEndpoint(SAMPLELIGHT_ENDPOINT,groupList_p);
slaveAddr_p->addr.shortAddr = groupList_p[0];
uint8 cmd = ZCL_CMD_WRITE;
uint8 direction = ZCL_FRAME_CLIENT_SERVER_DIR;
uint8 disableDefaultRsp = 0;
uint16 clusterID = ZCL_CLUSTER_ID_MS_OCCUPANCY_SENSING;
writeCmd_p->numAttr = 1;
writeCmd_p->attrList[0].attrID = ATTRID_MS_OCCUPANCY_SENSING_CONFIG_OCCUPANCY;
writeCmd_p->attrList[0].dataType = ZCL_DATATYPE_UINT16;
writeCmd_p->attrList[0].attrData = (void *)&zclSampleOcc_Occupied;
status = zcl_SendWriteRequest( srcEP, slaveAddr_p, clusterID,writeCmd_p, cmd, direction,disableDefaultRsp, seqNum++ );
Ideally, every occupancy state multicast from master router must reach the four other routers
Sometimes we have noticed that the all four routers do not receive the multicast message, i.e. 3 out of 4 routers respond to the multicast message, 2 out of 4 routers respond to multicast message
Not been able to figure out this irregular behaviour, could not trace at which level this problem is happening.
Regards,
Suhrith