The Radio Setup Configuration in Definitions section is the list of initialization commands that are sent to the radio over the SPI inter-
face. The structure of one element of the list is shown below. The comment lines describe how the C definition configures the dedicated
API properties. The C define line stands for the initialization command.
/* Set Multiple Properties starting with MODEM_MOD_TYPE
* Starting Location: 0x2000
* Number of properties: 3
* Defaults: 0x02 0x80 0x07
* Descriptions:
* MODEM_MOD_TYPE - Modulation Type.
* Bit[7] : TX_DIRECT_MODE_TYPE : 0
* Bit[6:5] : TX_DIRECT_MODE_GPIO [1:0] : 0
* Bit[4:3] : MOD_SOURCE[1:0] : 0
* Bit[2:0] : MOD_TYPE[2:0]: 3
* MODEM_MAP_CONTROL - Controls bit mapping.
* Bit[7] : enmanch : 0
* Bit[6] : eninv_rxbit : 0
* Bit[5] : envinv_txbit : 0
* Bit[4] : envinv_fd : 0
* Bit[3] : envinv_adcq : 0
* MODEM_DSM_CTRL - DSM control.
* Bit[7] : dsmclk_sel : 0
* Bit[6] : dsm_mode : 0
* Bit[5] : dsmdt_en : 0
* Bit[4] : dsmdttp : 0
* Bit[3] : dsm_rst : 0
* Bit[2] : dsm_lsb : 1
* Bit[1:0] :dsm_order :3
*/
#define RADIO_CONFIGURATION_SET_PROPERTIES_MODEM_MOD_TYPE 0x11, 0x20, 0x03, 0x00, 0x03,
0x00, 0x07
The commented lines explain which API property/properties will be overwritten with new value(s). For example, this definition is respon-
sible for initializing three API properties of the radio at one time, MODEM_MOD_TYPE, MODEM_MAP_CONTROL, and MO-
DEM_DSM_CTRL. The format of the definition is as follows:
• The first byte is the command ID of the SET_PROPERTY API command.
• The next three bytes are the requirements of the command:
• MSB of the starting location of the API property
• Numberof the immediate adjacent API properties
• LSB of the starting location of the API property
• Finally, the values of the properties set by the command.
Figure 5.9. Command Structure
The Radio Setup Configuration section is intended only for the example project. This part only has a C-like structure, called Radio_Set-
up_Configuration_Array, that contains the previously mentioned definitions with the modification that the first element is the length of
the API command. The format of the definition remains almost the same but the length field is added. The importance of the extended
structure is to build the appropriate format of the input parameter for the Si4455_configuration_init(…) function. The format of a
line from the array is as follows:
The Specific Configuration of the Example Project section is intended for the example project. It contains some specific definitions for
the example application such as which channel is selected either for the transmission or for the reception. The content of the custom
packet is initialized in this section. It also contains WDS calculator-related information in the commented lines.
/**
#define CUSTOM_PACKET_TX_CONTENT {SiliconLabs}
#define CUSTOM_PACKET_RX_CONTENT {SiliconLabs}
#define CUSTOM_CHANNEL_NUMBER_TX 0
AN954: Programming Guide for EFM8 and EZRadio ®
Radio Initialization
silabs.com | Smart. Connected. Energy-friendly. Rev. 0.1 | 30