Part Number: CC2530
Calling NLME_LeaveReq() first time succeeds (After Firmware flash)
After wards it fails with Response of 0xC2 (ZNwkInvalidRequest). even though the device (that needs to leave) exist in the Network.
I don't see why the request is invalid,
I am calling NLME_LeaveReq() this way, inside a function(devExtAddrs & Rejoin are passed to the function).
NLME_LeaveReq_t *leavereq = (NLME_LeaveReq_t*)osal_mem_alloc(sizeof(NLME_LeaveReq_t)); leavereq->extAddr = devExtAddrs; leavereq->removeChildren = FALSE; leavereq->rejoin = Rejoin; leavereq->silent = FALSE; NLME_ResponseCapture = NLME_LeaveReq((NLME_LeaveReq_t*) leavereq); osal_mem_free((NLME_LeaveReq_t*)leavereq); //free
The Response is captured in the NLME_ResponseCapture which showed up 0xC2.
Could someone help with a solution.