09.12.2012 Views

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>RM0090</strong> Embedded Flash memory interface<br />

3.8.2 Flash key register (FLASH_KEYR)<br />

The Flash key register is used to allow access to the Flash control register and so, to allow<br />

program and erase operations.<br />

Address offset: 0x04<br />

Reset value: 0x0000 0000<br />

Access: no wait state, word access<br />

31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16<br />

KEY[31:16]<br />

w w w w w w w w w w w w w w w w<br />

15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />

KEY[15:0]<br />

w w w w w w w w w w w w w w w w<br />

Bits 31:0 FKEYR: FPEC key<br />

The following values must be programmed consecutively to unlock the FLASH_CR register<br />

and allow programming/erasing it:<br />

a) KEY1 = 0x45670123<br />

b) KEY2 = 0xCDEF89AB<br />

3.8.3 Flash option key register (FLASH_OPTKEYR)<br />

The Flash option key register is used to allow program and erase operations in the user<br />

configuration sector.<br />

Address offset: 0x08<br />

Reset value: 0x0000 0000<br />

Access: no wait state, word access<br />

31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16<br />

OPTKEYR[31:16<br />

w w w w w w w w w w w w w w w w<br />

15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />

OPTKEYR[15:0]<br />

w w w w w w w w w w w w w w w w<br />

Bits 31:0 OPTKEYR: Option byte key<br />

The following values must be programmed consecutively to unlock the FLASH_OPTCR<br />

register and allow programming it:<br />

a) OPTKEY1 = 0x08192A3B<br />

b) OPTKEY2 = 0x4C5D6E7F<br />

Doc ID 018909 Rev 3 78/1416

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!