Multiprotocol

Multiprotocol scheduler APIs to support multiple time-sliced PHYs.

Modules

EFR32
EFR32 Specific multiprotocol support defines.

Data Structures

struct  RAILSched_Config_t
 Multiprotocol scheduler configuration and internal state.
 
struct  RAIL_SchedulerInfo_t
 A structure to hold information used by the scheduler.

Macros

#define RAIL_SCHEDULER_STATE_UINT32_BUFFER_SIZE   25
 The size in 32-bit words of RAIL_SchedulerStateBuffer_t to store RAIL multiprotocol internal state.

Typedefs

typedef uint32_t RAIL_Time_t
 Time in microseconds.
 
typedef uint32_t RAIL_SchedulerStateBuffer_t[25]
 Buffer used to store multiprotocol scheduler internal state.

Enumerations

enum  RAIL_SchedulerStatus_t {
  RAIL_SCHEDULER_STATUS_NO_ERROR,
  RAIL_SCHEDULER_STATUS_UNSUPPORTED,
  RAIL_SCHEDULER_STATUS_EVENT_INTERRUPTED,
  RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL,
  RAIL_SCHEDULER_STATUS_SCHEDULED_TX_FAIL,
  RAIL_SCHEDULER_STATUS_SINGLE_TX_FAIL,
  RAIL_SCHEDULER_STATUS_CCA_CSMA_TX_FAIL,
  RAIL_SCHEDULER_STATUS_CCA_LBT_TX_FAIL,
  RAIL_SCHEDULER_STATUS_SCHEDULED_RX_FAIL,
  RAIL_SCHEDULER_STATUS_TX_STREAM_FAIL,
  RAIL_SCHEDULER_STATUS_AVERAGE_RSSI_FAIL,
  RAIL_SCHEDULER_STATUS_INTERNAL_ERROR
}
 Multiprotocol scheduler status returned by RAIL_GetSchedulerStatus().

Functions

void RAIL_YieldRadio (RAIL_Handle_t railHandle)
 Yields the radio to other configurations.
 
RAIL_SchedulerStatus_t RAIL_GetSchedulerStatus (RAIL_Handle_t railHandle)
 Get the status of the RAIL scheduler.

Detailed Description

Multiprotocol scheduler APIs to support multiple time-sliced PHYs.

Typedef Documentation

◆ RAIL_SchedulerStateBuffer_t

RAIL_SchedulerStateBuffer_t

Buffer used to store multiprotocol scheduler internal state.

This buffer must be allocated in application global read-write memory that persists for the duration of RAIL usage. It cannot be allocated in read-only memory or on the call stack.

Definition at line 75 of file rail_types.h.

Enumeration Type Documentation

◆ RAIL_SchedulerStatus_t

Multiprotocol scheduler status returned by RAIL_GetSchedulerStatus().

Enumerator
RAIL_SCHEDULER_STATUS_NO_ERROR 

Multiprotocol scheduler reports no error.

RAIL_SCHEDULER_STATUS_UNSUPPORTED 

The scheduler is disabled or the requested scheduler operation is unsupported.

RAIL_SCHEDULER_STATUS_EVENT_INTERRUPTED 

The scheduled event was started but was interrupted by a higher priority event before it could be completed.

RAIL_SCHEDULER_STATUS_SCHEDULE_FAIL 

This task could not be scheduled given its priority and the other tasks running on the system.

RAIL_SCHEDULER_STATUS_SCHEDULED_TX_FAIL 

Calling the scheduled transmit function returned an error code.

See RAIL_StartScheduledTx() for more information about possible errors.

RAIL_SCHEDULER_STATUS_SINGLE_TX_FAIL 

Calling the start transmit function returned an error code.

See RAIL_StartTx() for more information about possible errors.

RAIL_SCHEDULER_STATUS_CCA_CSMA_TX_FAIL 

Calling the CSMA transmit function returned an error code.

See RAIL_StartCcaCsmaTx() for more information about possible errors.

RAIL_SCHEDULER_STATUS_CCA_LBT_TX_FAIL 

Calling the LBT transmit function returned an error code.

See RAIL_StartCcaLbtTx() for more information about possible errors.

RAIL_SCHEDULER_STATUS_SCHEDULED_RX_FAIL 

Calling the scheduled receive function returned an error code.

This likely means that we were a little too late and could not setup the hardware in time to do this receive.

RAIL_SCHEDULER_STATUS_TX_STREAM_FAIL 

Calling the stream transmit function returned an error code.

See RAIL_StartTxStream() for more information about possible errors.

RAIL_SCHEDULER_STATUS_AVERAGE_RSSI_FAIL 

RSSI averaging failed.

If this scheduler status occurs RAIL_GetAverageRssi() will return RAIL_RSSI_INVALID until a RAIL_StartAverageRssi() completes successfully.

RAIL_SCHEDULER_STATUS_INTERNAL_ERROR 

There was an internal error in the scheduler data structures.

This should not happen and indicates a problem if seen.

Definition at line 126 of file rail_types.h.

Function Documentation

◆ RAIL_GetSchedulerStatus()

RAIL_SchedulerStatus_t RAIL_GetSchedulerStatus ( RAIL_Handle_t  railHandle)

Get the status of the RAIL scheduler.

Parameters
[in]railHandleA RAIL instance handle.
Returns
RAIL_SchedulerStatus_t status.

This function can only be called from callback context after the RAIL_EVENT_SCHEDULER_STATUS event occurs.

Referenced by RAIL_CopyRxPacket().

◆ RAIL_YieldRadio()

void RAIL_YieldRadio ( RAIL_Handle_t  railHandle)

Yields the radio to other configurations.

Parameters
[in]railHandleA RAIL instance handle.
Returns
void.

This function is used to indicate that the previous transmit or scheduled receive operation has completed. It must be used in multiprotocol RAIL since the scheduler assumes that any transmit or receive operation that is started by you can go on infinitely based on state transitions and your protocol. RAIL will not allow a lower priority tasks to run until this is called so it can negatively impact performance of those protocols if this is omitted or delayed. It is also possible to simply call the RAIL_Idle() API to to both terminate the operation and idle the radio. In single protocol RAIL this API does nothing.

See Yielding the radio for more details.

Referenced by RAIL_CopyRxPacket().