I have a dual protocol application using BLE and IEEE 802.15.4. When only one protocol is active, everything works fine.
If I have activity on the IEEE radio while a BLE connection is active, I occasionally get scheduler events, and I want to know how to associate these with the RAIL operations.
The scheduler events occur mostly during transmissions started with RAIL_StartCcaCsmaTx. Sometimes, I will also get some sort of "transmission complete" event - the code catches all events in the RAIL_EVENTS_TX_COMPLETION group. Other times, I get no indication other than the scheduler event. This makes is difficult to determine when the transmission is complete.
I would also note that the scheduler status is always indicated as RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL. I never see the more specific values like RAIL_SCHEDULER_STATUS_SCHEDULED_TX_FAIL.
Can anyone help, or point me at some additional documentation about this?
(SDK 2.7.2, BGLIB 2.13.6, RAIL 2.8.6 multi-protocol, GCC 7.2.1)
Looking in the rail source, RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL means that the scheduler had to remove the task before it could try to start it. RAIL_SCHEDULER_STATUS_SCHEDULED_TX_FAIL would mean that that the scheduler did start the tx process, but the internal pair of RAIL_StartSecheduledTx returned with an error.
This could happen if a higher priority task is scheduled to the same time. You could try increasing the slip time, that would help the scheduler to reschedule the task after the high prio task.
The scheduling failure itself is not a problem.
The issue is that sometimes I get only a RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL event, and other times I get a RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL and some other event in the RAIL_EVENTS_TX_COMPLETION group. This makes it hard to determine when the transmission attempt has been completed or abandoned.
OK - thanks for the feedback.
I have a work-round for now anyway, and the issue only occurs under exceptional conditions.