English
Language : 

AN452 Datasheet, PDF (11/26 Pages) Silicon Laboratories – WIRELESS M-BUS STACK PROGRAMMERS GUIDE
AN452
3.3. Functions
3.3.1. MbusLinkInit
Prototype:
LINK_STATUS MbusLinkInit(void);
Parameters:
none
Returns:
LINK_STATUS_SUCCESS
LINK_STATUS_PHY_ERROR_INVALID_STATE
Description:
This function initializes the Data Link Layer module attributes to their default values, initializes the RTC at
32.768 kHz, and initializes the PHY registers. This function only needs to be called once at the beginning of code
after an MCU reset.
3.3.2. MbusLinkRadioPowerOn
Prototype:
LINK_STATUS MbusLinkRadioPowerOn(void);
Parameters:
none
Returns:
LINK_STATUS_SUCCESS
LINK_STATUS_PHY_ERROR_INVALID_STATE
Description:
This function turns on the EZRadioPRO® but does not wait for the radio to enter IDLE mode. The NHL/AL can
perform work while waiting for the radio oscillator to stabilize. Next, call MbusLinkRadioConfig() to wait for the radio
to enter IDLE mode and configure the radio modes and channel.
3.3.3. MbusLinkRadioConfig
Prototype:
LINK_STATUS MbusLinkRadioConfig(void);
Parameters:
none
Returns:
LINK_STATUS_SUCCESS
LINK_STATUS_PHY_ERROR_INVALID_VALUE
LINK_STATUS_PHY_ERROR_INVALID_STATE
LINK_STATUS_PHY_ERROR_POR_TIMEOUT
LINK_STATUS_PHY_ERROR_XTAL_TIMEOUT
LINK_STATUS_PHY_ERROR_UNSUPPORTED_RADIO
Description:
This function waits for the EZRadioPRO to enter IDLE mode and stores the radio modes and channel settings
before configuring the radio over SPI. Users must call this function after changing radio settings before the new
settings will apply.
Rev. 0.1
11