cancel
Showing results for 
Search instead for 
Did you mean: 

why stm32f411ve jump to Hard Fault

Erkan MURTLU
Associate
Posted on September 24, 2017 at 23:23

I want to write and read file using FATFS and USB DÄ°SK Host Only middlewares on stm32f411ve but the processor jumps to hard fault when it makes 'f_open(&MyFile,'example.txt',FA_CREATE_ALWAYS|FA_WRITE)!=FR_OK'  code. I don't understand why it does, one could run the app on that i watched video. 

2 REPLIES 2
Posted on September 25, 2017 at 03:35

Try examining the instructions that are actually faulting, determine why from the code and the registers. Use a Hard Fault Handler that does more than while(1);

Big enough stack? Errant pointer?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on September 25, 2017 at 07:51

How can i determine why from the code and the registers. I think it's due to the registers. Because it has jumped to memory management handler.