I am facing an issue where RF transmit gets struck for ever after running a while .
Look at the below snapshot, the RF_runScheduleCmd() stops for ever to transmit the packet waiting for Semaphore to release, it is in this state for hours. This happens very frequency, sometimes with in an hour and sometimes in 3-4 hours time but it happens ultimately. Here wireless node transmits hardly 1 packet for every 30-sec on an average.
I see 1354 went into deep sleep while RF driver is waiting for the semaphore release. I don’t know why one of the termination events (RF_TERMINATION_EVENT_MASK) never happened. Also Semaphore waiting for ever doesn’t look correct. I would like to have a timeout based RF transmit to avoid this issue in future. Do we have an API with such a timeout option for RF transmit with out touching the library code?
/* Wait for semaphore */
SemaphoreP_pend(&h->state.semSync, SemaphoreP_WAIT_FOREVER);
SDK used - simplelink_cc13xx_cc26xx_sdk_7_10_01_24
No RTOS used.
IAR Workbench is the environment.
Radio is in IEEE 802.15.4 mode in Channel 15.

The callback doesn't do anything other than just counting the number of transmit success. I also removed callback and tried like below call but the result is same. The code works for few hours (3-4 hours most of the time) but ultimately gets into this state. Before transmit command, i do flush any pending commands in the RF queue and then execute the transmit.
// clean any pending commands before putting radio into Transmit
RF_flushCmd(rfHandle, RF_CMDHANDLE_FLUSH_ALL, RF_ABORT_GRACEFULLY);
// Two additional bytes are added for the CRC16 at the end of the frame.
RF_cmdIeeeTx_ieee154_0.payloadLen = len; // + 2;
//memset(RF_cmdIeeeTx_ieee154_0.pPayload+len, 0, 2); // make CRC bytes 0x00
memcpy(RF_cmdIeeeTx_ieee154_0.pPayload, data, len);
RF_EventMask terminationReason = RF_runScheduleCmd(
rfHandle,
(RF_Op*)&RF_cmdIeeeTx_ieee154_0,
&rfSchedParams,
NULL,
RF_EventTxEntryDone
);























