STM32 RTOS
0.2.3
Bare-metal preemptive RTOS for STM32F446RE
Toggle main menu visibility
Loading...
Searching...
No Matches
flash_reg.h
Go to the documentation of this file.
1
12
#ifndef FLASH_REG_H
13
#define FLASH_REG_H
14
15
#include <stdint.h>
16
21
22
#define FLASH_BASE (0x40023C00UL)
23
25
typedef
struct
FlashRegisters_t
26
{
27
volatile
uint32_t
ACR
;
28
volatile
uint32_t
KEYR
;
29
volatile
uint32_t
OPTKEYR
;
30
volatile
uint32_t
SR
;
31
volatile
uint32_t
CR
;
32
volatile
uint32_t
OPTCR
;
33
volatile
uint32_t
OPTCR1
;
34
}
FlashRegisters_t
;
35
36
#define FLASH ((FlashRegisters_t *)FLASH_BASE)
37
40
#define FLASH_ACR_LATENCY_Pos (0U)
42
#define FLASH_ACR_LATENCY_Msk ((uint32_t)0xFU << FLASH_ACR_LATENCY_Pos)
43
#define FLASH_ACR_PRFTEN_Pos (8U)
45
#define FLASH_ACR_PRFTEN ((uint32_t)1U << FLASH_ACR_PRFTEN_Pos)
46
#define FLASH_ACR_ICEN_Pos (9U)
48
#define FLASH_ACR_ICEN ((uint32_t)1U << FLASH_ACR_ICEN_Pos)
49
#define FLASH_ACR_DCEN_Pos (10U)
51
#define FLASH_ACR_DCEN ((uint32_t)1U << FLASH_ACR_DCEN_Pos)
52
#define FLASH_ACR_ICRST_Pos (11U)
54
#define FLASH_ACR_ICRST ((uint32_t)1U << FLASH_ACR_ICRST_Pos)
55
#define FLASH_ACR_DCRST_Pos (12U)
57
#define FLASH_ACR_DCRST ((uint32_t)1U << FLASH_ACR_DCRST_Pos)
59
62
#define FLASH_SR_EOP_Pos (0U)
64
#define FLASH_SR_EOP ((uint32_t)1U << FLASH_SR_EOP_Pos)
65
#define FLASH_SR_WRPERR_Pos (4U)
67
#define FLASH_SR_WRPERR ((uint32_t)1U << FLASH_SR_WRPERR_Pos)
68
#define FLASH_SR_BSY_Pos (16U)
70
#define FLASH_SR_BSY ((uint32_t)1U << FLASH_SR_BSY_Pos)
72
74
75
#endif
/* FLASH_REG_H */
FlashRegisters_t
Flash interface register block.
Definition
flash_reg.h:26
FlashRegisters_t::OPTCR1
volatile uint32_t OPTCR1
0x18: option control 1 (offset from ST's CMSIS header)
Definition
flash_reg.h:33
FlashRegisters_t::OPTKEYR
volatile uint32_t OPTKEYR
0x08: option key
Definition
flash_reg.h:29
FlashRegisters_t::KEYR
volatile uint32_t KEYR
0x04: key
Definition
flash_reg.h:28
FlashRegisters_t::ACR
volatile uint32_t ACR
0x00: access control
Definition
flash_reg.h:27
FlashRegisters_t::OPTCR
volatile uint32_t OPTCR
0x14: option control
Definition
flash_reg.h:32
FlashRegisters_t::CR
volatile uint32_t CR
0x10: control
Definition
flash_reg.h:31
FlashRegisters_t::SR
volatile uint32_t SR
0x0C: status
Definition
flash_reg.h:30
soc
stm32f446
inc
flash_reg.h
Generated by
1.18.0