Skip to main content
jhasa.2
Associate III
October 22, 2023
Question

stm32f4 hardfault

  • October 22, 2023
  • 35 replies
  • 19096 views

hi

I use stm32f4 micro but an external interrupt pin

when i increase frequency of the external signal connected to interrupt pin, the micro jump to hardfault

why? how I can detect the solution?

jhasa2_0-1697953350580.png

jhasa2_1-1697953356273.pngjhasa2_2-1697953358673.png

 

This topic has been closed for replies.

35 replies

jhasa.2
jhasa.2Author
Associate III
November 4, 2023

can every body check my code? or help me?

Karl Yamashita
Principal
November 4, 2023

Everyone explained to you what is wrong with your array. Think of it this way, you have a tennis ball container (array)  that can only hold 3 tennis balls (values), max. You're basically trying to fit 4 or more balls into a container. So when you try to fit 4 balls in a container, all it's going to do is burst (hard fault).

 

So in your instance you're trying to put 5 or more values into an array that can fit only 4 values. Get the idea what's wrong now?

If a reply has proven helpful, click on Accept as Solution so that it'll show at top of the post.CAN Jammer an open source CAN bus hacking toolCANableV3 Open Source
jhasa.2
jhasa.2Author
Associate III
November 4, 2023

the new code is here!