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.

CC2652P: Debugging Bootloader + Application

Part Number: CC2652P

I am trying to debug a device (CC2652P) that consists of a custom bootloader based on BIM and an additional application.
Using the CCFG the integrated ROM-Bootloader starts my custom bootloader on reset.

Eventually, my bootloader will jump to the application.
The bootloader and the application are individual projects in Code Composer.

Now I would like to be able to start a debug session and debug the application as well as the bootloader in the same session.
I tried to manually add the *.out file of the bootloader after starting a debug session of the application (Run --> Load --> Add Symbols).
I also tried it using a GEL script with the command: "GEL_SymbolAdd(...)"

The symbols seem to be added correctly as I can find the associated functions in the "Disassembly" view and I am able to insert breakpoints there.

When I try to insert a breakpoint in the editor it shows a disabled (grey) breakpoint. When I try to enable the breakpoint in the "Breakpoints" view, an error message "No code is associated with .... in any loaded symbols" appears.

I want to be able to set breakpoints in the editor for the bootloader and the application project in Code Composer Studio.

  • Hi J K,

    Are you using a BLE project?  Regardless, have you referred to Task 4 of the BLE Enhanced OAD SimpleLink Academy Lab? Taking this approach should help you be able to debug both applications in the same session.  Other debug information is provided in the BLE5-Stack Debugging Guide.

    Regards,
    Ryan

  • [deleted]
  • Hi Ryan,

    Thanks for your response.

    I am not using a BLE project. I used the information from Task 4 of the BLE Enhanced OAD SimpleLink Academy Lab to add the symbols from the *.out file of my custom bootloader. (Run --> Load --> Add Symbols)
    Im doing the following in CCS:

    1. Start debug session of application
    2. Let the application run (automatic breakpoint at main)
    3. ADD the symbols of the bootloader project. (as described in Task 4 mentioned above)
    4. Reset the device (Board reset with automatic connect/disconnect)
    5. Varying from the Task 4 tutorial, the debugger is automatically connected to the device (no need to click "connect")
    6. Breakpoints cannot be set in the editor, just in the "Disassembly" view.

    I also tried to disconnect and connect in step 5 with the same result in the end.

    I am wondering why the breakpoints are working when added in the "Disassembly" view, but not when they are added directly in the editor.
    Do you have any additional ideas?

    PS:
    When I use "Load symbols" it works and I can set breakpoints in the editor in the bootloader project.
    The problem is that this replaces the currently loaded symbols and I can't set breakpoints in the application afterward.

    PPS:
    I added a *.gif to show my debugging process:

  • Thanks for providing this additional information.  I will try to loop in some CCS experts to comment on the symbol loading and window behavior.  Which version of CCS and the SimpleLink SDK are you currently evaluating?  Make sure you have loaded the bootloader code into your device before attempting to load the symbols.  If you follow the SimpleLink Academy Lab from start to finish (using the BLE project and off-chip BIM as provided by TI), are you able to experience the operable debug behavior described in Task 4?

    Regards,
    Ryan

  • "Which version of CCS and the SimpleLink SDK are you currently evaluating?"

    I am using:

        - Code Composer Studio:Version: 10.4.0.00006
        - simplelink_cc13x2_26x2_sdk_5_10_00_48

    What exactly do you mean by: "Make sure you have loaded the bootloader code into your device before attempting to load the symbols."?
    I am flashing the bootloader project before trying to debug the application project. Using the verbose flashing output, I can see that the bootloader is just writing its own page and the CCFG into the FLASH.
    Is there a need to specifically load the code before debugging?

    "If you follow the SimpleLink Academy Lab from start to finish (using the BLE project and off-chip BIM as provided by TI), are you able to experience the operable debug behavior described in Task 4?"

    I will try to find time to test this today.


    Thank you for your support so far and regards,
    Johannes

  • I just wanted to make sure that the bootloader code exists and is operational on the device that you are attempting to debug and is not erased while programming the application or loading the debug session.

    Regards,
    Ryan