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.

Compiler/TDA3: How to flash program using UART in Win7

Part Number: TDA3

Tool/software: TI C/C++ Compiler

Hello,

I'm developing TDA3x in the environment of Windows 7.

I'd like to flash bin file to qspi using UART, but the mflash tool for that is only supporting Window 10.

Can I have the tool for the version of Window 7 if you have?

Or is there any other way to flash w/ UART besides mflash?

Thank you.

Kevin

  • Hi Kevin,

    Did you try to run this tool on Windows 7?

    Regards,
    Rishabh
  • Hi Rishabh,

    I already tried it because sometimes the execution files for Win10 run well in Win7.

    But in this time, mflash doesn't work. When I run it, the windows error message occurs - "No libgcc_s_dw2-1.dll. Please Install program again".

    The message may be different from the original because I translated Korean into English.

    If you have any solution, please let me know.

    Kevin

  • Kevin,

    Unfortunately we don't have Windows 7 PC and hence won't to validate this.
    I searched this dll on my PC and it is part of compiler.
    Multiple solutions popped up when I searched internet for string "libgcc_s_dw2-1.dll".
    Maybe you can do the same.

    Regards,
    Rishabh
  • I downloaded the dll file in the internet.

    and then I run the batch file and the results are like the below and stopped.

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_mflash="sbl_mflash_tda2ex-evm"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET board="tda2exevm"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET appimage_location="AppImage_BE"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET appimage_offset="0x80000"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_location="sbl"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_offset="0x00"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET uart_port_number="34"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>ECHO 15:23:34.80

    15:23:34.80

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>mflash -S "tda2exevm" -M "sbl_mflash_tda2ex-evm" -P "34" -F "AppImage_BE" "0x80000" -F "sbl" "0x00" -C

    Usage: mflash -M <sbl_mflash> -P <Port Number> -C [optional: to clean the QSPI Flash]-F <fileName> <offset> -F <fileName> <offset> ... [PC] sbl_mflash sbl_mflash_tda2ex-evm

    [PC] File 0 AppImage_BE

    [PC] Offset 0 0x80000

    [PC] File 1 sbl

    [PC] Offset 1 0x00

    [PC] com \\.\COM34

    [PC] ##########Starting USB/UART Flasing Utility##############

    [PC] Put UART Boot Mode, make fresh UART connection & restart

    [PC] Press Enter when done...

        Baud     = 0

        Parity   = 0

        StopBits = 0

        ByteSize = 0[PC] Opening serial port successful.

    mflash_run_config.bat is like the below:

    SET sbl_mflash="sbl_mflash_tda3ex-evm"

    SET board="tda3exevm"

    SET appimage_location="AppImage_BE"

    SET appimage_offset="0x80000"

    SET sbl_location="sbl"

    SET sbl_offset="0x00"

    SET uart_port_number="5"

    ECHO %time%

    mflash -S %board% -M %sbl_mflash% -P %uart_port_number% -F %appimage_location% %appimage_offset% -F %sbl_location% %sbl_offset% -C

     

    I can see the "AL!" in the serial terminal.

    What do you think about the problem?

    Thank you.

    Kevin

  • I modified the board type like the below:

    SET sbl_mflash="sbl_mflash_tda3xx-evm"
    SET board="tda3xx-evm"
    SET appimage_location="AppImage_BE"
    SET appimage_offset="0x80000"
    SET sbl_location="sbl"
    SET sbl_offset="0x00"
    SET uart_port_number="5"
    ECHO %time%
    mflash -S %board% -M %sbl_mflash% -P %uart_port_number% -F %appimage_location% %appimage_offset% -F %sbl_location% %sbl_offset% -C


    and then the message like the below:
    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>mflash -S "tda3xx-evm" -M "sbl_mflash_tda3xx-evm" -P "5" -F "AppImage_BE" "0x80000" -F "sbl" "0x00" -C
    Usage: mflash -M <sbl_mflash> -P <Port Number> -C [optional: to clean the QSPI F
    lash]-F <fileName> <offset> -F <fileName> <offset> ... Invalid BOARD type. Exiting


    What do I have to write down the board type, please?

    Kevin
  • Kevin,

    You should set board to "tda3xxevm".

    Regards,
    Rishabh
  • Kevin,

    Let me know if you face any further issues.

    Regards,
    Rishabh
  • Thank you, Rishabh.

    But I still have problem.
    This is the configuring file that I modified.

    ---------------------------------------------------------------------------
    SET sbl_mflash="sbl_mflash_tda3xx-evm"
    SET board="tda3xxevm"
    SET appimage_location="AppImage_BE"
    SET appimage_offset="0x80000"
    SET sbl_location="sbl"
    SET sbl_offset="0x00"
    SET uart_port_number="5"
    ECHO %time%
    mflash -S %board% -M %sbl_mflash% -P %uart_port_number% -F %appimage_location% %appimage_offset% -F %sbl_location% %sbl_offset% -C
    ---------------------------------------------------------------------------

    But the results are like this:
    ---------------------------------------------------------------------------
    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_mflash="sbl_mflash_tda3xx-evm"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET board="tda3xxevm"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET appimage_location="AppImage_BE"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET appimage_offset="0x80000"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_location="sbl"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET sbl_offset="0x00"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>SET uart_port_number="5"

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>ECHO 15:38:54.86
    15:38:54.86

    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packages\ti\boot\sbl_auto\tools\mflash>mflash -S "tda3xxevm" -M "sbl_mflash_tda3xx-evm" -P "5" -F "AppImage_BE" "0x80000" -F "sbl" "0x00" -C
    Usage: mflash -M <sbl_mflash> -P <Port Number> -C [optional: to clean the QSPI F
    lash]-F <fileName> <offset> -F <fileName> <offset> ... [PC] sbl_mflash sbl_mflas
    h_tda3xx-evm
    [PC] File 0 AppImage_BE
    [PC] Offset 0 0x80000
    [PC] File 1 sbl
    [PC] Offset 1 0x00
    [PC] com \\.\COM5
    [PC] ##########Starting USB/UART Flasing Utility##############
    [PC] Put UART Boot Mode, make fresh UART connection & restart
    [PC] Press Enter when done...

    Baud = 0
    Parity = 0
    StopBits = 0
    ByteSize = 0[PC] Opening serial port successful.
    ---------------------------------------------------------------------------
    And then there is no progress..
    Do I have to do something else more?

    Thank you.
    Kevin
  • Hi Kevin,

    Does the same work for you on a Windows 10 machine? I am not sure why you are getting Baud rate as 0.
    Maybe there is some issue with library itself.

    Regards,
    Rishabh
  • Rishabh,

    I have no computer with Windows 10.
    That's why I'm trying this in Windows 7.
    I can see "AL!" in "COM5" of TeraTerm.
    So it's weird.
    I'm wondering if mflash really doesn't work in Windows 7?
    And I'm wondering if I have to use JTAG for flashing in my environment.

    Thank you.
    Kevin
  • Hi Kevin,

    If you have JTAG then you can use the qspi_flash_writer instead of mflash.

    Regards,
    Rishabh
  • Hi Rishabh,

    I'm supporting Kevin, and do you think it would be helpful to build 'mflash' tool again in Kevin's PC environment?


    Thanks and Best Regards,
    SI.
  • Hi SI,

    It could be an issue with port number as Kevin is getting UART serial port configuration as 0.

    Regards,
    Rishabh
  • Hi Rishabh,

    I succeeded a little bit more.
    The reason I got the wrong baudrate and port number was because I kept connecting terminal program.
    When I disconnected the terminal program, I can see the following messages.
    I'm sorry about that, but it's not solved yet.

    -----------------------------------------
    C:\PROCESSOR_SDK_VISION_03_05_00_00\ti_components\drivers\pdk_01_10_01_06\packag
    es\ti\boot\sbl_auto\tools\mflash>mflash -S "tda3xxevm" -M "sbl_mflash_tda3xx-evm
    " -P "5" -F "AppImage_BE" "0x80000" -F "sbl" "0x00" -C
    Usage: mflash -M <sbl_mflash> -P <Port Number> -C [optional: to clean the QSPI F
    lash]-F <fileName> <offset> -F <fileName> <offset> ... [PC] sbl_mflash sbl_mflas
    h_tda3xx-evm
    [PC] File 0 AppImage_BE
    [PC] Offset 0 0x80000
    [PC] File 1 sbl
    [PC] Offset 1 0x00
    [PC] com \\.\COM5
    [PC] ##########Starting USB/UART Flasing Utility##############
    [PC] Put UART Boot Mode, make fresh UART connection & restart
    [PC] Press Enter when done...

    Baud = 115200
    Parity = 2
    StopBits = 0
    ByteSize = 8[PC] Opening serial port successful.
    [RBL]4 [RBL]1 [RBL]5 [RBL]1 [RBL]41 [RBL]4c [RBL]7 [RBL]2 [RBL]13 [RBL]2
    [RBL]1 [RBL]0 [RBL]12 [RBL]15 [RBL]1 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]14 [RBL]21 [RBL]1 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0

    [PC] Requesting the ASIC ID
    [RBL]4 [RBL]1 [RBL]5 [RBL]1 [RBL]41 [RBL]4c [RBL]7 [RBL]2 [RBL]13 [RBL]2
    [RBL]1 [RBL]0 [RBL]12 [RBL]15 [RBL]1 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]14 [RBL]21 [RBL]1 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0
    [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0 [RBL]0

    [PC] Requesting PERI_REQ mode
    [PC] Sending SBL_MFLASH filesize.
    [PC] Size of sbl_mflash = 125872
    [PC] Sending SBL_MFLASH... Please wait
    [PC] File Size = 125872
    [PC] ##
    [PC] Transfer Complete. Time = 1.000
    [PC] Opening port for sbl_mflash.
    Baud = 12000000
    Parity = 0
    StopBits = 0
    ByteSize = 8
    [PC] Opening serial port successful.
    -----------------------------------

    The messages are the end up to here. There is no more progress.
    Please let me know what I should do for the next?

    Kevin
  • Kevin,

    Can you see similar thread: e2e.ti.com/.../632697

    Regards,
    Rishabh
  • Hi Rishabh,

    This issue was resolved.

    I found UART port should be unpluged, and UART should be connected to PC at below time.

    I found Kevin ran the batch file while connecting UART to PC and just recycle EVM. 

    After unplug UART before running the batch file and connect UART to PC at above menu, it works well.

    Thanks and Best Regards,

    SI.

  • Hi SI,

    Thanks for the update.

    Regards,
    Rishabh