How to flash uboot binary on iMX8MQ eMMC using dd command

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

How to flash uboot binary on iMX8MQ eMMC using dd command

6,271 Views
haseeb_ashraf
Contributor I

I was able to flash the imx8mq uboot binary with uuu but I need to know the equivalent dd command to flash uboot binary to emmc.

I successfully flashed uboot environment on emmc with the following command

dd if=u-boot.env of=/dev/mmcblk0 bs=1k seek=4096 conv=fsync (the offset is same as sd-card)

but couldn't flash uboot binary with following dd commands (using same offset as for sd-card)

dd if=imx-boot-imx8mqevk-mel-emmc.bin of=/dev/mmcblk0 bs=1k seek=33 conv=fsync

dd if=imx-boot-imx8mqevk-mel-emmc.bin of=/dev/mmcblk0 bs=512 seek=66 conv=fsync

Though I was able to flash the same binary with uuu.

Is there a different offset for emmc ?

Tags (4)
0 Kudos
4 Replies

5,540 Views
BiyongSUN
NXP Employee
NXP Employee

Each and every  binary BSP release contains the example for using Linux mode to flash the board. 

Please check the  <binary releas>/samples/example_kernel_emmc.uuu

 

Untitled.png

5,549 Views
thomasnam
Contributor II

Hello,
I'm working with iMX8MQ EVK board to make a product.

I need to program the flash.bin to eMMC by itself, so I need to know the equivalent method to dd command to flash bootloader binary to the eMMC.
The method in the kernel mode is better but U-Boot mode also good.

I think UUU can't self-programming.
I can flash the bootloader to SD card with dd command, but it is not working to the eMMC.
All documents describe how to program to SD/MMC card but the eMMC programming method is only the UUU.

Please guide me.

Tags (4)
0 Kudos

5,789 Views
vinothkumars
Senior Contributor IV

Hi @haseeb_ashraf 

 

Did you find the solution 

 

 

Regards,
Vinothkumar Sekar
0 Kudos

6,092 Views
joanxie
NXP TechSupport
NXP TechSupport

refer to the user guide, $ sudo dd if= of=/dev/sdx bs=1k seek= conv=fsync Where offset is: • 1 - for i.MX 6 or i.MX 7 • 33 - for i.MX 8QuadMax A0, i.MX 8QuadXPlus A0, i.MX 8M Quad, and i.MX 8M Mini • 32 - for i.MX 8QuadXPlus B0 and i.MX 8QuadMax B0 The first 16 KB of the SD/MMC card, which includes the partition table, is reserved. you also can refer to the 4.3.3 Partitioning the SD/MMC card of enclose file, don't forget fdisk your emmc

0 Kudos