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.

AM2732-Q1: Is it possible to run SBL_UART_Uniflash in debugging mode

Part Number: AM2732-Q1
Other Parts Discussed in Thread: UNIFLASH

Tool/software:

Hi Team,

I was facing a problem while flashing a bin into particular offset of flash memory using SBL_UART_uniflash. Uart prints are disabled in SBL_Uart_Uniflash because of which no able to find out the root cause.

So I wanted to run SBL_Uart_Uniflash in debugging mode using XDS tool. But for flashing I need to set the TI SOC in Uart Mode but for step by step debugging SOC has to be in "No Boot" mode. Can you please suggest a way to run SBL_Uart_Uniflash in debugging mode?

Regards,

Shyam.

  • Hi Syam,

    Yes. It is possible.

    If you want to use the SBL_uart_uniflash debug version as is, you can use the pre-built one at C:\ti\mcu_plus_sdk_am273x_09_02_00_52\tools\boot\sbl_prebuilt\am273x-evm\sbl_uart.debug.tiimage. Simply change the "sbl_uart_uniflash.release.tiimage" in *.cfg into "sbl_uart_uniflash.debug.tiimage"

    You can also build your customized sbl_uart_uniflash.debug.tiimage. you can either import the CCS project from C:\ti\mcu_plus_sdk_am273x_09_02_00_52\examples\drivers\boot\sbl_uart_uniflash, then build it in Debug profile, or use makefile to build it with PROFILE=debug.

    Then you can use the generated sbl_uart_uniflash.debug.tiimage to replace the one in C:\ti\mcu_plus_sdk_am273x_09_02_00_52\tools\boot\sbl_prebuilt\am273x-evm folder.

    Best regards,

    Ming

  • Hi Ming,

    Thanks for the reply.

    Problem here is I was not able to run official SBL_UART_Uniflash debug binary in XDS mode (Debugger shows program counter is stuck at reset_vector). Is it possible to use SBL_Uart_Uniflash with XDS debugger ?

    I was able to use SBL_JTAG_Uniflash with XDS debugger and I could debug with breakpoints.

    Regards,

    Shyam.

  • Hi Syam,

    Although you cannot load and run the SBL_UART_Uniflash using JTAG, you still can debug and single step through the SBL_UART_Uniflash using the following method:

    1. Add the following code in the beginning of the main() in SBL_UART_Uniflash

    int loopForever = 1;

    while (loopForever)

    {

    }

    2. Flash the SBL_UART_Uniflash (*.tiimage) into the NOR flash

    3. Set boot mode to QSPI boot mode and power cycle the board

    4. Connect to the target using JTAG and halt the CPU

    5. Load symbol from the SBL_UART_Uniflash (*.out)

    6. Change the loopForever to 0

    7. Start single step debug

    Best regards,

    Ming