Hi
I am using Apalis imx 8 board.
We have added mender layers to our custom Yocto Build. Layers have been added and local.conf file changed accordingly.
We use QT boot to Qt 6.4.3 layer.
Integrating mender layer have worked and we created tezii image for our board. Loaded this image using Toradex easy installer. IT worked as expected. Partitions has created A/B and data partitions are present.
We tested manual update using “mender install file.mender”. This worked too.
root@b2qt-apalis-imx8:~# mender install /media/sda1/b2qt-embedded-qt6-image-apalis-imx8-20230531134214.mender
INFO[0000] Loaded configuration file: /var/lib/mender/mender.conf
INFO[0000] Loaded configuration file: /etc/mender/mender.conf
INFO[0002] Mender running on partition: /dev/mmcblk0p3
INFO[0003] Mender running on partition: /dev/mmcblk0p3
INFO[0003] Start updating from local image file: [/media/sda1/b2qt-embedded-qt6-image-apalis-imx8-20230531134214.mender]
Installing Artifact of size 852783616…
INFO[0003] No public key was provided for authenticating the artifact
INFO[0003] Opening device “/dev/mmcblk0p2” for writing
INFO[0003] Native sector size of block device /dev/mmcblk0p2 is 512 bytes. Mender will write in chunks of 1048576 bytes
… - 99 %INFO[0119] All bytes were successfully written to the new partition
INFO[0119] The optimized block-device writer wrote a total of 6049 frames, where 97 frames did need to be rewritten (i.e., skipped)
INFO[0120] Wrote 6341787648/6341787648 bytes to the inactive partition
… - 100 %
INFO[0120] Enabling partition with new image installed to be a boot candidate: 2
Use ‘commit’ to update, or ‘rollback’ to roll back the update.
At least one payload requested a reboot of the device it updated.
root@b2qt-apalis-imx8:~#
It was booted from /dev/mmcblk0p3 and as seen from the log it updated /dev/mmcblk0p2 partition.
I have used mender commit on next power up.
The problem is kernel and boot settings (device tree file) have changed with the update. But file system partition has not been updated to correct one. It still boots to /dev/mmcblk0p3.
I have checked /dev/mmcblk0p2 and looks like it is updated with correct image, files are there. But it is not an active partition after the update.
I have started to experiment local.conf file settings and added e a few attributes for mender.
But no luck with the image created and written to board with this settings it stuck on boot after kernel load.
Waiting for root device /dev/mmcblk02…
These are the partitions in previous test:
b2qt-apalis-imx8:~:>ls /dev/mmcblk0
mmcblk0 mmcblk0boot0 mmcblk0boot1 mmcblk0p1 mmcblk0p2 mmcblk0p3 mmcblk0p4 mmcblk0rpmb
Any help on the topic appreciated. We feel like missed it so close.
Nothing immediately comes to mind. My best guess is something is not right in the uboot environment itself. Can you post the output of “printenv” from the U-Boot prompt?
Drew
any help would be appreciated. we are this close to integrating it with the system now !! maybe something in our uboot environment that we are missing out !!
Well it uses distro_bootcmd which is expected. Since you are using boot2qt I’m assuming you didn’t use the same steps as documented here to get your sources right? Can you share the details of how you got the full set of sources?
I’ve never tried to get it working using the Boot2QT repo manifests. I’ve only ever used the Toradex manifests. I suspect something is not getting applied properly related to the Distro Boot stuff. Specifically I would suggest investigating this patch.
I’ll try to build with TORADEX_BSP_VERSION=6.2.0 and will probably need to make a few mods to the layer to support that but I suspect in your case you will need even more changes.
yes , i remember i applied this patch as it was failing in patching. I manually created this patch and applied.
so seems like i applied.
+env set bootcmd_run 'run m4boot; run bootcmd_dtb && run bootcmd_overlays && run bootcmd_args && run bootcmd_kernel && run bootcmd_unzip && run bootcmd_boot; echo “Booting from ${devtype} failed!” && false’env set bootcmd_run ‘run m4boot; run bootcmd_dtb && run bootcmd_overlays && run bootcmd_args && run bootcmd_kernel && run bootcmd_unzip && run bootcmd_boot; echo “Booting from ${devtype} failed!”’
instead of
+env set bootcmd_run ‘run m4boot; run bootcmd_dtb && run bootcmd_overlays && run bootcmd_args && run bootcmd_kernel && run bootcmd_unzip && run bootcmd_boot; echo “Booting from ${devtype} failed!”’
Noting down a kind of summary would be very much appreciated @dhiry2k, es far as I know the board also does not have a known good integration at the moment.