[SOLVED] J-Link doesn't stop at all breakpoints

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] J-Link doesn't stop at all breakpoints

    I'm trying to debug some code running on a STM32F722 on a custom board with J-Link EDU. My IDE is Atollic Studio.

    Flashing code with J-Link is absolutely no problem. But when I try to debug, J-Link won't stop at all breakpoints. In fact, it will stop at breakpoints set in main.c or functions called by main.c, but not in functions that have been triggered by an external interrupt.

    I've been trying to resolve this for over a week now, but I simply cannot find any reason for this. Personally, I suspect some configuration issue with my project, but I cannot tell for sure.

    I attached the log of my debug session with a few annotations of mine, and my Debug target software startup script. The main error message when a breakpoint is hit reads

    ERROR: Can not read register 15 (R15) while CPU is running
    Reading all registers
    ERROR: Can not read register 0 (R0) while CPU is running
    ERROR: Can not read register 1 (R1) while CPU is running


    I would greatly appreciate any suggestions, as otherwise I'd have to kill my project.
    Files
    • debug2.log

      (16.12 kB, downloaded 211 times, last: )
    • target-script.txt

      (834 Byte, downloaded 281 times, last: )
  • As I discovered just now, the error is not caused by reaching a breakpoint, but by reaching a certain, unknown code position. In other words, the error occurs even without any breakpoints.

    What code error causes J-Link to fail? And is there an option option I could disable to not trip up the debugger? Why is it trying to read registers when code is just executing without being debugged?