2019-04-10 08:03 AM
Hi,
I'm working on porting a project from the Nucleo-F411 to a custom PCB. Everything works fine when setting the HCLK to 60MHz and below (running from the internal HSI RC clock and PLL), but i'm getting Hard and Usage Faults when setting the HCLK to anything above 60MHz, the target HCLK is 82MHz.
Find attached the CubeMX project i'm using, can you replicate the issue?
Solved! Go to Solution.
2019-04-10 09:02 AM
Sorry, not looking to replicate CubeMX failures.
Does the faster code fail on the NUCLEO?
Make sure there are sufficient wait states on the FLASH.
Check voltages and capacitors on VCAP pins.
Make sure you have an adequate STACK allocation.
Use a proper Hard Fault Handler, so you can better identify the source of the fault, it occurs at one location, or is more randomized in nature.
Make sure the clock configuration code clears the auto/local variable structure properly.
2019-04-10 09:02 AM
Sorry, not looking to replicate CubeMX failures.
Does the faster code fail on the NUCLEO?
Make sure there are sufficient wait states on the FLASH.
Check voltages and capacitors on VCAP pins.
Make sure you have an adequate STACK allocation.
Use a proper Hard Fault Handler, so you can better identify the source of the fault, it occurs at one location, or is more randomized in nature.
Make sure the clock configuration code clears the auto/local variable structure properly.
2019-04-10 10:53 AM
It was a VCAP pin problem, i reworked the pin solder and now it's working, even with the HCLK configured at 84MHz.
I knew it was something silly, thanks a lot for your help Clive :)