Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions bootloaders/riotboot/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ BOARD ?= samr21-xpro
# Select the boards with riotboot feature
FEATURES_REQUIRED += riotboot

# Provide a define to detect if building the bootloader
CFLAGS += -DRIOTBOOT

# Disable unused modules
CFLAGS += -DNDEBUG -DLOG_LEVEL=LOG_NONE
DISABLE_MODULE += auto_init
Expand Down
6 changes: 6 additions & 0 deletions bootloaders/riotboot/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ A board capable to use riotboot must meet the following requirements:
The above requirements are usually met if the board succeeds to execute
the riotboot test in tests/.

When building the bootloader, the global define `RIOTBOOT` is available. You
can use this define to skip certain parts in `board_init()` (or `cpu_init()`)
that should not be executed during boot. Note that this define is different
from `MODULE_RIOTBOOT`, which is also defined when building an application that
utilizes riotboot.

# Single Slot
Just compile your application with `FEATURES_REQUIRED += riotboot`. The header
is generated automatically according to your `APP_VER`, which can be optionally
Expand Down