cancel
Showing results for 
Search instead for 
Did you mean: 

FMC hardfault STM32L471

pcu
Associate II
Posted on June 12, 2017 at 17:12

Hello,

I tried my LCD with parallel FMC-16bit on the NucleoL496 kit. All is working so far so good.

Now I working on my board and this is a L471 processor.

The problem is that it crashes when I try to writing to FMC(0x60000000). It goes directly in hardfault.

Only FMC is activated and the difference between the two project are the number of pin (100 vs 144) and the model (L471 vs L496)

An idea what happens?

Pierre

1 ACCEPTED SOLUTION

Accepted Solutions
Posted on June 12, 2017 at 17:22

Check that the FMC is properly initialized, compare the register settings between working and non-working example. ie dump the registers, compare and contrast.

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

View solution in original post

2 REPLIES 2
Posted on June 12, 2017 at 17:22

Check that the FMC is properly initialized, compare the register settings between working and non-working example. ie dump the registers, compare and contrast.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on June 12, 2017 at 21:15

Yes you are right.

After compare I remember that I chanded the stm32l4xx_ll_fmc.c file because it didn't enable the FMC in FMC_NORSRAM_Init().

It is neccessary to add __FMC_NORSRAM_ENABLE(Device, Init->NSBank);

Than you.