Imx uuu: Difference between revisions

From Variscite Wiki
No edit summary
No edit summary
Line 2: Line 2:
--> {{#vardefine:RELEASE_PARAM|{{#urlget:release}}}} <!--
--> {{#vardefine:RELEASE_PARAM|{{#urlget:release}}}} <!--
--> {{#lst:Yocto_Platform_Customization|{{#var:RELEASE_PARAM|RELEASE_SUMO_V2.1_DART-MX8M}}}} <!--
--> {{#lst:Yocto_Platform_Customization|{{#var:RELEASE_PARAM|RELEASE_SUMO_V2.1_DART-MX8M}}}} <!--
--> {{PageHeader|Booting from USB using UUU utility}} {{DocImage|category1={{#var:HARDWARE_NAME}}|category2=Yocto}} __toc__
--> {{PageHeader|Booting from USB using uuu (Universal Update Utility)}} {{DocImage|category1={{#var:HARDWARE_NAME}}|category2=Yocto}} __toc__
= Introduction =
= Introduction =


UUU is an open source utility by NXP that allows downloading and executing code on NXP i.MX6/i.MX7/i.MX8 SoCs through the Serial Download Protocol (SDP).<br>
uuu (Universal Update Utility) is an open source utility by NXP that allows downloading and executing code on NXP i.MX6/i.MX7/i.MX8 SoCs through the Serial Download Protocol (SDP).<br>
It is the next generation of NXP's MFGTOOL used to load SPL and U-Boot via the USB OTG port and optionally program the internal storage of the SOM.<br>
It is the next generation of NXP's MFGTOOL used to load SPL and U-Boot via the USB OTG port and optionally program the internal storage of the SOM.<br>
For more details please visit https://github.com/NXPmicro/mfgtools<br>
For more details please visit https://github.com/NXPmicro/mfgtools<br>
Line 15: Line 15:


= Step by step usage instructions =
= Step by step usage instructions =
'''Download and build the UUU utility''':<br>
'''Download and build uuu''':<br>
<pre>
<pre>
$ sudo apt-get install libusb-1.0-0-dev libzip-dev libbz2-dev pkg-config cmake
$ sudo apt-get install libusb-1.0-0-dev libzip-dev libbz2-dev pkg-config cmake
Line 27: Line 27:
'''Build U-Boot''':<br>
'''Build U-Boot''':<br>
* Build U-Boot using the defconfig for SD card/eMMC. You can follow the "Build U-Boot from source code" instructions {{Varlink|Yocto_Build_U-Boot|{{#var:RELEASE_LINK}}|here}}.<br>
* Build U-Boot using the defconfig for SD card/eMMC. You can follow the "Build U-Boot from source code" instructions {{Varlink|Yocto_Build_U-Boot|{{#var:RELEASE_LINK}}|here}}.<br>
* Copy the U-Boot image to uuu directory:
* Copy the U-Boot image to the uuu directory:


  $ cp -v {{#var:U-BOOT_SD_IMAGE_NAME}} ~/mfgtools/uuu
  $ cp -v {{#var:U-BOOT_SD_IMAGE_NAME}} ~/mfgtools/uuu

Revision as of 18:30, 5 February 2020

Booting from USB using uuu (Universal Update Utility)

Introduction

uuu (Universal Update Utility) is an open source utility by NXP that allows downloading and executing code on NXP i.MX6/i.MX7/i.MX8 SoCs through the Serial Download Protocol (SDP).
It is the next generation of NXP's MFGTOOL used to load SPL and U-Boot via the USB OTG port and optionally program the internal storage of the SOM.
For more details please visit https://github.com/NXPmicro/mfgtools

Note:
All Variscite SOMs are shipped with U-Boot pre-programmed on the internal storage.
In addition, all Variscite carrier boards have an SD card slot, and even in the unlikely event of the U-Boot being erased from the internal storage, the SOM can always be booted from an SD card (like our recovery SD card, for example).
This utility can be used to program full software image to internal storage when SD and network boot options are not available.

Step by step usage instructions

Download and build uuu:

$ sudo apt-get install libusb-1.0-0-dev libzip-dev libbz2-dev pkg-config cmake
$ cd ~
$ git clone https://github.com/NXPmicro/mfgtools.git
$ cd mfgtools
$ cmake .
$ make

Build U-Boot:

  • Build U-Boot using the defconfig for SD card/eMMC. You can follow the "Build U-Boot from source code" instructions here.
  • Copy the U-Boot image to the uuu directory:
$ cp -v imx-boot-sd.bin ~/mfgtools/uuu
$ cd ~/mfgtools/uuu 
$ ln -fs imx-boot-sd.bin _flash.bin

Boot the board into serial download mode:

  • Set the board boot mode to SD card, while not having an actual card inserted in its slot.
  • Alternatively, set the board boot mode to eMMC/NAND flash, when the eMMC/NAND flash does not contain a bootloader.
  • Connect the board to your host PC via the USB OTG port, and power on the board.
  • Make sure the board is recognized on the host by running lsusb command and looking for the following output:
Bus 001 Device 021: ID 1fc9:013e NXP Semiconductors


Note:
If your board only has a regular USB type-A connector and doesn't have a USB Micro-AB or Type-C receptacle, you can use a "male USB type-A to male USB type-A" cable

Run uuu to load U-Boot on the board:

 $ sudo ./uuu ./spl_boot.lst

The board should now run U-Boot.
You can see its output on the console via the debug port, as always.

Note:
The default boot command when booting from USB is bootcmd_mfg. It is defined in the board's default environment.
By default it runs fastboot but can be redefined or made empty.