This example application runs out of the box on the STM32 Nucleo-WL55 Kit (NUCLEO-WL55JC2)
To build and flash the example, you need to have rustup. In practice you can use whatever tool you want to flash the device, but this guide will assume that
probe-run is used (
cargo install probe-run).
Over The Air Authentication (OTAA) credentials will come from these entries in
"dev-eui" = "..." "app-eui" = "..." "app-key" = "..."
Flashing the firmware uses
probe-run which auto-detects the probe connected to your device.
The following command will build and flash the firmware and open the
debugger console so you can see the console debug output.
DEFMT_LOG=info cargo run --release
Once the device is flashed, it will connect to the local LoRaWAN network. Once the network is joined, you can press the B1 button on the development kit to send a test message
num-clicks is the number of times you pressed the button since resetting the board.
The board features 3 user controllable LEDs. The program will use 3 of them to show the internal status:
Will light up when starting and turn off once it joined the LoRa network.
Turns on while sending the uplink message.
Can be controlled through the downlink message:
You can also use this example with
embassy-boot to enable firmware updates over the air! To do
that, you must flash the bootloader:
cargo flash --manifest-path ../bootloader/Cargo.toml --release --no-default-features --chip STM32WLE5JCIx
You can then run the application with the
DEFMT_LOG=info cargo run --release --features dfu