With the zephyr-image Update Module, Mender leverages MCUboot to enable atomic updates on microcontrollers. MCUboot manages two firmware slots: the active slot holds the currently running image, and the inactive slot contains the new update. When an update is deployed, the new firmware is written into the inactive slot, and on reboot, MCUboot swaps the images by placing the new firmware inside the active slot. If the new firmware fails to boot or isn’t confirmed as valid, MCUboot reverts to the previous image to ensure the device recovers and is not bricked. Note that this mechanism applies when using the zephyr-image Update Module; Mender can work with other bootloaders, provided you implement the corresponding Update Module yourself.
For Mender's Zephyr integration:
CONFIG_BOOTLOADER_MCUBOOT
). This will include the MCUboot build as part of the application (or require you to build MCUboot separately and flash it to the bootloader partition). The Mender reference integration uses Zephyr's sysbuild to build MCUboot alongside the application, simplifying the process.boot_partition
for MCUboot itself.slot0_partition
for the primary image.slot1_partition
for the secondary image.mender_partition
but a generic storage_partition
can be used.CONFIG_MCUBOOT_SWAP_USING_SCRATCH
is disabled (MCUBOOT_SWAP_USING_SCRATCH=n
; the default in most cases).© 2025 Northern.tech AS