Electronic – The purpose of FSMC

microcontrollersramstm32

For a project, I need to have some external memory. I went for 1MB of SRAM.

I am using an STM32 and I discovered the FSMC. I had a hard time understanding the purpose of this.

What I read about it led me to the fact that by using it, it gives you a direct memory location. So you can write to memory without having to pilot the specific pins (like CE, OE, WE…). It also allows you to write/read to SRAM without having to use GPIO write registers, so you are way faster. (of course, there are a lot more advantages). If I'm right I guess it is a very good idea to use it.

Am I right to think like that? Did I get it completely wrong?

Best Answer

Am I right to think like that ? Did I got it completely wrong ?

FSMC can be used for storing data in a volatile configuration. Some (not all) STM32's have FSMC mapped to an address space (at 0x60000000). Using a serial SRAM is best for storing data that you don't need fast access to. If you use it for values that are common in execution it could slow your program down considerably.

You still have to configure the pins for use with FSMC and wrap your head around the interface, and test it.