WavePhoenix Bootloader
Dependencies
- GNU Arm Embedded Toolchain
- Silicon Labs Simplicity SDK
- Silicon Labs Configurator (SLC-CLI) (requires Java)
Configuration
You'll need to tell SLC-CLI where your Simplicity SDK and ARM toolchain are located:
slc configuration --sdk path/to/simplicity_sdk
slc configuration --gcc-toolchain path/to/gcc-arm-none-eabi
slc signature trust --sdk path/to/simplicity_sdk
Building
To build the WavePhoenix bootloader, run the following script, replacing rf-bm-bg22c3 with your target board:
BOARD=rf-bm-bg22c3 ./build.sh
This will generate target/rf-bm-bg22c3/build/release/bootloader.hex.
Flashing
Using Simplicity Commander
If you are using a dev board with a built-in J-Link debugger, you can use Simplicity Commander to flash the bootloader:
commander flash bootloader.hex
Using OpenOCD
If you are using a generic SWD debug probe, you can use OpenOCD to flash the bootloader:
-
Download and install Arduino's fork of OpenOCD (Windows, macOS, Linux)
-
Connect GND, SWDIO, SWCLK, and 3V3 between the debug probe and the SoC.
-
If this is your first time flashing this chip, you'll need to do a full device erase to unlock the debug interface:
openocd -f "interface/cmsis-dap.cfg" \ -f "target/efm32s2.cfg" \ -c "init; efm32s2_dci_device_erase; shutdown" -
Disconnect then reconnect the debug probe.
-
Then, flash the bootloader, replacing
bootloader.hexwith the path to your bootloader file:openocd -f interface/cmsis-dap.cfg \ -c "transport select swd" \ -f target/efm32s2.cfg \ -c "init; halt; flash write_image erase bootloader.hex; exit"