summaryrefslogtreecommitdiff
path: root/rcc/flash.h
diff options
context:
space:
mode:
authorVegard Storheil Eriksen <zyp@jvnv.net>2019-04-03 17:14:01 +0200
committerVegard Storheil Eriksen <zyp@jvnv.net>2019-04-03 17:14:01 +0200
commit3c526f3d0b30e200462290651f7c6a5eb30710a2 (patch)
tree4fe3cb5fc237d5ce7cd761a1c8a5640d88f6d21a /rcc/flash.h
parentd81982edb1c4abf9a38da742f81bb648ce6882c5 (diff)
Added STM32WB support.stm32wb
Diffstat (limited to 'rcc/flash.h')
-rw-r--r--rcc/flash.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/rcc/flash.h b/rcc/flash.h
index c1f7c1c..97875c6 100644
--- a/rcc/flash.h
+++ b/rcc/flash.h
@@ -31,6 +31,30 @@ struct FLASH_t {
volatile uint32_t SR;
volatile uint32_t OPTR;
volatile uint32_t WRPROT;
+ #elif defined(STM32WB)
+ volatile uint32_t ACR;
+ uint32_t _reserved;
+ volatile uint32_t KEYR;
+ volatile uint32_t OPTKEYR;
+ volatile uint32_t SR;
+ volatile uint32_t CR;
+ volatile uint32_t ECCR;
+ uint32_t _reserved_1;
+ volatile uint32_t OPTR;
+ volatile uint32_t PCROP1ASR;
+ volatile uint32_t PCROP1AER;
+ volatile uint32_t WRP1AR;
+ volatile uint32_t WRP1BR;
+ volatile uint32_t PCROP1BSR;
+ volatile uint32_t PCROP1BER;
+ volatile uint32_t IPCCBR;
+ uint32_t _reserved_2[7];
+ volatile uint32_t C2ACR;
+ volatile uint32_t C2SR;
+ volatile uint32_t C2CR;
+ uint32_t _reserved_3[6];
+ volatile uint32_t SFR;
+ volatile uint32_t SRRVR;
#endif
};
@@ -40,6 +64,8 @@ static FLASH_t& FLASH = *(FLASH_t*)0x40022000;
static FLASH_t& FLASH = *(FLASH_t*)0x40023c00;
#elif defined(STM32L0)
static FLASH_t& FLASH = *(FLASH_t*)0x40022000;
+#elif defined(STM32WB)
+static FLASH_t& FLASH = *(FLASH_t*)0x58004000;
#endif
void flash_init();