mbed official / mbed

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

Committer:
<>
Date:
Fri Sep 30 16:49:46 2016 +0100
Revision:
127:25aea2a3f4e3
Parent:
123:b0220dba8be7
Release 127 of the mbed library

Ports for Upcoming Targets

2669: Added u-blox C029 target https://github.com/ARMmbed/mbed-os/pull/2669
2707: [EFM32] Add IAR support for remaining Silicon Labs targets https://github.com/ARMmbed/mbed-os/pull/2707
2819: MultiTech xDot platform support - 09.26.2016 https://github.com/ARMmbed/mbed-os/pull/2819
2827: include MultiTech xDot in mbed 5 releases https://github.com/ARMmbed/mbed-os/pull/2827

Fixes and Changes

2522: Add CThunk for CM7 https://github.com/ARMmbed/mbed-os/pull/2522
2518: Enable uvisor on Beetle https://github.com/ARMmbed/mbed-os/pull/2518
2571: STM32F7 - Add asynchronous serial https://github.com/ARMmbed/mbed-os/pull/2571
2616: STM32F3xx - Add Serial Flow Control pins + enable it https://github.com/ARMmbed/mbed-os/pull/2616
2619: NUCLEO_L152RE - Add Serial Flow Control https://github.com/ARMmbed/mbed-os/pull/2619
2620: NUCLEO_F429ZI - Add SERIAL_FC macro https://github.com/ARMmbed/mbed-os/pull/2620
2666: [EFM32] Microsecond ticker optimization https://github.com/ARMmbed/mbed-os/pull/2666
2681: STM32F0xx - Add support of ADC internal channels https://github.com/ARMmbed/mbed-os/pull/2681
2687: [NRF5] Add fs_data symbol in data secton for gcc https://github.com/ARMmbed/mbed-os/pull/2687
2696: Add device_has to all nrf51 devices https://github.com/ARMmbed/mbed-os/pull/2696
2703: TARGET_NRF5: Changed 'serial_baud' implementation to support special baud rates. https://github.com/ARMmbed/mbed-os/pull/2703
2704: DISCO_L476VG: add SPI nicknames https://github.com/ARMmbed/mbed-os/pull/2704
2723: KSDK serial_api.c: Fix assertion error for ParityEven https://github.com/ARMmbed/mbed-os/pull/2723
2463: [STM32L0] Add asynchronous serial https://github.com/ARMmbed/mbed-os/pull/2463
2572: Fix STM32F407VG target name and LPC11U6X linker errors https://github.com/ARMmbed/mbed-os/pull/2572
2698: DELTA_DFBM_NQ620 target https://github.com/ARMmbed/mbed-os/pull/2698
2542: Dev spi asynch stm32f4 https://github.com/ARMmbed/mbed-os/pull/2542
2650: STM32F3 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2650
2415: [STM32F0] Add asynchronous serial https://github.com/ARMmbed/mbed-os/pull/2415
2585: Added support for ADC only pins in LPC43xx https://github.com/ARMmbed/mbed-os/pull/2585
2622: [STM32F4] Add asynchronous I2C https://github.com/ARMmbed/mbed-os/pull/2622
2719: Updated ARM linker scripts for Kinetis platforms that use SDK 2.0 https://github.com/ARMmbed/mbed-os/pull/2719
2728: Added ethernet and enabled IPV4 feature for the EVK-ODIN-W2/C029 target https://github.com/ARMmbed/mbed-os/pull/2728
2747: [LPC11U68] Fix pin interrupt select offset https://github.com/ARMmbed/mbed-os/pull/2747
2751: STM32L0xx - Add Serial Flow Control https://github.com/ARMmbed/mbed-os/pull/2751
2753: [NUCLEO_F767ZI] Add CAN capability https://github.com/ARMmbed/mbed-os/pull/2753
2759: STM32F0 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2759
2763: STM32L1 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2763
2764: STM32L4 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2764
2771: STM32L4 - Update deepsleep implementation https://github.com/ARMmbed/mbed-os/pull/2771
2775: Update KSDK SDHC driver for K64F & K66F https://github.com/ARMmbed/mbed-os/pull/2775
2792: [NUCLEO_F303ZE] MBED-OS5 capability https://github.com/ARMmbed/mbed-os/pull/2792
2762: STM32L0 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2762
2761: STM32F7 - Add low power timer https://github.com/ARMmbed/mbed-os/pull/2761

Who changed what in which revision?

UserRevisionLine numberNew contents of line
bogdanm 86:04dd9b1680ae 1 /**
bogdanm 86:04dd9b1680ae 2 ******************************************************************************
bogdanm 86:04dd9b1680ae 3 * @file stm32f3xx_hal_flash_ex.h
bogdanm 86:04dd9b1680ae 4 * @author MCD Application Team
Kojto 123:b0220dba8be7 5 * @version V1.3.0
Kojto 123:b0220dba8be7 6 * @date 01-July-2016
bogdanm 92:4fc01daae5a5 7 * @brief Header file of Flash HAL Extended module.
bogdanm 86:04dd9b1680ae 8 ******************************************************************************
bogdanm 86:04dd9b1680ae 9 * @attention
bogdanm 86:04dd9b1680ae 10 *
Kojto 122:f9eeca106725 11 * <h2><center>&copy; COPYRIGHT(c) 2016 STMicroelectronics</center></h2>
bogdanm 86:04dd9b1680ae 12 *
bogdanm 86:04dd9b1680ae 13 * Redistribution and use in source and binary forms, with or without modification,
bogdanm 86:04dd9b1680ae 14 * are permitted provided that the following conditions are met:
bogdanm 86:04dd9b1680ae 15 * 1. Redistributions of source code must retain the above copyright notice,
bogdanm 86:04dd9b1680ae 16 * this list of conditions and the following disclaimer.
bogdanm 86:04dd9b1680ae 17 * 2. Redistributions in binary form must reproduce the above copyright notice,
bogdanm 86:04dd9b1680ae 18 * this list of conditions and the following disclaimer in the documentation
bogdanm 86:04dd9b1680ae 19 * and/or other materials provided with the distribution.
bogdanm 86:04dd9b1680ae 20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
bogdanm 86:04dd9b1680ae 21 * may be used to endorse or promote products derived from this software
bogdanm 86:04dd9b1680ae 22 * without specific prior written permission.
bogdanm 86:04dd9b1680ae 23 *
bogdanm 86:04dd9b1680ae 24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
bogdanm 86:04dd9b1680ae 25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
bogdanm 86:04dd9b1680ae 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
bogdanm 86:04dd9b1680ae 27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
bogdanm 86:04dd9b1680ae 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
bogdanm 86:04dd9b1680ae 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
bogdanm 86:04dd9b1680ae 30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
bogdanm 86:04dd9b1680ae 31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
bogdanm 86:04dd9b1680ae 32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
bogdanm 86:04dd9b1680ae 33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
bogdanm 86:04dd9b1680ae 34 *
bogdanm 86:04dd9b1680ae 35 ******************************************************************************
bogdanm 86:04dd9b1680ae 36 */
bogdanm 86:04dd9b1680ae 37
bogdanm 86:04dd9b1680ae 38 /* Define to prevent recursive inclusion -------------------------------------*/
bogdanm 86:04dd9b1680ae 39 #ifndef __STM32F3xx_HAL_FLASH_EX_H
bogdanm 86:04dd9b1680ae 40 #define __STM32F3xx_HAL_FLASH_EX_H
bogdanm 86:04dd9b1680ae 41
bogdanm 86:04dd9b1680ae 42 #ifdef __cplusplus
bogdanm 86:04dd9b1680ae 43 extern "C" {
bogdanm 86:04dd9b1680ae 44 #endif
bogdanm 86:04dd9b1680ae 45
bogdanm 86:04dd9b1680ae 46 /* Includes ------------------------------------------------------------------*/
bogdanm 86:04dd9b1680ae 47 #include "stm32f3xx_hal_def.h"
bogdanm 86:04dd9b1680ae 48
bogdanm 86:04dd9b1680ae 49 /** @addtogroup STM32F3xx_HAL_Driver
bogdanm 86:04dd9b1680ae 50 * @{
bogdanm 86:04dd9b1680ae 51 */
bogdanm 86:04dd9b1680ae 52
Kojto 122:f9eeca106725 53 /** @addtogroup FLASHEx
bogdanm 86:04dd9b1680ae 54 * @{
bogdanm 86:04dd9b1680ae 55 */
bogdanm 86:04dd9b1680ae 56
Kojto 122:f9eeca106725 57 /** @addtogroup FLASHEx_Private_Constants
bogdanm 86:04dd9b1680ae 58 * @{
Kojto 122:f9eeca106725 59 */
Kojto 122:f9eeca106725 60
bogdanm 86:04dd9b1680ae 61 #define FLASH_SIZE_DATA_REGISTER ((uint32_t)0x1FFFF7CC)
Kojto 122:f9eeca106725 62
bogdanm 86:04dd9b1680ae 63 /**
bogdanm 86:04dd9b1680ae 64 * @}
Kojto 122:f9eeca106725 65 */
bogdanm 86:04dd9b1680ae 66
Kojto 122:f9eeca106725 67 /** @addtogroup FLASHEx_Private_Macros
bogdanm 86:04dd9b1680ae 68 * @{
bogdanm 86:04dd9b1680ae 69 */
Kojto 122:f9eeca106725 70 #define IS_FLASH_TYPEERASE(VALUE) (((VALUE) == FLASH_TYPEERASE_PAGES) || \
Kojto 122:f9eeca106725 71 ((VALUE) == FLASH_TYPEERASE_MASSERASE))
Kojto 122:f9eeca106725 72
Kojto 122:f9eeca106725 73 #define IS_OPTIONBYTE(VALUE) ((VALUE) <= (OPTIONBYTE_WRP | OPTIONBYTE_RDP | OPTIONBYTE_USER | OPTIONBYTE_DATA))
Kojto 122:f9eeca106725 74
Kojto 122:f9eeca106725 75 #define IS_WRPSTATE(VALUE) (((VALUE) == OB_WRPSTATE_DISABLE) || \
Kojto 122:f9eeca106725 76 ((VALUE) == OB_WRPSTATE_ENABLE))
Kojto 122:f9eeca106725 77
Kojto 122:f9eeca106725 78 #define IS_OB_DATA_ADDRESS(ADDRESS) (((ADDRESS) == OB_DATA_ADDRESS_DATA0) || ((ADDRESS) == OB_DATA_ADDRESS_DATA1))
Kojto 122:f9eeca106725 79
Kojto 122:f9eeca106725 80 #define IS_OB_RDP_LEVEL(LEVEL) (((LEVEL) == OB_RDP_LEVEL_0) ||\
Kojto 122:f9eeca106725 81 ((LEVEL) == OB_RDP_LEVEL_1))/*||\
Kojto 122:f9eeca106725 82 ((LEVEL) == OB_RDP_LEVEL_2))*/
Kojto 122:f9eeca106725 83
Kojto 122:f9eeca106725 84 #define IS_OB_IWDG_SOURCE(SOURCE) (((SOURCE) == OB_IWDG_SW) || ((SOURCE) == OB_IWDG_HW))
Kojto 122:f9eeca106725 85
Kojto 122:f9eeca106725 86 #define IS_OB_STOP_SOURCE(SOURCE) (((SOURCE) == OB_STOP_NO_RST) || ((SOURCE) == OB_STOP_RST))
Kojto 122:f9eeca106725 87
Kojto 122:f9eeca106725 88 #define IS_OB_STDBY_SOURCE(SOURCE) (((SOURCE) == OB_STDBY_NO_RST) || ((SOURCE) == OB_STDBY_RST))
Kojto 122:f9eeca106725 89
Kojto 122:f9eeca106725 90 #define IS_OB_BOOT1(BOOT1) (((BOOT1) == OB_BOOT1_RESET) || ((BOOT1) == OB_BOOT1_SET))
Kojto 122:f9eeca106725 91
Kojto 122:f9eeca106725 92 #define IS_OB_VDDA_ANALOG(ANALOG) (((ANALOG) == OB_VDDA_ANALOG_ON) || ((ANALOG) == OB_VDDA_ANALOG_OFF))
Kojto 122:f9eeca106725 93
Kojto 122:f9eeca106725 94 #define IS_OB_SRAM_PARITY(PARITY) (((PARITY) == OB_SRAM_PARITY_SET) || ((PARITY) == OB_SRAM_PARITY_RESET))
Kojto 122:f9eeca106725 95
Kojto 122:f9eeca106725 96
Kojto 122:f9eeca106725 97 #if defined(FLASH_OBR_SDADC12_VDD_MONITOR)
Kojto 122:f9eeca106725 98 #define IS_OB_SDACD_VDD_MONITOR(VDD_MONITOR) (((VDD_MONITOR) == OB_SDACD_VDD_MONITOR_SET) || \
Kojto 122:f9eeca106725 99 ((VDD_MONITOR) == OB_SDACD_VDD_MONITOR_RESET))
Kojto 122:f9eeca106725 100 #endif /* FLASH_OBR_SDADC12_VDD_MONITOR */
Kojto 122:f9eeca106725 101
Kojto 122:f9eeca106725 102 #define IS_OB_WRP(PAGE) (((PAGE) != 0x0000000))
Kojto 122:f9eeca106725 103
Kojto 122:f9eeca106725 104 #if defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 105 || defined(STM32F373xC) || defined(STM32F378xx)
Kojto 122:f9eeca106725 106 #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= FLASH_BASE) && (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x100) ? \
bogdanm 86:04dd9b1680ae 107 ((ADDRESS) <= 0x0803FFFF) : (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x80) ? \
bogdanm 86:04dd9b1680ae 108 ((ADDRESS) <= 0x0801FFFF) : ((ADDRESS) <= 0x0800FFFF))))
bogdanm 86:04dd9b1680ae 109 #endif /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 86:04dd9b1680ae 110 /* STM32F373xC || STM32F378xx */
bogdanm 86:04dd9b1680ae 111
bogdanm 92:4fc01daae5a5 112 #if defined(STM32F302xE) || defined(STM32F303xE) || defined(STM32F398xx)
Kojto 122:f9eeca106725 113 #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= FLASH_BASE) && ((ADDRESS) <= 0x0807FFFF))
bogdanm 92:4fc01daae5a5 114 #endif /* STM32F302xE || STM32F303xE || STM32F398xx */
bogdanm 92:4fc01daae5a5 115
Kojto 122:f9eeca106725 116 #if defined(STM32F301x8) || defined(STM32F302x8) || defined(STM32F318xx) \
Kojto 122:f9eeca106725 117 || defined(STM32F303x8) || defined(STM32F334x8) || defined(STM32F328xx)
Kojto 122:f9eeca106725 118 #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= FLASH_BASE) && (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x40) ? \
bogdanm 86:04dd9b1680ae 119 ((ADDRESS) <= 0x0800FFFF) : (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x20) ? \
bogdanm 86:04dd9b1680ae 120 ((ADDRESS) <= 0x08007FFF) : ((ADDRESS) <= 0x08003FFF))))
bogdanm 86:04dd9b1680ae 121 #endif /* STM32F301x8 || STM32F302x8 || STM32F318xx || */
bogdanm 86:04dd9b1680ae 122 /* STM32F303x8 || STM32F334x8 || STM32F328xx */
bogdanm 86:04dd9b1680ae 123
Kojto 122:f9eeca106725 124 #if defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 125 || defined(STM32F373xC) || defined(STM32F378xx)
bogdanm 86:04dd9b1680ae 126 #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x100) ? ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0803FFFF) : \
bogdanm 86:04dd9b1680ae 127 (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x80) ? ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0801FFFF) : \
bogdanm 86:04dd9b1680ae 128 ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0800FFFF)))
bogdanm 86:04dd9b1680ae 129 #endif /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 86:04dd9b1680ae 130 /* STM32F373xC || STM32F378xx */
bogdanm 86:04dd9b1680ae 131
bogdanm 92:4fc01daae5a5 132 #if defined(STM32F302xE) || defined(STM32F303xE) || defined(STM32F398xx)
bogdanm 92:4fc01daae5a5 133 #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0807FFFF)
bogdanm 92:4fc01daae5a5 134 #endif /* STM32F302xE || STM32F303xE || STM32F398xx */
bogdanm 92:4fc01daae5a5 135
Kojto 122:f9eeca106725 136 #if defined(STM32F301x8) || defined(STM32F302x8) || defined(STM32F318xx) \
Kojto 122:f9eeca106725 137 || defined(STM32F303x8) || defined(STM32F334x8) || defined(STM32F328xx)
bogdanm 86:04dd9b1680ae 138 #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x40) ? ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0800FFFF) : \
bogdanm 86:04dd9b1680ae 139 (((*((uint16_t *)FLASH_SIZE_DATA_REGISTER)) == 0x20) ? ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x08007FFF) : \
bogdanm 86:04dd9b1680ae 140 ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x08003FFF)))
bogdanm 86:04dd9b1680ae 141 #endif /* STM32F301x8 || STM32F302x8 || STM32F318xx || */
bogdanm 86:04dd9b1680ae 142 /* STM32F303x8 || STM32F334x8 || STM32F328xx */
Kojto 122:f9eeca106725 143
bogdanm 86:04dd9b1680ae 144 /**
bogdanm 86:04dd9b1680ae 145 * @}
bogdanm 86:04dd9b1680ae 146 */
bogdanm 86:04dd9b1680ae 147
Kojto 122:f9eeca106725 148 /* Exported types ------------------------------------------------------------*/
Kojto 122:f9eeca106725 149 /** @defgroup FLASHEx_Exported_Types FLASHEx Exported Types
Kojto 122:f9eeca106725 150 * @{
Kojto 122:f9eeca106725 151 */
Kojto 122:f9eeca106725 152 /**
Kojto 122:f9eeca106725 153 * @brief FLASH Erase structure definition
Kojto 122:f9eeca106725 154 */
Kojto 122:f9eeca106725 155 typedef struct
Kojto 122:f9eeca106725 156 {
Kojto 122:f9eeca106725 157 uint32_t TypeErase; /*!< TypeErase: Mass erase or page erase.
Kojto 122:f9eeca106725 158 This parameter can be a value of @ref FLASHEx_Type_Erase */
Kojto 122:f9eeca106725 159
Kojto 122:f9eeca106725 160 uint32_t PageAddress; /*!< PageAdress: Initial FLASH page address to erase when mass erase is disabled
Kojto 122:f9eeca106725 161 This parameter must be a number between Min_Data = FLASH_BASE and Max_Data = FLASH_BANK1_END */
Kojto 122:f9eeca106725 162
Kojto 122:f9eeca106725 163 uint32_t NbPages; /*!< NbPages: Number of pagess to be erased.
Kojto 122:f9eeca106725 164 This parameter must be a value between Min_Data = 1 and Max_Data = (max number of pages - value of initial page)*/
Kojto 122:f9eeca106725 165
Kojto 122:f9eeca106725 166 } FLASH_EraseInitTypeDef;
Kojto 122:f9eeca106725 167
Kojto 122:f9eeca106725 168 /**
Kojto 122:f9eeca106725 169 * @brief FLASH Options bytes program structure definition
Kojto 122:f9eeca106725 170 */
Kojto 122:f9eeca106725 171 typedef struct
Kojto 122:f9eeca106725 172 {
Kojto 122:f9eeca106725 173 uint32_t OptionType; /*!< OptionType: Option byte to be configured.
Kojto 122:f9eeca106725 174 This parameter can be a value of @ref FLASHEx_OB_Type */
Kojto 122:f9eeca106725 175
Kojto 122:f9eeca106725 176 uint32_t WRPState; /*!< WRPState: Write protection activation or deactivation.
Kojto 122:f9eeca106725 177 This parameter can be a value of @ref FLASHEx_OB_WRP_State */
Kojto 122:f9eeca106725 178
Kojto 122:f9eeca106725 179 uint32_t WRPPage; /*!< WRPPage: specifies the page(s) to be write protected
Kojto 122:f9eeca106725 180 This parameter can be a value of @ref FLASHEx_OB_Write_Protection */
Kojto 122:f9eeca106725 181
Kojto 122:f9eeca106725 182 uint8_t RDPLevel; /*!< RDPLevel: Set the read protection level..
Kojto 122:f9eeca106725 183 This parameter can be a value of @ref FLASHEx_OB_Read_Protection */
Kojto 122:f9eeca106725 184
Kojto 122:f9eeca106725 185 uint8_t USERConfig; /*!< USERConfig: Program the FLASH User Option Byte:
Kojto 122:f9eeca106725 186 IWDG / STOP / STDBY / BOOT1 / VDDA_ANALOG / SRAM_PARITY / SDADC12_VDD_MONITOR
Kojto 122:f9eeca106725 187 This parameter can be a combination of @ref FLASHEx_OB_IWatchdog, @ref FLASHEx_OB_nRST_STOP,
Kojto 122:f9eeca106725 188 @ref FLASHEx_OB_nRST_STDBY, @ref FLASHEx_OB_BOOT1, @ref FLASHEx_OB_VDDA_Analog_Monitoring,
Kojto 122:f9eeca106725 189 @ref FLASHEx_OB_RAM_Parity_Check_Enable.
Kojto 122:f9eeca106725 190 @if STM32F373xC
Kojto 122:f9eeca106725 191 And @ref FLASHEx_OB_SDADC12_VDD_MONITOR (only for STM32F373xC & STM32F378xx devices)
Kojto 122:f9eeca106725 192 @endif
Kojto 122:f9eeca106725 193 @if STM32F378xx
Kojto 122:f9eeca106725 194 And @ref FLASHEx_OB_SDADC12_VDD_MONITOR (only for STM32F373xC & STM32F378xx devices)
Kojto 122:f9eeca106725 195 @endif
Kojto 122:f9eeca106725 196 */
Kojto 122:f9eeca106725 197
Kojto 122:f9eeca106725 198 uint32_t DATAAddress; /*!< DATAAddress: Address of the option byte DATA to be programmed
Kojto 122:f9eeca106725 199 This parameter can be a value of @ref FLASHEx_OB_Data_Address */
Kojto 122:f9eeca106725 200
Kojto 122:f9eeca106725 201 uint8_t DATAData; /*!< DATAData: Data to be stored in the option byte DATA
Kojto 122:f9eeca106725 202 This parameter must be a number between Min_Data = 0x00 and Max_Data = 0xFF */
Kojto 122:f9eeca106725 203 } FLASH_OBProgramInitTypeDef;
Kojto 122:f9eeca106725 204 /**
Kojto 122:f9eeca106725 205 * @}
Kojto 122:f9eeca106725 206 */
Kojto 122:f9eeca106725 207
Kojto 122:f9eeca106725 208 /* Exported constants --------------------------------------------------------*/
Kojto 122:f9eeca106725 209 /** @defgroup FLASHEx_Exported_Constants FLASHEx Exported Constants
Kojto 122:f9eeca106725 210 * @{
Kojto 122:f9eeca106725 211 */
Kojto 122:f9eeca106725 212
Kojto 122:f9eeca106725 213 /** @defgroup FLASHEx_Page_Size FLASHEx Page Size
Kojto 122:f9eeca106725 214 * @{
Kojto 122:f9eeca106725 215 */
Kojto 122:f9eeca106725 216 #define FLASH_PAGE_SIZE 0x800
Kojto 122:f9eeca106725 217 /**
Kojto 122:f9eeca106725 218 * @}
Kojto 122:f9eeca106725 219 */
Kojto 122:f9eeca106725 220
Kojto 122:f9eeca106725 221 /** @defgroup FLASHEx_Type_Erase FLASH Type Erase
Kojto 122:f9eeca106725 222 * @{
Kojto 122:f9eeca106725 223 */
Kojto 122:f9eeca106725 224 #define FLASH_TYPEERASE_PAGES ((uint32_t)0x00) /*!<Pages erase only*/
Kojto 122:f9eeca106725 225 #define FLASH_TYPEERASE_MASSERASE ((uint32_t)0x01) /*!<Flash mass erase activation*/
Kojto 122:f9eeca106725 226
Kojto 122:f9eeca106725 227 /**
Kojto 122:f9eeca106725 228 * @}
Kojto 122:f9eeca106725 229 */
Kojto 122:f9eeca106725 230
Kojto 122:f9eeca106725 231 /** @defgroup FLASHEx_OptionByte_Constants Option Byte Constants
Kojto 122:f9eeca106725 232 * @{
Kojto 122:f9eeca106725 233 */
Kojto 122:f9eeca106725 234
Kojto 122:f9eeca106725 235 /** @defgroup FLASHEx_OB_Type Option Bytes Type
Kojto 122:f9eeca106725 236 * @{
Kojto 122:f9eeca106725 237 */
Kojto 122:f9eeca106725 238 #define OPTIONBYTE_WRP ((uint32_t)0x01) /*!<WRP option byte configuration*/
Kojto 122:f9eeca106725 239 #define OPTIONBYTE_RDP ((uint32_t)0x02) /*!<RDP option byte configuration*/
Kojto 122:f9eeca106725 240 #define OPTIONBYTE_USER ((uint32_t)0x04) /*!<USER option byte configuration*/
Kojto 122:f9eeca106725 241 #define OPTIONBYTE_DATA ((uint32_t)0x08) /*!<DATA option byte configuration*/
Kojto 122:f9eeca106725 242
Kojto 122:f9eeca106725 243 /**
Kojto 122:f9eeca106725 244 * @}
Kojto 122:f9eeca106725 245 */
Kojto 122:f9eeca106725 246
Kojto 122:f9eeca106725 247 /** @defgroup FLASHEx_OB_WRP_State Option Byte WRP State
Kojto 122:f9eeca106725 248 * @{
Kojto 122:f9eeca106725 249 */
Kojto 122:f9eeca106725 250 #define OB_WRPSTATE_DISABLE ((uint32_t)0x00) /*!<Disable the write protection of the desired pages*/
Kojto 122:f9eeca106725 251 #define OB_WRPSTATE_ENABLE ((uint32_t)0x01) /*!<Enable the write protection of the desired pagess*/
Kojto 122:f9eeca106725 252
Kojto 122:f9eeca106725 253 /**
Kojto 122:f9eeca106725 254 * @}
Kojto 122:f9eeca106725 255 */
Kojto 122:f9eeca106725 256
Kojto 122:f9eeca106725 257 /** @defgroup FLASHEx_OB_Write_Protection FLASHEx OB Write Protection
bogdanm 86:04dd9b1680ae 258 * @{
bogdanm 86:04dd9b1680ae 259 */
bogdanm 86:04dd9b1680ae 260 #define OB_WRP_PAGES0TO1 ((uint32_t)0x00000001) /* Write protection of page 0 to 1 */
bogdanm 86:04dd9b1680ae 261 #define OB_WRP_PAGES2TO3 ((uint32_t)0x00000002) /* Write protection of page 2 to 3 */
bogdanm 86:04dd9b1680ae 262 #define OB_WRP_PAGES4TO5 ((uint32_t)0x00000004) /* Write protection of page 4 to 5 */
bogdanm 86:04dd9b1680ae 263 #define OB_WRP_PAGES6TO7 ((uint32_t)0x00000008) /* Write protection of page 6 to 7 */
bogdanm 86:04dd9b1680ae 264 #define OB_WRP_PAGES8TO9 ((uint32_t)0x00000010) /* Write protection of page 8 to 9 */
bogdanm 86:04dd9b1680ae 265 #define OB_WRP_PAGES10TO11 ((uint32_t)0x00000020) /* Write protection of page 10 to 11 */
bogdanm 86:04dd9b1680ae 266 #define OB_WRP_PAGES12TO13 ((uint32_t)0x00000040) /* Write protection of page 12 to 13 */
bogdanm 86:04dd9b1680ae 267 #define OB_WRP_PAGES14TO15 ((uint32_t)0x00000080) /* Write protection of page 14 to 15 */
bogdanm 86:04dd9b1680ae 268 #define OB_WRP_PAGES16TO17 ((uint32_t)0x00000100) /* Write protection of page 16 to 17 */
bogdanm 86:04dd9b1680ae 269 #define OB_WRP_PAGES18TO19 ((uint32_t)0x00000200) /* Write protection of page 18 to 19 */
bogdanm 86:04dd9b1680ae 270 #define OB_WRP_PAGES20TO21 ((uint32_t)0x00000400) /* Write protection of page 20 to 21 */
bogdanm 86:04dd9b1680ae 271 #define OB_WRP_PAGES22TO23 ((uint32_t)0x00000800) /* Write protection of page 22 to 23 */
bogdanm 86:04dd9b1680ae 272 #define OB_WRP_PAGES24TO25 ((uint32_t)0x00001000) /* Write protection of page 24 to 25 */
bogdanm 86:04dd9b1680ae 273 #define OB_WRP_PAGES26TO27 ((uint32_t)0x00002000) /* Write protection of page 26 to 27 */
bogdanm 86:04dd9b1680ae 274 #define OB_WRP_PAGES28TO29 ((uint32_t)0x00004000) /* Write protection of page 28 to 29 */
bogdanm 86:04dd9b1680ae 275 #define OB_WRP_PAGES30TO31 ((uint32_t)0x00008000) /* Write protection of page 30 to 31 */
bogdanm 92:4fc01daae5a5 276
Kojto 122:f9eeca106725 277 #if defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 278 || defined(STM32F373xC) || defined(STM32F378xx)
bogdanm 86:04dd9b1680ae 279 #define OB_WRP_PAGES32TO33 ((uint32_t)0x00010000) /* Write protection of page 32 to 33 */
bogdanm 86:04dd9b1680ae 280 #define OB_WRP_PAGES34TO35 ((uint32_t)0x00020000) /* Write protection of page 34 to 35 */
bogdanm 86:04dd9b1680ae 281 #define OB_WRP_PAGES36TO37 ((uint32_t)0x00040000) /* Write protection of page 36 to 37 */
bogdanm 86:04dd9b1680ae 282 #define OB_WRP_PAGES38TO39 ((uint32_t)0x00080000) /* Write protection of page 38 to 39 */
bogdanm 86:04dd9b1680ae 283 #define OB_WRP_PAGES40TO41 ((uint32_t)0x00100000) /* Write protection of page 40 to 41 */
bogdanm 86:04dd9b1680ae 284 #define OB_WRP_PAGES42TO43 ((uint32_t)0x00200000) /* Write protection of page 42 to 43 */
bogdanm 86:04dd9b1680ae 285 #define OB_WRP_PAGES44TO45 ((uint32_t)0x00400000) /* Write protection of page 44 to 45 */
bogdanm 86:04dd9b1680ae 286 #define OB_WRP_PAGES46TO47 ((uint32_t)0x00800000) /* Write protection of page 46 to 47 */
bogdanm 86:04dd9b1680ae 287 #define OB_WRP_PAGES48TO49 ((uint32_t)0x01000000) /* Write protection of page 48 to 49 */
bogdanm 86:04dd9b1680ae 288 #define OB_WRP_PAGES50TO51 ((uint32_t)0x02000000) /* Write protection of page 50 to 51 */
bogdanm 86:04dd9b1680ae 289 #define OB_WRP_PAGES52TO53 ((uint32_t)0x04000000) /* Write protection of page 52 to 53 */
bogdanm 86:04dd9b1680ae 290 #define OB_WRP_PAGES54TO55 ((uint32_t)0x08000000) /* Write protection of page 54 to 55 */
bogdanm 86:04dd9b1680ae 291 #define OB_WRP_PAGES56TO57 ((uint32_t)0x10000000) /* Write protection of page 56 to 57 */
bogdanm 86:04dd9b1680ae 292 #define OB_WRP_PAGES58TO59 ((uint32_t)0x20000000) /* Write protection of page 58 to 59 */
bogdanm 86:04dd9b1680ae 293 #define OB_WRP_PAGES60TO61 ((uint32_t)0x40000000) /* Write protection of page 60 to 61 */
Kojto 122:f9eeca106725 294 #define OB_WRP_PAGES62TO127 ((uint32_t)0x80000000U) /* Write protection of page 62 to 127 */
bogdanm 92:4fc01daae5a5 295 #endif /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 92:4fc01daae5a5 296 /* STM32F373xC || STM32F378xx */
bogdanm 92:4fc01daae5a5 297
bogdanm 92:4fc01daae5a5 298 #if defined(STM32F302xE) || defined(STM32F303xE) || defined(STM32F398xx)
bogdanm 92:4fc01daae5a5 299 #define OB_WRP_PAGES32TO33 ((uint32_t)0x00010000) /* Write protection of page 32 to 33 */
bogdanm 92:4fc01daae5a5 300 #define OB_WRP_PAGES34TO35 ((uint32_t)0x00020000) /* Write protection of page 34 to 35 */
bogdanm 92:4fc01daae5a5 301 #define OB_WRP_PAGES36TO37 ((uint32_t)0x00040000) /* Write protection of page 36 to 37 */
bogdanm 92:4fc01daae5a5 302 #define OB_WRP_PAGES38TO39 ((uint32_t)0x00080000) /* Write protection of page 38 to 39 */
bogdanm 92:4fc01daae5a5 303 #define OB_WRP_PAGES40TO41 ((uint32_t)0x00100000) /* Write protection of page 40 to 41 */
bogdanm 92:4fc01daae5a5 304 #define OB_WRP_PAGES42TO43 ((uint32_t)0x00200000) /* Write protection of page 42 to 43 */
bogdanm 92:4fc01daae5a5 305 #define OB_WRP_PAGES44TO45 ((uint32_t)0x00400000) /* Write protection of page 44 to 45 */
bogdanm 92:4fc01daae5a5 306 #define OB_WRP_PAGES46TO47 ((uint32_t)0x00800000) /* Write protection of page 46 to 47 */
bogdanm 92:4fc01daae5a5 307 #define OB_WRP_PAGES48TO49 ((uint32_t)0x01000000) /* Write protection of page 48 to 49 */
bogdanm 92:4fc01daae5a5 308 #define OB_WRP_PAGES50TO51 ((uint32_t)0x02000000) /* Write protection of page 50 to 51 */
bogdanm 92:4fc01daae5a5 309 #define OB_WRP_PAGES52TO53 ((uint32_t)0x04000000) /* Write protection of page 52 to 53 */
bogdanm 92:4fc01daae5a5 310 #define OB_WRP_PAGES54TO55 ((uint32_t)0x08000000) /* Write protection of page 54 to 55 */
bogdanm 92:4fc01daae5a5 311 #define OB_WRP_PAGES56TO57 ((uint32_t)0x10000000) /* Write protection of page 56 to 57 */
bogdanm 92:4fc01daae5a5 312 #define OB_WRP_PAGES58TO59 ((uint32_t)0x20000000) /* Write protection of page 58 to 59 */
bogdanm 92:4fc01daae5a5 313 #define OB_WRP_PAGES60TO61 ((uint32_t)0x40000000) /* Write protection of page 60 to 61 */
Kojto 122:f9eeca106725 314 #define OB_WRP_PAGES62TO255 ((uint32_t)0x80000000U) /* Write protection of page 62 to 255 */
bogdanm 92:4fc01daae5a5 315 #endif /* STM32F302xE || STM32F303xE || STM32F398xx */
bogdanm 86:04dd9b1680ae 316
Kojto 122:f9eeca106725 317 #define OB_WRP_PAGES0TO15MASK ((uint32_t)0x000000FFU)
Kojto 122:f9eeca106725 318 #define OB_WRP_PAGES16TO31MASK ((uint32_t)0x0000FF00U)
bogdanm 92:4fc01daae5a5 319
Kojto 122:f9eeca106725 320 #if defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 321 || defined(STM32F373xC) || defined(STM32F378xx)
Kojto 122:f9eeca106725 322 #define OB_WRP_PAGES32TO47MASK ((uint32_t)0x00FF0000U)
Kojto 122:f9eeca106725 323 #define OB_WRP_PAGES48TO127MASK ((uint32_t)0xFF000000U)
bogdanm 92:4fc01daae5a5 324 #endif /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 92:4fc01daae5a5 325 /* STM32F373xC || STM32F378xx */
bogdanm 86:04dd9b1680ae 326
bogdanm 92:4fc01daae5a5 327 #if defined(STM32F302xE) || defined(STM32F303xE) || defined(STM32F398xx)
Kojto 122:f9eeca106725 328 #define OB_WRP_PAGES32TO47MASK ((uint32_t)0x00FF0000U)
Kojto 122:f9eeca106725 329 #define OB_WRP_PAGES48TO255MASK ((uint32_t)0xFF000000U)
bogdanm 92:4fc01daae5a5 330 #endif /* STM32F302xE || STM32F303xE || STM32F398xx */
bogdanm 92:4fc01daae5a5 331
Kojto 122:f9eeca106725 332 #if defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 333 || defined(STM32F373xC) || defined(STM32F378xx)
Kojto 122:f9eeca106725 334 #define OB_WRP_PAGES32TO47MASK ((uint32_t)0x00FF0000U)
Kojto 122:f9eeca106725 335 #define OB_WRP_PAGES48TO127MASK ((uint32_t)0xFF000000U)
bogdanm 92:4fc01daae5a5 336 #endif /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 92:4fc01daae5a5 337 /* STM32F373xC || STM32F378xx */
bogdanm 86:04dd9b1680ae 338
Kojto 122:f9eeca106725 339 #if defined(STM32F302xE) || defined(STM32F303xE) || defined(STM32F398xx) \
Kojto 122:f9eeca106725 340 || defined(STM32F302xC) || defined(STM32F303xC) || defined(STM32F358xx) \
Kojto 122:f9eeca106725 341 || defined(STM32F373xC) || defined(STM32F378xx)
Kojto 122:f9eeca106725 342 #define OB_WRP_ALLPAGES ((uint32_t)0xFFFFFFFFU) /*!< Write protection of all pages */
bogdanm 92:4fc01daae5a5 343 #endif /* STM32F302xE || STM32F303xE || STM32F398xx || */
bogdanm 92:4fc01daae5a5 344 /* STM32F302xC || STM32F303xC || STM32F358xx || */
bogdanm 92:4fc01daae5a5 345 /* STM32F373xC || STM32F378xx */
bogdanm 86:04dd9b1680ae 346
Kojto 122:f9eeca106725 347 #if defined(STM32F301x8) || defined(STM32F302x8) || defined(STM32F318xx) \
Kojto 122:f9eeca106725 348 || defined(STM32F303x8) || defined(STM32F334x8) || defined(STM32F328xx)
bogdanm 86:04dd9b1680ae 349 #define OB_WRP_ALLPAGES ((uint32_t)0x0000FFFF) /*!< Write protection of all pages */
bogdanm 86:04dd9b1680ae 350 #endif /* STM32F301x8 || STM32F302x8 || STM32F318xx || */
bogdanm 92:4fc01daae5a5 351 /* STM32F303x8 || STM32F334x8 || STM32F328xx */
bogdanm 86:04dd9b1680ae 352
Kojto 122:f9eeca106725 353 /**
Kojto 122:f9eeca106725 354 * @}
Kojto 122:f9eeca106725 355 */
Kojto 122:f9eeca106725 356
Kojto 122:f9eeca106725 357 /** @defgroup FLASHEx_OB_Read_Protection Option Byte Read Protection
Kojto 122:f9eeca106725 358 * @{
Kojto 122:f9eeca106725 359 */
Kojto 122:f9eeca106725 360 #define OB_RDP_LEVEL_0 ((uint8_t)0xAA)
Kojto 122:f9eeca106725 361 #define OB_RDP_LEVEL_1 ((uint8_t)0xBB)
Kojto 122:f9eeca106725 362 #define OB_RDP_LEVEL_2 ((uint8_t)0xCC) /*!< Warning: When enabling read protection level 2
Kojto 122:f9eeca106725 363 it's no more possible to go back to level 1 or 0 */
Kojto 122:f9eeca106725 364 /**
Kojto 122:f9eeca106725 365 * @}
Kojto 122:f9eeca106725 366 */
Kojto 122:f9eeca106725 367
Kojto 122:f9eeca106725 368 /** @defgroup FLASHEx_OB_IWatchdog Option Byte IWatchdog
Kojto 122:f9eeca106725 369 * @{
Kojto 122:f9eeca106725 370 */
Kojto 122:f9eeca106725 371 #define OB_IWDG_SW ((uint8_t)0x01) /*!< Software IWDG selected */
Kojto 122:f9eeca106725 372 #define OB_IWDG_HW ((uint8_t)0x00) /*!< Hardware IWDG selected */
Kojto 122:f9eeca106725 373 /**
Kojto 122:f9eeca106725 374 * @}
Kojto 122:f9eeca106725 375 */
Kojto 122:f9eeca106725 376
Kojto 122:f9eeca106725 377 /** @defgroup FLASHEx_OB_nRST_STOP Option Byte nRST STOP
Kojto 122:f9eeca106725 378 * @{
Kojto 122:f9eeca106725 379 */
Kojto 122:f9eeca106725 380 #define OB_STOP_NO_RST ((uint8_t)0x02) /*!< No reset generated when entering in STOP */
Kojto 122:f9eeca106725 381 #define OB_STOP_RST ((uint8_t)0x00) /*!< Reset generated when entering in STOP */
bogdanm 86:04dd9b1680ae 382 /**
bogdanm 86:04dd9b1680ae 383 * @}
bogdanm 86:04dd9b1680ae 384 */
bogdanm 86:04dd9b1680ae 385
Kojto 122:f9eeca106725 386 /** @defgroup FLASHEx_OB_nRST_STDBY Option Byte nRST STDBY
Kojto 122:f9eeca106725 387 * @{
Kojto 122:f9eeca106725 388 */
Kojto 122:f9eeca106725 389 #define OB_STDBY_NO_RST ((uint8_t)0x04) /*!< No reset generated when entering in STANDBY */
Kojto 122:f9eeca106725 390 #define OB_STDBY_RST ((uint8_t)0x00) /*!< Reset generated when entering in STANDBY */
Kojto 122:f9eeca106725 391 /**
Kojto 122:f9eeca106725 392 * @}
Kojto 122:f9eeca106725 393 */
Kojto 122:f9eeca106725 394
Kojto 122:f9eeca106725 395 /** @defgroup FLASHEx_OB_BOOT1 Option Byte BOOT1
Kojto 122:f9eeca106725 396 * @{
Kojto 122:f9eeca106725 397 */
Kojto 122:f9eeca106725 398 #define OB_BOOT1_RESET ((uint8_t)0x00) /*!< BOOT1 Reset */
Kojto 122:f9eeca106725 399 #define OB_BOOT1_SET ((uint8_t)0x10) /*!< BOOT1 Set */
Kojto 122:f9eeca106725 400 /**
Kojto 122:f9eeca106725 401 * @}
Kojto 122:f9eeca106725 402 */
Kojto 122:f9eeca106725 403
Kojto 122:f9eeca106725 404 /** @defgroup FLASHEx_OB_VDDA_Analog_Monitoring Option Byte VDDA Analog Monitoring
Kojto 122:f9eeca106725 405 * @{
Kojto 122:f9eeca106725 406 */
Kojto 122:f9eeca106725 407 #define OB_VDDA_ANALOG_ON ((uint8_t)0x20) /*!< Analog monitoring on VDDA Power source ON */
Kojto 122:f9eeca106725 408 #define OB_VDDA_ANALOG_OFF ((uint8_t)0x00) /*!< Analog monitoring on VDDA Power source OFF */
Kojto 122:f9eeca106725 409 /**
Kojto 122:f9eeca106725 410 * @}
Kojto 122:f9eeca106725 411 */
Kojto 122:f9eeca106725 412
Kojto 122:f9eeca106725 413 /** @defgroup FLASHEx_OB_RAM_Parity_Check_Enable Option Byte SRAM Parity Check Enable
Kojto 122:f9eeca106725 414 * @{
Kojto 122:f9eeca106725 415 */
Kojto 122:f9eeca106725 416 #define OB_SRAM_PARITY_SET ((uint8_t)0x00) /*!< SRAM parity check enable set */
Kojto 122:f9eeca106725 417 #define OB_SRAM_PARITY_RESET ((uint8_t)0x40) /*!< SRAM parity check enable reset */
Kojto 122:f9eeca106725 418 /**
Kojto 122:f9eeca106725 419 * @}
Kojto 122:f9eeca106725 420 */
Kojto 122:f9eeca106725 421
Kojto 122:f9eeca106725 422
Kojto 122:f9eeca106725 423 #if defined(FLASH_OBR_SDADC12_VDD_MONITOR)
Kojto 122:f9eeca106725 424 /** @defgroup FLASHEx_OB_SDADC12_VDD_MONITOR OB SDADC12 VDD MONITOR
bogdanm 86:04dd9b1680ae 425 * @{
bogdanm 86:04dd9b1680ae 426 */
bogdanm 86:04dd9b1680ae 427 #define OB_SDACD_VDD_MONITOR_RESET ((uint8_t)0x00) /*!< SDADC VDD Monitor reset */
bogdanm 86:04dd9b1680ae 428 #define OB_SDACD_VDD_MONITOR_SET ((uint8_t)0x80) /*!< SDADC VDD Monitor set */
bogdanm 86:04dd9b1680ae 429
bogdanm 86:04dd9b1680ae 430 /**
bogdanm 86:04dd9b1680ae 431 * @}
bogdanm 86:04dd9b1680ae 432 */
Kojto 122:f9eeca106725 433 #endif /* FLASH_OBR_SDADC12_VDD_MONITOR */
bogdanm 86:04dd9b1680ae 434
Kojto 122:f9eeca106725 435 /** @defgroup FLASHEx_OB_Data_Address Option Byte Data Address
bogdanm 92:4fc01daae5a5 436 * @{
bogdanm 92:4fc01daae5a5 437 */
Kojto 122:f9eeca106725 438 #define OB_DATA_ADDRESS_DATA0 ((uint32_t)0x1FFFF804)
Kojto 122:f9eeca106725 439 #define OB_DATA_ADDRESS_DATA1 ((uint32_t)0x1FFFF806)
bogdanm 86:04dd9b1680ae 440 /**
bogdanm 86:04dd9b1680ae 441 * @}
bogdanm 86:04dd9b1680ae 442 */
bogdanm 86:04dd9b1680ae 443
bogdanm 86:04dd9b1680ae 444 /**
bogdanm 86:04dd9b1680ae 445 * @}
bogdanm 86:04dd9b1680ae 446 */
bogdanm 92:4fc01daae5a5 447
bogdanm 92:4fc01daae5a5 448 /**
bogdanm 92:4fc01daae5a5 449 * @}
bogdanm 92:4fc01daae5a5 450 */
bogdanm 92:4fc01daae5a5 451
Kojto 122:f9eeca106725 452 /* Exported functions --------------------------------------------------------*/
Kojto 122:f9eeca106725 453 /** @addtogroup FLASHEx_Exported_Functions
Kojto 122:f9eeca106725 454 * @{
Kojto 122:f9eeca106725 455 */
Kojto 122:f9eeca106725 456
Kojto 122:f9eeca106725 457 /** @addtogroup FLASHEx_Exported_Functions_Group1
Kojto 122:f9eeca106725 458 * @{
Kojto 122:f9eeca106725 459 */
Kojto 122:f9eeca106725 460 /* IO operation functions *****************************************************/
Kojto 122:f9eeca106725 461 HAL_StatusTypeDef HAL_FLASHEx_Erase(FLASH_EraseInitTypeDef *pEraseInit, uint32_t *PageError);
Kojto 122:f9eeca106725 462 HAL_StatusTypeDef HAL_FLASHEx_Erase_IT(FLASH_EraseInitTypeDef *pEraseInit);
Kojto 122:f9eeca106725 463
Kojto 122:f9eeca106725 464 /**
Kojto 122:f9eeca106725 465 * @}
Kojto 122:f9eeca106725 466 */
Kojto 122:f9eeca106725 467
Kojto 122:f9eeca106725 468 /** @addtogroup FLASHEx_Exported_Functions_Group2
Kojto 122:f9eeca106725 469 * @{
Kojto 122:f9eeca106725 470 */
Kojto 122:f9eeca106725 471 /* Peripheral Control functions ***********************************************/
Kojto 122:f9eeca106725 472 HAL_StatusTypeDef HAL_FLASHEx_OBErase(void);
Kojto 122:f9eeca106725 473 HAL_StatusTypeDef HAL_FLASHEx_OBProgram(FLASH_OBProgramInitTypeDef *pOBInit);
Kojto 122:f9eeca106725 474 void HAL_FLASHEx_OBGetConfig(FLASH_OBProgramInitTypeDef *pOBInit);
Kojto 122:f9eeca106725 475 uint32_t HAL_FLASHEx_OBGetUserData(uint32_t DATAAdress);
Kojto 122:f9eeca106725 476
bogdanm 92:4fc01daae5a5 477 /**
bogdanm 92:4fc01daae5a5 478 * @}
bogdanm 92:4fc01daae5a5 479 */
Kojto 122:f9eeca106725 480
Kojto 122:f9eeca106725 481 /**
Kojto 122:f9eeca106725 482 * @}
Kojto 122:f9eeca106725 483 */
Kojto 122:f9eeca106725 484
Kojto 122:f9eeca106725 485 /**
Kojto 122:f9eeca106725 486 * @}
Kojto 122:f9eeca106725 487 */
Kojto 122:f9eeca106725 488
Kojto 122:f9eeca106725 489 /**
Kojto 122:f9eeca106725 490 * @}
Kojto 122:f9eeca106725 491 */
Kojto 122:f9eeca106725 492
bogdanm 86:04dd9b1680ae 493 #ifdef __cplusplus
bogdanm 86:04dd9b1680ae 494 }
bogdanm 86:04dd9b1680ae 495 #endif
bogdanm 86:04dd9b1680ae 496
bogdanm 86:04dd9b1680ae 497 #endif /* __STM32F3xx_HAL_FLASH_EX_H */
bogdanm 86:04dd9b1680ae 498
bogdanm 86:04dd9b1680ae 499 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
Kojto 122:f9eeca106725 500