This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM62A7: Methods and tools for quickly batch programming eMMC

Part Number: AM62A7

Tool/software:

Hello TI experts,

We are currently using the DFU tool for programming eMMC, which requires us to interactively input multiple commands through a virtual machine and serial interface. This process is quite cumbersome, and if we need to perform batch programming for eMMC, this method is very inefficient.

We would like to inquire if there are any methods or tools available for quickly and efficiently batch programming eMMC.

Thank you for your assistance.

Best Regards,

Kangbai Li

  • Hello,

    We would like to inquire if there are any methods or tools available for quickly and efficiently batch programming eMMC.

    Please see the following guide for flashing via DFU:

    https://software-dl.ti.com/processor-sdk-linux/esd/AM62AX/10_01_00/exports/docs/linux/Foundational_Components/Tools/Flash_via_DFU.html

    Regards,

    Prashant

  • Dear [Recipient's Name],

    I have followed the method outlined in the link, and I am currently able to perform eMMC flashing; however, the board fails to boot. The file serial output.txt is the serial output, and the Ubuntu output is as shown in the attached image.

    The content of the flash-files.cfg is set as shown in the other attached image.

    We are using the am62a7 board and have employed the hsfs method for flashing.

    I would like to ask for your assistance with the following questions:

    1. How should I set the value for flash-offset in the flash-files.cfg file? Does it need to be adjusted based on the size of the flashing file?

    2. If I need to format the eMMC into two partitions, boot and rootfs, where should the corresponding commands be placed? Should these commands be included in the uEnv.txt file? If so, how can I add these commands to the uEnv.txt file?

    3. If my eMMC is set up as two partitions, how should the attributes property in the flash-files.cfg file be configured?

    Thank you for your help!

    Best regards,

    Kangbai Li

    U-Boot SPL 2024.04-ti-dirty (Apr 29 2025 - 09:31:28 +0800)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.1.8--v10.01.08 (Fiery Fox)')
    SPL initial stack usage: 13568 bytes
    Trying to boot from DFU
    ########################################################################DOWNLOAD ... OK
    Ctrl+C to exit ...
    Authentication passed
    Authentication passed
    Authentication passed
    Loading Environment from nowhere... OK
    init_env from device 10 not supported!
    Authentication passed
    Authentication passed
    Starting ATF on ARM64 core...
    
    NOTICE:  BL31: v2.11.0(release):v2.11.0-906-g58b25570c9-dirty
    NOTICE:  BL31: Built : 04:20:32, Nov  1 2024
    
    U-Boot SPL 2024.04-ti-dirty (Apr 29 2025 - 09:30:27 +0800)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.1.8--v10.01.08 (Fiery Fox)')
    Trying to boot from DFU
    #####DOWNLOAD ... OK
    Ctrl+C to exit ...
    Authentication passed
    Authentication passed
    
    
    U-Boot 2024.04-ti-dirty (Apr 29 2025 - 09:30:27 +0800)
    
    SoC:   AM62AX SR1.0 HS-FS
    Model: Texas Instruments AM62A7 SK
    DRAM:  2 GiB (effective 4 GiB)
    Core:  81 devices, 29 uclasses, devicetree: separate
    MMC:   mmc@fa10000: 0, mmc@fa00000: 1
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Net:   eth0: ethernet@8000000port@1
    Hit any key to stop autoboot:  0
    generic_phy_get_bulk : no phys property
    #DOWNLOAD ... OK
    Ctrl+C to exit ...
    ## Info: input data size = 175 = 0xAF
    generic_phy_get_bulk : no phys property
    ##DOWNLOAD ... OK
    Ctrl+C to exit ...
    ######DOWNLOAD ... OK
    Ctrl+C to exit ...
    #####DOWNLOAD ... OK
    Ctrl+C to exit ...
    ################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################DOWNLOAD ... OK
    Ctrl+C to exit ...
    
    U-Boot SPL 2024.04-ti-dirty (Apr 29 2025 - 09:31:28 +0800)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.1.8--v10.01.08 (Fiery Fox)')
    SPL initial stack usage: 13568 bytes
    SPL: failed to boot from all boot devices
    ### ERROR ### Please RESET the board ###
    

  • I will get back to you by today EOD.

  • How should I set the value for flash-offset in the flash-files.cfg file? Does it need to be adjusted based on the size of the flashing file?

    The "flash-offset" values comes from the offset set in the U-Boot source code. In case you have not modified the offsets in the source code, you don't need to modify the default "flash-offset" values.

    If I need to format the eMMC into two partitions, boot and rootfs, where should the corresponding commands be placed? Should these commands be included in the uEnv.txt file? If so, how can I add these commands to the uEnv.txt file?

    You may modify the following variable to add your own commands to partition the eMMC as required.

    https://git.ti.com/cgit/processor-sdk/uboot-flash-writer/tree/tools/DFU_flash/src/constants.py#n6

    If my eMMC is set up as two partitions, how should the attributes property in the flash-files.cfg file be configured?

    Please see:

    git.ti.com/.../constants.py

  • The flash-files.cfg file and the emmc partition are set as follows,

    but when I burn it, I get an error, as shown in the figure below,

    and from the printing it seems that hwpart represents an MMC device. Also, when I change the value of attributes to attributes="part,0,2", the tisdk-tiny-image3.img file can be burned normally, but the board still can't be started from emmmc.

    Thank for your help.

  • Hi Prashant,

    May I know if there is any update for above question? Thanks

  • Hello,

    and the Ubuntu output is as shown in the attached image.

    I see you have flashed the images from the path "bin/am62axx-evm/hsfs". These are just images curated for flashing any given binaries over DFU and so these cannot be flashed and used for normal booting purposes.

    Please build your own U-Boot images from the SDK and flash those.

    BR, Prashant

  • Hi Prashant,

    I have replaced the original files in the /mnt/hgfs/share/uboot-flash-writer/tools/DFU_flash/bin/am62axx-evm/hsfs/ directories with the tiboot3.bin, tispl.bin, and u-boot.img files generated by the compiled SDK, and I am sure that the tiboot3.bin tispl.bin, and u-boot.img files I generated are correct.

    Additionally, I have a question. As shown in the image below from the Ubuntu virtual machine printout, did the tiboot3.bin tispl.bin, and u-boot.img files all get programmed twice?

    Thank you for your help!

    Best regards,

    Kangbai Li

  • Hello,

    The flashing procedure involves two steps:

    Step1: Boot to A53 U-Boot over DFU.

    Step2: Send the U-Boot or any other binaries over DFU for them to be flashed by the booted A53 U-Boot.

    The U-Boot images in Step1 are supposed to be different from the Step2 as the former ones are specifically built with the DFU support.

    Regards,

    Prashant

  • Hi,

    We can successfully flash the eMMC using DFU, but the system fails to boot normally from the eMMC, with the error message shown in the figure below. 

    Additionally, the image displays the content of the flash-files.cfg file.

    Thank you for your help!

    Best regards,

    Kangbai Li

  • Since you have flashed the rootfs to the 2nd partition, you would have to use the following commands to boot the Kernel from eMMC:

    => setenv mmcdev 0
    => setenv bootpart 0:2
    => boot