Device InitializationBSP

Detailed Description

Device Initialization using HAL configuration.

The BSP Device Initialization APIs provide functionality to initialize the device for a specific application and board based on a HAL configuration header file. The BSP Device Initialization module provides APIs that perform

  • EFM32/EZR32/EFR32 errata workaround
  • DC-to-DC converter initialization on devices with DCDC
  • Clock initialization for crystal oscillators and clock selection for HF and LF clock trees

Functions

void BSP_initBoard (void)
Initialize board based on HAL configuration.
void BSP_initClocks (void)
Initialize crystal oscillators and configure clock trees.
void BSP_initDcdc (void)
Configure and initialize the DC-to-DC converter.
void BSP_initDevice (void)
Initialize the device using HAL config settings.
void BSP_initEmu (void)
Configure EMU energy modes.

Function Documentation

void BSP_initBoard ( void )

Initialize board based on HAL configuration.

Initialize peripherals to communicate with board components

Definition at line 210 of file bsp_init.c .

References BSP_Init() , BSP_INIT_IOEXP , BSP_IOEXP_LEDS , BSP_IOEXP_SENSORS , BSP_IOEXP_VCOM , BSP_LedsInit() , BSP_PeripheralAccess() , CMU_ClockEnable() , cmuClock_GPIO , GPIO_PinModeSet() , gpioModePushPull , I2CSPM_Init() , and RETARGET_SerialInit() .

void BSP_initClocks ( void )

Initialize crystal oscillators and configure clock trees.

Initialize HFXO and LFXO crystal oscillators if present. Select clock sources for HF and LF clock trees.

Definition at line 93 of file bsp_init.c .

References CMU_ClockSelectSet() , CMU_HFXOInit() , CMU_LFXOInit() , CMU_OscillatorEnable() , cmuClock_HF , cmuClock_LFA , cmuClock_LFB , cmuClock_LFC , cmuOsc_HFRCO , cmuOsc_HFXO , cmuSelect_HFCLKLE , cmuSelect_HFRCO , cmuSelect_HFXO , cmuSelect_LFRCO , cmuSelect_LFXO , cmuSelect_ULFRCO , SystemHFXOClockSet() , and SystemLFXOClockSet() .

Referenced by BSP_initDevice() .

void BSP_initDcdc ( void )

Configure and initialize the DC-to-DC converter.

Initialize the DC-to-DC converter if the board is wired for DCDC operation. Power down the DC-to-DC converter if the board is not wired for DCDC operation.

Referenced by BSP_initDevice() .

void BSP_initDevice ( void )

Initialize the device using HAL config settings.

Perform errata workarounds, DC-to-DC converter initialization and clock initialization and selection

Definition at line 37 of file bsp_init.c .

References BSP_initClocks() , BSP_initDcdc() , BSP_initEmu() , and CHIP_Init() .

void BSP_initEmu ( void )

Configure EMU energy modes.

Configure EM2/3.

Definition at line 69 of file bsp_init.c .

References EMU_EM23Init_TypeDef::em23VregFullEn , EMU_EM23Init() , and EMU_EM23INIT_DEFAULT .

Referenced by BSP_initDevice() .