Go to the documentation of this file.
8 #error This header should not be included directly, use hal/micro/cortexm3/memmap.h
11 #ifndef __STM32W108_MEMMAP_H__
12 #define __STM32W108_MEMMAP_H__
14 #define RAM_BOTTOM (0x20000000u)
15 #define RAM_SIZE_B (0x2000)
16 #define RAM_SIZE_W (RAM_SIZE_B/4)
17 #define RAM_TOP (RAM_BOTTOM+RAM_SIZE_B-1)
19 #define MFB_BOTTOM (0x08000000u)
20 #define MFB_SIZE_B (0x20000)
21 #define MFB_SIZE_W (MFB_SIZE_B/4)
22 #define MFB_TOP (MFB_BOTTOM+MFB_SIZE_B-1)
23 #define MFB_PAGE_SIZE_B (1024)
24 #define MFB_PAGE_SIZE_W (MFB_PAGE_SIZE_B/4)
25 #define MFB_PAGE_MASK_B (0xFFFFFC00)
26 #define MFB_REGION_SIZE (4) // One write protection region is 4 pages.
27 #define MFB_ADDR_MASK (0x0003FFFFu)
29 #define CIB_BOTTOM (0x08040800u)
30 #define CIB_SIZE_B (0x200)
31 #define CIB_SIZE_W (CIB_SIZE_B/4)
32 #define CIB_TOP (CIB_BOTTOM+CIB_SIZE_B-1)
33 #define CIB_PAGE_SIZE_B (512)
34 #define CIB_PAGE_SIZE_W (CIB_PAGE_SIZE_B/4)
35 #define CIB_OB_BOTTOM (CIB_BOTTOM+0x00) //bottom address of CIB option bytes
36 #define CIB_OB_TOP (CIB_BOTTOM+0x0F) //top address of CIB option bytes
38 #define FIB_BOTTOM (0x08040000u)
39 #define FIB_SIZE_B (0x800)
40 #define FIB_SIZE_W (FIB_SIZE_B/4)
41 #define FIB_TOP (FIB_BOTTOM+FIB_SIZE_B-1)
42 #define FIB_PAGE_SIZE_B (1024)
43 #define FIB_PAGE_SIZE_W (FIB_PAGE_SIZE_B/4)
45 #define FPEC_KEY1 0x45670123 //magic key defined in hardware
46 #define FPEC_KEY2 0xCDEF89AB //magic key defined in hardware
49 #define SIMEE_ADDR_TO_PAGE(x) ((int8u)(((int16u)(x)) >> 9))
50 #define PAGE_TO_SIMEE_ADDR(x) (((int16u)(x)) << 9)
53 #define PROG_ADDR_TO_PAGE(x) ((int8u)((((int32u)(x))&MFB_ADDR_MASK) >> 10))
54 #define PAGE_TO_PROG_ADDR(x) ((((int32u)(x)) << 10)|MFB_BOTTOM)
57 #endif //__STM32W108_MEMMAP_H__