29.01.2015 Views

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Flexible static memory controller (FSMC)<br />

RM0008<br />

19.4.1 NOR/PSRAM address mapping<br />

HADDR[27:26] bits are used to select one of the four memory banks as shown in Table 84.<br />

Table 84.<br />

NOR/PSRAM bank selection<br />

HADDR[27:26] (1)<br />

Selected bank<br />

00 Bank 1 NOR/PSRAM 1<br />

01 Bank 1 NOR/PSRAM 2<br />

10 Bank 1 NOR/PSRAM 3<br />

11 Bank 1 NOR/PSRAM 4<br />

1. HADDR are internal AHB address lines that are translated to external memory.<br />

HADDR[25:0] contain the external memory address. Since HADDR is a byte address<br />

whereas the memory is addressed in words, the address actually issued to the memory<br />

varies according to the memory data width, as shown in the following table.<br />

Table 85. External memory address<br />

Memory width (1) Data address issued to the memory<br />

Maximum memory capacity (bits)<br />

8-bit HADDR[25:0] 64 Mbytes x 8 = 512 Mbit<br />

16-bit HADDR[25:1] >> 1 64 Mbytes/2 x 16 = 512 Mbit<br />

1. In case of a 16-bit external memory width, the FSMC will internally use HADDR[25:1] to generate the<br />

address for external memory FSMC_A[24:0].<br />

Whatever the external memory width (16-bit or 8-bit), FSMC_A[0] should be connected to external memory<br />

address A[0].<br />

Wrap support for NOR Flash/PSRAM<br />

Each NOR Flash/PSRAM memory bank can be configured to support wrap accesses.<br />

On the memory side, two cases must be considered depending on the access mode:<br />

asynchronous or synchronous.<br />

● Asynchronous mode: in this case, wrap accesses are fully supported as long as the<br />

address is supplied for every single access.<br />

● Synchronous mode: in this case, the FSMC issues the address only once, <strong>and</strong> then<br />

the burst transfer is sequenced by the FSMC clock CLK.<br />

Some NOR memories support linear burst with wrap-around accesses, in which a fixed<br />

number of words is read from consecutive addresses modulo N (N is typically 8 or 16<br />

<strong>and</strong> can be programmed through the NOR Flash configuration register). In this case, it<br />

is possible to set the memory wrap mode identical to the AHB master wrap mode.<br />

Otherwise, in the case when the memory wrap mode <strong>and</strong> the AHB master wrap mode<br />

cannot be set identically, wrapping should be disabled (through the appropriate bit in the<br />

FSMC configuration register) <strong>and</strong> the wrap transaction split into two consecutive linear<br />

transactions.<br />

19.4.2 NAND/PC Card address mapping<br />

In this case, three banks are available, each of them divided into memory spaces as<br />

indicated in Table 86.<br />

412/995 Doc ID 13902 Rev 9

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!