i.MX8 - iMX8MEVK - Getting Started - Loading Pre-built Images

From RidgeRun Developer Connection
Jump to: navigation, search


NXP Partner Program Registered Vertical.jpg NXP Partner Program Horizontal.jpg
Previous: iMX8MEVK/Getting Started/Software Support Index Next: iMX8EVK/Yocto





Yocto Images

Prebuilt images are .sdcard files, disk images that can be flashed directly to any SD card. These .sdcard files are the simplest way to evaluate the board and Linux features since they easily flash all the required components to boot the iMX8M EVK.

The .sdcard file includes the 4 elements required to boot the board:

  • Bootloader
  • Linux kernel image
  • Device tree
  • Root file system

You can get the prebuilt images from the latest Linux BSP. You need to decompress the BSP and decompress the bz2 image sdcard included in it.

For BSP L4.9.88_2.0.0 run:

##
## BSP and IMAGE_NAME in the example may not match exactly your BSP version. 
## Please make sure you set them accordingly.
##

 BSP=L4.9.88_2.0.0_images_MX8MQ
 tar -xvf $BSP.tar.gz
 cd $BSP

 IMAGE_NAME=fsl-image-qt5-validation-imx-xwayland-imx8mqevk
 bunzip2 -dk -f  $IMAGE_NAME.sdcard.bz2

Write the image to the SD Card

DEVICE=/dev/sdX # The device may change in your system
sudo dd if=$IMAGE_NAME.sdcard of=$DEVICE bs=4M && sync

Android Images

This section describes the boot process of loading the i.MX8MQuad EVK board with an Embedded Android system image and introduces how to build the software components that create your own system image. For more information refer to the Android User Guide.

Image Storage

The storage devices on the development system (MMC/SD or NAND) must be programmed with the U-Boot boot loader. The boot process determines which storage device to access based on the switch settings. When the boot loader is loaded and begins execution, the U-Boot environment space is then read to determine how to proceed with the boot process.

Get NXP Android BSP Image

The pre-built images from the package are categorized by the boot device and put in the directory with the device name. You can get the pre-built images from the latest Linux BSP. You need to decompress the BSP and decompress the bz2 image sdcard included in it.

Loading images onto an SD Card

Partition the SD card

The images are inside the downloaded BSP tarball called <package_name>. Let's consider the tarball content is uncompressed in a folder called MY_ANDROID by running the following command:

tar -xvf <package_name>

IMPORTANT: The minimum SD card size required is 8 GB.

NOTE: Unmount all the SD card partitions before running any script inside the aforementioned folder:

umount /dev/<device>

Where the device can be recognized as one of the following options by the host machine:

  • sdX
  • mmcblkX
  • Other

With X the disk index from 'a' to 'z'. We have modified the original script in order to support any name the host computer assign to the SD card device. Such modified script can be obtained from this page.

Once you have the pre-built images and the new version of the script, you are able to partition an SD card:

cd ${MY_ANDROID}/

sudo ./fsl-sdcard-partition-rr.sh -f imx8mq -c <size_parameter> /dev/<device>

Where the <size_parameter> should be selected from the table below.

SD Card Size Size Parameter
8GB 7
16GB 14
32GB 28

Make sure you have the images required by the fsl-sdcard-partition.sh script are present inside the MY_ANDROID folder. The scripts could be the following: boot-loader, boot image, system image, recovery image, GPT table image, and vendor image. This script requires to install the simg2img tool on the computer. simg2img is a tool that converts the sparse system image to raw system image on the Linux OS host computer. The android-toolsfsutils package includes the simg2img command for Ubuntu Linux OS. If you don't have simg2img in your host machine, install it as follows:

sudo apt install android-tools-fsutils


Previous: iMX8MEVK/Getting Started/Software Support Index Next: iMX8EVK/Yocto