I'm looking into designing a custom board based on a Microchip / ATMEL SAM S70 or STM32F7 / STM32H7. The SAMS S70 appears to be the cheapest option and offers roughly the same as the ST competitors.

I'm now trying to figure out how much SDRAM I can attach to these MCUs.

  1. The datasheet of the S70 does not specify what type of SDRAM (DDR2, DDR3) etc. it can handle. How do I know what memory chips are compatible?

  2. Browsing through digitec, I noticed that almost all (?) 1G memory chips have 8 banks, which is more than the SAM S70 can handle (4 banks max). And all the chips that I found that offer 1G on 4 banks are DDR1 only. Is the amount of data per bank somehow limited?

  3. Also I am unsure how much data the memory controller on the SAMS S70 can adress per bank (row / column adresses) and in total. If I read the datasheet correctly, the biggest address is 13 bits of row address, 11 bits of column address + 1 bit byte offset + 2 bit bank address, i.e. 27 address bits in total.. that would be 1/8 of 1G, i.e. 128M?

  4. Where does Page size play into this?

I know that these are many questions but I am quite overwhelmed by the amount of memory configurations and the limited information in the datasheets doesn't help.

  • \$\begingroup\$ If they have a reference design it will show what memory to use. \$\endgroup\$
    – EE_socal
    Commented Jan 9, 2018 at 0:10

2 Answers 2


The type of memory you need is SDRAM. It is not the same as DDR SDRAM. I don't think I've seen a Cortex-M device that supports DDR memory yet. You would typically go for Cortex-A family, if you need that kind of capability.

You can easily find SDRAM chips on digikey or any other distributor site.

At this point, the rest of you question is probably irrelevant, but let me give you some extra points.

Both of the chips support 256MB of RAM. If you look at the digikey link above, the largest amount in a single chip is 512 Mbits (64 MBytes). This is where the data bus width comes into play. You can see that 512Mb chips come in three configurations:

  • 16M x 32bit
  • 32M x 16bit
  • 64M x 8bit

One way to increase the memory capacity would be to use two 512Mb devices in 32M x 16bit configuration, and wire them up as shown in this Atmel app note, for a total of 128MB of RAM:

enter image description here

  • \$\begingroup\$ I totally agree with you about supporting SDRAM, I spent a lot of time. I couldn't find a solution except FPGA. \$\endgroup\$
    – dsgdfg
    Commented Jan 9, 2018 at 5:57
  • \$\begingroup\$ Thanks for the answer. If I'm correct there is no way to extend the memory capacity of the SAM S70 beyond 256MB because of the limited 16-bit data bus, am I correct? \$\endgroup\$
    – Xaser
    Commented Jan 9, 2018 at 10:44
  • \$\begingroup\$ Actually, I'm not quite getting how I can even attach 256MB. For 8K rows, 2K columns, 4 banks and 16-bit datapath I get just 128MB? \$\endgroup\$
    – Xaser
    Commented Jan 9, 2018 at 11:28
  • \$\begingroup\$ @Xaser The app note I linked claims that the MCU can handle four banks of a 32bit wide SDRAM. The S70 should be able to do the same. Either that, or the spec is a copy-paste error. \$\endgroup\$
    – Armandas
    Commented Jan 10, 2018 at 0:55
  • \$\begingroup\$ @Armandas yea but the mcu has only 16 physical data lines, i.e. 16 bit wide? and the inconsistency appears to be in the datasheet itself (my calculation says 128MB, but datasheet says 256MB) weird stuff. \$\endgroup\$
    – Xaser
    Commented Jan 10, 2018 at 23:15

Datasheet says on first page:

"-16-bit Static Memory Controller (SMC) with support for SRAM, PSRAM, LCD module, NOR and NAND Flash with on-the-fly scrambling

̶ 16-bit SDRAM Controller (SDRAMC) interfacing up to 256 MB and with on-the-fly scrambling"

Just to mention: SAM S70 supports just 16bit (external) bus width. I prefer STM MCUs which allow also 32bit. It matters for the performance: if you let do code fetches or you use 32bit (int, float) or even double words (64bit) - you get just half of the 1/2 potential throughput. It depends for what and how often do you use the external memory (temporary data or main data and code there?). Check also if this MCU provides caches, e.g. is it a Cortex-M4/M7 with caches? If so, configure the MPU properly to make use of it. I prefer MCUs with caches, plus ITCM and DTCM, e.g. STM32F7 for high performance embedded systems. External memory I use often just as a RAM disk or for temporary buffers, not as the main memory.

BTW: You could also check if using SDIO (SD Card) might be sufficient as well. You can have GB of space there. Even often code fetches are supported, it is just even slower (e.g. 4bit bus). But much easier to connect and to create a PCB with SD card slot (or soldered eMMC chip).

Or: what about SPI memory chips, e.g. FRAMs?

BTW2: A real DDR memory (often just to find on Cortex-A Application Processors, as LP-DDR2 or DDR3) is very tough to design as PCB: they need matching trace length on all lines, impedance matching, also a termination at the end. Not an easy design like with Static-(S)RAM or Static-(S)DRAM.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.