Hello community
I am using the sensor and collector example with the non-beacon mode. If the connection is lost and the sensor enter orphan state, I want to clear the sensors tx queue to reduce the used memory space.
Therefor I use the function: ApiMac_status_t ApiMac_mcpsPurgeReq (uint8_t msduHandle) with a callback function. But the data in the queue is not discarded.
The status in the callback function is: 0x18 ApiMac_status_unsupported -> /*! The operation is not supported in the current configuration */
So my question is, how can I purge the sensors tx queue and in which configuration?
**** some additional information: how I call the purge request *****
uint8_t msduHandle = deviceTxMsduHandle;
// decrement because it was already incremented when sending data
if(msduHandle == 0) // counter is 0
{
msduHandle += MSDU_HANDLE_MAX;
}
else
{
msduHandle--;
}
/* Add the App specific bit */
msduHandle |= APP_MARKER_MSDU_HANDLE;
/* Add the sensor specific bit */
msduHandle |= APP_SENSOR_MSDU_HANDLE;
ApiMac_mcpsPurgeReq(msduHandle);
