Skip to main content
Charlie CHEN
Associate III
May 13, 2019
Question

Keil Debug

  • May 13, 2019
  • 1 reply
  • 2030 views

Hi professor,

I`m trying to use debug mode with keil.I get it in to the function and it run the function without press run button,but when I stop it ,it go in to hardfault.

Is any one have faced the problem before?

THKS!0690X000008BZKvQAO.png

This topic has been closed for replies.

1 reply

Tesla DeLorean
Guru
May 13, 2019

SystemInit faults? Perhaps step in to that and review the code. Inspect Hard Fault location reported by processor, it has registers for that.

Are you using RAM which needs a clock enabled?

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
Charlie CHEN
Associate III
May 16, 2019

Hi @Community member​ ,

Thanks for your reply!

I have enabled the appropriate clock ,and I cannot check the register cause it can`t run normally,just stuck in Reset_Handler.

Is there any problem occur?

Thanks again!

Tesla DeLorean
Guru
May 17, 2019

Use Stop to see where it is.

Turn off the "Run to main()" setting of the debugger, and start stepping into/through the SystemInit() function. Determine where things go wrong, and where exactly it ends up.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..