Skip to main content
luuk
Associate II
April 14, 2020
Solved

How to disable breakpoint in hard fault handler?

  • April 14, 2020
  • 1 reply
  • 1448 views

I'm controlling the temperature of high power heaters in my project. Because ithe product can damage if the heaters stay on too long, I have added code to disable the heaters in the hard fault handler. This way I can be sure that if something goes wrong the heaters are turned off directly.

However, it turns out that if the hard fault handler is entered while debugging a breakpoint is set at the beginning of the handler. All safety code that follows after the breakpoint isn't executed until I continue the program.

Since the heaters can overheat in a few seconds there is a good chance I'm not fast enough to respond when this happens. Can anyone tell me how I can make STM32CubeIDE not stop there or not add breakpoints at the hard fault handler?

This topic has been closed for replies.
Best answer by berendi

Open the Run / Debug configurations dialog, uncheck Halt on exception on the Startup tab. You may have to scroll down to expose the option.

1 reply

berendi
berendiAnswer
Principal
April 14, 2020

Open the Run / Debug configurations dialog, uncheck Halt on exception on the Startup tab. You may have to scroll down to expose the option.

luuk
luukAuthor
Associate II
April 14, 2020

Thank you so much!