Fork of the official mbed C/C SDK provides the software platform and libraries to build your applications for RenBED.
Dependents: 1-RenBuggyTimed RenBED_RGB RenBED_RGB_PWM RenBED_RGB
Fork of mbed by
TARGET_DISCO_L476VG/stm32l4xx_hal.h@121:672067c3ada4, 2016-04-14 (annotated)
- Committer:
- elijahorr
- Date:
- Thu Apr 14 07:28:54 2016 +0000
- Revision:
- 121:672067c3ada4
- Parent:
- 107:4f6c30876dfa
.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Kojto | 107:4f6c30876dfa | 1 | /** |
Kojto | 107:4f6c30876dfa | 2 | ****************************************************************************** |
Kojto | 107:4f6c30876dfa | 3 | * @file stm32l4xx_hal.h |
Kojto | 107:4f6c30876dfa | 4 | * @author MCD Application Team |
Kojto | 107:4f6c30876dfa | 5 | * @version V1.0.0 |
Kojto | 107:4f6c30876dfa | 6 | * @date 26-June-2015 |
Kojto | 107:4f6c30876dfa | 7 | * @brief This file contains all the functions prototypes for the HAL |
Kojto | 107:4f6c30876dfa | 8 | * module driver. |
Kojto | 107:4f6c30876dfa | 9 | ****************************************************************************** |
Kojto | 107:4f6c30876dfa | 10 | * @attention |
Kojto | 107:4f6c30876dfa | 11 | * |
Kojto | 107:4f6c30876dfa | 12 | * <h2><center>© COPYRIGHT(c) 2015 STMicroelectronics</center></h2> |
Kojto | 107:4f6c30876dfa | 13 | * |
Kojto | 107:4f6c30876dfa | 14 | * Redistribution and use in source and binary forms, with or without modification, |
Kojto | 107:4f6c30876dfa | 15 | * are permitted provided that the following conditions are met: |
Kojto | 107:4f6c30876dfa | 16 | * 1. Redistributions of source code must retain the above copyright notice, |
Kojto | 107:4f6c30876dfa | 17 | * this list of conditions and the following disclaimer. |
Kojto | 107:4f6c30876dfa | 18 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
Kojto | 107:4f6c30876dfa | 19 | * this list of conditions and the following disclaimer in the documentation |
Kojto | 107:4f6c30876dfa | 20 | * and/or other materials provided with the distribution. |
Kojto | 107:4f6c30876dfa | 21 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
Kojto | 107:4f6c30876dfa | 22 | * may be used to endorse or promote products derived from this software |
Kojto | 107:4f6c30876dfa | 23 | * without specific prior written permission. |
Kojto | 107:4f6c30876dfa | 24 | * |
Kojto | 107:4f6c30876dfa | 25 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
Kojto | 107:4f6c30876dfa | 26 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
Kojto | 107:4f6c30876dfa | 27 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
Kojto | 107:4f6c30876dfa | 28 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
Kojto | 107:4f6c30876dfa | 29 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
Kojto | 107:4f6c30876dfa | 30 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
Kojto | 107:4f6c30876dfa | 31 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
Kojto | 107:4f6c30876dfa | 32 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
Kojto | 107:4f6c30876dfa | 33 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
Kojto | 107:4f6c30876dfa | 34 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
Kojto | 107:4f6c30876dfa | 35 | * |
Kojto | 107:4f6c30876dfa | 36 | ****************************************************************************** |
Kojto | 107:4f6c30876dfa | 37 | */ |
Kojto | 107:4f6c30876dfa | 38 | |
Kojto | 107:4f6c30876dfa | 39 | /* Define to prevent recursive inclusion -------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 40 | #ifndef __STM32L4xx_HAL_H |
Kojto | 107:4f6c30876dfa | 41 | #define __STM32L4xx_HAL_H |
Kojto | 107:4f6c30876dfa | 42 | |
Kojto | 107:4f6c30876dfa | 43 | #ifdef __cplusplus |
Kojto | 107:4f6c30876dfa | 44 | extern "C" { |
Kojto | 107:4f6c30876dfa | 45 | #endif |
Kojto | 107:4f6c30876dfa | 46 | |
Kojto | 107:4f6c30876dfa | 47 | /* Includes ------------------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 48 | #include "stm32l4xx_hal_conf.h" |
Kojto | 107:4f6c30876dfa | 49 | |
Kojto | 107:4f6c30876dfa | 50 | /** @addtogroup STM32L4xx_HAL_Driver |
Kojto | 107:4f6c30876dfa | 51 | * @{ |
Kojto | 107:4f6c30876dfa | 52 | */ |
Kojto | 107:4f6c30876dfa | 53 | |
Kojto | 107:4f6c30876dfa | 54 | /** @addtogroup HAL |
Kojto | 107:4f6c30876dfa | 55 | * @{ |
Kojto | 107:4f6c30876dfa | 56 | */ |
Kojto | 107:4f6c30876dfa | 57 | |
Kojto | 107:4f6c30876dfa | 58 | /* Exported types ------------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 59 | /* Exported constants --------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 60 | /** @defgroup SYSCFG_Exported_Constants SYSCFG Exported Constants |
Kojto | 107:4f6c30876dfa | 61 | * @{ |
Kojto | 107:4f6c30876dfa | 62 | */ |
Kojto | 107:4f6c30876dfa | 63 | |
Kojto | 107:4f6c30876dfa | 64 | /** @defgroup SYSCFG_BootMode Boot Mode |
Kojto | 107:4f6c30876dfa | 65 | * @{ |
Kojto | 107:4f6c30876dfa | 66 | */ |
Kojto | 107:4f6c30876dfa | 67 | #define SYSCFG_BOOT_MAINFLASH ((uint32_t)0x00000000) |
Kojto | 107:4f6c30876dfa | 68 | #define SYSCFG_BOOT_SYSTEMFLASH SYSCFG_MEMRMP_MEM_MODE_0 |
Kojto | 107:4f6c30876dfa | 69 | #define SYSCFG_BOOT_FMC SYSCFG_MEMRMP_MEM_MODE_1 |
Kojto | 107:4f6c30876dfa | 70 | #define SYSCFG_BOOT_SRAM (SYSCFG_MEMRMP_MEM_MODE_1 | SYSCFG_MEMRMP_MEM_MODE_0) |
Kojto | 107:4f6c30876dfa | 71 | #define SYSCFG_BOOT_QUADSPI (SYSCFG_MEMRMP_MEM_MODE_2 | SYSCFG_MEMRMP_MEM_MODE_1) |
Kojto | 107:4f6c30876dfa | 72 | |
Kojto | 107:4f6c30876dfa | 73 | /** |
Kojto | 107:4f6c30876dfa | 74 | * @} |
Kojto | 107:4f6c30876dfa | 75 | */ |
Kojto | 107:4f6c30876dfa | 76 | |
Kojto | 107:4f6c30876dfa | 77 | /** @defgroup SYSCFG_FPU_Interrupts FPU Interrupts |
Kojto | 107:4f6c30876dfa | 78 | * @{ |
Kojto | 107:4f6c30876dfa | 79 | */ |
Kojto | 107:4f6c30876dfa | 80 | #define SYSCFG_IT_FPU_IOC SYSCFG_CFGR1_FPU_IE_0 /*!< Floating Point Unit Invalid operation Interrupt */ |
Kojto | 107:4f6c30876dfa | 81 | #define SYSCFG_IT_FPU_DZC SYSCFG_CFGR1_FPU_IE_1 /*!< Floating Point Unit Divide-by-zero Interrupt */ |
Kojto | 107:4f6c30876dfa | 82 | #define SYSCFG_IT_FPU_UFC SYSCFG_CFGR1_FPU_IE_2 /*!< Floating Point Unit Underflow Interrupt */ |
Kojto | 107:4f6c30876dfa | 83 | #define SYSCFG_IT_FPU_OFC SYSCFG_CFGR1_FPU_IE_3 /*!< Floating Point Unit Overflow Interrupt */ |
Kojto | 107:4f6c30876dfa | 84 | #define SYSCFG_IT_FPU_IDC SYSCFG_CFGR1_FPU_IE_4 /*!< Floating Point Unit Input denormal Interrupt */ |
Kojto | 107:4f6c30876dfa | 85 | #define SYSCFG_IT_FPU_IXC SYSCFG_CFGR1_FPU_IE_5 /*!< Floating Point Unit Inexact Interrupt */ |
Kojto | 107:4f6c30876dfa | 86 | |
Kojto | 107:4f6c30876dfa | 87 | /** |
Kojto | 107:4f6c30876dfa | 88 | * @} |
Kojto | 107:4f6c30876dfa | 89 | */ |
Kojto | 107:4f6c30876dfa | 90 | |
Kojto | 107:4f6c30876dfa | 91 | /** @defgroup SYSCFG_SRAM2WRP SRAM2 Write protection |
Kojto | 107:4f6c30876dfa | 92 | * @{ |
Kojto | 107:4f6c30876dfa | 93 | */ |
Kojto | 107:4f6c30876dfa | 94 | #define SYSCFG_SRAM2WRP_PAGE0 SYSCFG_SWPR_PAGE0 /*!< SRAM2 Write protection page 0 */ |
Kojto | 107:4f6c30876dfa | 95 | #define SYSCFG_SRAM2WRP_PAGE1 SYSCFG_SWPR_PAGE1 /*!< SRAM2 Write protection page 1 */ |
Kojto | 107:4f6c30876dfa | 96 | #define SYSCFG_SRAM2WRP_PAGE2 SYSCFG_SWPR_PAGE2 /*!< SRAM2 Write protection page 2 */ |
Kojto | 107:4f6c30876dfa | 97 | #define SYSCFG_SRAM2WRP_PAGE3 SYSCFG_SWPR_PAGE3 /*!< SRAM2 Write protection page 3 */ |
Kojto | 107:4f6c30876dfa | 98 | #define SYSCFG_SRAM2WRP_PAGE4 SYSCFG_SWPR_PAGE4 /*!< SRAM2 Write protection page 4 */ |
Kojto | 107:4f6c30876dfa | 99 | #define SYSCFG_SRAM2WRP_PAGE5 SYSCFG_SWPR_PAGE5 /*!< SRAM2 Write protection page 5 */ |
Kojto | 107:4f6c30876dfa | 100 | #define SYSCFG_SRAM2WRP_PAGE6 SYSCFG_SWPR_PAGE6 /*!< SRAM2 Write protection page 6 */ |
Kojto | 107:4f6c30876dfa | 101 | #define SYSCFG_SRAM2WRP_PAGE7 SYSCFG_SWPR_PAGE7 /*!< SRAM2 Write protection page 7 */ |
Kojto | 107:4f6c30876dfa | 102 | #define SYSCFG_SRAM2WRP_PAGE8 SYSCFG_SWPR_PAGE8 /*!< SRAM2 Write protection page 8 */ |
Kojto | 107:4f6c30876dfa | 103 | #define SYSCFG_SRAM2WRP_PAGE9 SYSCFG_SWPR_PAGE9 /*!< SRAM2 Write protection page 9 */ |
Kojto | 107:4f6c30876dfa | 104 | #define SYSCFG_SRAM2WRP_PAGE10 SYSCFG_SWPR_PAGE10 /*!< SRAM2 Write protection page 10 */ |
Kojto | 107:4f6c30876dfa | 105 | #define SYSCFG_SRAM2WRP_PAGE11 SYSCFG_SWPR_PAGE11 /*!< SRAM2 Write protection page 11 */ |
Kojto | 107:4f6c30876dfa | 106 | #define SYSCFG_SRAM2WRP_PAGE12 SYSCFG_SWPR_PAGE12 /*!< SRAM2 Write protection page 12 */ |
Kojto | 107:4f6c30876dfa | 107 | #define SYSCFG_SRAM2WRP_PAGE13 SYSCFG_SWPR_PAGE13 /*!< SRAM2 Write protection page 13 */ |
Kojto | 107:4f6c30876dfa | 108 | #define SYSCFG_SRAM2WRP_PAGE14 SYSCFG_SWPR_PAGE14 /*!< SRAM2 Write protection page 14 */ |
Kojto | 107:4f6c30876dfa | 109 | #define SYSCFG_SRAM2WRP_PAGE15 SYSCFG_SWPR_PAGE15 /*!< SRAM2 Write protection page 15 */ |
Kojto | 107:4f6c30876dfa | 110 | #define SYSCFG_SRAM2WRP_PAGE16 SYSCFG_SWPR_PAGE16 /*!< SRAM2 Write protection page 16 */ |
Kojto | 107:4f6c30876dfa | 111 | #define SYSCFG_SRAM2WRP_PAGE17 SYSCFG_SWPR_PAGE17 /*!< SRAM2 Write protection page 17 */ |
Kojto | 107:4f6c30876dfa | 112 | #define SYSCFG_SRAM2WRP_PAGE18 SYSCFG_SWPR_PAGE18 /*!< SRAM2 Write protection page 18 */ |
Kojto | 107:4f6c30876dfa | 113 | #define SYSCFG_SRAM2WRP_PAGE19 SYSCFG_SWPR_PAGE19 /*!< SRAM2 Write protection page 19 */ |
Kojto | 107:4f6c30876dfa | 114 | #define SYSCFG_SRAM2WRP_PAGE20 SYSCFG_SWPR_PAGE20 /*!< SRAM2 Write protection page 20 */ |
Kojto | 107:4f6c30876dfa | 115 | #define SYSCFG_SRAM2WRP_PAGE21 SYSCFG_SWPR_PAGE21 /*!< SRAM2 Write protection page 21 */ |
Kojto | 107:4f6c30876dfa | 116 | #define SYSCFG_SRAM2WRP_PAGE22 SYSCFG_SWPR_PAGE22 /*!< SRAM2 Write protection page 22 */ |
Kojto | 107:4f6c30876dfa | 117 | #define SYSCFG_SRAM2WRP_PAGE23 SYSCFG_SWPR_PAGE23 /*!< SRAM2 Write protection page 23 */ |
Kojto | 107:4f6c30876dfa | 118 | #define SYSCFG_SRAM2WRP_PAGE24 SYSCFG_SWPR_PAGE24 /*!< SRAM2 Write protection page 24 */ |
Kojto | 107:4f6c30876dfa | 119 | #define SYSCFG_SRAM2WRP_PAGE25 SYSCFG_SWPR_PAGE25 /*!< SRAM2 Write protection page 25 */ |
Kojto | 107:4f6c30876dfa | 120 | #define SYSCFG_SRAM2WRP_PAGE26 SYSCFG_SWPR_PAGE26 /*!< SRAM2 Write protection page 26 */ |
Kojto | 107:4f6c30876dfa | 121 | #define SYSCFG_SRAM2WRP_PAGE27 SYSCFG_SWPR_PAGE27 /*!< SRAM2 Write protection page 27 */ |
Kojto | 107:4f6c30876dfa | 122 | #define SYSCFG_SRAM2WRP_PAGE28 SYSCFG_SWPR_PAGE28 /*!< SRAM2 Write protection page 28 */ |
Kojto | 107:4f6c30876dfa | 123 | #define SYSCFG_SRAM2WRP_PAGE29 SYSCFG_SWPR_PAGE29 /*!< SRAM2 Write protection page 29 */ |
Kojto | 107:4f6c30876dfa | 124 | #define SYSCFG_SRAM2WRP_PAGE30 SYSCFG_SWPR_PAGE30 /*!< SRAM2 Write protection page 30 */ |
Kojto | 107:4f6c30876dfa | 125 | #define SYSCFG_SRAM2WRP_PAGE31 SYSCFG_SWPR_PAGE31 /*!< SRAM2 Write protection page 31 */ |
Kojto | 107:4f6c30876dfa | 126 | |
Kojto | 107:4f6c30876dfa | 127 | /** |
Kojto | 107:4f6c30876dfa | 128 | * @} |
Kojto | 107:4f6c30876dfa | 129 | */ |
Kojto | 107:4f6c30876dfa | 130 | |
Kojto | 107:4f6c30876dfa | 131 | /** @defgroup SYSCFG_VREFBUF_VoltageScale VREFBUF Voltage Scale |
Kojto | 107:4f6c30876dfa | 132 | * @{ |
Kojto | 107:4f6c30876dfa | 133 | */ |
Kojto | 107:4f6c30876dfa | 134 | #define SYSCFG_VREFBUF_VOLTAGE_SCALE0 ((uint32_t)0x00000000) /*!< Voltage reference scale 0 (VREF_OUT1) */ |
Kojto | 107:4f6c30876dfa | 135 | #define SYSCFG_VREFBUF_VOLTAGE_SCALE1 VREFBUF_CSR_VRS /*!< Voltage reference scale 1 (VREF_OUT2) */ |
Kojto | 107:4f6c30876dfa | 136 | |
Kojto | 107:4f6c30876dfa | 137 | /** |
Kojto | 107:4f6c30876dfa | 138 | * @} |
Kojto | 107:4f6c30876dfa | 139 | */ |
Kojto | 107:4f6c30876dfa | 140 | |
Kojto | 107:4f6c30876dfa | 141 | /** @defgroup SYSCFG_VREFBUF_HighImpedance VREFBUF High Impedance |
Kojto | 107:4f6c30876dfa | 142 | * @{ |
Kojto | 107:4f6c30876dfa | 143 | */ |
Kojto | 107:4f6c30876dfa | 144 | #define SYSCFG_VREFBUF_HIGH_IMPEDANCE_DISABLE ((uint32_t)0x00000000) /*!< VREF_plus pin is internally connected to Voltage reference buffer output */ |
Kojto | 107:4f6c30876dfa | 145 | #define SYSCFG_VREFBUF_HIGH_IMPEDANCE_ENABLE VREFBUF_CSR_HIZ /*!< VREF_plus pin is high impedance */ |
Kojto | 107:4f6c30876dfa | 146 | |
Kojto | 107:4f6c30876dfa | 147 | /** |
Kojto | 107:4f6c30876dfa | 148 | * @} |
Kojto | 107:4f6c30876dfa | 149 | */ |
Kojto | 107:4f6c30876dfa | 150 | |
Kojto | 107:4f6c30876dfa | 151 | /** @defgroup SYSCFG_flags_definition Flags |
Kojto | 107:4f6c30876dfa | 152 | * @{ |
Kojto | 107:4f6c30876dfa | 153 | */ |
Kojto | 107:4f6c30876dfa | 154 | |
Kojto | 107:4f6c30876dfa | 155 | #define SYSCFG_FLAG_SRAM2_PE SYSCFG_CFGR2_SPF /*!< SRAM2 parity error */ |
Kojto | 107:4f6c30876dfa | 156 | #define SYSCFG_FLAG_SRAM2_BUSY SYSCFG_SCSR_SRAM2BSY /*!< SRAM2 busy by erase operation */ |
Kojto | 107:4f6c30876dfa | 157 | |
Kojto | 107:4f6c30876dfa | 158 | /** |
Kojto | 107:4f6c30876dfa | 159 | * @} |
Kojto | 107:4f6c30876dfa | 160 | */ |
Kojto | 107:4f6c30876dfa | 161 | |
Kojto | 107:4f6c30876dfa | 162 | /** @defgroup SYSCFG_FastModePlus_GPIO Fast-mode Plus on GPIO |
Kojto | 107:4f6c30876dfa | 163 | * @{ |
Kojto | 107:4f6c30876dfa | 164 | */ |
Kojto | 107:4f6c30876dfa | 165 | |
Kojto | 107:4f6c30876dfa | 166 | /** @brief Fast-mode Plus driving capability on a specific GPIO |
Kojto | 107:4f6c30876dfa | 167 | */ |
Kojto | 107:4f6c30876dfa | 168 | #define SYSCFG_FASTMODEPLUS_PB6 SYSCFG_CFGR1_I2C_PB6_FMP /*!< Enable Fast-mode Plus on PB6 */ |
Kojto | 107:4f6c30876dfa | 169 | #define SYSCFG_FASTMODEPLUS_PB7 SYSCFG_CFGR1_I2C_PB7_FMP /*!< Enable Fast-mode Plus on PB7 */ |
Kojto | 107:4f6c30876dfa | 170 | #define SYSCFG_FASTMODEPLUS_PB8 SYSCFG_CFGR1_I2C_PB8_FMP /*!< Enable Fast-mode Plus on PB8 */ |
Kojto | 107:4f6c30876dfa | 171 | #define SYSCFG_FASTMODEPLUS_PB9 SYSCFG_CFGR1_I2C_PB9_FMP /*!< Enable Fast-mode Plus on PB9 */ |
Kojto | 107:4f6c30876dfa | 172 | |
Kojto | 107:4f6c30876dfa | 173 | /** |
Kojto | 107:4f6c30876dfa | 174 | * @} |
Kojto | 107:4f6c30876dfa | 175 | */ |
Kojto | 107:4f6c30876dfa | 176 | |
Kojto | 107:4f6c30876dfa | 177 | /** |
Kojto | 107:4f6c30876dfa | 178 | * @} |
Kojto | 107:4f6c30876dfa | 179 | */ |
Kojto | 107:4f6c30876dfa | 180 | |
Kojto | 107:4f6c30876dfa | 181 | /* Exported macros -----------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 182 | |
Kojto | 107:4f6c30876dfa | 183 | /** @defgroup DBGMCU_Exported_Macros DBGMCU Exported Macros |
Kojto | 107:4f6c30876dfa | 184 | * @{ |
Kojto | 107:4f6c30876dfa | 185 | */ |
Kojto | 107:4f6c30876dfa | 186 | |
Kojto | 107:4f6c30876dfa | 187 | /** @brief Freeze/Unfreeze Peripherals in Debug mode |
Kojto | 107:4f6c30876dfa | 188 | */ |
Kojto | 107:4f6c30876dfa | 189 | #if defined(DBGMCU_APB1FZR1_DBG_TIM2_STOP) |
Kojto | 107:4f6c30876dfa | 190 | #define __HAL_DBGMCU_FREEZE_TIM2() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM2_STOP) |
Kojto | 107:4f6c30876dfa | 191 | #define __HAL_DBGMCU_UNFREEZE_TIM2() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM2_STOP) |
Kojto | 107:4f6c30876dfa | 192 | #endif |
Kojto | 107:4f6c30876dfa | 193 | |
Kojto | 107:4f6c30876dfa | 194 | #if defined(DBGMCU_APB1FZR1_DBG_TIM3_STOP) |
Kojto | 107:4f6c30876dfa | 195 | #define __HAL_DBGMCU_FREEZE_TIM3() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM3_STOP) |
Kojto | 107:4f6c30876dfa | 196 | #define __HAL_DBGMCU_UNFREEZE_TIM3() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM3_STOP) |
Kojto | 107:4f6c30876dfa | 197 | #endif |
Kojto | 107:4f6c30876dfa | 198 | |
Kojto | 107:4f6c30876dfa | 199 | #if defined(DBGMCU_APB1FZR1_DBG_TIM4_STOP) |
Kojto | 107:4f6c30876dfa | 200 | #define __HAL_DBGMCU_FREEZE_TIM4() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM4_STOP) |
Kojto | 107:4f6c30876dfa | 201 | #define __HAL_DBGMCU_UNFREEZE_TIM4() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM4_STOP) |
Kojto | 107:4f6c30876dfa | 202 | #endif |
Kojto | 107:4f6c30876dfa | 203 | |
Kojto | 107:4f6c30876dfa | 204 | #if defined(DBGMCU_APB1FZR1_DBG_TIM5_STOP) |
Kojto | 107:4f6c30876dfa | 205 | #define __HAL_DBGMCU_FREEZE_TIM5() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM5_STOP) |
Kojto | 107:4f6c30876dfa | 206 | #define __HAL_DBGMCU_UNFREEZE_TIM5() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM5_STOP) |
Kojto | 107:4f6c30876dfa | 207 | #endif |
Kojto | 107:4f6c30876dfa | 208 | |
Kojto | 107:4f6c30876dfa | 209 | #if defined(DBGMCU_APB1FZR1_DBG_TIM6_STOP) |
Kojto | 107:4f6c30876dfa | 210 | #define __HAL_DBGMCU_FREEZE_TIM6() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM6_STOP) |
Kojto | 107:4f6c30876dfa | 211 | #define __HAL_DBGMCU_UNFREEZE_TIM6() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM6_STOP) |
Kojto | 107:4f6c30876dfa | 212 | #endif |
Kojto | 107:4f6c30876dfa | 213 | |
Kojto | 107:4f6c30876dfa | 214 | #if defined(DBGMCU_APB1FZR1_DBG_TIM7_STOP) |
Kojto | 107:4f6c30876dfa | 215 | #define __HAL_DBGMCU_FREEZE_TIM7() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM7_STOP) |
Kojto | 107:4f6c30876dfa | 216 | #define __HAL_DBGMCU_UNFREEZE_TIM7() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_TIM7_STOP) |
Kojto | 107:4f6c30876dfa | 217 | #endif |
Kojto | 107:4f6c30876dfa | 218 | |
Kojto | 107:4f6c30876dfa | 219 | #if defined(DBGMCU_APB1FZR1_DBG_RTC_STOP) |
Kojto | 107:4f6c30876dfa | 220 | #define __HAL_DBGMCU_FREEZE_RTC() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_RTC_STOP) |
Kojto | 107:4f6c30876dfa | 221 | #define __HAL_DBGMCU_UNFREEZE_RTC() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_RTC_STOP) |
Kojto | 107:4f6c30876dfa | 222 | #endif |
Kojto | 107:4f6c30876dfa | 223 | |
Kojto | 107:4f6c30876dfa | 224 | #if defined(DBGMCU_APB1FZR1_DBG_WWDG_STOP) |
Kojto | 107:4f6c30876dfa | 225 | #define __HAL_DBGMCU_FREEZE_WWDG() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_WWDG_STOP) |
Kojto | 107:4f6c30876dfa | 226 | #define __HAL_DBGMCU_UNFREEZE_WWDG() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_WWDG_STOP) |
Kojto | 107:4f6c30876dfa | 227 | #endif |
Kojto | 107:4f6c30876dfa | 228 | |
Kojto | 107:4f6c30876dfa | 229 | #if defined(DBGMCU_APB1FZR1_DBG_IWDG_STOP) |
Kojto | 107:4f6c30876dfa | 230 | #define __HAL_DBGMCU_FREEZE_IWDG() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_IWDG_STOP) |
Kojto | 107:4f6c30876dfa | 231 | #define __HAL_DBGMCU_UNFREEZE_IWDG() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_IWDG_STOP) |
Kojto | 107:4f6c30876dfa | 232 | #endif |
Kojto | 107:4f6c30876dfa | 233 | |
Kojto | 107:4f6c30876dfa | 234 | #if defined(DBGMCU_APB1FZR1_DBG_I2C1_STOP) |
Kojto | 107:4f6c30876dfa | 235 | #define __HAL_DBGMCU_FREEZE_I2C1_TIMEOUT() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C1_STOP) |
Kojto | 107:4f6c30876dfa | 236 | #define __HAL_DBGMCU_UNFREEZE_I2C1_TIMEOUT() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C1_STOP) |
Kojto | 107:4f6c30876dfa | 237 | #endif |
Kojto | 107:4f6c30876dfa | 238 | |
Kojto | 107:4f6c30876dfa | 239 | #if defined(DBGMCU_APB1FZR1_DBG_I2C2_STOP) |
Kojto | 107:4f6c30876dfa | 240 | #define __HAL_DBGMCU_FREEZE_I2C2_TIMEOUT() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C2_STOP) |
Kojto | 107:4f6c30876dfa | 241 | #define __HAL_DBGMCU_UNFREEZE_I2C2_TIMEOUT() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C2_STOP) |
Kojto | 107:4f6c30876dfa | 242 | #endif |
Kojto | 107:4f6c30876dfa | 243 | |
Kojto | 107:4f6c30876dfa | 244 | #if defined(DBGMCU_APB1FZR1_DBG_I2C3_STOP) |
Kojto | 107:4f6c30876dfa | 245 | #define __HAL_DBGMCU_FREEZE_I2C3_TIMEOUT() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C3_STOP) |
Kojto | 107:4f6c30876dfa | 246 | #define __HAL_DBGMCU_UNFREEZE_I2C3_TIMEOUT() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_I2C3_STOP) |
Kojto | 107:4f6c30876dfa | 247 | #endif |
Kojto | 107:4f6c30876dfa | 248 | |
Kojto | 107:4f6c30876dfa | 249 | #if defined(DBGMCU_APB1FZR1_DBG_CAN_STOP) |
Kojto | 107:4f6c30876dfa | 250 | #define __HAL_DBGMCU_FREEZE_CAN1() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_CAN_STOP) |
Kojto | 107:4f6c30876dfa | 251 | #define __HAL_DBGMCU_UNFREEZE_CAN1() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_CAN_STOP) |
Kojto | 107:4f6c30876dfa | 252 | #endif |
Kojto | 107:4f6c30876dfa | 253 | |
Kojto | 107:4f6c30876dfa | 254 | #if defined(DBGMCU_APB1FZR1_DBG_LPTIM1_STOP) |
Kojto | 107:4f6c30876dfa | 255 | #define __HAL_DBGMCU_FREEZE_LPTIM1() SET_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_LPTIM1_STOP) |
Kojto | 107:4f6c30876dfa | 256 | #define __HAL_DBGMCU_UNFREEZE_LPTIM1() CLEAR_BIT(DBGMCU->APB1FZR1, DBGMCU_APB1FZR1_DBG_LPTIM1_STOP) |
Kojto | 107:4f6c30876dfa | 257 | #endif |
Kojto | 107:4f6c30876dfa | 258 | |
Kojto | 107:4f6c30876dfa | 259 | #if defined(DBGMCU_APB1FZR2_DBG_LPTIM2_STOP) |
Kojto | 107:4f6c30876dfa | 260 | #define __HAL_DBGMCU_FREEZE_LPTIM2() SET_BIT(DBGMCU->APB1FZR2, DBGMCU_APB1FZR2_DBG_LPTIM2_STOP) |
Kojto | 107:4f6c30876dfa | 261 | #define __HAL_DBGMCU_UNFREEZE_LPTIM2() CLEAR_BIT(DBGMCU->APB1FZR2, DBGMCU_APB1FZR2_DBG_LPTIM2_STOP) |
Kojto | 107:4f6c30876dfa | 262 | #endif |
Kojto | 107:4f6c30876dfa | 263 | |
Kojto | 107:4f6c30876dfa | 264 | #if defined(DBGMCU_APB2FZ_DBG_TIM1_STOP) |
Kojto | 107:4f6c30876dfa | 265 | #define __HAL_DBGMCU_FREEZE_TIM1() SET_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM1_STOP) |
Kojto | 107:4f6c30876dfa | 266 | #define __HAL_DBGMCU_UNFREEZE_TIM1() CLEAR_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM1_STOP) |
Kojto | 107:4f6c30876dfa | 267 | #endif |
Kojto | 107:4f6c30876dfa | 268 | |
Kojto | 107:4f6c30876dfa | 269 | #if defined(DBGMCU_APB2FZ_DBG_TIM8_STOP) |
Kojto | 107:4f6c30876dfa | 270 | #define __HAL_DBGMCU_FREEZE_TIM8() SET_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM8_STOP) |
Kojto | 107:4f6c30876dfa | 271 | #define __HAL_DBGMCU_UNFREEZE_TIM8() CLEAR_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM8_STOP) |
Kojto | 107:4f6c30876dfa | 272 | #endif |
Kojto | 107:4f6c30876dfa | 273 | |
Kojto | 107:4f6c30876dfa | 274 | #if defined(DBGMCU_APB2FZ_DBG_TIM15_STOP) |
Kojto | 107:4f6c30876dfa | 275 | #define __HAL_DBGMCU_FREEZE_TIM15() SET_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM15_STOP) |
Kojto | 107:4f6c30876dfa | 276 | #define __HAL_DBGMCU_UNFREEZE_TIM15() CLEAR_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM15_STOP) |
Kojto | 107:4f6c30876dfa | 277 | #endif |
Kojto | 107:4f6c30876dfa | 278 | |
Kojto | 107:4f6c30876dfa | 279 | #if defined(DBGMCU_APB2FZ_DBG_TIM16_STOP) |
Kojto | 107:4f6c30876dfa | 280 | #define __HAL_DBGMCU_FREEZE_TIM16() SET_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM16_STOP) |
Kojto | 107:4f6c30876dfa | 281 | #define __HAL_DBGMCU_UNFREEZE_TIM16() CLEAR_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM16_STOP) |
Kojto | 107:4f6c30876dfa | 282 | #endif |
Kojto | 107:4f6c30876dfa | 283 | |
Kojto | 107:4f6c30876dfa | 284 | #if defined(DBGMCU_APB2FZ_DBG_TIM17_STOP) |
Kojto | 107:4f6c30876dfa | 285 | #define __HAL_DBGMCU_FREEZE_TIM17() SET_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM17_STOP) |
Kojto | 107:4f6c30876dfa | 286 | #define __HAL_DBGMCU_UNFREEZE_TIM17() CLEAR_BIT(DBGMCU->APB2FZ, DBGMCU_APB2FZ_DBG_TIM17_STOP) |
Kojto | 107:4f6c30876dfa | 287 | #endif |
Kojto | 107:4f6c30876dfa | 288 | |
Kojto | 107:4f6c30876dfa | 289 | /** |
Kojto | 107:4f6c30876dfa | 290 | * @} |
Kojto | 107:4f6c30876dfa | 291 | */ |
Kojto | 107:4f6c30876dfa | 292 | |
Kojto | 107:4f6c30876dfa | 293 | /** @defgroup SYSCFG_Exported_Macros SYSCFG Exported Macros |
Kojto | 107:4f6c30876dfa | 294 | * @{ |
Kojto | 107:4f6c30876dfa | 295 | */ |
Kojto | 107:4f6c30876dfa | 296 | |
Kojto | 107:4f6c30876dfa | 297 | /** @brief Main Flash memory mapped at 0x00000000. |
Kojto | 107:4f6c30876dfa | 298 | */ |
Kojto | 107:4f6c30876dfa | 299 | #define __HAL_SYSCFG_REMAPMEMORY_FLASH() CLEAR_BIT(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE) |
Kojto | 107:4f6c30876dfa | 300 | |
Kojto | 107:4f6c30876dfa | 301 | /** @brief System Flash memory mapped at 0x00000000. |
Kojto | 107:4f6c30876dfa | 302 | */ |
Kojto | 107:4f6c30876dfa | 303 | #define __HAL_SYSCFG_REMAPMEMORY_SYSTEMFLASH() MODIFY_REG(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE, SYSCFG_MEMRMP_MEM_MODE_0) |
Kojto | 107:4f6c30876dfa | 304 | |
Kojto | 107:4f6c30876dfa | 305 | /** @brief Embedded SRAM mapped at 0x00000000. |
Kojto | 107:4f6c30876dfa | 306 | */ |
Kojto | 107:4f6c30876dfa | 307 | #define __HAL_SYSCFG_REMAPMEMORY_SRAM() MODIFY_REG(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE, (SYSCFG_MEMRMP_MEM_MODE_1|SYSCFG_MEMRMP_MEM_MODE_0)) |
Kojto | 107:4f6c30876dfa | 308 | |
Kojto | 107:4f6c30876dfa | 309 | /** @brief FMC Bank1 (NOR/PSRAM 1 and 2) mapped at 0x00000000. |
Kojto | 107:4f6c30876dfa | 310 | */ |
Kojto | 107:4f6c30876dfa | 311 | #define __HAL_SYSCFG_REMAPMEMORY_FMC() MODIFY_REG(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE, SYSCFG_MEMRMP_MEM_MODE_1) |
Kojto | 107:4f6c30876dfa | 312 | |
Kojto | 107:4f6c30876dfa | 313 | /** @brief QUADSPI mapped at 0x00000000. |
Kojto | 107:4f6c30876dfa | 314 | */ |
Kojto | 107:4f6c30876dfa | 315 | #define __HAL_SYSCFG_REMAPMEMORY_QUADSPI() MODIFY_REG(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE, (SYSCFG_MEMRMP_MEM_MODE_2|SYSCFG_MEMRMP_MEM_MODE_1)) |
Kojto | 107:4f6c30876dfa | 316 | |
Kojto | 107:4f6c30876dfa | 317 | /** |
Kojto | 107:4f6c30876dfa | 318 | * @brief Return the boot mode as configured by user. |
Kojto | 107:4f6c30876dfa | 319 | * @retval The boot mode as configured by user. The returned value can be one |
Kojto | 107:4f6c30876dfa | 320 | * of the following values: |
Kojto | 107:4f6c30876dfa | 321 | * @arg SYSCFG_BOOT_MAINFLASH |
Kojto | 107:4f6c30876dfa | 322 | * @arg SYSCFG_BOOT_SYSTEMFLASH |
Kojto | 107:4f6c30876dfa | 323 | * @arg SYSCFG_BOOT_FMC |
Kojto | 107:4f6c30876dfa | 324 | * @arg SYSCFG_BOOT_SRAM |
Kojto | 107:4f6c30876dfa | 325 | * @arg SYSCFG_BOOT_QUADSPI |
Kojto | 107:4f6c30876dfa | 326 | */ |
Kojto | 107:4f6c30876dfa | 327 | #define __HAL_SYSCFG_GET_BOOT_MODE() READ_BIT(SYSCFG->MEMRMP, SYSCFG_MEMRMP_MEM_MODE) |
Kojto | 107:4f6c30876dfa | 328 | |
Kojto | 107:4f6c30876dfa | 329 | /** @brief SRAM2 page write protection enable macro |
Kojto | 107:4f6c30876dfa | 330 | * @param __SRAM2WRP__: This parameter can be a value of @ref SYSCFG_SRAM2WRP |
Kojto | 107:4f6c30876dfa | 331 | * @note write protection can only be disabled by a system reset |
Kojto | 107:4f6c30876dfa | 332 | */ |
Kojto | 107:4f6c30876dfa | 333 | #define __HAL_SYSCFG_SRAM2_WRP_ENABLE(__SRAM2WRP__) do {assert_param(IS_SYSCFG_SRAM2WRP_PAGE((__SRAM2WRP__)));\ |
Kojto | 107:4f6c30876dfa | 334 | SET_BIT(SYSCFG->SWPR, (__SRAM2WRP__));\ |
Kojto | 107:4f6c30876dfa | 335 | }while(0) |
Kojto | 107:4f6c30876dfa | 336 | |
Kojto | 107:4f6c30876dfa | 337 | /** @brief SRAM2 page write protection unlock prior to erase |
Kojto | 107:4f6c30876dfa | 338 | * @note Writing a wrong key reactivates the write protection |
Kojto | 107:4f6c30876dfa | 339 | */ |
Kojto | 107:4f6c30876dfa | 340 | #define __HAL_SYSCFG_SRAM2_WRP_UNLOCK() do {SYSCFG->SKR = 0xCA;\ |
Kojto | 107:4f6c30876dfa | 341 | SYSCFG->SKR = 0x53;\ |
Kojto | 107:4f6c30876dfa | 342 | }while(0) |
Kojto | 107:4f6c30876dfa | 343 | |
Kojto | 107:4f6c30876dfa | 344 | /** @brief SRAM2 erase |
Kojto | 107:4f6c30876dfa | 345 | * @note __SYSCFG_GET_FLAG(SYSCFG_FLAG_SRAM2_BUSY) may be used to check end of erase |
Kojto | 107:4f6c30876dfa | 346 | */ |
Kojto | 107:4f6c30876dfa | 347 | #define __HAL_SYSCFG_SRAM2_ERASE() SET_BIT(SYSCFG->SCSR, SYSCFG_SCSR_SRAM2ER) |
Kojto | 107:4f6c30876dfa | 348 | |
Kojto | 107:4f6c30876dfa | 349 | /** @brief Floating Point Unit interrupt enable/disable macros |
Kojto | 107:4f6c30876dfa | 350 | * @param __INTERRUPT__: This parameter can be a value of @ref SYSCFG_FPU_Interrupts |
Kojto | 107:4f6c30876dfa | 351 | */ |
Kojto | 107:4f6c30876dfa | 352 | #define __HAL_SYSCFG_FPU_INTERRUPT_ENABLE(__INTERRUPT__) do {assert_param(IS_SYSCFG_FPU_INTERRUPT((__INTERRUPT__)));\ |
Kojto | 107:4f6c30876dfa | 353 | SET_BIT(SYSCFG->CFGR1, (__INTERRUPT__));\ |
Kojto | 107:4f6c30876dfa | 354 | }while(0) |
Kojto | 107:4f6c30876dfa | 355 | |
Kojto | 107:4f6c30876dfa | 356 | #define __HAL_SYSCFG_FPU_INTERRUPT_DISABLE(__INTERRUPT__) do {assert_param(IS_SYSCFG_FPU_INTERRUPT((__INTERRUPT__)));\ |
Kojto | 107:4f6c30876dfa | 357 | CLEAR_BIT(SYSCFG->CFGR1, (__INTERRUPT__));\ |
Kojto | 107:4f6c30876dfa | 358 | }while(0) |
Kojto | 107:4f6c30876dfa | 359 | |
Kojto | 107:4f6c30876dfa | 360 | /** @brief SYSCFG Break ECC lock. |
Kojto | 107:4f6c30876dfa | 361 | * Enable and lock the connection of Flash ECC error connection to TIM1/8/15/16/17 Break input. |
Kojto | 107:4f6c30876dfa | 362 | * @note The selected configuration is locked and can be unlocked only by system reset. |
Kojto | 107:4f6c30876dfa | 363 | */ |
Kojto | 107:4f6c30876dfa | 364 | #define __HAL_SYSCFG_BREAK_ECC_LOCK() SET_BIT(SYSCFG->CFGR2, SYSCFG_CFGR2_ECCL) |
Kojto | 107:4f6c30876dfa | 365 | |
Kojto | 107:4f6c30876dfa | 366 | /** @brief SYSCFG Break Cortex-M4 Lockup lock. |
Kojto | 107:4f6c30876dfa | 367 | * Enable and lock the connection of Cortex-M4 LOCKUP (Hardfault) output to TIM1/8/15/16/17 Break input. |
Kojto | 107:4f6c30876dfa | 368 | * @note The selected configuration is locked and can be unlocked only by system reset. |
Kojto | 107:4f6c30876dfa | 369 | */ |
Kojto | 107:4f6c30876dfa | 370 | #define __HAL_SYSCFG_BREAK_LOCKUP_LOCK() SET_BIT(SYSCFG->CFGR2, SYSCFG_CFGR2_CLL) |
Kojto | 107:4f6c30876dfa | 371 | |
Kojto | 107:4f6c30876dfa | 372 | /** @brief SYSCFG Break PVD lock. |
Kojto | 107:4f6c30876dfa | 373 | * Enable and lock the PVD connection to Timer1/8/15/16/17 Break input, as well as the PVDE and PLS[2:0] in the PWR_CR2 register. |
Kojto | 107:4f6c30876dfa | 374 | * @note The selected configuration is locked and can be unlocked only by system reset. |
Kojto | 107:4f6c30876dfa | 375 | */ |
Kojto | 107:4f6c30876dfa | 376 | #define __HAL_SYSCFG_BREAK_PVD_LOCK() SET_BIT(SYSCFG->CFGR2, SYSCFG_CFGR2_PVDL) |
Kojto | 107:4f6c30876dfa | 377 | |
Kojto | 107:4f6c30876dfa | 378 | /** @brief SYSCFG Break SRAM2 parity lock. |
Kojto | 107:4f6c30876dfa | 379 | * Enable and lock the SRAM2 parity error signal connection to TIM1/8/15/16/17 Break input. |
Kojto | 107:4f6c30876dfa | 380 | * @note The selected configuration is locked and can be unlocked by system reset. |
Kojto | 107:4f6c30876dfa | 381 | */ |
Kojto | 107:4f6c30876dfa | 382 | #define __HAL_SYSCFG_BREAK_SRAM2PARITY_LOCK() SET_BIT(SYSCFG->CFGR2, SYSCFG_CFGR2_SPL) |
Kojto | 107:4f6c30876dfa | 383 | |
Kojto | 107:4f6c30876dfa | 384 | /** @brief Check SYSCFG flag is set or not. |
Kojto | 107:4f6c30876dfa | 385 | * @param __FLAG__: specifies the flag to check. |
Kojto | 107:4f6c30876dfa | 386 | * This parameter can be one of the following values: |
Kojto | 107:4f6c30876dfa | 387 | * @arg SYSCFG_FLAG_SRAM2_PE: SRAM2 Parity Error Flag |
Kojto | 107:4f6c30876dfa | 388 | * @arg SYSCFG_FLAG_SRAM2_BUSY: SRAM2 Erase Ongoing |
Kojto | 107:4f6c30876dfa | 389 | * @retval The new state of __FLAG__ (TRUE or FALSE). |
Kojto | 107:4f6c30876dfa | 390 | */ |
Kojto | 107:4f6c30876dfa | 391 | #define __HAL_SYSCFG_GET_FLAG(__FLAG__) ((((((__FLAG__) == SYSCFG_SCSR_SRAM2BSY)? SYSCFG->SCSR : SYSCFG->CFGR2) & (__FLAG__))!= 0) ? 1 : 0) |
Kojto | 107:4f6c30876dfa | 392 | |
Kojto | 107:4f6c30876dfa | 393 | /** @brief Set the SPF bit to clear the SRAM Parity Error Flag. |
Kojto | 107:4f6c30876dfa | 394 | */ |
Kojto | 107:4f6c30876dfa | 395 | #define __HAL_SYSCFG_CLEAR_FLAG() SET_BIT(SYSCFG->CFGR2, SYSCFG_CFGR2_SPF) |
Kojto | 107:4f6c30876dfa | 396 | |
Kojto | 107:4f6c30876dfa | 397 | /** @brief Fast-mode Plus driving capability enable/disable macros |
Kojto | 107:4f6c30876dfa | 398 | * @param __FASTMODEPLUS__: This parameter can be a value of : |
Kojto | 107:4f6c30876dfa | 399 | * @arg SYSCFG_FASTMODEPLUS_PB6: Fast-mode Plus driving capability activation on PB6 |
Kojto | 107:4f6c30876dfa | 400 | * @arg SYSCFG_FASTMODEPLUS_PB7: Fast-mode Plus driving capability activation on PB7 |
Kojto | 107:4f6c30876dfa | 401 | * @arg SYSCFG_FASTMODEPLUS_PB8: Fast-mode Plus driving capability activation on PB8 |
Kojto | 107:4f6c30876dfa | 402 | * @arg SYSCFG_FASTMODEPLUS_PB9: Fast-mode Plus driving capability activation on PB9 |
Kojto | 107:4f6c30876dfa | 403 | */ |
Kojto | 107:4f6c30876dfa | 404 | #define __HAL_SYSCFG_FASTMODEPLUS_ENABLE(__FASTMODEPLUS__) do {assert_param(IS_SYSCFG_FASTMODEPLUS((__FASTMODEPLUS__)));\ |
Kojto | 107:4f6c30876dfa | 405 | SET_BIT(SYSCFG->CFGR1, (__FASTMODEPLUS__));\ |
Kojto | 107:4f6c30876dfa | 406 | }while(0) |
Kojto | 107:4f6c30876dfa | 407 | |
Kojto | 107:4f6c30876dfa | 408 | #define __HAL_SYSCFG_FASTMODEPLUS_DISABLE(__FASTMODEPLUS__) do {assert_param(IS_SYSCFG_FASTMODEPLUS((__FASTMODEPLUS__)));\ |
Kojto | 107:4f6c30876dfa | 409 | CLEAR_BIT(SYSCFG->CFGR1, (__FASTMODEPLUS__));\ |
Kojto | 107:4f6c30876dfa | 410 | }while(0) |
Kojto | 107:4f6c30876dfa | 411 | |
Kojto | 107:4f6c30876dfa | 412 | /** |
Kojto | 107:4f6c30876dfa | 413 | * @} |
Kojto | 107:4f6c30876dfa | 414 | */ |
Kojto | 107:4f6c30876dfa | 415 | |
Kojto | 107:4f6c30876dfa | 416 | /* Private macros ------------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 417 | /** @defgroup SYSCFG_Private_Macros SYSCFG Private Macros |
Kojto | 107:4f6c30876dfa | 418 | * @{ |
Kojto | 107:4f6c30876dfa | 419 | */ |
Kojto | 107:4f6c30876dfa | 420 | |
Kojto | 107:4f6c30876dfa | 421 | #define IS_SYSCFG_FPU_INTERRUPT(__INTERRUPT__) ((((__INTERRUPT__) & SYSCFG_IT_FPU_IOC) == SYSCFG_IT_FPU_IOC) || \ |
Kojto | 107:4f6c30876dfa | 422 | (((__INTERRUPT__) & SYSCFG_IT_FPU_DZC) == SYSCFG_IT_FPU_DZC) || \ |
Kojto | 107:4f6c30876dfa | 423 | (((__INTERRUPT__) & SYSCFG_IT_FPU_UFC) == SYSCFG_IT_FPU_UFC) || \ |
Kojto | 107:4f6c30876dfa | 424 | (((__INTERRUPT__) & SYSCFG_IT_FPU_OFC) == SYSCFG_IT_FPU_OFC) || \ |
Kojto | 107:4f6c30876dfa | 425 | (((__INTERRUPT__) & SYSCFG_IT_FPU_IDC) == SYSCFG_IT_FPU_IDC) || \ |
Kojto | 107:4f6c30876dfa | 426 | (((__INTERRUPT__) & SYSCFG_IT_FPU_IXC) == SYSCFG_IT_FPU_IXC)) |
Kojto | 107:4f6c30876dfa | 427 | |
Kojto | 107:4f6c30876dfa | 428 | #define IS_SYSCFG_BREAK_CONFIG(__CONFIG__) (((__CONFIG__) == SYSCFG_BREAK_ECC) || \ |
Kojto | 107:4f6c30876dfa | 429 | ((__CONFIG__) == SYSCFG_BREAK_PVD) || \ |
Kojto | 107:4f6c30876dfa | 430 | ((__CONFIG__) == SYSCFG_BREAK_SRAM2_PARITY) || \ |
Kojto | 107:4f6c30876dfa | 431 | ((__CONFIG__) == SYSCFG_BREAK_LOCKUP)) |
Kojto | 107:4f6c30876dfa | 432 | |
Kojto | 107:4f6c30876dfa | 433 | #define IS_SYSCFG_SRAM2WRP_PAGE(__PAGE__) (((__PAGE__) > 0) && ((__PAGE__) <= 0xFFFFFFFF)) |
Kojto | 107:4f6c30876dfa | 434 | |
Kojto | 107:4f6c30876dfa | 435 | #define IS_SYSCFG_VREFBUF_VOLTAGE_SCALE(__SCALE__) (((__SCALE__) == SYSCFG_VREFBUF_VOLTAGE_SCALE0) || \ |
Kojto | 107:4f6c30876dfa | 436 | ((__SCALE__) == SYSCFG_VREFBUF_VOLTAGE_SCALE1)) |
Kojto | 107:4f6c30876dfa | 437 | |
Kojto | 107:4f6c30876dfa | 438 | #define IS_SYSCFG_VREFBUF_HIGH_IMPEDANCE(__VALUE__) (((__VALUE__) == SYSCFG_VREFBUF_HIGH_IMPEDANCE_DISABLE) || \ |
Kojto | 107:4f6c30876dfa | 439 | ((__VALUE__) == SYSCFG_VREFBUF_HIGH_IMPEDANCE_ENABLE)) |
Kojto | 107:4f6c30876dfa | 440 | |
Kojto | 107:4f6c30876dfa | 441 | #define IS_SYSCFG_VREFBUF_TRIMMING(__VALUE__) (((__VALUE__) > 0) && ((__VALUE__) <= VREFBUF_CCR_TRIM)) |
Kojto | 107:4f6c30876dfa | 442 | |
Kojto | 107:4f6c30876dfa | 443 | |
Kojto | 107:4f6c30876dfa | 444 | #define IS_SYSCFG_FASTMODEPLUS(__PIN__) ((((__PIN__) & SYSCFG_FASTMODEPLUS_PB6) == SYSCFG_FASTMODEPLUS_PB6) || \ |
Kojto | 107:4f6c30876dfa | 445 | (((__PIN__) & SYSCFG_FASTMODEPLUS_PB7) == SYSCFG_FASTMODEPLUS_PB7) || \ |
Kojto | 107:4f6c30876dfa | 446 | (((__PIN__) & SYSCFG_FASTMODEPLUS_PB8) == SYSCFG_FASTMODEPLUS_PB8) || \ |
Kojto | 107:4f6c30876dfa | 447 | (((__PIN__) & SYSCFG_FASTMODEPLUS_PB9) == SYSCFG_FASTMODEPLUS_PB9)) |
Kojto | 107:4f6c30876dfa | 448 | |
Kojto | 107:4f6c30876dfa | 449 | /** |
Kojto | 107:4f6c30876dfa | 450 | * @} |
Kojto | 107:4f6c30876dfa | 451 | */ |
Kojto | 107:4f6c30876dfa | 452 | |
Kojto | 107:4f6c30876dfa | 453 | /* Exported functions --------------------------------------------------------*/ |
Kojto | 107:4f6c30876dfa | 454 | |
Kojto | 107:4f6c30876dfa | 455 | /** @addtogroup HAL_Exported_Functions |
Kojto | 107:4f6c30876dfa | 456 | * @{ |
Kojto | 107:4f6c30876dfa | 457 | */ |
Kojto | 107:4f6c30876dfa | 458 | |
Kojto | 107:4f6c30876dfa | 459 | /** @addtogroup HAL_Exported_Functions_Group1 |
Kojto | 107:4f6c30876dfa | 460 | * @{ |
Kojto | 107:4f6c30876dfa | 461 | */ |
Kojto | 107:4f6c30876dfa | 462 | |
Kojto | 107:4f6c30876dfa | 463 | /* Initialization and de-initialization functions ******************************/ |
Kojto | 107:4f6c30876dfa | 464 | HAL_StatusTypeDef HAL_Init(void); |
Kojto | 107:4f6c30876dfa | 465 | HAL_StatusTypeDef HAL_DeInit(void); |
Kojto | 107:4f6c30876dfa | 466 | void HAL_MspInit(void); |
Kojto | 107:4f6c30876dfa | 467 | void HAL_MspDeInit(void); |
Kojto | 107:4f6c30876dfa | 468 | HAL_StatusTypeDef HAL_InitTick (uint32_t TickPriority); |
Kojto | 107:4f6c30876dfa | 469 | |
Kojto | 107:4f6c30876dfa | 470 | /** |
Kojto | 107:4f6c30876dfa | 471 | * @} |
Kojto | 107:4f6c30876dfa | 472 | */ |
Kojto | 107:4f6c30876dfa | 473 | |
Kojto | 107:4f6c30876dfa | 474 | /** @addtogroup HAL_Exported_Functions_Group2 |
Kojto | 107:4f6c30876dfa | 475 | * @{ |
Kojto | 107:4f6c30876dfa | 476 | */ |
Kojto | 107:4f6c30876dfa | 477 | |
Kojto | 107:4f6c30876dfa | 478 | /* Peripheral Control functions ************************************************/ |
Kojto | 107:4f6c30876dfa | 479 | void HAL_IncTick(void); |
Kojto | 107:4f6c30876dfa | 480 | void HAL_Delay(uint32_t Delay); |
Kojto | 107:4f6c30876dfa | 481 | uint32_t HAL_GetTick(void); |
Kojto | 107:4f6c30876dfa | 482 | void HAL_SuspendTick(void); |
Kojto | 107:4f6c30876dfa | 483 | void HAL_ResumeTick(void); |
Kojto | 107:4f6c30876dfa | 484 | uint32_t HAL_GetHalVersion(void); |
Kojto | 107:4f6c30876dfa | 485 | uint32_t HAL_GetREVID(void); |
Kojto | 107:4f6c30876dfa | 486 | uint32_t HAL_GetDEVID(void); |
Kojto | 107:4f6c30876dfa | 487 | |
Kojto | 107:4f6c30876dfa | 488 | /** |
Kojto | 107:4f6c30876dfa | 489 | * @} |
Kojto | 107:4f6c30876dfa | 490 | */ |
Kojto | 107:4f6c30876dfa | 491 | |
Kojto | 107:4f6c30876dfa | 492 | /** @addtogroup HAL_Exported_Functions_Group3 |
Kojto | 107:4f6c30876dfa | 493 | * @{ |
Kojto | 107:4f6c30876dfa | 494 | */ |
Kojto | 107:4f6c30876dfa | 495 | |
Kojto | 107:4f6c30876dfa | 496 | /* DBGMCU Peripheral Control functions *****************************************/ |
Kojto | 107:4f6c30876dfa | 497 | void HAL_DBGMCU_EnableDBGSleepMode(void); |
Kojto | 107:4f6c30876dfa | 498 | void HAL_DBGMCU_DisableDBGSleepMode(void); |
Kojto | 107:4f6c30876dfa | 499 | void HAL_DBGMCU_EnableDBGStopMode(void); |
Kojto | 107:4f6c30876dfa | 500 | void HAL_DBGMCU_DisableDBGStopMode(void); |
Kojto | 107:4f6c30876dfa | 501 | void HAL_DBGMCU_EnableDBGStandbyMode(void); |
Kojto | 107:4f6c30876dfa | 502 | void HAL_DBGMCU_DisableDBGStandbyMode(void); |
Kojto | 107:4f6c30876dfa | 503 | |
Kojto | 107:4f6c30876dfa | 504 | /** |
Kojto | 107:4f6c30876dfa | 505 | * @} |
Kojto | 107:4f6c30876dfa | 506 | */ |
Kojto | 107:4f6c30876dfa | 507 | |
Kojto | 107:4f6c30876dfa | 508 | /** @addtogroup HAL_Exported_Functions_Group4 |
Kojto | 107:4f6c30876dfa | 509 | * @{ |
Kojto | 107:4f6c30876dfa | 510 | */ |
Kojto | 107:4f6c30876dfa | 511 | |
Kojto | 107:4f6c30876dfa | 512 | /* SYSCFG Control functions ****************************************************/ |
Kojto | 107:4f6c30876dfa | 513 | void HAL_SYSCFG_SRAM2Erase(void); |
Kojto | 107:4f6c30876dfa | 514 | void HAL_SYSCFG_EnableMemorySwappingBank(void); |
Kojto | 107:4f6c30876dfa | 515 | void HAL_SYSCFG_DisableMemorySwappingBank(void); |
Kojto | 107:4f6c30876dfa | 516 | |
Kojto | 107:4f6c30876dfa | 517 | void HAL_SYSCFG_VREFBUF_VoltageScalingConfig(uint32_t VoltageScaling); |
Kojto | 107:4f6c30876dfa | 518 | void HAL_SYSCFG_VREFBUF_HighImpedanceConfig(uint32_t Mode); |
Kojto | 107:4f6c30876dfa | 519 | void HAL_SYSCFG_VREFBUF_TrimmingConfig(uint32_t TrimmingValue); |
Kojto | 107:4f6c30876dfa | 520 | HAL_StatusTypeDef HAL_SYSCFG_EnableVREFBUF(void); |
Kojto | 107:4f6c30876dfa | 521 | void HAL_SYSCFG_DisableVREFBUF(void); |
Kojto | 107:4f6c30876dfa | 522 | |
Kojto | 107:4f6c30876dfa | 523 | /** |
Kojto | 107:4f6c30876dfa | 524 | * @} |
Kojto | 107:4f6c30876dfa | 525 | */ |
Kojto | 107:4f6c30876dfa | 526 | |
Kojto | 107:4f6c30876dfa | 527 | /** |
Kojto | 107:4f6c30876dfa | 528 | * @} |
Kojto | 107:4f6c30876dfa | 529 | */ |
Kojto | 107:4f6c30876dfa | 530 | |
Kojto | 107:4f6c30876dfa | 531 | /** |
Kojto | 107:4f6c30876dfa | 532 | * @} |
Kojto | 107:4f6c30876dfa | 533 | */ |
Kojto | 107:4f6c30876dfa | 534 | |
Kojto | 107:4f6c30876dfa | 535 | /** |
Kojto | 107:4f6c30876dfa | 536 | * @} |
Kojto | 107:4f6c30876dfa | 537 | */ |
Kojto | 107:4f6c30876dfa | 538 | |
Kojto | 107:4f6c30876dfa | 539 | #ifdef __cplusplus |
Kojto | 107:4f6c30876dfa | 540 | } |
Kojto | 107:4f6c30876dfa | 541 | #endif |
Kojto | 107:4f6c30876dfa | 542 | |
Kojto | 107:4f6c30876dfa | 543 | #endif /* __STM32L4xx_HAL_H */ |
Kojto | 107:4f6c30876dfa | 544 | |
Kojto | 107:4f6c30876dfa | 545 | /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ |