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.

MCU-PLUS-SDK-AM263X: Custom SBL debugging

Part Number: MCU-PLUS-SDK-AM263X

Hi, I'm trying to build a custom SBL, but I've run into a number of basic problems.

I'm using a custom board based on AM263x-LP (which can be considered for this ticket, all tests were performed in LaunchPad). The board will be embedded in a case, so there is no access to the board (dip switches (SOP) or JTAG pinout) after production. The interface with the board is the UART communication (UART1-L3/M3 pins). The firmware MUST be available on the non-volatile memory (QSPI Flash), so the SBL was defined to QSPI boot mode. The requirement is to be able to update the firmware (flash) through the UART communication.
I thought of two possible implementations:
1. Two applications 
- The qspi sbl (0x0) pointed to the default address (0x80000)
- A first application stage at 0x80000 with two possible ways: update flash by UART (based SBL Uart flash writer) or run the application (go to another QSPI sbl (0x40000) pointed to another address, for example, 0x160000);
- The second and main application at 0x160000;
2. A custom QSPI sbl
- A custom QSPI SBL based on SBL QSPI, but checking the UART communication for any seconds or waiting for a message to start the application. The SBL QSPI pointed to default address 0x80000;
- The main application at the default address (0x80000);
Q1. Which is the recommended way to achieve the requirements, considering development time, security, and feasibility?
I was trying to debug a SBL and I couldn't. Initially, I tried to build and flash the SBL QSPI example, but it didn't work. So, I cleared the flash and tried to build and debug through the XDS110, but I inconsistently achieved three behaviors:
1. The debug session crashed: the pause, play and stop buttons were blocked.
2. I entered the debug session, and the program stuck on debugp_log method.
3. I entered the debug session and the program crashed on Hsmclient_loadHSMRtFirmware internal to Bootloader_socLoadHsmRtFw function.
I followed the below method to debug SBL, but the error "Cortex_R5_0: Trouble Setting Breakpoint with the Action 'Continue or Finish Stepping' at 0x3a04" was reached.