Hello @farooq,
Thanks for the detailed explanation.
There are a few considerations that are important here.
When it comes to what the devices final state will be and how you plan to update it in the future:
- If you want to keep the current mechanism: Creating a custom image type that puts the rootfs in a format which your custom updater can deal with is the way to go.
- This has some considerations on the bootloader side:
- While not always required, it is advisable to use the same bootloader as the respective Toradex BSP as a base.
- A bootloader upgrade would be especially advisable in this case where you are moving from BSP 2.8, which used downstream-NXP components, to BSP 7, with upstream components.
- This has some considerations on the bootloader side:
- If you are open to another update mechanism: We now have the Torizon Update system, which handles update security in a more secure way than just a simple check of GPG keys of the update itself.
- As you already have a Yocto build for your project, Torizon Minimal is likely a good starting point, as it is a very basic Yocto image with the update client integrated.
- In Torizon, if the device is connected there are many useful cloud features beyond the OTA updates.
- If the device is offline, you can use offline updates.
Either for updating the bootloader, using another process to flash the image, or moving to Torizon, if you need to load the Toradex Easy Installer, I see two main ways to do so:
Use the SD Card
By default on BSP 2.8, the boot is done with distro_bootcmd
, which if you dig a bit deeper tries to boot Linux from the SD Card first (mmc1
or mmc2
):
Apalis iMX6 # printenv distro_bootcmd
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
Apalis iMX6 # printenv boot_targets
boot_targets=mmc1 mmc2 mmc0 usb0 dhcp
Apalis iMX6 # mmc list
FSL_SDHC: 0 (eMMC)
FSL_SDHC: 1
FSL_SDHC: 2
This allows you to craft an sd-card with the Toradex Easy Installer and an image to be installed on the device.
Such SD-Card will be booted by default and automatically install the new image to the SoM’s flash memory without the need for human interaction.
Please see an example of this here: Verdin-imx8mm - easy installer and custom image in a single place - #7 by bruno.tx
Load the Toradex Easy Installer via USB OTG
Normally, this would require the use of the recovery button and following the full procedure described here: Loading Toradex Easy Installer | Toradex Developer Center
However, on the version of u-boot present in BSP 2.8, you can run a command that will bring the module to recovery mode: bmode usb
After running this command, the module will be effectively in recovery mode, allowing you to load the Toradex Easy Installer via the USB OTG port.
How to proceed further ends up being a design decision.
If you want to discuss more the possibilities here, please let me know.
Best Regards,
Bruno