Building TX8M/QS8M Series

We provide a script, karo-nxp-release.sh, that simplifies the setup for our machines. To use the script, the name of the specific machine to be built for needs to be specified as well as the desired graphical backend. The script sets up a directory and the configuration files for the specified machine and backend. [1] It also adds our layer to the bblayers.conf file.

There are different configurations you can choose from.

  • DISTRO configurations:
DISTRO= Description
fsl-imx-x11 X11 graphics are not supported on i.MX 8
fsl-imx-wayland Wayland weston graphics
fsl-imx-xwayland Wayland graphics and X11. X11 applications using EGL are not supported
fsl-imx-fb Frame Buffer graphics - no X11 or Wayland. Frame Buffer is not supported on i.MX 8
  • A list of supported MACHINE configurations:
MACHINE= Description
qs8m-mq00 QS8M-MQ00 i.MX8M Mini Solder-in Module on QSBase2 Mainboard
tx8m-1610 TX8M-1610 i.MX8M Mini CoM on MIPI-LVDS-Mainboard
tx8m-nd00 TX8M-ND00 i.MX8M Nano CoM on MIPI-LVDS-Mainboard
tx8m-1620 TX8M-1620 i.MX8M Mini CoM on LVDS-Mainboard (BETA)

Use this command to setup your build directory (specify the distro you want to use, the machine, and the build directory):

DISTRO=<distro> MACHINE=<machine> source karo-nxp-release.sh -b <build-dir>

When the script has run, your current directory changes to the <build-dir> you chose before.

Example:

DISTRO=fsl-imx-wayland MACHINE=tx8m-1610 source karo-nxp-release.sh -b build-tx8m-1610

U-Boot Version

Inside your build-directory in conf/local.conf you can set the variable UBOOT_CONFIG. This sets which u-boot should be built. If you leave it unset, “default” is built.

UBOOT_CONFIG = Description
default Our U-Boot with default environment to write inside the eMMC and boot your module.
noenv Our U-Boot with an empty environment.
mfg Our U-Boot with enabled fastboot protocol. (e.g. for using uuu)
secure-boot Our U-Boot with secure-boot enabled.

Note

For programming TX8M/QS8M with uuu (see UUU - Universal Update Utility), it is necessary to build both, default and mfg U-Boot.

Building The Image

Note

Before starting a build, you should consider enabling the SSTATE CACHE to speedup the build process.

See Enable sstate cache 1.

Here are the different images you can build:

Image Description Provided by layer
imx-boot U-Boot flashable binary, variant specified with above mentioned UBOOT_CONFIG  
linux-imx Linux Kernel and specified .dtb files only  
core-image-minimal See https://layers.openembedded.org/layerindex/recipe/579/ Poky
core-image-base See https://layers.openembedded.org/layerindex/recipe/584/ Poky
core-image-sato See https://layers.openembedded.org/layerindex/recipe/658/ Poky
fsl-image-machine-test An FSL Community i.MX core image with console environment - no GUI interface. meta-freescale-distro
fsl-image-validation-imx Builds an i.MX image with a GUI without any Qt content. meta-fsl-bsp-release/imx/meta-sdk
fsl-image-qt5-validation-imx Builds an opensource Qt 5 image. These images are only supported for i.MX SoC with hardware graphics. They are not supported on the i.MX 6UltraLite, i.MX 6UltraLiteLite, and i.MX 7Dual. meta-fsl-bsp-release/imx/meta-sdk
fsl-image-qt5 Fsl-image-gui with QT 5.9.  
meta-toolchain-qt5 QT 5 Toolchain SDK.  
fsl-image-multimedia    
fsl-image-multimedia-full    
fsl-image-gui Full image with demos and tests, used for testing with graphics, no QT  

Build the image with the following command inside your <build-dir>:

bitbake <image>

Restarting a build environment [1]

If a new terminal window is opened or the machine is rebooted after a build directory is set up, the setup environment script should be used to set up the environment variables and run a build again. The full karo-nxp-release.sh is not needed.

You can simply run:

source setup-environment <build-dir>

Image Deployment

After a build is complete, the created image resides in the tmp/deploy/images sub-directory. An image is, for the most part, specific to the machine set in the environment setup. Each image build usually creates U-Boot, kernel, and an images based on the IMAGE_FSTYPES defined in the machine configuration file.

Usually created files are:

Filename Content
imx-boot-<machine>-<version>.bin U-Boot binaries
Image-<version>-<machine>.bin Kernel image
modules-<machine>.tgz Kernel modules
<image>-<machine>.ext4 RFS
*.dtb Devicetree blob

To continue programming your board with these images have a look at UUU - Universal Update Utility.

[1](1, 2) Copied from the official NXP Yocto Project User’s Guide, mentioned above.