/TARGET_K64F/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_KPSDK_CODE/hal/adc/fsl_adc_hal.h substitute line 894 extern } by }
Fork of mbed by
TARGET_NUCLEO_F091RC/stm32f0xx_hal_flash_ex.h@93:9dd889aeda0e, 2014-12-05 (annotated)
- Committer:
- fblanc
- Date:
- Fri Dec 05 15:42:32 2014 +0000
- Revision:
- 93:9dd889aeda0e
- Parent:
- 90:cb3d968589d8
substitute line 894 extern } by }; /TARGET_K64F/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_KPSDK_CODE/hal/adc/fsl_adc_hal.h
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Kojto | 90:cb3d968589d8 | 1 | /** |
Kojto | 90:cb3d968589d8 | 2 | ****************************************************************************** |
Kojto | 90:cb3d968589d8 | 3 | * @file stm32f0xx_hal_flash_ex.h |
Kojto | 90:cb3d968589d8 | 4 | * @author MCD Application Team |
Kojto | 90:cb3d968589d8 | 5 | * @version V1.1.0 |
Kojto | 90:cb3d968589d8 | 6 | * @date 03-Oct-2014 |
Kojto | 90:cb3d968589d8 | 7 | * @brief Header file of FLASH HAL Extension module. |
Kojto | 90:cb3d968589d8 | 8 | ****************************************************************************** |
Kojto | 90:cb3d968589d8 | 9 | * @attention |
Kojto | 90:cb3d968589d8 | 10 | * |
Kojto | 90:cb3d968589d8 | 11 | * <h2><center>© COPYRIGHT(c) 2014 STMicroelectronics</center></h2> |
Kojto | 90:cb3d968589d8 | 12 | * |
Kojto | 90:cb3d968589d8 | 13 | * Redistribution and use in source and binary forms, with or without modification, |
Kojto | 90:cb3d968589d8 | 14 | * are permitted provided that the following conditions are met: |
Kojto | 90:cb3d968589d8 | 15 | * 1. Redistributions of source code must retain the above copyright notice, |
Kojto | 90:cb3d968589d8 | 16 | * this list of conditions and the following disclaimer. |
Kojto | 90:cb3d968589d8 | 17 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
Kojto | 90:cb3d968589d8 | 18 | * this list of conditions and the following disclaimer in the documentation |
Kojto | 90:cb3d968589d8 | 19 | * and/or other materials provided with the distribution. |
Kojto | 90:cb3d968589d8 | 20 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
Kojto | 90:cb3d968589d8 | 21 | * may be used to endorse or promote products derived from this software |
Kojto | 90:cb3d968589d8 | 22 | * without specific prior written permission. |
Kojto | 90:cb3d968589d8 | 23 | * |
Kojto | 90:cb3d968589d8 | 24 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
Kojto | 90:cb3d968589d8 | 25 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
Kojto | 90:cb3d968589d8 | 26 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
Kojto | 90:cb3d968589d8 | 27 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
Kojto | 90:cb3d968589d8 | 28 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
Kojto | 90:cb3d968589d8 | 29 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
Kojto | 90:cb3d968589d8 | 30 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
Kojto | 90:cb3d968589d8 | 31 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
Kojto | 90:cb3d968589d8 | 32 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
Kojto | 90:cb3d968589d8 | 33 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
Kojto | 90:cb3d968589d8 | 34 | * |
Kojto | 90:cb3d968589d8 | 35 | ****************************************************************************** |
Kojto | 90:cb3d968589d8 | 36 | */ |
Kojto | 90:cb3d968589d8 | 37 | |
Kojto | 90:cb3d968589d8 | 38 | /* Define to prevent recursive inclusion -------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 39 | #ifndef __STM32F0xx_HAL_FLASH_EX_H |
Kojto | 90:cb3d968589d8 | 40 | #define __STM32F0xx_HAL_FLASH_EX_H |
Kojto | 90:cb3d968589d8 | 41 | |
Kojto | 90:cb3d968589d8 | 42 | #ifdef __cplusplus |
Kojto | 90:cb3d968589d8 | 43 | extern "C" { |
Kojto | 90:cb3d968589d8 | 44 | #endif |
Kojto | 90:cb3d968589d8 | 45 | |
Kojto | 90:cb3d968589d8 | 46 | /* Includes ------------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 47 | #include "stm32f0xx_hal_def.h" |
Kojto | 90:cb3d968589d8 | 48 | |
Kojto | 90:cb3d968589d8 | 49 | /** @addtogroup STM32F0xx_HAL_Driver |
Kojto | 90:cb3d968589d8 | 50 | * @{ |
Kojto | 90:cb3d968589d8 | 51 | */ |
Kojto | 90:cb3d968589d8 | 52 | |
Kojto | 90:cb3d968589d8 | 53 | /** @addtogroup FLASHEx |
Kojto | 90:cb3d968589d8 | 54 | * @{ |
Kojto | 90:cb3d968589d8 | 55 | */ |
Kojto | 90:cb3d968589d8 | 56 | |
Kojto | 90:cb3d968589d8 | 57 | /* Exported types ------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 58 | /* Exported constants --------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 59 | /** @defgroup FLASHEx_Exported_Constants FLASHEx Exported Constants |
Kojto | 90:cb3d968589d8 | 60 | * @{ |
Kojto | 90:cb3d968589d8 | 61 | */ |
Kojto | 90:cb3d968589d8 | 62 | /** @defgroup FLASHEx_Address FLASHEx Address |
Kojto | 90:cb3d968589d8 | 63 | * @{ |
Kojto | 90:cb3d968589d8 | 64 | */ |
Kojto | 90:cb3d968589d8 | 65 | #if defined(STM32F030x6) || defined(STM32F031x6) || defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F038xx) |
Kojto | 90:cb3d968589d8 | 66 | #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= 0x08000000) && ((ADDRESS) <= 0x08007FFF)) |
Kojto | 90:cb3d968589d8 | 67 | #endif /* STM32F030x6 || STM32F031x6 || STM32F042x6 || STM32F048xx || STM32F038xx */ |
Kojto | 90:cb3d968589d8 | 68 | |
Kojto | 90:cb3d968589d8 | 69 | #if defined(STM32F030x8) || defined(STM32F051x8) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 70 | #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= 0x08000000) && ((ADDRESS) <= 0x0800FFFF)) |
Kojto | 90:cb3d968589d8 | 71 | #endif /* STM32F030x8 || STM32F051x8 || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 72 | |
Kojto | 90:cb3d968589d8 | 73 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) |
Kojto | 90:cb3d968589d8 | 74 | #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= 0x08000000) && ((ADDRESS) <= 0x0801FFFF)) |
Kojto | 90:cb3d968589d8 | 75 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx */ |
Kojto | 90:cb3d968589d8 | 76 | |
Kojto | 90:cb3d968589d8 | 77 | #if defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 78 | #define IS_FLASH_PROGRAM_ADDRESS(ADDRESS) (((ADDRESS) >= 0x08000000) && ((ADDRESS) <= 0x0803FFFF)) |
Kojto | 90:cb3d968589d8 | 79 | #endif /* STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 80 | /** |
Kojto | 90:cb3d968589d8 | 81 | * @} |
Kojto | 90:cb3d968589d8 | 82 | */ |
Kojto | 90:cb3d968589d8 | 83 | |
Kojto | 90:cb3d968589d8 | 84 | /** @defgroup FLASHEx_Page_Size FLASHEx Page Size |
Kojto | 90:cb3d968589d8 | 85 | * @{ |
Kojto | 90:cb3d968589d8 | 86 | */ |
Kojto | 90:cb3d968589d8 | 87 | #if defined(STM32F030x6) || defined(STM32F030x8) || defined(STM32F031x6) || defined(STM32F038xx) || \ |
Kojto | 90:cb3d968589d8 | 88 | defined(STM32F051x8) || defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 89 | #define FLASH_PAGE_SIZE 0x400 |
Kojto | 90:cb3d968589d8 | 90 | #endif /* STM32F030x6 || STM32F030x8 || STM32F031x6 || STM32F051x8 || STM32F042x6 || STM32F048xx || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 91 | |
Kojto | 90:cb3d968589d8 | 92 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) || \ |
Kojto | 90:cb3d968589d8 | 93 | defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 94 | #define FLASH_PAGE_SIZE 0x800 |
Kojto | 90:cb3d968589d8 | 95 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx || STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 96 | |
Kojto | 90:cb3d968589d8 | 97 | /** |
Kojto | 90:cb3d968589d8 | 98 | * @} |
Kojto | 90:cb3d968589d8 | 99 | */ |
Kojto | 90:cb3d968589d8 | 100 | |
Kojto | 90:cb3d968589d8 | 101 | /** @defgroup FLASHEx_Nb_Pages FLASHEx Nb Pages |
Kojto | 90:cb3d968589d8 | 102 | * @{ |
Kojto | 90:cb3d968589d8 | 103 | */ |
Kojto | 90:cb3d968589d8 | 104 | #if defined(STM32F030x6) || defined(STM32F031x6) || defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F038xx) |
Kojto | 90:cb3d968589d8 | 105 | #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x08007FFF) |
Kojto | 90:cb3d968589d8 | 106 | #endif /* STM32F030x6 || STM32F031x6 || STM32F042x6 || STM32F048xx || STM32F038xx */ |
Kojto | 90:cb3d968589d8 | 107 | |
Kojto | 90:cb3d968589d8 | 108 | #if defined(STM32F030x8) || defined(STM32F051x8) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 109 | #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0800FFFF) |
Kojto | 90:cb3d968589d8 | 110 | #endif /* STM32F030x8 || STM32F051x8 || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 111 | |
Kojto | 90:cb3d968589d8 | 112 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) |
Kojto | 90:cb3d968589d8 | 113 | #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0801FFFF) |
Kojto | 90:cb3d968589d8 | 114 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx */ |
Kojto | 90:cb3d968589d8 | 115 | |
Kojto | 90:cb3d968589d8 | 116 | #if defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 117 | #define IS_FLASH_NB_PAGES(ADDRESS,NBPAGES) ((ADDRESS)+((NBPAGES)*FLASH_PAGE_SIZE)-1 <= 0x0803FFFF) |
Kojto | 90:cb3d968589d8 | 118 | #endif /* STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 119 | /** |
Kojto | 90:cb3d968589d8 | 120 | * @} |
Kojto | 90:cb3d968589d8 | 121 | */ |
Kojto | 90:cb3d968589d8 | 122 | |
Kojto | 90:cb3d968589d8 | 123 | /** @defgroup FLASHEx_OB_Write_Protection FLASHEx OB Write Protection |
Kojto | 90:cb3d968589d8 | 124 | * @{ |
Kojto | 90:cb3d968589d8 | 125 | */ |
Kojto | 90:cb3d968589d8 | 126 | #if defined(STM32F030x6) || defined(STM32F030x8) || defined(STM32F031x6) || defined(STM32F038xx) || \ |
Kojto | 90:cb3d968589d8 | 127 | defined(STM32F051x8) || defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 128 | #define OB_WRP_PAGES0TO3 ((uint32_t)0x00000001) /* Write protection of page 0 to 3 */ |
Kojto | 90:cb3d968589d8 | 129 | #define OB_WRP_PAGES4TO7 ((uint32_t)0x00000002) /* Write protection of page 4 to 7 */ |
Kojto | 90:cb3d968589d8 | 130 | #define OB_WRP_PAGES8TO11 ((uint32_t)0x00000004) /* Write protection of page 8 to 11 */ |
Kojto | 90:cb3d968589d8 | 131 | #define OB_WRP_PAGES12TO15 ((uint32_t)0x00000008) /* Write protection of page 12 to 15 */ |
Kojto | 90:cb3d968589d8 | 132 | #define OB_WRP_PAGES16TO19 ((uint32_t)0x00000010) /* Write protection of page 16 to 19 */ |
Kojto | 90:cb3d968589d8 | 133 | #define OB_WRP_PAGES20TO23 ((uint32_t)0x00000020) /* Write protection of page 20 to 23 */ |
Kojto | 90:cb3d968589d8 | 134 | #define OB_WRP_PAGES24TO27 ((uint32_t)0x00000040) /* Write protection of page 24 to 27 */ |
Kojto | 90:cb3d968589d8 | 135 | #define OB_WRP_PAGES28TO31 ((uint32_t)0x00000080) /* Write protection of page 28 to 31 */ |
Kojto | 90:cb3d968589d8 | 136 | #if defined(STM32F030x8) || defined(STM32F051x8) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 137 | #define OB_WRP_PAGES32TO35 ((uint32_t)0x00000100) /* Write protection of page 32 to 35 */ |
Kojto | 90:cb3d968589d8 | 138 | #define OB_WRP_PAGES36TO39 ((uint32_t)0x00000200) /* Write protection of page 36 to 39 */ |
Kojto | 90:cb3d968589d8 | 139 | #define OB_WRP_PAGES40TO43 ((uint32_t)0x00000400) /* Write protection of page 40 to 43 */ |
Kojto | 90:cb3d968589d8 | 140 | #define OB_WRP_PAGES44TO47 ((uint32_t)0x00000800) /* Write protection of page 44 to 47 */ |
Kojto | 90:cb3d968589d8 | 141 | #define OB_WRP_PAGES48TO51 ((uint32_t)0x00001000) /* Write protection of page 48 to 51 */ |
Kojto | 90:cb3d968589d8 | 142 | #define OB_WRP_PAGES52TO57 ((uint32_t)0x00002000) /* Write protection of page 52 to 57 */ |
Kojto | 90:cb3d968589d8 | 143 | #define OB_WRP_PAGES56TO59 ((uint32_t)0x00004000) /* Write protection of page 56 to 59 */ |
Kojto | 90:cb3d968589d8 | 144 | #define OB_WRP_PAGES60TO63 ((uint32_t)0x00008000) /* Write protection of page 60 to 63 */ |
Kojto | 90:cb3d968589d8 | 145 | #endif /* STM32F030x8 || STM32F051x8 || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 146 | |
Kojto | 90:cb3d968589d8 | 147 | #define OB_WRP_PAGES0TO31MASK ((uint32_t)0x000000FF) |
Kojto | 90:cb3d968589d8 | 148 | #if defined(STM32F030x8) || defined(STM32F051x8) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 149 | #define OB_WRP_PAGES32TO63MASK ((uint32_t)0x0000FF00) |
Kojto | 90:cb3d968589d8 | 150 | #endif /* STM32F030x8 || STM32F051x8 || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 151 | |
Kojto | 90:cb3d968589d8 | 152 | #if defined(STM32F030x6) || defined(STM32F031x6) || defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F038xx) |
Kojto | 90:cb3d968589d8 | 153 | #define OB_WRP_ALLPAGES ((uint32_t)0x000000FF) /*!< Write protection of all pages */ |
Kojto | 90:cb3d968589d8 | 154 | #endif /* STM32F030x6 || STM32F031x6 || STM32F042x6 || STM32F048xx || STM32F038xx */ |
Kojto | 90:cb3d968589d8 | 155 | |
Kojto | 90:cb3d968589d8 | 156 | #if defined(STM32F030x8) || defined(STM32F051x8) || defined(STM32F058xx) |
Kojto | 90:cb3d968589d8 | 157 | #define OB_WRP_ALLPAGES ((uint32_t)0x0000FFFF) /*!< Write protection of all pages */ |
Kojto | 90:cb3d968589d8 | 158 | #endif /* STM32F030x8 || STM32F051x8 || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 159 | #endif /* STM32F030x6 || STM32F030x8 || STM32F031x6 || STM32F051x8 || STM32F042x6 || STM32F048xx || STM32F038xx || STM32F058xx */ |
Kojto | 90:cb3d968589d8 | 160 | |
Kojto | 90:cb3d968589d8 | 161 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) || \ |
Kojto | 90:cb3d968589d8 | 162 | defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 163 | #define OB_WRP_PAGES0TO1 ((uint32_t)0x00000001) /* Write protection of page 0 to 1 */ |
Kojto | 90:cb3d968589d8 | 164 | #define OB_WRP_PAGES2TO3 ((uint32_t)0x00000002) /* Write protection of page 2 to 3 */ |
Kojto | 90:cb3d968589d8 | 165 | #define OB_WRP_PAGES4TO5 ((uint32_t)0x00000004) /* Write protection of page 4 to 5 */ |
Kojto | 90:cb3d968589d8 | 166 | #define OB_WRP_PAGES6TO7 ((uint32_t)0x00000008) /* Write protection of page 6 to 7 */ |
Kojto | 90:cb3d968589d8 | 167 | #define OB_WRP_PAGES8TO9 ((uint32_t)0x00000010) /* Write protection of page 8 to 9 */ |
Kojto | 90:cb3d968589d8 | 168 | #define OB_WRP_PAGES10TO11 ((uint32_t)0x00000020) /* Write protection of page 10 to 11 */ |
Kojto | 90:cb3d968589d8 | 169 | #define OB_WRP_PAGES12TO13 ((uint32_t)0x00000040) /* Write protection of page 12 to 13 */ |
Kojto | 90:cb3d968589d8 | 170 | #define OB_WRP_PAGES14TO15 ((uint32_t)0x00000080) /* Write protection of page 14 to 15 */ |
Kojto | 90:cb3d968589d8 | 171 | #define OB_WRP_PAGES16TO17 ((uint32_t)0x00000100) /* Write protection of page 16 to 17 */ |
Kojto | 90:cb3d968589d8 | 172 | #define OB_WRP_PAGES18TO19 ((uint32_t)0x00000200) /* Write protection of page 18 to 19 */ |
Kojto | 90:cb3d968589d8 | 173 | #define OB_WRP_PAGES20TO21 ((uint32_t)0x00000400) /* Write protection of page 20 to 21 */ |
Kojto | 90:cb3d968589d8 | 174 | #define OB_WRP_PAGES22TO23 ((uint32_t)0x00000800) /* Write protection of page 22 to 23 */ |
Kojto | 90:cb3d968589d8 | 175 | #define OB_WRP_PAGES24TO25 ((uint32_t)0x00001000) /* Write protection of page 24 to 25 */ |
Kojto | 90:cb3d968589d8 | 176 | #define OB_WRP_PAGES26TO27 ((uint32_t)0x00002000) /* Write protection of page 26 to 27 */ |
Kojto | 90:cb3d968589d8 | 177 | #define OB_WRP_PAGES28TO29 ((uint32_t)0x00004000) /* Write protection of page 28 to 29 */ |
Kojto | 90:cb3d968589d8 | 178 | #define OB_WRP_PAGES30TO31 ((uint32_t)0x00008000) /* Write protection of page 30 to 31 */ |
Kojto | 90:cb3d968589d8 | 179 | #define OB_WRP_PAGES32TO33 ((uint32_t)0x00010000) /* Write protection of page 32 to 33 */ |
Kojto | 90:cb3d968589d8 | 180 | #define OB_WRP_PAGES34TO35 ((uint32_t)0x00020000) /* Write protection of page 34 to 35 */ |
Kojto | 90:cb3d968589d8 | 181 | #define OB_WRP_PAGES36TO37 ((uint32_t)0x00040000) /* Write protection of page 36 to 37 */ |
Kojto | 90:cb3d968589d8 | 182 | #define OB_WRP_PAGES38TO39 ((uint32_t)0x00080000) /* Write protection of page 38 to 39 */ |
Kojto | 90:cb3d968589d8 | 183 | #define OB_WRP_PAGES40TO41 ((uint32_t)0x00100000) /* Write protection of page 40 to 41 */ |
Kojto | 90:cb3d968589d8 | 184 | #define OB_WRP_PAGES42TO43 ((uint32_t)0x00200000) /* Write protection of page 42 to 43 */ |
Kojto | 90:cb3d968589d8 | 185 | #define OB_WRP_PAGES44TO45 ((uint32_t)0x00400000) /* Write protection of page 44 to 45 */ |
Kojto | 90:cb3d968589d8 | 186 | #define OB_WRP_PAGES46TO47 ((uint32_t)0x00800000) /* Write protection of page 46 to 47 */ |
Kojto | 90:cb3d968589d8 | 187 | #define OB_WRP_PAGES48TO49 ((uint32_t)0x01000000) /* Write protection of page 48 to 49 */ |
Kojto | 90:cb3d968589d8 | 188 | #define OB_WRP_PAGES50TO51 ((uint32_t)0x02000000) /* Write protection of page 50 to 51 */ |
Kojto | 90:cb3d968589d8 | 189 | #define OB_WRP_PAGES52TO53 ((uint32_t)0x04000000) /* Write protection of page 52 to 53 */ |
Kojto | 90:cb3d968589d8 | 190 | #define OB_WRP_PAGES54TO55 ((uint32_t)0x08000000) /* Write protection of page 54 to 55 */ |
Kojto | 90:cb3d968589d8 | 191 | #define OB_WRP_PAGES56TO57 ((uint32_t)0x10000000) /* Write protection of page 56 to 57 */ |
Kojto | 90:cb3d968589d8 | 192 | #define OB_WRP_PAGES58TO59 ((uint32_t)0x20000000) /* Write protection of page 58 to 59 */ |
Kojto | 90:cb3d968589d8 | 193 | #define OB_WRP_PAGES60TO61 ((uint32_t)0x40000000) /* Write protection of page 60 to 61 */ |
Kojto | 90:cb3d968589d8 | 194 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) |
Kojto | 90:cb3d968589d8 | 195 | #define OB_WRP_PAGES62TO63 ((uint32_t)0x80000000) /* Write protection of page 62 to 63 */ |
Kojto | 90:cb3d968589d8 | 196 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx */ |
Kojto | 90:cb3d968589d8 | 197 | #if defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 198 | #define OB_WRP_PAGES62TO127 ((uint32_t)0x80000000) /* Write protection of page 62 to 127 */ |
Kojto | 90:cb3d968589d8 | 199 | #endif /* STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 200 | |
Kojto | 90:cb3d968589d8 | 201 | #define OB_WRP_PAGES0TO15MASK ((uint32_t)0x000000FF) |
Kojto | 90:cb3d968589d8 | 202 | #define OB_WRP_PAGES16TO31MASK ((uint32_t)0x0000FF00) |
Kojto | 90:cb3d968589d8 | 203 | #define OB_WRP_PAGES32TO47MASK ((uint32_t)0x00FF0000) |
Kojto | 90:cb3d968589d8 | 204 | #if defined(STM32F071xB) || defined(STM32F072xB) || defined(STM32F078xx) |
Kojto | 90:cb3d968589d8 | 205 | #define OB_WRP_PAGES48TO63MASK ((uint32_t)0xFF000000) |
Kojto | 90:cb3d968589d8 | 206 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx */ |
Kojto | 90:cb3d968589d8 | 207 | #if defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 208 | #define OB_WRP_PAGES48TO127MASK ((uint32_t)0xFF000000) |
Kojto | 90:cb3d968589d8 | 209 | #endif /* STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 210 | |
Kojto | 90:cb3d968589d8 | 211 | #define OB_WRP_ALLPAGES ((uint32_t)0xFFFFFFFF) /*!< Write protection of all pages */ |
Kojto | 90:cb3d968589d8 | 212 | #endif /* STM32F071xB || STM32F072xB || STM32F078xx || STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 213 | |
Kojto | 90:cb3d968589d8 | 214 | #define IS_OB_WRP(PAGE) (((PAGE) != 0x0000000)) |
Kojto | 90:cb3d968589d8 | 215 | /** |
Kojto | 90:cb3d968589d8 | 216 | * @} |
Kojto | 90:cb3d968589d8 | 217 | */ |
Kojto | 90:cb3d968589d8 | 218 | |
Kojto | 90:cb3d968589d8 | 219 | #if defined(STM32F042x6) || defined(STM32F048xx) || defined(STM32F091xC) || defined(STM32F098xx) |
Kojto | 90:cb3d968589d8 | 220 | /** @defgroup FLASHEx_OB_BOOT_SEL FLASHEx OB BOOT SEL |
Kojto | 90:cb3d968589d8 | 221 | * @{ |
Kojto | 90:cb3d968589d8 | 222 | */ |
Kojto | 90:cb3d968589d8 | 223 | #define OB_BOOT_SEL_RESET ((uint8_t)0x00) /*!< BOOT_SEL Reset */ |
Kojto | 90:cb3d968589d8 | 224 | #define OB_BOOT_SEL_SET ((uint8_t)0x80) /*!< BOOT_SEL Set */ |
Kojto | 90:cb3d968589d8 | 225 | #define IS_OB_BOOT_SEL(BOOT_SEL) (((BOOT_SEL) == OB_BOOT_SEL_RESET) || ((BOOT_SEL) == OB_BOOT_SEL_SET)) |
Kojto | 90:cb3d968589d8 | 226 | /** |
Kojto | 90:cb3d968589d8 | 227 | * @} |
Kojto | 90:cb3d968589d8 | 228 | */ |
Kojto | 90:cb3d968589d8 | 229 | |
Kojto | 90:cb3d968589d8 | 230 | /** @defgroup FLASHEx_OB_BOOT0 FLASHEx OB BOOT0 |
Kojto | 90:cb3d968589d8 | 231 | * @{ |
Kojto | 90:cb3d968589d8 | 232 | */ |
Kojto | 90:cb3d968589d8 | 233 | #define OB_BOOT0_RESET ((uint8_t)0x00) /*!< BOOT0 Reset */ |
Kojto | 90:cb3d968589d8 | 234 | #define OB_BOOT0_SET ((uint8_t)0x08) /*!< BOOT0 Set */ |
Kojto | 90:cb3d968589d8 | 235 | #define IS_OB_BOOT0(BOOT0) (((BOOT0) == OB_BOOT0_RESET) || ((BOOT0) == OB_BOOT0_SET)) |
Kojto | 90:cb3d968589d8 | 236 | /** |
Kojto | 90:cb3d968589d8 | 237 | * @} |
Kojto | 90:cb3d968589d8 | 238 | */ |
Kojto | 90:cb3d968589d8 | 239 | #endif /* STM32F042x6 || STM32F048xx || STM32F091xC || STM32F098xx */ |
Kojto | 90:cb3d968589d8 | 240 | |
Kojto | 90:cb3d968589d8 | 241 | /** |
Kojto | 90:cb3d968589d8 | 242 | * @} |
Kojto | 90:cb3d968589d8 | 243 | */ |
Kojto | 90:cb3d968589d8 | 244 | |
Kojto | 90:cb3d968589d8 | 245 | /* Exported macro ------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 246 | |
Kojto | 90:cb3d968589d8 | 247 | /* Exported functions --------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 248 | /** @addtogroup FLASHEx_Exported_Functions FLASHEx Exported Functions |
Kojto | 90:cb3d968589d8 | 249 | * @{ |
Kojto | 90:cb3d968589d8 | 250 | */ |
Kojto | 90:cb3d968589d8 | 251 | |
Kojto | 90:cb3d968589d8 | 252 | /** @addtogroup FLASHEx_Exported_Functions_Group2 Extended I/O operation functions |
Kojto | 90:cb3d968589d8 | 253 | * @brief Extended I/O operation functions |
Kojto | 90:cb3d968589d8 | 254 | * @{ |
Kojto | 90:cb3d968589d8 | 255 | */ |
Kojto | 90:cb3d968589d8 | 256 | /* IO operation functions *****************************************************/ |
Kojto | 90:cb3d968589d8 | 257 | HAL_StatusTypeDef HAL_FLASHEx_Erase(FLASH_EraseInitTypeDef *pEraseInit, uint32_t *PageError); |
Kojto | 90:cb3d968589d8 | 258 | HAL_StatusTypeDef HAL_FLASHEx_Erase_IT(FLASH_EraseInitTypeDef *pEraseInit); |
Kojto | 90:cb3d968589d8 | 259 | |
Kojto | 90:cb3d968589d8 | 260 | /** |
Kojto | 90:cb3d968589d8 | 261 | * @} |
Kojto | 90:cb3d968589d8 | 262 | */ |
Kojto | 90:cb3d968589d8 | 263 | |
Kojto | 90:cb3d968589d8 | 264 | /** @addtogroup FLASHEx_Exported_Functions_Group3 Extended Peripheral Control functions |
Kojto | 90:cb3d968589d8 | 265 | * @brief Extended Peripheral Control functions |
Kojto | 90:cb3d968589d8 | 266 | * @{ |
Kojto | 90:cb3d968589d8 | 267 | */ |
Kojto | 90:cb3d968589d8 | 268 | /* Peripheral Control functions ***********************************************/ |
Kojto | 90:cb3d968589d8 | 269 | HAL_StatusTypeDef HAL_FLASHEx_OBErase(void); |
Kojto | 90:cb3d968589d8 | 270 | HAL_StatusTypeDef HAL_FLASHEx_OBProgram(FLASH_OBProgramInitTypeDef *pOBInit); |
Kojto | 90:cb3d968589d8 | 271 | void HAL_FLASHEx_OBGetConfig(FLASH_OBProgramInitTypeDef *pOBInit); |
Kojto | 90:cb3d968589d8 | 272 | |
Kojto | 90:cb3d968589d8 | 273 | /** |
Kojto | 90:cb3d968589d8 | 274 | * @} |
Kojto | 90:cb3d968589d8 | 275 | */ |
Kojto | 90:cb3d968589d8 | 276 | |
Kojto | 90:cb3d968589d8 | 277 | /** |
Kojto | 90:cb3d968589d8 | 278 | * @} |
Kojto | 90:cb3d968589d8 | 279 | */ |
Kojto | 90:cb3d968589d8 | 280 | |
Kojto | 90:cb3d968589d8 | 281 | /** |
Kojto | 90:cb3d968589d8 | 282 | * @} |
Kojto | 90:cb3d968589d8 | 283 | */ |
Kojto | 90:cb3d968589d8 | 284 | |
Kojto | 90:cb3d968589d8 | 285 | /** |
Kojto | 90:cb3d968589d8 | 286 | * @} |
Kojto | 90:cb3d968589d8 | 287 | */ |
Kojto | 90:cb3d968589d8 | 288 | |
Kojto | 90:cb3d968589d8 | 289 | #ifdef __cplusplus |
Kojto | 90:cb3d968589d8 | 290 | } |
Kojto | 90:cb3d968589d8 | 291 | #endif |
Kojto | 90:cb3d968589d8 | 292 | |
Kojto | 90:cb3d968589d8 | 293 | #endif /* __STM32F0xx_HAL_FLASH_EX_H */ |
Kojto | 90:cb3d968589d8 | 294 | |
Kojto | 90:cb3d968589d8 | 295 | /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ |
Kojto | 90:cb3d968589d8 | 296 |