cancel
Showing results for 
Search instead for 
Did you mean: 

need Hard fault Exception Help

balu_darukumalli
Associate
Posted on October 05, 2009 at 16:06

need Hard fault Exception Help

4 REPLIES 4
balu_darukumalli
Associate
Posted on May 17, 2011 at 13:25

Hi,

I am using STM32F103ve Controller. I am getting HARD_FAULT EXCEPTION Continuously every 15 minutes after RESET.

Can any one tell me what are the reasons for getting hard fault exception?

ccowdery9
Associate III
Posted on May 17, 2011 at 13:25

In my experience, a hardfault is caused by a faulty pointer which itself causes a read or write to a non-existent memory location.

Check your pointers contain what you think they do.

Chris.

swhite
Associate III
tomas23
Associate II
Posted on May 17, 2011 at 13:25

Not only pointers, but array indexes, stack corruption (overflow), even wrong priorities of error handlers, SWI etc.

My hint: Hard fault is not a specific exception, it is only a collector for other unhandled faults. Enable memory, bus and usage fault vectors and read within NVIC registers, what's the error and which instruction or address caused it (www.arm.com, Cortex M3 or Architecture v7M manuals).

If the flags are empty, but hard fault is still present, check whether you don't call eg. SWI from interrupt.

Btw. why every 15 minutes? What's the repetitive task in your application, related to the MCU?

[ This message was edited by: edison on 05-10-2009 19:37 ]