Callbacks Utility#
RAIL Callbacks Utility#
This optional software component can be enabled to include default functionality related to RAIL callback configuration.
This utility provides basic callbacks that can be made available to RAIL. If a callback is not registered for use, it will be compiled out. The provided callbacks include:
This callback is called when a RAIL library-level assertion occurs. This callback occurs regardless of the other configuration options enabled in this software component.
This callback overrides a weak function in the RAIL library and as such cannot be compiled out. Any assert within the RAIL library will cause this callback to run and provide information as to the cause.
The weak function
sl_rail_util_on_assert_failed
is provided for application use and will be called when RAILCb_AssertFailed is called.This callback override can be configured to be excluded, in which case the application is responsible for creating its own RAILCb_AssertFailed override if so desired.
sli_rail_util_on_rf_ready
This callback is called when the call to RAIL_Init completes.
The
Initialize RAIL
configuration option must be enabled, and this callback must be passed as a parameter to RAIL_Init to enable its use.The weak function
sl_rail_util_on_rf_ready
is provided for application use and will be called whensli_rail_util_on_rf_ready
is called.
sli_rail_util_on_channel_config_change
This callback is called when an automatic switch from one channel configuration entry to another is performed internal to the RAIL library.
The
Initialize RAIL
andProtocol Configuration
configuration options must be enabled, and this callback must be passed as a parameter to RAIL_ConfigChannels to enable its use.The weak function
sl_rail_util_on_channel_config_change
is provided for application use and will be called whensli_rail_util_on_channel_config_change
is called.
sli_rail_util_on_event
This callback is called when a configured radio event occurs. The radio events capable of causing this callback are identified in RAIL_Events_t.
The
Initialize RAIL
andRadio Event Configuration
configuration options must be enabled, and this callback must be passed as a parameter to RAIL_Init to enable its use.The weak function
sl_rail_util_on_event
is provided for application use and will be called whensli_rail_util_on_event
is called.
Configuration Options#
The following configuration options can be changed:
Include/exclude RAILCb_AssertFailed callback override.