2. Memory and bus architecture
2.1 System architecture
The architecture relies on an Arm Cortex®-M33 core optimized for execution thanks to an instruction cache having a direct access to the embedded flash memory.
This architecture also features a 32-bit multilayer AHB bus matrix that interconnects
- • up to 16 masters:
- – Fast C-bus, connecting Cortex®-M33 with TrustZone® mainline and FPU core C-bus to the internal SRAMs through the instruction cache
- – Slow C-bus, connecting Cortex®-M33 with TrustZone® mainline and FPU core C-bus to the external memories through the instruction cache
- – Cortex®-M33 with TrustZone® mainline and FPU core S-bus (three masters connected to three internal SRAMs without latency)
- – Cortex®-M33 with TrustZone® mainline and FPU core S-bus connected to the external memories through the data cache
- – DMA2D
- – Ethernet MAC
- – GPDMA1 (general purpose DMA featuring two master ports)
- – GPDMA2 (general purpose DMA featuring two master ports)
- – LTDC
- – OTG_HS
- – SDMMC1
- – SDMMC2
- • up to 13 slaves:
- – Internal flash memory (4 Mbytes)
- – Internal SRAM1 (256 Kbytes)
- – Internal SRAM2 (128 Kbytes)
- – Internal SRAM3, SRAM4, and SRAM5 (384 Kbytes)
- – AHB1 peripherals and 4-Kbyte BKPSRAM, including AHB to APB bridges and APB peripherals (connected to APB1 and APB2)
- – AHB2 peripherals
- – FMC (flexible memory controller)
- – OCTOSPI1, OCTOSPI2
- – AHB3 peripherals, including AHB to APB bridge and APB peripherals (connected to APB3)
- – AHB4 peripherals
The bus matrix provides the access from a master to a slave, enabling concurrent access, and efficient operation even when several high-speed peripherals work simultaneously. This architecture is shown in the following figure.
Figure 1. System architecture

The diagram illustrates the system architecture of the RM0517 microcontroller. At the top, the Cortex-M33 core (with TrustZone mainline and FPU) is connected to the system via a C-bus and an S-bus. The C-bus connects to an ICACHE (16-Kbyte) and a Fast bus. The S-bus connects to a DCACHE (8-Kbyte) and a Slow bus. Both caches feed into a large bus matrix. The matrix has multiple rows and columns, with connections to various peripherals and memory blocks. On the left, peripherals include GPDMA1, GPDMA2, ETHERNET MAC, SDMMC1, SDMMC2, OTG_HS, DMA2D, and LTDC. On the right, the matrix connects to a 128-bit AHB bus, which then branches to several memory and peripheral blocks: FLASH (4MB), MPCBB1-SRAM1 (256KB), MPCBB2-SRAM2 (128KB), MPCBB3-SRAM3 (384KB), MPCBB4-SRAM4 (384KB), MPCBB5-SRAM5 (384KB), AHB1/AHB2 peripherals, MPCWM4-BKPSRAM, MPCWM1/OTFDEC1/OCTOSPI1, MPCWM5/OTFDEC2/OCTOSPI2, MPCWM2/FMC, and AHB3/AHB4 peripherals. A legend defines symbols for bus multiplexers, master and slave interfaces, and memory protection controllers (MPCBB and MPCWM). The diagram is labeled MSv74520V2.
2.1.1 Fast C-bus
This bus connects the C-bus of the Cortex®-M33 core to the internal flash memory and to the bus matrix through the instruction cache. This bus is used for instruction fetch and data access to the internal memories mapped in the code region. This bus targets the internal flash memory and the internal SRAMs (SRAM1/2/3/4/5).
SRAM1/2/3/4/5 are accessible on this bus with a continuous mapping.
2.1.2 Slow C-bus
This bus connects the C-bus of the Cortex®-M33 core to the bus matrix via the instruction cache. This bus is used for instruction fetch and data access to the external memories mapped in the code region. This bus targets the external memories (FMC and OCTOSPIs).
2.1.3 S-bus
This bus connects the system bus of the Cortex®-M33 core to the bus matrix. This bus is used by the core to access data located in a peripheral or SRAM area. This bus targets the internal SRAMs (SRAM1/2/3/4/5 and BKPSRAM), the AHB1 peripherals including the APB1, APB2, AHB2, AHB3, and AHB4 peripherals.
SRAM1/2/3/4/5 are accessible on this bus with a continuous mapping.
Note: The bus matrix has a zero latency when accessing SRAM1/2/3/4/5.
2.1.4 DCACHE S-bus
This bus connects the system bus of the Cortex®-M33 core to the bus matrix through the data cache. This bus is used for instruction fetch and data access to the external memories mapped in the data region. This bus targets the external memories (FMC and OCTOSPIs).
Note: Fetching instructions through this bus is less efficient than fetching instructions through the slow C-bus.
2.1.5 GPDMA1 and GPDMA2 buses
These buses connect the four AHB master interfaces of the GPDMA1 and GPDMA2 to the bus matrix. These buses target the internal flash memory, the internal SRAMs (SRAM1/2/3/4/5 and BKPSRAM), the AHB1 peripherals including the APB1 and APB2 peripherals, the AHB2 peripherals, the AHB3 peripherals, the AHB4 peripherals, and the external memories through FMC or OCTOSPIs.
2.1.6 SDMMC1 and SDMMC2 controllers DMA buses
These buses connect the SDMMC1 and SDMMC2 DMA master interfaces to the bus matrix. They are used only by the SDMMC1 and SDMMC2 DMA to load/store data from/to the memory. These buses target the data memories: internal flash memory, internal SRAMs (SRAM1/2/3/4/5), and external memories through FMC or OCTOSPIs.
2.1.7 OTG_HS bus
This bus connects the OTG_HS master interface to the bus matrix. This bus is used only by the OTG_HS to load/store data from/to the memory. This bus targets the data memories: internal flash memory, internal SRAMs (SRAM1/2/3/4/5), and external memories through FMC or OCTOSPIs.
2.1.8 LTDC bus
This bus connects the LTDC master interface to the bus matrix. This bus is used only to load data from the memory. This bus targets the data memories: internal flash memory, internal SRAMs (SRAM1/2/3/4/5), and external memories through FMC or OCTOSPIs.
2.1.9 Bus matrix
The bus matrix manages the access arbitration between masters. The arbitration uses a round-robin algorithm. This bus matrix features a fast bus multiplexer used to connect each master to a given slave without latency (see Figure 1). For the same master, other slaves undergo a latency of at least one cycle at each new access.
2.1.10 AHB/APB bridges
The three AHB/APB bridges provide full synchronous connections between the AHB and the APB buses, allowing flexible selection of the peripheral frequency.
Refer to Section 2.3.2: Memory map and register boundary addresses for the address mapping of the peripherals connected to these bridges.
After each device reset, all peripheral clocks are disabled (except for the internal SRAMs and flash memory interfaces). Before using a peripheral, its clock must be enabled in the RCC_AHBxENR and RCC_APBxENR registers.
Note: When an 8- or 16-bit access is performed on an APB register, the access is transformed into a 32-bit access: the bridge duplicates the 8- or 16-bit data to feed the 32-bit vector.
2.1.11 Ethernet MAC
The Ethernet MAC uses a 32-bit bus, connected to the AHB bus matrix. Through the system bus matrix, it can access the internal flash memory, the internal memories, and the external memories through the OCTOSPIs and the FMC.
2.2 TrustZone® security architecture
The security architecture is based on Arm TrustZone® with the Armv8-M mainline extension. The TrustZone® security is activated by the TZEN option bit in the FLASH_OPTR register.
When the TrustZone® is enabled, the SAU (security-attribution unit) and IDAU (implementation-defined-attribution unit) define the access permissions based on secure and nonsecure states.
- • SAU: Up to eight SAU configurable regions are available for security attribution.
- • IDAU: provides a first memory partition as nonsecure or nonsecure callable attributes. The IDAU memory map partition is not configurable, it is fixed by hardware implementation (refer to Figure 2: Memory map based on IDAU mapping). It is then combined with the results from the SAU security attribution, and the higher security state is selected.
Based on IDAU security attribution, the flash memory, system SRAMs, and peripheral memory spaces are aliased twice for secure and nonsecure states. However, the external memory space is not aliased.
2.2.1 Default TrustZone® security state
When the TrustZone® security is activated by the TZEN option bit in the FLASH_OPTR, the default system security state is detailed below:
- • CPU:
- – Cortex®-M33 is in a secure state after reset. The boot address must be at a secure address.
- • Memory map:
- – SAU is fully secure after reset. Consequently, all memory maps are fully secure. Up to eight SAU configurable regions are available for security attribution.
- • Flash memory:
- – The flash memory security area is defined by watermark user options.
- – Block-based security attributions are nonsecure after reset.
- • SRAMs:
- – All SRAMs are secure after reset. MPCBBx (block-based memory protection controller) are secure.
- • External memories:
- – FMC and OCTOSPI banks are secure after reset. MPCWMx (watermark-based memory protection controller) are secure.
- • Peripherals (see Table 1 and Table 2 for a list of securable and TrustZone-aware peripherals)
- – Securable peripherals are nonsecure after reset.
- – TrustZone-aware peripherals are nonsecure after reset. Their secure configuration registers are secure.
- • All GPIOs are secure after reset.
- • Interrupts:
- – NVIC: All interrupts are secure after reset. NVIC is banked for both secure and nonsecure state.
- – TZIC: All illegal access interrupts are disabled after reset (see GTZC TrustZone system architecture).
2.2.2 TrustZone® peripheral classification
When the TrustZone® security is active, a peripheral can be either securable or TrustZone-aware type as follows:
- • Securable: peripheral protected by an AHB/APB firewall gate that is controlled from the TZSC controller to define security properties.
- • TrustZone-aware: peripheral connected directly to the AHB or APB bus and implementing a specific TrustZone® behavior such as a subset of registers being secure.
Refer to the GTZC TrustZone system architecture for more details.
Tables below list the securable and TrustZone-aware peripherals within the system.
Table 1. Securable peripherals by TZSC
| Bus | Peripheral |
|---|---|
| AHB4 | FMC |
| OCTOSPI1 | |
| OCTOSPI2 | |
| OCTOSPIM | |
| SDMMC1 | |
| SDMMC2 |
Table 1. Securable peripherals by TZSC (continued)
| Bus | Peripheral |
|---|---|
| AHB2 | ADC1 |
| ADC2 | |
| ADC3 | |
| ADF1 | |
| AES | |
| DAC1 | |
| DAC2 | |
| DCMI | |
| HASH | |
| OTG_FS | |
| PKA | |
| RNG | |
| SAES | |
| AHB1 | CORDIC |
| CRC | |
| DCACHE registers | |
| DMA2D | |
| ETHERNET | |
| FMAC | |
| ICACHE registers | |
| JPEG | |
| RAMCFG | |
| MDF1 | |
| OTG_HS | |
| RAMCFG |
Table 1. Securable peripherals by TZSC (continued)
| Bus | Peripheral |
|---|---|
| APB3 | I2C3 |
| I2C4 | |
| I3C2 | |
| LPTIM1 | |
| LPTIM3 | |
| LPTIM4 | |
| LPTIM5 | |
| LPTIM6 | |
| LPUART1 | |
| SPI5 | |
| VREFBUF | |
| APB2 | GFXTIM |
| LTDC | |
| SAI1 | |
| SAI2 | |
| SPI1 | |
| SPI4 | |
| SPI6 | |
| TIM1 | |
| TIM8 | |
| TIM15 | |
| TIM16 | |
| TIM17 | |
| USART1 |
Table 1. Securable peripherals by TZSC (continued)
| Bus | Peripheral |
|---|---|
| APB1 | CEC |
| COMP | |
| CRS | |
| DAC1 | |
| DAC2 | |
| DTS | |
| FDCAN1 | |
| FDCAN2 | |
| FDCAN3 | |
| I2C1 | |
| I2C2 | |
| I3C1 | |
| IWDG | |
| LPTIM2 | |
| OPAMP | |
| SPI2S2 | |
| SPI2S3 | |
| TM2 | |
| TM3 | |
| TM4 | |
| TM5 | |
| TM6 | |
| TM7 | |
| TM12 |
Table 1. Securable peripherals by TZSC (continued)
| Bus | Peripheral |
|---|---|
| APB1 (cont'd) | TM13 |
| TM14 | |
| UART4 | |
| UART5 | |
| UART7 | |
| UART8 | |
| UART9 | |
| UART12 | |
| UCPD | |
| USART2 | |
| USART3 | |
| USART6 | |
| USART10 | |
| USART11 | |
| WWDG |
Table 2. TrustZone-aware peripherals
| Bus | Peripheral |
|---|---|
| AHB3 | EXTI |
| PWR | |
| RCC | |
| AHB4 | OTFDEC1 |
| OTFDEC2 | |
| AHB2 | GPIOA |
| GPIOB | |
| GPIOC | |
| GPIOD | |
| GPIOE | |
| GPIOF | |
| GPIOG | |
| GPIOH | |
| GPIOI | |
| GPIOJ | |
| GPIOK |
Table 2. TrustZone-aware peripherals (continued)
| Bus | Peripheral |
|---|---|
| AHB1 | DCACHE |
| ICACHE | |
| FLASH | |
| GPDMA1 | |
| GPDMA2 | |
| GTZC | |
| APB3 | PLAY |
| RTC | |
| SBS | |
| TAMP |
2.3 Memory organization
2.3.1 Introduction
Program memory, data memory, registers and I/O ports are organized within the same linear 4-Gbyte address space.
The bytes are coded in memory in Little Endian format. The lowest numbered byte in a word is considered the word's least significant byte and the highest numbered byte the most significant.
2.3.2 Memory map and register boundary addresses
Figure 2. Memory map based on IDAU mapping

Legend:
- Nonsecure
- Secure - nonsecure callable
- Reserved
Main Memory Map:
| Address Range | Region Name / Type | Security Attribute |
|---|---|---|
| 0xFFFF FFFF - 0xE000 0000 | Cortex M33 | Nonsecure |
| 0xE000 0000 - 0xC000 0000 | FMC SDRAM | Nonsecure |
| 0xC000 0000 - 0xA000 0000 | OCTOSPI1 bank | Nonsecure |
| 0xA000 0000 - 0x9000 0000 | FMC Bank 3 | Nonsecure |
| 0x9000 0000 - 0x8000 0000 | OCTOSPI2 bank | Nonsecure |
| 0x8000 0000 - 0x7000 0000 | FMC Bank 1 | Nonsecure |
| 0x7000 0000 - 0x6000 0000 | Peripherals | Secure - nonsecure callable |
| 0x6000 0000 - 0x5000 0000 | Peripherals | Nonsecure |
| 0x4000 0000 - 0x3018 0000 / 0x3000 0000 | SRAM 1/2/3/4/5 | Secure - nonsecure callable |
| 0x3000 0000 - 0x2018 0000 / 0x2000 0000 | SRAM 1/2/3/4/5 | Nonsecure |
| 0x2000 0000 - 0x1000 0000 | Code | Nonsecure |
| 0x1000 0000 - 0x0C00 0000 | Code | Secure - nonsecure callable |
| 0x0C00 0000 - 0x0000 0000 | Code | Nonsecure |
Peripherals Sub-map Detail (0x4000 0000 to 0x6000 0000):
- 0x6000 0000: Reserved
- 0x5700 3800: AHB4
- 0x5600 5000: Reserved
- 0x5402 4400: AHB3
- 0x5402 0800: Reserved
- 0x5400 8400: APB3
- 0x5400 0400: Reserved
- 0x520C 8000: AHB2
- 0x5202 0000: Reserved
- 0x5003 7400: AHB1
- 0x5002 0000: Reserved
- 0x5001 7800: APB2
- 0x5001 2C00: Reserved
- 0x5000 E000: APB1
- 0x5000 0000: Reserved
- 0x4700 3800: AHB4
- 0x4600 5000: Reserved
- 0x4402 4400: AHB3
- 0x4402 0800: Reserved
- 0x4400 8400: APB3
- 0x4400 0400: Reserved
- 0x420C 8000: AHB2
- 0x4202 0000: Reserved
- 0x4005 1400: AHB1
- 0x4002 0000: Reserved
- 0x4001 7800: APB2
- 0x4001 2C00: Reserved
- 0x4000 FC00: APB1
- 0x4000 0000: Base
Code / Memory Sub-map Detail (0x0000 0000 to 0x2000 0000):
- 0x2000 0000 - 0x1000 0000: External memories
- 0x1000 0000 - 0x0FF8 0000: System memory
- 0x0FF8 0000 - 0x0E18 0000: Reserved
- 0x0E18 0000 - 0x0E00 0000: SRAM1/2/3/4/5 (Breakdown: 0x0E18 0000 SRAM5, 0x0E12 0000 SRAM4, 0x0E0C 0000 SRAM3, 0x0E06 0000 SRAM2, 0x0E00 0000 SRAM1)
- 0x0E00 0000 - 0x0D03 0000: Reserved
- 0x0D03 0000 - 0x0D00 0000: Flash high-cycle data
- 0x0D00 0000 - 0x0C40 0000: Reserved
- 0x0C40 0000 - 0x0C00 0000: FLASH
- 0x0C00 0000 - 0x0BF8 0000: System memory
- 0x0BF8 0000 - 0x0A18 0000: Reserved
- 0x0A18 0000 - 0x0A00 0000: SRAM1/2/3/4/5 (Breakdown: 0x0A18 0000 SRAM5, 0x0A12 0000 SRAM4, 0x0A0C 0000 SRAM3, 0x0A06 0000 SRAM2, 0x0A00 0000 SRAM1)
- 0x0A00 0000 - 0x0903 0000: Reserved
- 0x0903 0000 - 0x0900 0000: Flash high-cycle data
- 0x0900 0000 - 0x0840 0000: Reserved
- 0x0840 0000 - 0x0800 0000: FLASH
- 0x0800 0000 - 0x0000 0000: External memories remap
MSv74527V2
All the memory map areas not allocated to on-chip memories and peripherals are reserved.
The following table gives the boundary addresses of the available peripherals.
Table 3. Memory map and peripheral register addresses
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| AHB4 | 0x5700 3800 - 0x57FF FFFF | 0x4700 3800 - 0x47FF FFFF | Reserved | - |
| 0x5700 3400 - 0x5700 37FF | 0x4700 3400 - 0x4700 37FF | OCTOSPIM | Section 27.6.2: OCTOSPIM register map | |
| 0x5700 2800 - 0x5700 33FF | 0x4700 2800 - 0x4700 33FF | Reserved | - | |
| 0x5700 2400 - 0x5700 27FF | 0x4700 2400 - 0x4700 27FF | OCTOSPI2 | Section 26.7.28: OCTOSPI register map | |
| 0x5700 1800 - 0x57FF 23FF | 0x4700 1800 - 0x47FF 23FF | Reserved | - | |
| 0x5700 1400 - 0x5700 17FF | 0x4700 1400 - 0x4700 17FF | OCTOSPI1 | Section 26.7.28: OCTOSPI register map | |
| 0x5700 0800 - 0x5700 13FF | 0x4700 0800 - 0x4700 13FF | Reserved | - | |
| 0x5700 0400 - 0x5700 07FF | 0x4700 0400 - 0x4700 07FF | FMC | Section 25.8.6: FMC register map | |
| 0x5600 F800 - 0x5700 03FF | 0x4600 F800 - 0x4700 03FF | Reserved | - | |
| 0x5600 F400 - 0x5600 F7FF | 0x4600 F400 - 0x4600 F7FF | DLYBOS2 | Section 29.5.3: DLYB register map | |
| 0x5600 F000 - 0x5600 F3FF | 0x4600 F000 - 0x4600 F3FF | DLYBOS1 | ||
| 0x5600 9000 - 0x5600 EFFF | 0x4600 9000 - 0x4600 EFFF | Reserved | - | |
| 0x5600 8C00 - 0x5600 8FFF | 0x4600 8C00 - 0x4600 8FFF | SDMMC2 | Section 28.10.21: SDMMC register map | |
| 0x5600 8800 - 0x5600 8BFF | 0x4600 8800 - 0x4600 8BFF | DLYBSD2 | Section 29.5.3: DLYB register map | |
| 0x5600 8400 - 0x5600 87FF | 0x4600 8400 - 0x4600 87FF | DLYBSD1 | ||
| 0x5600 8000 - 0x5600 83FF | 0x4600 8000 - 0x4600 83FF | SDMMC1 | Section 28.10.21: SDMMC register map | |
| 0x5600 5800 - 0x5600 7FFF | 0x4600 5800 - 0x4600 7FFF | Reserved | - | |
| 0x5600 5400 - 0x5600 57FF | 0x4600 5400 - 0x6400 57FF | OTFDEC2 | Section 48.6.15: OTFDEC register map | |
| 0x5600 5000 - 0x5600 53FF | 0x4600 5000 - 0x4600 53FF | OTFDEC1 | ||
| 0x5600 0000 - 0x5600 4FFF | 0x4600 0000 - 0x4600 4FFF | Reserved | - |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| AHB3 | 0x5402 4400 - 0x54FF FFFF | 0x4402 4400 - 0x44FF FFFF | Reserved | - |
| 0x5402 4000 - 0x5402 43FF | 0x4402 4000 - 0x4402 43FF | DEBUG | Section 71.12.5: DBGMCU register map | |
| 0x5402 2400 - 0x5402 3FFF | 0x4402 2400 - 0x4402 3FFF | Reserved | - | |
| 0x5402 2000 - 0x5402 23FF | 0x4402 2000 - 0x4402 23FF | EXTI | Section 20.6.33: EXTI register map | |
| 0x5402 1000 - 0x5402 1FFF | 0x4402 1000 - 0x4402 1FFF | Reserved | - | |
| 0x5402 0C00 - 0x5402 0FFF | 0x4402 0C00 - 0x4402 0FFF | RCC | Section 11.8.49: RCC register map | |
| 0x5402 0800 - 0x5402 0BFF | 0x4402 0800 - 0x4402 0BFF | PWR | Section 10.11.19: PWR register map | |
| 0x5400 8400 - 0x5402 07FF | 0x4402 0000 - 0x4402 07FF | Reserved | - |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| APB3 | 0x5400 8400 - 0x5400 FFFF | 0x4400 8400 - 0x4400 FFFF | Reserved | - |
| 0x5400 8000 - 0x5400 83FF | 0x4400 8000 - 0x4400 83FF | PLAY | Section 24.7: PLAY register map | |
| 0x5400 7C00 - 0x5400 7FFF | 0x4400 7C00 - 0x4400 7FFF | TAMP | Section 58.6.20: TAMP register map | |
| 0x5400 7800 - 0x5400 7BFF | 0x4400 7800 - 0x4400 7BFF | RTC | Section 57.6.27: RTC register map | |
| 0x5400 7400 - 0x5400 77FF | 0x4400 7400 - 0x4400 77FF | VREFBUF | Section 33.5.3: VREFBUF register map | |
| 0x5400 5800 - 0x5400 73FF | 0x4400 5800 - 0x4400 73FF | Reserved | - | |
| 0x5400 5400 - 0x5400 57FF | 0x4400 5400 - 0x4400 57FF | LPTIM6 | Section 54.7.19: LPTIM register map | |
| 0x5400 5000 - 0x5400 53FF | 0x4400 5000 - 0x4400 53FF | LPTIM5 | ||
| 0x5400 4C00 - 0x5400 4FFF | 0x4400 4C00 - 0x4400 4FFF | LPTIM4 | ||
| 0x5400 4800 - 0x5400 4BFF | 0x4400 4800 - 0x4400 4BFF | LPTIM3 | ||
| 0x5400 4400 - 0x5400 47FF | 0x4400 4400 - 0x4400 47FF | LPTIM1 | ||
| 0x5400 3400 - 0x5400 43FF | 0x4400 3400 - 0x4400 43FF | Reserved | - | |
| 0x5400 3000 - 0x5400 33FF | 0x4400 3000 - 0x4400 33FF | I3C2 | Section 60.15.30: I3C register map | |
| 0x5400 2C00 - 0x5400 2FFF | 0x4400 2C00 - 0x4400 2FFF | I2C4 | Section 59.9.12: I2C register map | |
| 0x5400 2800 - 0x5400 2BFF | 0x4400 2800 - 0x4400 2BFF | I2C3 | ||
| 0x5400 2400 - 0x5400 27FF | 0x4400 2400 - 0x4400 27FF | LPUART1 | Section 62.7.14: LPUART register map | |
| 0x5400 2000 - 0x5400 23FF | 0x4400 2000 - 0x4400 23FF | SPI5 | Section 63.11.15: SPI/I2S register map | |
| 0x5400 0800 - 0x5400 1FFF | 0x4400 0800 - 0x4400 1FFF | Reserved | - | |
| 0x5400 0400 - 0x5400 07FF | 0x4400 0400 - 0x4400 07FF | SBS | Section 14.5.20: SBS register map | |
| 0x5400 0000 - 0x5400 03FF | 0x4400 0000 - 0x4400 03FF | Reserved | - |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| AHB2 | 0x520C 8000 - 0x53FF FFFF | 0x420C 8000 - 0x43FF FFFF | Reserved | - |
| 0x520C 7C00 - 0x520C 7FFF | 0x420C 7C00 - 0x420C 7FFF | CCB | Section 42.7.4: CCB register map | |
| 0x520C 4000 - 0x53FF 7BFF | 0x420C 4000 - 0x43FF 7BFF | Reserved | - | |
| 0x520C 2000 - 0x520C 3FFF | 0x420C 2000 - 0x420C 3FFF | PKA +RAM | Section 47.7.5: PKA register map | |
| 0x520C 1000 - 0x520C 1FFF | 0x420C 1000 - 0x420C 1FFF | Reserved | - | |
| 0x520C 0C00 - 0x520C 0FFF | 0x420C 0C00 - 0x420C 0FFF | SAES | Section 44.8.21: AES register map | |
| 0x520C 0800 - 0x520C 0BFF | 0x420C 0800 - 0x420C 0BFF | RNG | Section 43.7.9: RNG register map | |
| 0x520C 0400 - 0x520C 07FF | 0x420C 0400 - 0x420C 07FF | HASH | Section 46.6.8: HASH register map | |
| 0x520C 0000 - 0x520C 03FF | 0x420C 0000 - 0x420C 03FF | AES | Section 44.8.21: AES register map | |
| 0x5208 0000 - 0x520B FFFF | 0x4208 0000 - 0x420B FFFF | OTG_FS | Section 66.15.63: OTG_FS register map | |
| 0x5204 0000 - 0x5207 FFFF | 0x4204 0000 - 0x4207 FFFF | OTG_HS | Section 67.14.63: OTG_HS register map | |
| 0x5202 DC00 - 0x5203 FFFF | 0x4202 DC00 - 0x4203 FFFF | Reserved | - | |
| 0x5202 D800 - 0x5202 DBFF | 0x4202 D800 - 0x4202 DBFF | ADC3 | Section 30.8: ADC register map | |
| 0x5202 C800 - 0x5202 D7FF | 0x4202 C800 - 0x4202 D7FF | ADF1 | Section 37.8.16: ADF register map |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| AHB2(cont'd) | 0x5202 C400 - 0x5202 C7FF | 0x4202 C400 - 0x4202 C7FF | PSSI | Section 39.5.8: PSSI register map |
| 0x5202 C000 - 0x5202 C3FF | 0x4202 C000 - 0x4202 C3FF | DCMI | Section 38.5.12: DCMI register map | |
| 0x5202 8800 - 0x5202 BFFF | 0x4202 8800 - 0x4202 BFFF | Reserved | - | |
| 0x5202 8400 - 0x5202 87FF | 0x4202 8400 - 0x4202 87FF | DAC1 /DAC2 | Section 32.7.21: DAC register map | |
| 0x5202 8000 - 0x5202 83FF | 0x4202 8000 - 0x4202 83FF | ADC1 / ADC2 | Section 30.8: ADC register map | |
| 0x5202 2C00 - 0x5202 7FFF | 0x4202 2C00 - 0x4202 7FFF | Reserved | - | |
| 0x5202 2800 - 0x5202 2BFF | 0x4202 2800 - 0x4202 2BFF | GPIOK | Section 13.4.14: GPIO register map | |
| 0x5202 2400 - 0x5202 27FF | 0x4202 2400 - 0x4202 27FF | GPIOJ | ||
| 0x5202 2000 - 0x5202 23FF | 0x4202 2000 - 0x4202 23FF | GPIOI | ||
| 0x5202 1C00 - 0x5202 1FFF | 0x4202 1C00 - 0x4202 1FFF | GPIOH | ||
| 0x5202 1800 - 0x5202 1BFF | 0x4202 1800 - 0x4202 1BFF | GPIOG | ||
| 0x5202 1400 - 0x5202 17FF | 0x4202 1400 - 0x4202 17FF | GPIOF | ||
| 0x5202 1000 - 0x5202 13FF | 0x4202 1000 - 0x4202 13FF | GPIOE | ||
| 0x5202 0C00 - 0x5202 0FFF | 0x4202 0C00 - 0x4202 0FFF | GPIOD | ||
| 0x5202 0800 - 0x5202 0BFF | 0x4202 0800 - 0x4202 0BFF | GPIOC | ||
| 0x5202 0400 - 0x5202 07FF | 0x4202 0400 - 0x4202 07FF | GPIOB | ||
| 0x5202 0000 - 0x5202 03FF | 0x4202 0000 - 0x4202 03FF | GPIOA |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| AHB1 | 0x5003 7400 - 0x51FF FFFF | 0x4003 7400 - 0x41FF FFFF | Reserved | - |
| 0x5003 6400 - 0x5003 73FF | 0x4003 6400 - 0x4003 73FF | MPCWM4_BKPRAM | Section 5.6.12: GTZC1 TZSC register map | |
| 0x5003 4100 - 0x5003 63FF | 0x4003 4100 - 0x4003 63FF | Reserved | - | |
| 0x5003 2400 - 0x5003 40FF | 0x4003 2400 - 0x4003 40FF | GTZC1 | Section 5.6.12: GTZC1 TZSC register map | |
| 0x5003 1800 - 0x5003 23FF | 0x4003 1800 - 0x4003 23FF | Reserved | - | |
| 0x5003 1400 - 0x5003 17FF | 0x4003 1400 - 0x4003 17FF | DCACHE | Section 9.7.11: DCACHE register map | |
| 0x5003 0800 - 0x5003 13FF | 0x4003 0800 - 0x4003 13FF | Reserved | - | |
| 0x5003 0400 - 0x5003 07FF | 0x4003 0400 - 0x4003 07FF | ICACHE | Section 8.7.8: ICACHE register map | |
| 0x5002 C000 - 0x5003 03FF | 0x4002 C000 - 0x4003 03FF | Reserved | - | |
| 0x5002 B000 - 0x5002 BFFF | 0x4002 B000 - 0x4002 BFFF | JPEG | Section 41.5.19: JPEG codec register map | |
| 0x5002 A000 - 0x5002 AFFF | 0x4002 A000 - 0x4002 AFFF | DMA2D | Section 17.5.47: DMA2D register map | |
| 0x5002 9400 - 0x5002 9FFF | 0x4002 9400 - 0x4002 9FFF | Reserved | - | |
| 0x5002 8000 - 0x5002 93FF | 0x4002 8000 - 0x4002 93FF | ETHERNET MAC | Section 69.11.4: Ethernet MAC and MMC registers | |
| 0x5002 7000 - 0x5002 7FFF | 0x4002 7000 - 0x4002 7FFF | Reserved | - | |
| 0x5002 6000 - 0x5002 6FFF | 0x4002 6000 - 0x4002 6FFF | RAMCFG | Section 6.6.13: RAMCFG register map | |
| 0x5002 5000 - 0x5002 5FFF | 0x4002 5000 - 0x4002 5FFF | MDF1 | Section 36.8.21: MDF register map | |
| 0x5002 4000 - 0x5002 4FFF | 0x4002 4000 - 0x4002 4FFF | Reserved | - | |
| 0x5002 3C00 - 0x5002 3FFF | 0x4002 3C00 - 0x4002 3FFF | FMAC | Section 23.4.9: FMAC register map | |
| 0x5002 3800 - 0x5002 3BFF | 0x4002 3800 - 0x4002 3BFF | CORDIC | Section 22.4.4: CORDIC register map | |
| 0x5002 3400 - 0x5002 37FF | 0x4002 3400 - 0x4002 37FF | Reserved | - | |
| 0x5002 3000 - 0x5002 33FF | 0x4002 3000 - 0x4002 33FF | CRC | Section 21.4.6: CRC register map | |
| 0x5002 2400 - 0x5002 2FFF | 0x4002 2400 - 0x4002 2FFF | Reserved | - | |
| 0x5002 2000 - 0x5002 23FF | 0x4002 2000 - 0x4002 23FF | FLASH | Section 7.12: FLASH register map and reset values | |
| 0x5002 1000 - 0x5002 1FFF | 0x4002 1000 - 0x4002 1FFF | GPDMA2 | Section 16.8.20: GPDMA register map | |
| 0x5002 0000 - 0x5002 0FFF | 0x4002 0000 - 0x4002 0FFF | GPDMA1 |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| APB2 | 0x5001 7800 - 0x5001 FFFF | 0x4001 7800 - 0x4001 FFFF | Reserved | - |
| 0x5001 7400 - 0x5001 77FF | 0x4001 7400 - 0x4001 77FF | GFXTIM | Section 18.5.27: GFXTIM register map | |
| 0x5001 7000 - 0x5001 73FF | 0x4001 7000 - 0x4001 73FF | Reserved | - | |
| 0x5001 6C00 - 0x5001 6FFF | 0x4001 6C00 - 0x4001 6FFF | LTDC | Section 40.7.26: LTDC register map | |
| 0x5001 5C00 - 0x5001 6BFF | 0x4001 6400 - 0x4001 6BFF | Reserved | - | |
| 0x5001 5800 - 0x5001 5BFF | 0x4001 5800 - 0x4001 5BFF | SAI2 | Section 64.6.20: SAI register map | |
| 0x5001 5400 - 0x5001 57FF | 0x4001 5400 - 0x4001 57FF | SAI1 | ||
| 0x5001 5000 - 0x5001 53FF | 0x4001 5000 - 0x4001 53FF | SPI6 | Section 63.11.15: SPI/I2S register map | |
| 0x5001 4C00 - 0x5001 4FFF | 0x4001 4C00 - 0x4001 4FFF | SPI4 | ||
| 0x5001 4800 - 0x5001 4BFF | 0x4001 4800 - 0x4001 4BFF | TIM17 | Section 53.8.22: TIM16/TIM17 register map | |
| 0x5001 4400 - 0x5001 47FF | 0x4001 4400 - 0x4001 47FF | TIM16 | ||
| 0x5001 4000 - 0x5001 43FF | 0x4001 4000 - 0x4001 43FF | TIM15 | Section 53.7.23: TIM15 register map | |
| 0x5001 3C00 - 0x5001 3FFF | 0x4001 3C00 - 0x4001 3FFF | Reserved | - | |
| 0x5001 3800 - 0x5001 3BFF | 0x4001 3800 - 0x4001 3BFF | USART1 | Section 61.8.16: USART register map | |
| 0x5001 3400 - 0x5001 37FF | 0x4001 3400 - 0x4001 37FF | TIM8 | Section 49.6.31: TIMx register map | |
| 0x5001 3000 - 0x5001 33FF | 0x4001 3000 - 0x4001 33FF | SPI2S1 | Section 63.11.15: SPI/I2S register map | |
| 0x5001 2C00 - 0x5001 2FFF | 0x4001 2C00 - 0x4001 2FFF | TIM1 | Section 49.6.31: TIMx register map | |
| 0x5001 0000 - 0x5001 2BFF | 0x4001 0000 - 0x4001 2BFF | Reserved | - |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| APB1 | 0x5000 E000 - 0x5000 FFFF | 0x4000 E000 - 0x4000 FFFF | Reserved | - |
| 0x5000 DC00 - 0x5000 DFFF | 0x4000 DC00 - 0x4000 DFFF | UCPD1 | Section 68.8.15: UCPD register map | |
| 0x5000 B800 - 0x5000 DBFF | 0x4000 B800 - 0x4000 DBFF | Reserved | - | |
| 0x5000 AC00 - 0x5000 B7FF | 0x4000 AC00 - 0x4000 B7FF | FDCAN SRAM | Section 65.4.38: FDCAN register map | |
| 0x5000 A800 - 0x5000 ABFF | 0x4000 A800 - 0x4000 ABFF | FDCAN2 | ||
| 0x5000 A400 - 0x5000 A7FF | 0x4000 A400 - 0x4000 A7FF | FDCAN1 | ||
| 0x5000 A000 - 0x5000 A3FF | 0x4000 A000 - 0x4000 A3FF | FDCAN3 | ||
| 0x5000 9800 - 0x5000 9FFF | 0x4000 9800 - 0x4000 9FFF | Reserved | - | |
| 0x5000 9400 - 0x5000 97FF | 0x4000 9400 - 0x4000 97FF | LPTIM2 | Section 54.7.19: LPTIM register map | |
| 0x5000 9000 - 0x5000 93FF | 0x4000 9000 - 0x4000 93FF | Reserved | - | |
| 0x5000 8C00 - 0x5000 8FFF | 0x4000 8C00 - 0x4000 8FFF | DTS | Section 31.6.10: DTS register map | |
| 0x5000 8800 - 0x5000 8BFF | 0x4000 8800 - 0x4000 8BFF | Reserved | - | |
| 0x5000 8400 - 0x5000 87FF | 0x4000 8400 - 0x4000 87FF | UART12 | Section 61.8.16: USART register map | |
| 0x5000 8000 - 0x5000 83FF | 0x4000 8000 - 0x4000 83FF | UART9 | ||
| 0x5000 7C00 - 0x5000 7FFF | 0x4000 7C00 - 0x4000 7FFF | UART8 | ||
| 0x5000 7800 - 0x5000 7BFF | 0x4000 7800 - 0x4000 7BFF | UART7 | ||
| 0x5000 7400 - 0x5000 77FF | 0x4000 7400 - 0x4000 77FF | Reserved | - | |
| 0x5000 7000 - 0x5000 73FF | 0x4000 7000 - 0x4000 73FF | CEC | Section 70.7.7: HDMI-CEC register map | |
| 0x5000 6C00 - 0x5000 6FFF | 0x4000 6C00 - 0x4000 6FFF | USART11 | Section 61.8.16: USART register map | |
| 0x5000 6800 - 0x5000 6BFF | 0x4000 6800 - 0x4000 6BFF | USART10 | ||
| 0x5000 6400 - 0x5000 67FF | 0x4000 6400 - 0x4000 67FF | USART6 | ||
| 0x5000 6000 - 0x5000 63FF | 0x4000 6000 - 0x4000 63FF | CRS | Section 12.7.5: CRS register map | |
| 0x5000 5C00 - 0x5000 5FFF | 0x4000 5C00 - 0x4000 5FFF | I3C1 | Section 60.15.30: I3C register map |
Table 3. Memory map and peripheral register addresses (continued)
| Bus | Secure boundary address | Nonsecure boundary address | Peripheral | Register map |
|---|---|---|---|---|
| APB1 (cont'd) | 0x5000 5800 - 0x5000 5BFF | 0x4000 5800 - 0x4000 5BFF | I2C2 | Section 59.9.12: I2C register map |
| 0x5000 5400 - 0x5000 57FF | 0x4000 5400 - 0x4000 57FF | I2C1 | ||
| 0x5000 5000 - 0x5000 53FF | 0x4000 5000 - 0x4000 53FF | UART5 | Section 61.8.16: USART register map | |
| 0x5000 4C00 - 0x5000 4FFF | 0x4000 4C00 - 0x4000 4FFF | UART4 | ||
| 0x5000 4800 - 0x5000 4BFF | 0x4000 4800 - 0x4000 4BFF | USART3 | ||
| 0x5000 4400 - 0x5000 47FF | 0x4000 4400 - 0x4000 47FF | USART2 | ||
| 0x5000 4000 - 0x5000 43FF | 0x4000 4000 - 0x4000 43FF | COMP1 / COMP2 | Section 35.7.5: COMP register map | |
| 0x5000 3C00 - 0x5000 3FFF | 0x4000 3C00 - 0x4000 3FFF | SPI2S3 | Section 63.11.15: SPI/I2S register map | |
| 0x5000 3800 - 0x5000 3BFF | 0x4000 3800 - 0x4000 3BFF | SPI2S2 | ||
| 0x5000 3400 - 0x5000 37FF | 0x4000 3400 - 0x4000 37FF | OPAMP | Section 34.6.4: OPAMP register map | |
| 0x5000 3000 - 0x5000 33FF | 0x4000 3000 - 0x4000 33FF | IWDG | Section 55.7.7: IWDG register map | |
| 0x5000 2C00 - 0x5000 2FFF | 0x4000 2C00 - 0x4000 2FFF | WWDG | Section 56.6.4: WWDG register map | |
| 0x5000 2400 - 0x5000 2BFF | 0x4000 2400 - 0x4000 2BFF | Reserved | - | |
| 0x5000 2000 - 0x5000 23FF | 0x4000 2000 - 0x4000 23FF | TIM14 | Section 52.8.13: TIM13/TIM14 register map | |
| 0x5000 1C00 - 0x5000 1FFF | 0x4000 1C00 - 0x4000 1FFF | TIM13 | ||
| 0x5000 1800 - 0x5000 1BFF | 0x4000 1800 - 0x4000 1BFF | TIM12 | Section 52.7.16: TIM12 register map | |
| 0x5000 1400 - 0x5000 17FF | 0x4000 1400 - 0x4000 17FF | TIM7 | Section 51.4.9: TIMx register map | |
| 0x5000 1000 - 0x5000 13FF | 0x4000 1000 - 0x4000 13FF | TIM6 | ||
| 0x5000 0C00 - 0x5000 0FFF | 0x4000 0C00 - 0x4000 0FFF | TIM5 | Section 50.5.31: TIMx register map | |
| 0x5000 0800 - 0x5000 0BFF | 0x4000 0800 - 0x4000 0BFF | TIM4 | ||
| 0x5000 0400 - 0x5000 07FF | 0x4000 0400 - 0x4000 07FF | TIM3 | ||
| 0x5000 0000 - 0x5000 03FF | 0x4000 0000 - 0x4000 03FF | TIM2 |
2.3.3 Embedded SRAMs
The devices feature:
- • 256-Kbyte SRAM1
- • 128-Kbyte SRAM2
- • 384-Kbyte SRAM3
- • 384-Kbyte SRAM4
- • 384-Kbyte SRAM5
- • 4-Kbyte BKPSRAM
The SRAMs can be accessed as bytes, half-words (16 bits), or full words (32 bits).
The memories can be addressed both by CPU and DMAs. The CPU can access the SRAM1/2/3/4/5 through the system bus or through the C-bus, depending on the selected address. The CPU can access the BKPSRAM only through the system bus.
When the TrustZone security is enabled, all SRAMs are secure after reset. The SRAMs can be programmed as nonsecure with a block granularity. For more details, refer to Section 5: Global TrustZone® controller (GTZC).
SRAM features are detailed in Section 6.3.1: Internal SRAM features.
2.3.4 Flash memory overview
The flash memory is composed of two distinct physical areas:
- • The main memory block, which contains the application program and user data.
- • The information block is composed of the following parts:
- – Option bytes for hardware and memory protection user configuration
- – System memory, with the ST proprietary code
- – OTP (one-time programmable) area
The flash interface implements instruction and data access based on the AHB protocol. It also implements the logic necessary to carry out the program/erase operations controlled through the FLASH registers plus security access control features. Refer to Section 7: Embedded flash memory (FLASH) for more details.
2.3.5 Boot modes
At startup, the core jumps to the boot address configured through the BOOT0 pin, the BOOT_ADDR option bytes, the TZEN option bit, the debug request, and the product state.
If BOOT_ADDR is not yet configured, dedicated libraries (programmed during ST production), can be used for secure boot. They are located in system flash memory:
- • ST libraries in system flash memory assist the application software boot with special features such as secure boot and secure firmware install (SFI-RSS).
- • ST iROT (immutable root of trust) secure software in user flash memory is used for secure firmware update and provisioning (SFU).
If a debugger is attached to the product, the entry point is a debug authentication policy, used to unlock the device when attached to the debugger. A digital signature must be provided to perform a regression to the product state, where debug is allowed.
Embedded bootloader
The embedded bootloader is located in the system memory, programmed by ST during production. Refer to the application note STM32 microcontroller system memory boot mode (AN2606).