iMX8MP-COMPACT-CM U-Boot
Overview
The U-Boot bootloader is used for low-level initialization and operating system loading.
Setting Boot mode
BOOT | J4:1-2 | J4:3-4 | J4:5-6 | J4:7-8 |
---|---|---|---|---|
Cortex-A53 Serial Downloader | close | open | open | open |
Cortex-A53, eMMC | open | close | open | open |
Terminal Setup
The carrier board connects the host PC using the micro-B USB connector (J6).
Common serial communication programs such as Minicom, HyperTerminal, Tera Term, or PuTTY can be used.
The iMX8MP-COMPACT-CM board uses the second port for the Arm Cortex-A cores console.
Building U-BOOT for iMX8MP-COMPACT-CM
This U-BOOT is based on https://github.com/nxp-imx/uboot-imx, branch lf_v2023.04
Set up the cross-compiler and CPU architecture
$ export ARCH=arm64 $ export CROSS_COMPILE=/opt/cross/aarch64-ronetix-linux-11.1/bin/aarch64-ronetix-linux-gnu-
A cross-compiler can be downloaded from here: http://download.ronetix.at/toolchains/crosstool-ng
Clone the latest revision of the repo
$ git clone https://github.com/ronetix/u-boot.git uboot-imx --depth=1 -b lf_v2023.04 $ cd uboot-imx
Configure
$ make imx8mp_cm_defconfig
Build
$ make
Create IMX image
Create a new Firmware package flash.bin that contains SPL, U-Boot, Arm Trusted Firmware, Sentinel
Firmware, DDR PHY Firmware.
$ source ./tools/imx_build_firmware.sh imx8mp
Build Results
File Name | Description |
---|---|
u-boot | U-BOOT ELF image used for JTAG debugging |
u-boot-dtb.bin | U-BOOT image with DTB |
./imx-mkimage/iMX8M/flash.bin | IMX bootloader |
Programming the IMX image
This section describes how to write the bootloader into the eMMC using UUU.
Universal update utility
The Universal Update Utility (UUU) runs on a Windows or Linux OS host and is used to download images to devices on an i.MX board.
Downloading UUU
Download UUU version 1.5.21 or later from https://github.com/nxp-imx/mfgtools/releases
Connect USB ports
Follow the instructions below:
- Connect a USB cable from a computer to the J7, port USB-3 (Type C) port on the carrier board for download link.
- Connect a USB cable from J6, port UART-DBG (Micro-AB) port to the computer for console output.
- Open a Terminal emulator program
- Set the boot mode to "Cortex-A53 Serial Downloader", see #Setting Boot mode
Write flash.bin into eMMC
$ cd ./imx-mkimage/iMX8M $ wget http://download.ronetix.at/boards/doc/i.MX8MP-COMPACT-CM/tools/u-boot.uuu $ uuu u-boot.uuu
See also