EasyManuals Logo

ST STM32F31xx User Manual

ST STM32F31xx
584 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 #218 background imageLoading...
Page #218 background image
FLASH Memory (FLASH)
UM1581
218/584
DocID023800 Rev 1
 Launch the Option Bytes loader
 Erase the Option Bytes
 Set/Reset the write protection
 Set the Read protection Level
 Program the user option Bytes
 Set/Reset the BOOT1 bit
 Enable/Disable the VDDA Analog Monitoring
 Enable/Disable the SRAM parity
 Get the user option bytes
 Get the Write protection
 Get the read protection status
4. FLASH Interrupts and flags management functions: this group includes all needed
functions to:
 Enable/Disable the FLASH interrupt sources.
 Get flags status.
 Clear flags.
 Get FLASH operation status.
 Wait for last FLASH operation.
11.2.2 FLASH Interface configuration functions
This group includes the following functions:
ï‚· void FLASH_SetLatency(uint32_t FLASH_Latency);
ï‚· void FLASH_HalfCycleAccessCmd(uint32_t FLASH_HalfCycleAccess);
ï‚· void FLASH_PrefetchBufferCmd(FunctionalState NewState);
The unlock sequence is not needed for these functions.
ï‚· FLASH_SetLatency()
ï‚· FLASH_HalfCycleAccessCmd()
ï‚· FLASH_PrefetchBufferCmd()
11.2.3 FLASH Memory Programming functions
This group includes the following functions:
ï‚· void FLASH_Unlock(void);
ï‚· void FLASH_Lock(void);
ï‚· FLASH_Status FLASH_ErasePage(uint32_t Page_Address);
ï‚· FLASH_Status FLASH_EraseAllPages(void);
ï‚· FLASH_Status FLASH_ProgramWord(uint32_t Address, uint32_t Data);
ï‚· FLASH_Status FLASH_ProgramHalfWord(uint32_t Address, uint16_t Data);
Any operation of erase or program should follow these steps:
1. Call the FLASH_Unlock() function to enable the FLASH control register program
memory access.
2. Call the desired function to erase page or program data.
3. Call the FLASH_Lock() function to disable the FLASH control register access
(recommended to protect the FLASH memory against possible unwanted operation).
ï‚· FLASH_Unlock()
ï‚· FLASH_Lock()
ï‚· FLASH_ErasePage()

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

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

ST STM32F31xx Specifications

General IconGeneral
BrandST
ModelSTM32F31xx
CategoryMicrocontrollers
LanguageEnglish

Related product manuals