AM2634: Uniflash error "Timed out waiting for target to halt" using LP-XDS110 on custom board

Part Number: AM2634
Other Parts Discussed in Thread: LP-XDS110, UNIFLASH, SYSCONFIG

Tool/software:

Hello TI Support Team,

I have an LP-XDS110 connected to a custom AM2634 board and am not able to program QSPI via JTAG using Uniflash 9.2.0.  These are the last few lines of output seen:

...
[8/18/2025, 4:23:01 PM]
 [INFO] Cortex_R5_0: GEL Output: ***All IP Clocks are Enabled***
[8/18/2025, 4:23:01 PM] [INFO] Cortex_R5_0: AM2634
[8/18/2025, 4:23:01 PM] [INFO] Cortex_R5_0: Board Selected : LP
[8/18/2025, 4:23:01 PM] [INFO] Cortex_R5_0: GEL Output: CPU reset (soft reset) has been issued through GEL on program load.
[8/18/2025, 4:23:22 PM] [ERROR] Cortex_R5_0: Run failed...
[8/18/2025, 4:23:22 PM] [ERROR] Cortex_R5_0: File Loader: Memory write failed: Timed out waiting for target to halt while executing uniflash.out
Between the last [INFO] message and the [ERROR] messages, the Load Program dialog stays up with "0 of 32752 at 0x60080000" showing for about 10 seconds (I am only trying to flash the .mcelf in this case; trying to flash SBL gives the same result).
With this same XDS-110 attached to our board, I am able to debug code in CCS so I believe the JTAG connections are correct.  I can also connect the RXD/TXD to the board's UART and flash via serial port without issue (though it is of course slower and I have to change boot modes back and forth, so is not ideal).
I am using custom sbl_jtag_uniflash and sbl_uart_uniflash builds which have their syscfg modified to match the flash device on our board, and given the UART flashing works I am confident this part is correct.  I also tried enabling the UART Debug log for the JTAG uniflash loader and saw the JTAG Uniflash Menu along with its 1,2,3,x choices come out the UART, which indicates that it is recognizing the flash device and gets past the driver initialization (I turned the UART off after doing this test, in case it interferes with the JTAG download).  Are there other diagnostics I can perform using a custom uniflash loader build?
Interestingly, if I run from the command-line, I get output which looks successful but does not actually perform any flashing:
./dslite.sh --config AM2634.ccxml -e -s CustomFlashEnable=true -s FlasherCustomPath=<system path> -s FlasherCustomName=uniflash.out -s FlashVerboseMode=true -f bringup.mcelf
...
Cortex_R5_0: GEL Output: CPTS Clock Enabled (250MHz)
Cortex_R5_0: GEL Output:

***All IP Clocks are Enabled***

info: Cortex_R5_0: AM2634
info: Cortex_R5_0: Board Selected : CC
Cortex_R5_0: GEL Output: CPU reset (soft reset) has been issued through GEL on program load.
Loading Program: bringup.mcelf
Preparing ...
Finished
Setting PC to entry point.
Success
The last steps where it indicates it's loading the program are instantaneous and appear to have no effect, as booting the board results in it running what was already in flash.  This is on a Mac OS system, using a .ccxml file exported from the Uniflash GUI.
 
If I can provide any further information please let me know – thank you!
- M. Fairman
  • Hi M. Fairman,

    Thank you for the query!! 

    From what I am understanding you are using a custom QSPI flash instead of then default flash present in EVM, in this case you will need to update SysConfig with the custom flash json file in both the sbl_qspi and jtag_uniflash

    1. C:\ti\mcu_plus_sdk_am263x_10_02_00_13\examples\drivers\boot\sbl_qspi
    2. C:\ti\mcu_plus_sdk_am263x_10_02_00_13\tools\flasher\jtag_uniflash

    Please follow the below steps to update the example.syconfig

    1. Import both the projects to your workspace
    2. Open the example.sysconfig file
      1. Navigate to FLASH tab and  update the Flash Name
      2. Click on the Load from JSON  button and select the <custom_flash>.json file from the <path_where_json_is_present>
      3. Predefined flash JSON path in mcu_plus_sdk : C:\ti\mcu_plus_sdk_am263x_10_02_00_13\source\sysconfig\board\.meta\flash
      4. Save and build the example projects
    3. Now once the examples are built, use the custom flash option in uniflash9.2 to load the custom flasher binary.(use the appropriate path and .out file similar to the image below)
      1. Do Erase entire flash, just to ensure a clean start and paths are correct (optional)
      2. Keep the bootmode to Devboot (so that the image that was flashed previously might not be executing while we are trying to reflash)
    4. Load the newly built sbl_qspi and hello_world images after a power cycle.

    Please try the above steps and let us know your observations.

    Thanks & Regards,
    Rijohn

  • Hi Rijon,

    Thank you for your reply!

    I have already modified the both the JTAG Uniflash loader syscfg and the SBL syscfg to work with our board's flash.  I can tell that is working because (a) the uniflash loader gets past device initialization (before modifying the syscfg, it would error-out), and the SBL succeeds in loading the application code when I flash it via UART, which does work.

    The problem here is that once Uniflash starts the loader on the target, it gets stuck with the "Timed out waiting for target to halt" message.  And in the case of the CLI, it doesn't get stuck but also doesn't perform any flashing operation.  I would like to be able to flash via JTAG, preferably using the command line but using the GUI would be OK to start with.

    Are there other ideas of things to try?

    Thanks,

    - Michael

  • Hi Michael,
     
    Can you please help me with the following:

    1. Which bootmode is the device currently in (while flashing)?
      1. Try erasing the entire flash.
      2. and then re-flashing in DEVBOOT mode.

    2. Which is the custom flash part number?


    Thanks & Regards,
    Rijohn


  • Hi Michael,

    I have already modified the both the JTAG Uniflash loader syscfg 

    Just to confirm, have you modified "C:\ti\mcu_plus_sdk_am263x_10_02_00_13\tools\flasher\jtag_uniflash" ----> present in tools folder ? This flasher_jtag.out should be used in the Uniflash tool custom flasher field.

    Reconfirming this as I saw mentions about sbl_jtag_uniflash project which is present in  C:\ti\mcu_plus_sdk_am263x_10_02_00_13\examples\drivers\boot\sbl_jtag_uniflash.

    NOTE: .out generated from ..\tools\flasher\jtag_uniflash is used by UNIFLASH tool, not "..\examples\drivers\boot\sbl_jtag_uniflash."


    Thanks & Regards,
    Rijohn

  • Hi Rijohn,

    That was it!  I had only seen the "sbl_jtag_uniflash" section of the documentation under "Tools and Utilities -> Flashing Tools -> JTAG Uniflash" and not the one present under "Uniflash Custom Flash Writer" which is what you pointed to.  When I use the latter, and apply the flash device customizations, I am able to flash the board via the Uniflash GUI Sunglasses

    The command-line DSLite still does not seem to write to the flash but I may be missing some required parameters and can pursue that separately.

    Thank you very much for your help!

    - Michael