Reduce Turnaround Time For Device Tree Changes

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Reduce Turnaround Time For Device Tree Changes

1,749 Views
david_ochs1
Contributor III

I'm doing some development on an i.MX8M Mini EVK, and I am looking for some advice on how to change and load the device tree efficiently. I am using Yocto to build the fsl-image-validation-imx image, and flashing emmc by passing a zip file to uuu, as described in the NXP documentation.

Presently when I want to change the device tree, I change the fsl-imx8mm-evk.dts file, run bitbake -f -c compile linux-imx, and the dtb files called out in the machine conf file are regenerated in about a minute. Then I run bitbake fsl-image-validation-imx, when does its thing in about 30 minutes or so. Then I extract the .sdcard.bz2 image file that was generated, zip the entire images/imx8mmevk directory with uuu.auto in it, and flash the EVK with uuu. This whole process takes somewhere around 40 minutes, which adds up when I'm making iterative changes to the device tree.

I found these instructions on how to change the device tree at runtime, but I couldn't find the dtb on the i.MX8M Mini to run the commands on.

Any advice on how to make these sort of changes more efficiently would be greatly appreciated!

Thanks,

Dave

0 Kudos
7 Replies

1,545 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hi Dave,

    For your purpose, I feel it is better choice to build u-boot and kernel in standalone mode.  You can refer to :

1. "i.MX_Porting_Guide.pdf" in linux BSP documents.

or

2. https://community.nxp.com/docs/DOC-343273 

For rootfs, you can build it in Yocto, probably you only need to build it for one time.

Have a nice day!

BR,

Weidong

1,545 Views
david_ochs1
Contributor III

Hi Weidong,

Thanks for the advice; I can successfully build the kernel, dtb, and u-boot in standalone mode. How, then, should I go about loading them onto the board? Should I use uuu? I looked through the uuu wiki, but nothing seemed like a clear direction for this. I also see instructions in the porting guide to use dd, but I'm confused by the of=/dev/sd<partition> parts - how do I know what do put there?

Best,

Dave

0 Kudos

1,545 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hello David,

 Actually, for i.MX8MQ and i.MX8M MINI, MFG TOOLS are both OK.

 Presently uuu is recommended, if you are not familiar with it, don't worry,  you can read uuu.pdf, which has described how to use uuu clearly. Read it carefully, and try several times.

0 Kudos

1,545 Views
david_ochs1
Contributor III

I'm having a hard time reconciling the UUU documentation with what I built in the standalone environment. As I followed your instructions to built dtb, kernel, and u-boot, the build products were a dtb file, and image files for the kernel and u-boot (correct?). The UUU documentation shows instructions for flashing eMMC with a flash.bin file, which I don't see as a build product. An example would be really helpful here!

Thanks,

Dave

0 Kudos

1,545 Views
weidong_sun
NXP TechSupport
NXP TechSupport

 Hi David,

     This is a documen I wrote, there are some steps on using uuu to download images to eMMC on board. read it please! and open "uuu_imx_android_flash.bat" file, you will find how uuu runs.

https://community.nxp.com/docs/DOC-342719 

In addition, on how to use uuu tools, you can create a new case on community for it. We can focus on handling one question in one case.

Have a nice day!

BR,

Weidong

0 Kudos

1,545 Views
david_ochs1
Contributor III

HI Weidong,

That document doesn't seem very applicable to my problem. It seems to be instructions for how to load a prebuilt image using a certain script that (uuu_imx_android_flash.bat) don't have, and I don't have any documentation for. To reiterate: I'm looking for a way to load a kernel image and dtb file without having to run bitbake <image> and flash the entire .sdcard file again. I am using Ubuntu as my host system.

Thanks,

Dave

0 Kudos

1,545 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hello David,

   OK, you can download the file on the link:

Android OS for i.MX Applications Processors | NXP 

----P9.0.0_1.0.0_GA_TOOL

After decompressing it, you can find it.

pastedImage_3.png

Instrustions in the script can help you understand hwo uuu works.

Have a nice day!

Weidong

0 Kudos