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.

CCS/MSP430FR5994: cannot debug with breakpoints enabled

Part Number: MSP430FR5994

Tool/software: Code Composer Studio

Hello, I'm using the MSP430FR5994 board with CCS and have a newly issue which I really like to resolve.

When I have some breakpoints set in my program and click "debug", it builds the project and then gives the following error:

Trouble Setting Breakpoint with the Action "Finish Auto Run" at 0x100c0: Software breakpoints cannot be set on the given opcode.

(at 0x100C0 is the main() program)

When I then disable all my breakpoints, I can start the debug session. Afterwards I can re-enable all my breakpoints and everything works fine. 

But one week ago, I did not have this issue, I could start the debug session with as many breakpoints as I wanted. How can I resolve this issue?

 

Regards, LS

  • LS,

    I can reproduce this. However, as you can see from the short clip below, it is a consequence of the number of hardware breakpoints available on the device. 

    At the debugger launch and code load, the Auto run to main functionality uses a breakpoint, which is automatically cleared immediately after it is reached at the initial launch.  

    In this case, many alternatives can be implemented, ranging from setting only software breakpoints to disabling the Auto run to main functionality altogether. 

    I found an old bug report (MSPTMSPDS-579) that mentions the same scenario on a different device, where the driver disallows setting a software breakpoint at the main() location. 

    MSPTMSPDS-579 said:
    When no hardware breakpoints are left for the run-to-main breakpoint, CCS uses a software breakpoint. Due to a silicon bug, the target can't be properly synced if the following instruction is a RRCM instruction (0x0?40 or 0x0?50).

    A software breakpoint replaces the actual instruction with 0x4343 (a do-nothing dummy instruction). This causes the following data word (0x0150 in your code) to look like an instruction which triggers the silicon bug.

    For this reason, CCS doesn't allow a software breakpoint at this location (but also can't do anything else, because all hardware breakpoints are already in use).

    Regards,

    Rafael