Trucrux Inc

Flashing Guide for Yocto OS

To build OS follow Building TruxOS from Source Code

Once the image is ready the resulting image is located in tmp/deploy/images/imx8mq-trux-q01/

The build results are as follows:

Image Name How to use
fsl-image-gui-imx8mq-trux-q01.wic.gz SD card flashing image
fsl-image-gui-imx8mq-trux-q01.tar.gz rootfs for bootable sd card
Image.gz Linux Kernel Image
imx-boot-sd.bin Uboot Image

Custom Flashing #

The IMAGE contains U-Boot, the Linux image and device trees, and the rootfs.
If flexibility is not required the image can be installed on the SD card with one command.
Carry out the following command to copy the SD card image to the SD/MMC card. Change sdX below to match the one used
by the SD card.

to check for SD card run

$ ls /dev

without connecting the SD card.

rerun the above command after connecting the SD card and spot the additional sdX.

The same can be done using

$ sudo fdsik -l

a search for the size of the SD card and a note for sdX

To flash the SD card run the following command and replace X with your SD card.

$ cd ~/CodeSetup
$ sudo MACHINE=imx8mq-trux-q01 sources/meta-trucrux/scripts/trux_mk_yocto_sdcard/trux-create-yocto-sdcard.sh < options > /dev/sdX
OPTIONS :
-h Display help message
-s Only show partition sizes to be written, without actually write them
-a Automatically set the rootfs partition size to fill the SD card
-r Select alternative rootfs for recovery images (default: /tmp/deploy/images/imx8mq-trucrux/fsl-image-gui-imx8mq-trucrux.*)

Generally, the -a option is used for automatic flashing. Below is the example for automatic flashing with SD card “b”.

$ sudo MACHINE=imx8mq-trux-q01 sources/meta-trucrux/scripts/trux_mk_yocto_sdcard/trux-create-yocto-sdcard.sh -a /dev/sdb

Once flashing is done insert an SD card in the device turn the device ON and check for boot logs on the serial port (ttymxc0).

NOTE: Refer Quick Start Guide before Turning on the deviceĀ 

Flashing SD card image to eMMC #

Once the device is booted successfully you can then copy the SD card image to the device eMMC (internal storage). To copy the SD card image to eMMC open the device terminal and run the following commands.

$ cd /usr/bin/

$ ./install_yocto.sh -u

once the image is copied successfully reboot the device by removing the SD card.