This topic explains how to run a firmware update on a device with a dual boot layout (not single system).
To update your system using a SWU package, you need:
An external media such as microSD card or USB disk. Optionally, you can save it to your device’s eMMC if you have enough free space.
A software update package with the new firmware.
Perform local firmware update
update-firmware command with the
*.swu file as parameter:
# update-firmware </your-path/your-filename>.swu
The mechanism updates the firmware on the inactive system partitions. If the update process is successful, the target reboots into the new system image.
If the target boots successfully, the new image becomes the current active system.
If the target fails to boot the new system, the dual boot mechanism increments a boot attempt counter and waits for the user (or a watchdog) to reboot the device.
If the target fails to boot the number of times established in U-Boot variable
bootlimit (default is 3), the dual boot mechanism switches back to boot the previously active system.
Enable a watchdog
The dual boot mechanism doesn’t enable a watchdog by default. To guarantee that an update doesn’t result in a blocked system (especially if updating remotely), Digi recommends you enable a watchdog timer that can reset the device in case of a boot failure.
See Watchdog for information about enabling and using the watchdog.
In a typical use case, a user space application or service starts the watchdog. However, if the system hangs before reaching this point, the watchdog is not able to reset the device.
In this case, you can add
panic=10 to the kernel arguments to force a restart 10 seconds (or any number of seconds you choose) after a kernel panic.
To add this parameter to the kernel arguments, run this on U-Boot:
=> setenv extra_bootargs panic=10 => saveenv