UUU - Universal Update Utility

The Universal Update Utility is used to program your board.

We actually can use uuu to flash most of our products.

For i.MX6 based modules (TX6 and TXUL series) please continue to use MFGTool.

Getting uuu

Get the latest stable file uuu (for Linux) or uuu.exe (for Windows) from NXP’s official repository: https://github.com/NXPmicro/mfgtools/releases

udev Rules

Note

This is relevant for LINUX users only.

There’s no need to call uuu as sudo. Just update your udev rules as follows.
Running uuu -udev will output a list of ‘udev’ rules that will allow access to any logged in non-privileged user.
Put those rules into /etc/udev/rules.d/70-uuu.rules. This can be achieved running the following two commands:

sudo sh -c "uuu -udev >> /etc/udev/rules.d/70-uuu.rules"
sudo udevadm control --reload

STM32 based Modules

Since STM32 based modules (QSMP/TXMP) appear with an unknown VID/PID, you have to add it to uuu’s udev rules manually.

Add this line to: /etc/udev/rules.d/70-uuu.rules. Don’t forget to reload udev rules - mentioned above.

SUBSYSTEM=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="0afb", MODE="0666" #STM32

Usage

UUU uses the android fastboot protocol. The usual way to flash our modules is to start the mfg-uboot, write the default u-boot into eMMC and then flash the Boot-partition and Rootfs as filesystem image.

Tip

You can use pre-compiled images and scripts from our Customer Area or your own Yocto built images.

Running uuu

On Windows 10 or Linux uuu will work fine. For Windows 7 see Running UUU on Windows 7.

  1. Put the bootmode jumper in place (for Help see Enabling USB-Bootmode) and connect your module via OTG-programming port of the baseboard.
  2. Get terminal access. If you need help for this see TTL Converter Terminal Connection.
  1. Open a command line inside the folder where uuu is and run the following command to use the before created script:
uuu -v <script-file>

Tip

Inside your terminal you should now see progress and information while uuu is programming your module.

UUU with Custom Files

Creating Filesystems

For e.g. the /boot partition you can create your own filesystem image. The example below gives you an idea how this is done.

It also shows, how existing filesystem images can be mounted.

dd if=/dev/zero of=bootfs.fat bs=1M count=0 seek=32
mkfs -t vfat bootfs.fat
sudo mount -o loop bootfs.fat /mnt/temp/
sudo cp Image imx8mn-tx8m-nd00-mipi-mb.dtb /mnt/temp/
sudo umount /mnt/temp

Script Examples [1]

Hint

Some commands differ depending on the module you are using.

Module Loading bootloader command-set Comments
tx8m-1610
SDP: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
 
tx8m-1620
SDP: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
 
tx8m-nd00
SDPS: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
See Note below
tx8p-ml81
SDPS: boot -f <mfg-uboot>
 
tx8p-ml82
SDPS: boot -f <mfg-uboot>
 
qsxp-ml81
SDPS: boot -f <mfg-uboot>
 
qsxm-mm60
SDP: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
 
qs8m-mq00
SDP: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
 
qs8m-nd00
SDPS: boot -f <mfg-uboot>
SDPV: write -f <mfg-boot> -skipspl
SDPV: jump
See Note below

Note

UUU has a problem reconnecting to i.MX8MNano devices after the first boot stage, resulting in a “libusb TIMEOUT” error. After this just run uuu again and it will work. You may also start uuu in Daemon mode (Option -d) to get around this problem.

Flashing U-Boot to eMMC

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
uuu_version 1.4.77

#
# author: Markus Bauer <mb@karo-electronics.de>
# (c) 2019
#
# This file flashes default u-boot to your TX8M-ND00

### boot uboot with fastboot support
SDPS: boot -f imx-boot-karo-mfg
SDPV: write -f imx-boot-karo-mfg -skipspl
SDPV: jump

### Writing default u-boot to emmc
FB: ucmd setenv fastboot_dev mmc
FB: ucmd mmc dev ${emmc_dev}
FB: flash bootloader imx-boot-karo-default
FB: ucmd mmc partconf ${emmc_dev} ${emmc_boot_ack} ${emmc_boot_part} 0

FB: continue
FB: done

Flashing filesystems

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
uuu_version 1.4.77

#
# author: Markus Bauer <mb@karo-electronics.de>
# (c) 2019
#
# This file flashes desktop release (QT from Yocto) and bootfs to your TX8M

### Boot our uboot with fastboot support
SDPS: boot -f imx-boot-karo-mfg
SDPV: write -f imx-boot-karo-mfg -skipspl
SDPV: jump

### GPT partition layout
#
# 32M /boot
# MAX /
FB: ucmd setenv partitions 'uuid_disk=${uuid_gpt_disk};name=boot,size=32M,start=1MiB,uuid=${uuid_boot};name=rootfs,size=MAX,uuid=0cc66cc0-5458-384d-1610-726f6f746673;'
FB: ucmd gpt write mmc 0 ${partitions}

### force re-read partition table
FB: ucmd setenv fastboot_dev sata
FB: ucmd setenv fastboot_dev mmc

### Flashing partitions
FB: flash boot bootfs.fat
FB: flash -raw2sparse rootfs fsl-image-qt5.rootfs.ext4

FB: continue
FB: done

Note

Run man fastboot on your host to see which possibilities you have with FB: command in uuu.

Importing environment

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
uuu_version 1.0.1

#
# author: Markus Bauer <mb@karo-electronics.de>
# (c) 2019
#
# This file imports u-boot environment file.
# The entries into the file look like:
#
# append_bootargs=quiet
# {variable}={value}
# ...
#
# The file has to end with a ZERO byte.

### Boot our uboot with fastboot support
SDPS: boot -f imx-boot-karo-mfg
SDPV: write -f imx-boot-karo-default -skipspl
SDPV: jump

### Importing u-boot environment
FB: ucmd setenv fastboot_buffer ${loadaddr}
FB: download -f emmc-boot.env
# -t: text -r: support <CRLF> line delimiters -d: delete existing env
FB: ucmd env import -trd ${loadaddr}
FB: ucmd printenv
FB: ucmd saveenv

FB: done
[1]Further information about uuu, and the official documentation can be found in uuu.pdf