Questions tagged [breakpoint]

Use this tag when referencing a debugging technique that can stop a program with variables and/or registers intact at a specific point.

Use this tag when referencing a debugging technique that can stop a program with variables and/or registers intact at a specific point.

This is very useful when making sure a program is progressing in the intended manner. Often a breakpoint will be set, then when it is either determined to be correct or the program is fixed in order to reach that point properly, then another breakpoint can be set further along in the code for the same reason.

In this way it is helpful for localizing software misbehavior and repair.

5 questions
3
votes
1 answer

Can Cortex M4 data watchpoint trigger an interrupt without a debugger?

I am trying to diagnose memory corruption on a Cortex M4 (Kinetis K64). With the debugger (J-Link) attached I can set data watchpoints and the core will stop when a memory address is written. I want to use this feature for field diagnostics. I set…
filo
  • 8,801
  • 1
  • 25
  • 46
2
votes
0 answers

DebugMon_Handler not triggered even after configuring DWT (Data Watchpoint and Trace) to look for memory writes

Can anyone advise why my actions described below do not work?: I have been trying to run the code snippet from the post Can Cortex M4 data watchpoint trigger an interrupt without a debugger? on(STM32F407VG board emulated with QEMU on eclipse.), but…
2
votes
2 answers

How to put a breakpoint to after last line of a loop in GDB?

Consider the following loop: 28: while (true) { 29: chThdSleepMilliseconds(1); 30: txbuffer[1] = num_zero + offset; 31: spiExchange(&SPID1, 2, txbuffer, rxbuffer); 32: // we want to examine rxbuffer at this point 33: } I want to…
ceremcem
  • 1,386
  • 17
  • 35
0
votes
0 answers

Is it possible to determine if a breakpoint is hit during an interrupt?

I'm composing some GDB commands to make it behave like a "print()" function: break Core/Src/main.c:243 commands silent printf "write addr: %d, val: %d\n", la, value continue end That'd worked great until now. I've been bitten by this approach…
ceremcem
  • 1,386
  • 17
  • 35
0
votes
1 answer

breakpoints in baremetal code for arm stm32

I am writing a simple baremetal code for STM32. I wrote the linker and the startup code similar to this . My understanding is that the .text section will be placed in the flash memory of the controller. Question: In such a case, it is not possible…
C Marius
  • 229
  • 1
  • 6