Download Print this page

Quadspi Flash Memory Configuration - ST STM32F413 Reference Manual

Advanced arm-based 32-bit mcus
Hide thumbs Also See for STM32F413:

Advertisement

RM0430
nCS is released after a period of TIMEOUT[15:0] (QUADSPI_LPTR) cycles have elapsed
without any access since when the FIFO becomes full with prefetch data.
BUSY goes high as soon as the first memory-mapped access occurs. Because of the
prefetch operations, BUSY does not fall until there is a timeout, there is an abort, or the
peripheral is disabled.
12.3.8

QUADSPI Flash memory configuration

The device configuration register (QUADSPI_DCR) can be used to specify the
characteristics of the external SPI Flash memory.
The FSIZE[4:0] field defines the size of external memory using the following formula:
Number of bytes in Flash memory = 2
FSIZE+1 is effectively the number of address bits required to address the Flash memory.
The Flash memory capacity can be up to 4GB (addressed using 32 bits) in indirect mode,
but the addressable space in memory-mapped mode is limited to 256MB.
If DFM = 1, FSIZE indicates the total capacity of the two Flash memories together.
When the QUADSPI executes two commands, one immediately after the other, it raises the
chip select signal (nCS) high between the two commands for only one CLK cycle by default.
If the Flash memory requires more time between commands, the chip select high time
(CSHT) field can be used to specify the minimum number of CLK cycles (up to 8) that nCS
must remain high.
The clock mode (CKMODE) bit indicates the CLK signal logic level in between commands
(when nCS = 1).
12.3.9
QUADSPI delayed data sampling
By default, the QUADSPI samples the data driven by the Flash memory one half of a CLK
cycle after the Flash memory drives the signal.
In case of external signal delays, it may be beneficial to sample the data later. Using the
SSHIFT bit (QUADSPI_CR[4]), the sampling of the data can be shifted by half of a CLK
cycle.
Clock shifting is not supported in DDR mode: the SSHIFT bit must be clear when DDRM bit
is set.
12.3.10
QUADSPI configuration
The QUADSPI configuration is done in two phases:
QUADSPI IP configuration
QUADSPI Flash memory configuration
Once configured and enabled, the QUADSPI can be used in one of its three operating
modes: indirect mode, status-polling mode, or memory-mapped mode.
QUADSPI IP configuration
The QUADSPI IP is configured using the QUADSPI_CR. The user shall configure the clock
prescaler division factor and the sample shifting settings for the incoming data.
[FSIZE+1]
DocID029473 Rev 3
Quad-SPI interface (QUADSPI)
313/1284
332

Advertisement

loading
Need help?

Need help?

Do you have a question about the STM32F413 and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Stm32f423