BSP: Update the uSD 4.14 - WinSystems/c444-manifest GitHub Wiki
Updating the BSP on the MicroSD / uSD 4.14
-
Go to the directory the image components are deployed to:
cd [yocto dir]/build/tmp/deploy/images/imx8mqpicoitx/
-
Create a partition for the kernel and dts, and another partition for the rootfs:
parted --script /dev/[name of uSD] \
mklabel msdos \
mkpart primary 8MiB 150MiB \
mkpart primary 150MiB 100%
Ensure that the first partition is at least 8MiB away from the start of the disk. If it is too close to the start, it will conflict with where the environment variables for u-boot get saved. -
Write u-boot to the uSD:
dd if=imx-boot-imx8mqpicoitx-sd.bin-flash_evk of=/dev/[name of uSD] seek=33 bs=1k
-
Format first partition of the uSD as FAT:
mkfs.fat /dev/[uSD part 1]
-
Format second partition of the uSD as EXT4:
mkfs.ext4 /dev/[uSD part 2]
-
Mount the partitions of the uSD:
mkdir kmnt
mkdir rmnt
mount /dev/[uSD part 1] kmnt
mount /dev/[uSD part 2] rmnt
-
Copy the device tree and kernel to the first partition:
cp ./Image--4.14.78-r0-fsl-imx8mq-picoitx-[timestamp].dtb kmnt/fsl-imx8mq-picoitx.dtb
cp ./Image--4.14.78-r0-imx8mqpicoitx-[timestamp].bin kmnt/Image
-
Untar the rootfs into the second partition:
tar -xjvf fsl-image-qt-imx-imx8mqpicoitx-20200624125743.rootfs.tar.bz2 -C rmnt/
-
Unmount the uSD:
sync
umount /dev/[uSD part 1]
umount /dev/[uSD part 2]
-
Get rid of the mount directories:
rm -rf kmnt rmnt