EasyManua.ls Logo

ST STM32F103xx series User Manual

ST STM32F103xx series
31 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #21 background imageLoading...
Page #21 background image
PM0075 Reading/programming the embedded Flash memory
Doc ID 17863 Rev 1 21/31
On every system reset, the option byte loader (OBL) reads the information block and stores
the data into the Option byte register (FLASH_OBR) and the Write protection register
0x1FFF F80C
WRPx: Flash memory write protection option bytes
Bits [31:24]: nWRP3
Bits [23:16]: WRP3 (stored in FLASH_WRPR[31:24])
Bits [15:8]: nWRP2
Bits [7:0]: WRP2 (stored in FLASH_WRPR[23:16])
For low-density devices, one bit of the user option bytes WRPx is used to
protect 4 pages of 1 Kbyte in main memory block.
0: Write protection active
1: Write protection not active
In total, one user option byte is used to protect the 32-Kbyte main Flash memory.
WRP0: Write-protects pages 0 to 31
For medium-density devices, one bit of the user option bytes WRPx is used to
protect 4 pages of 1 Kbyte in main memory block.
0: Write protection active
1: Write protection not active
In total, four user option bytes are used to protect the 128-Kbyte main Flash
memory.
WRP0: Write-protects pages 0 to 31
WRP1: Write-protects pages 32 to 63
WRP2: Write-protects pages 64 to 95
WRP3: Write-protects pages 96 to 127
For high-density devices, one bit of the user option bytes WRPx is used to
protect 2 pages of 2 Kbytes in main memory block. However, the bit 7 of
WRP3 write protects pages 62 to 255.
0: Write protection active
1: Write protection not active
In total, four user option bytes are used to protect the 512-Kbyte main Flash
memory.
WRP0: Write-protects pages 0 to 15.
WRP1: Write-protects pages 16 to 31.
WRP2: Write-protects pages 32 to 47.
WRP3: bits 0-6 write-protect pages 48 to 61
bit 7 write-protects pages 62 to 255.
For connectivity line devices, one bit of the user option bytes WRPx is used to
protect 2 pages of 2 Kbytes in main memory block. However, the bit 7 of
WRP3 write-protects pages 62 to 127.
0: Write protection active
1: Write protection not active
In total, four user option bytes are used to protect the 256-Kbyte main Flash
memory.
WRP0: Write-protects pages 0 to 15.
WRP1: Write-protects pages 16 to 31.
WRP2: Write-protects pages 32 to 47.
WRP3: bits 0-6 write-protect pages 48 to 61
bit 7 write-protects pages 62 to 127.
Table 8. Description of the option bytes (continued)
Flash memory
address
Option bytes
Question and Answer IconNeed help?

Do you have a question about the ST STM32F103xx series and is the answer not in the manual?

ST STM32F103xx series Specifications

General IconGeneral
SeriesSTM32F103xx
CoreARM Cortex-M3
Operating FrequencyUp to 72 MHz
GPIO PinsUp to 80
Operating Voltage2.0 V to 3.6 V
ADC12-bit
Communication InterfacesUSART, SPI, I2C, CAN, USB
Operating Temperature-40°C to +85°C
PackageBGA

Summary

STM32F10xxx Flash Memory Programming and Erasing

Flash Memory Read Operations and Prefetching

Details how to read data from Flash memory, including instruction fetches and prefetch buffer.

Flash Program and Erase Controller (FPEC)

Covers the FPEC block, its registers, and key values for memory operations.

Unlocking Flash Memory and Main Programming

Explains the sequences for unlocking FPEC and the process of programming main Flash memory.

Flash Memory Erase Procedures

Details methods for erasing Flash memory, including page and mass erase operations.

STM32F10xxx Option Byte Programming

Describes the specific procedure for programming the device's option bytes.

Flash Memory Protection Mechanisms

Covers read protection, unprotection, and write protection for Flash memory.

STM32F10xxx Flash Interface Register Details

Related product manuals