my fork
Fork of mbed by
TARGET_NUCLEO_F302R8/stm32f3xx_hal.h@97:4298809c7c9e, 2015-04-08 (annotated)
- Committer:
- filartrix
- Date:
- Wed Apr 08 14:12:53 2015 +0000
- Revision:
- 97:4298809c7c9e
- Parent:
- 90:cb3d968589d8
First reale BlueNRG module for nucleo 401 board
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 stm32f3xx_hal.h |
Kojto | 90:cb3d968589d8 | 4 | * @author MCD Application Team |
Kojto | 90:cb3d968589d8 | 5 | * @version V1.1.0 |
Kojto | 90:cb3d968589d8 | 6 | * @date 12-Sept-2014 |
Kojto | 90:cb3d968589d8 | 7 | * @brief This file contains all the functions prototypes for the HAL |
Kojto | 90:cb3d968589d8 | 8 | * module driver. |
Kojto | 90:cb3d968589d8 | 9 | ****************************************************************************** |
Kojto | 90:cb3d968589d8 | 10 | * @attention |
Kojto | 90:cb3d968589d8 | 11 | * |
Kojto | 90:cb3d968589d8 | 12 | * <h2><center>© COPYRIGHT(c) 2014 STMicroelectronics</center></h2> |
Kojto | 90:cb3d968589d8 | 13 | * |
Kojto | 90:cb3d968589d8 | 14 | * Redistribution and use in source and binary forms, with or without modification, |
Kojto | 90:cb3d968589d8 | 15 | * are permitted provided that the following conditions are met: |
Kojto | 90:cb3d968589d8 | 16 | * 1. Redistributions of source code must retain the above copyright notice, |
Kojto | 90:cb3d968589d8 | 17 | * this list of conditions and the following disclaimer. |
Kojto | 90:cb3d968589d8 | 18 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
Kojto | 90:cb3d968589d8 | 19 | * this list of conditions and the following disclaimer in the documentation |
Kojto | 90:cb3d968589d8 | 20 | * and/or other materials provided with the distribution. |
Kojto | 90:cb3d968589d8 | 21 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
Kojto | 90:cb3d968589d8 | 22 | * may be used to endorse or promote products derived from this software |
Kojto | 90:cb3d968589d8 | 23 | * without specific prior written permission. |
Kojto | 90:cb3d968589d8 | 24 | * |
Kojto | 90:cb3d968589d8 | 25 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
Kojto | 90:cb3d968589d8 | 26 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
Kojto | 90:cb3d968589d8 | 27 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
Kojto | 90:cb3d968589d8 | 28 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
Kojto | 90:cb3d968589d8 | 29 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
Kojto | 90:cb3d968589d8 | 30 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
Kojto | 90:cb3d968589d8 | 31 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
Kojto | 90:cb3d968589d8 | 32 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
Kojto | 90:cb3d968589d8 | 33 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
Kojto | 90:cb3d968589d8 | 34 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
Kojto | 90:cb3d968589d8 | 35 | * |
Kojto | 90:cb3d968589d8 | 36 | ****************************************************************************** |
Kojto | 90:cb3d968589d8 | 37 | */ |
Kojto | 90:cb3d968589d8 | 38 | |
Kojto | 90:cb3d968589d8 | 39 | /* Define to prevent recursive inclusion -------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 40 | #ifndef __STM32F3xx_HAL_H |
Kojto | 90:cb3d968589d8 | 41 | #define __STM32F3xx_HAL_H |
Kojto | 90:cb3d968589d8 | 42 | |
Kojto | 90:cb3d968589d8 | 43 | #ifdef __cplusplus |
Kojto | 90:cb3d968589d8 | 44 | extern "C" { |
Kojto | 90:cb3d968589d8 | 45 | #endif |
Kojto | 90:cb3d968589d8 | 46 | |
Kojto | 90:cb3d968589d8 | 47 | /* Includes ------------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 48 | #include "stm32f3xx_hal_conf.h" |
Kojto | 90:cb3d968589d8 | 49 | |
Kojto | 90:cb3d968589d8 | 50 | /** @addtogroup STM32F3xx_HAL_Driver |
Kojto | 90:cb3d968589d8 | 51 | * @{ |
Kojto | 90:cb3d968589d8 | 52 | */ |
Kojto | 90:cb3d968589d8 | 53 | |
Kojto | 90:cb3d968589d8 | 54 | /** @addtogroup HAL |
Kojto | 90:cb3d968589d8 | 55 | * @{ |
Kojto | 90:cb3d968589d8 | 56 | */ |
Kojto | 90:cb3d968589d8 | 57 | |
Kojto | 90:cb3d968589d8 | 58 | /* Exported types ------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 59 | /* Exported constants --------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 60 | /** @defgroup HAL_Exported_Constants HAL Exported Constants |
Kojto | 90:cb3d968589d8 | 61 | * @{ |
Kojto | 90:cb3d968589d8 | 62 | */ |
Kojto | 90:cb3d968589d8 | 63 | /** @defgroup SYSCFG_BitAddress_AliasRegion SYSCFG registers bit address in the alias region |
Kojto | 90:cb3d968589d8 | 64 | * @brief SYSCFG registers bit address in the alias region |
Kojto | 90:cb3d968589d8 | 65 | * @{ |
Kojto | 90:cb3d968589d8 | 66 | */ |
Kojto | 90:cb3d968589d8 | 67 | /* ------------ SYSCFG registers bit address in the alias region -------------*/ |
Kojto | 90:cb3d968589d8 | 68 | #define SYSCFG_OFFSET (SYSCFG_BASE - PERIPH_BASE) |
Kojto | 90:cb3d968589d8 | 69 | /* --- CFGR2 Register ---*/ |
Kojto | 90:cb3d968589d8 | 70 | /* Alias word address of BYP_ADDR_PAR bit */ |
Kojto | 90:cb3d968589d8 | 71 | #define CFGR2_OFFSET (SYSCFG_OFFSET + 0x18) |
Kojto | 90:cb3d968589d8 | 72 | #define BYPADDRPAR_BitNumber 0x04 |
Kojto | 90:cb3d968589d8 | 73 | #define CFGR2_BYPADDRPAR_BB (PERIPH_BB_BASE + (CFGR2_OFFSET * 32) + (BYPADDRPAR_BitNumber * 4)) |
Kojto | 90:cb3d968589d8 | 74 | /** |
Kojto | 90:cb3d968589d8 | 75 | * @} |
Kojto | 90:cb3d968589d8 | 76 | */ |
Kojto | 90:cb3d968589d8 | 77 | |
Kojto | 90:cb3d968589d8 | 78 | #if defined(SYSCFG_CFGR1_DMA_RMP) |
Kojto | 90:cb3d968589d8 | 79 | /** @defgroup HAL_DMA_Remapping DMA Remapping |
Kojto | 90:cb3d968589d8 | 80 | * Elements values convention: 0xXXYYYYYY |
Kojto | 90:cb3d968589d8 | 81 | * - YYYYYY : Position in the register |
Kojto | 90:cb3d968589d8 | 82 | * - XX : Register index |
Kojto | 90:cb3d968589d8 | 83 | * - 00: CFGR1 register in SYSCFG |
Kojto | 90:cb3d968589d8 | 84 | * - 01: CFGR3 register in SYSCFG (not available on STM32F373xC/STM32F378xx devices) |
Kojto | 90:cb3d968589d8 | 85 | * @{ |
Kojto | 90:cb3d968589d8 | 86 | */ |
Kojto | 90:cb3d968589d8 | 87 | #define HAL_REMAPDMA_ADC24_DMA2_CH34 ((uint32_t)0x00000100) /*!< ADC24 DMA remap (STM32F303xB/C/E, STM32F358xx and STM32F398xx devices) |
Kojto | 90:cb3d968589d8 | 88 | 1: Remap (ADC24 DMA requests mapped on DMA2 channels 3 and 4) */ |
Kojto | 90:cb3d968589d8 | 89 | #define HAL_REMAPDMA_TIM16_DMA1_CH6 ((uint32_t)0x00000800) /*!< TIM16 DMA request remap |
Kojto | 90:cb3d968589d8 | 90 | 1: Remap (TIM16_CH1 and TIM16_UP DMA requests mapped on DMA1 channel 6) */ |
Kojto | 90:cb3d968589d8 | 91 | #define HAL_REMAPDMA_TIM17_DMA1_CH7 ((uint32_t)0x00001000) /*!< TIM17 DMA request remap |
Kojto | 90:cb3d968589d8 | 92 | 1: Remap (TIM17_CH1 and TIM17_UP DMA requests mapped on DMA1 channel 7) */ |
Kojto | 90:cb3d968589d8 | 93 | #define HAL_REMAPDMA_TIM6_DAC1_CH1_DMA1_CH3 ((uint32_t)0x00002000) /*!< TIM6 and DAC channel1 DMA remap (STM32F303xB/C/E, STM32F358xx and STM32F398xx devices) |
Kojto | 90:cb3d968589d8 | 94 | 1: Remap (TIM6_UP and DAC_CH1 DMA requests mapped on DMA1 channel 3) */ |
Kojto | 90:cb3d968589d8 | 95 | #define HAL_REMAPDMA_TIM7_DAC1_CH2_DMA1_CH4 ((uint32_t)0x00004000) /*!< TIM7 and DAC channel2 DMA remap (STM32F303xB/C/E, STM32F358xx and STM32F398xx devices) |
Kojto | 90:cb3d968589d8 | 96 | 1: Remap (TIM7_UP and DAC_CH2 DMA requests mapped on DMA1 channel 4) */ |
Kojto | 90:cb3d968589d8 | 97 | #define HAL_REMAPDMA_DAC2_CH1_DMA1_CH5 ((uint32_t)0x00008000) /*!< DAC2 channel1 DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 98 | 1: Remap (DAC2_CH1 DMA requests mapped on DMA1 channel 5) */ |
Kojto | 90:cb3d968589d8 | 99 | #define HAL_REMAPDMA_TIM18_DAC2_CH1_DMA1_CH5 ((uint32_t)0x00008000) /*!< DAC2 channel1 DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 100 | 1: Remap (DAC2_CH1 DMA requests mapped on DMA1 channel 5) */ |
Kojto | 90:cb3d968589d8 | 101 | #if defined(SYSCFG_CFGR3_DMA_RMP) |
Kojto | 90:cb3d968589d8 | 102 | #if !defined(HAL_REMAP_CFGR3_MASK) |
Kojto | 90:cb3d968589d8 | 103 | #define HAL_REMAP_CFGR3_MASK ((uint32_t)0x01000000) |
Kojto | 90:cb3d968589d8 | 104 | #endif |
Kojto | 90:cb3d968589d8 | 105 | |
Kojto | 90:cb3d968589d8 | 106 | #define HAL_REMAPDMA_SPI1_RX_DMA1_CH2 ((uint32_t)0x01000003) /*!< SPI1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 107 | 11: Map on DMA1 channel 2 */ |
Kojto | 90:cb3d968589d8 | 108 | #define HAL_REMAPDMA_SPI1_RX_DMA1_CH4 ((uint32_t)0x01000001) /*!< SPI1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 109 | 01: Map on DMA1 channel 4 */ |
Kojto | 90:cb3d968589d8 | 110 | #define HAL_REMAPDMA_SPI1_RX_DMA1_CH6 ((uint32_t)0x01000002) /*!< SPI1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 111 | 10: Map on DMA1 channel 6 */ |
Kojto | 90:cb3d968589d8 | 112 | #define HAL_REMAPDMA_SPI1_TX_DMA1_CH3 ((uint32_t)0x0100000C) /*!< SPI1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 113 | 11: Map on DMA1 channel 3 */ |
Kojto | 90:cb3d968589d8 | 114 | #define HAL_REMAPDMA_SPI1_TX_DMA1_CH5 ((uint32_t)0x01000004) /*!< SPI1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 115 | 01: Map on DMA1 channel 5 */ |
Kojto | 90:cb3d968589d8 | 116 | #define HAL_REMAPDMA_SPI1_TX_DMA1_CH7 ((uint32_t)0x01000008) /*!< SPI1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 117 | 10: Map on DMA1 channel 7 */ |
Kojto | 90:cb3d968589d8 | 118 | #define HAL_REMAPDMA_I2C1_RX_DMA1_CH7 ((uint32_t)0x01000030) /*!< I2C1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 119 | 11: Map on DMA1 channel 7 */ |
Kojto | 90:cb3d968589d8 | 120 | #define HAL_REMAPDMA_I2C1_RX_DMA1_CH3 ((uint32_t)0x01000010) /*!< I2C1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 121 | 01: Map on DMA1 channel 3 */ |
Kojto | 90:cb3d968589d8 | 122 | #define HAL_REMAPDMA_I2C1_RX_DMA1_CH5 ((uint32_t)0x01000020) /*!< I2C1_RX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 123 | 10: Map on DMA1 channel 5 */ |
Kojto | 90:cb3d968589d8 | 124 | #define HAL_REMAPDMA_I2C1_TX_DMA1_CH6 ((uint32_t)0x010000C0) /*!< I2C1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 125 | 11: Map on DMA1 channel 6 */ |
Kojto | 90:cb3d968589d8 | 126 | #define HAL_REMAPDMA_I2C1_TX_DMA1_CH2 ((uint32_t)0x01000040) /*!< I2C1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 127 | 01: Map on DMA1 channel 2 */ |
Kojto | 90:cb3d968589d8 | 128 | #define HAL_REMAPDMA_I2C1_TX_DMA1_CH4 ((uint32_t)0x01000080) /*!< I2C1_TX DMA remap (STM32F303x4/6/8 devices only) |
Kojto | 90:cb3d968589d8 | 129 | 10: Map on DMA1 channel 4 */ |
Kojto | 90:cb3d968589d8 | 130 | #define HAL_REMAPDMA_ADC2_DMA1_CH2 ((uint32_t)0x01000100) /*!< ADC2 DMA remap |
Kojto | 90:cb3d968589d8 | 131 | x0: No remap (ADC2 on DMA2) |
Kojto | 90:cb3d968589d8 | 132 | 10: Map on DMA1 channel 2 */ |
Kojto | 90:cb3d968589d8 | 133 | #define HAL_REMAPDMA_ADC2_DMA1_CH4 ((uint32_t)0x01000300) /*!< ADC2 DMA remap |
Kojto | 90:cb3d968589d8 | 134 | 11: Map on DMA1 channel 4 */ |
Kojto | 90:cb3d968589d8 | 135 | #endif /* SYSCFG_CFGR3_DMA_RMP */ |
Kojto | 90:cb3d968589d8 | 136 | |
Kojto | 90:cb3d968589d8 | 137 | #if defined(SYSCFG_CFGR3_DMA_RMP) |
Kojto | 90:cb3d968589d8 | 138 | #define IS_HAL_REMAPDMA(RMP) ((((RMP) & HAL_REMAPDMA_ADC24_DMA2_CH34) == HAL_REMAPDMA_ADC24_DMA2_CH34) || \ |
Kojto | 90:cb3d968589d8 | 139 | (((RMP) & HAL_REMAPDMA_TIM16_DMA1_CH6) == HAL_REMAPDMA_TIM16_DMA1_CH6) || \ |
Kojto | 90:cb3d968589d8 | 140 | (((RMP) & HAL_REMAPDMA_TIM17_DMA1_CH7) == HAL_REMAPDMA_TIM17_DMA1_CH7) || \ |
Kojto | 90:cb3d968589d8 | 141 | (((RMP) & HAL_REMAPDMA_TIM6_DAC1_CH1_DMA1_CH3) == HAL_REMAPDMA_TIM6_DAC1_CH1_DMA1_CH3) || \ |
Kojto | 90:cb3d968589d8 | 142 | (((RMP) & HAL_REMAPDMA_TIM7_DAC1_CH2_DMA1_CH4) == HAL_REMAPDMA_TIM7_DAC1_CH2_DMA1_CH4) || \ |
Kojto | 90:cb3d968589d8 | 143 | (((RMP) & HAL_REMAPDMA_DAC2_CH1_DMA1_CH5) == HAL_REMAPDMA_DAC2_CH1_DMA1_CH5) || \ |
Kojto | 90:cb3d968589d8 | 144 | (((RMP) & HAL_REMAPDMA_TIM18_DAC2_CH1_DMA1_CH5) == HAL_REMAPDMA_TIM18_DAC2_CH1_DMA1_CH5) || \ |
Kojto | 90:cb3d968589d8 | 145 | (((RMP) & HAL_REMAPDMA_SPI1_RX_DMA1_CH2) == HAL_REMAPDMA_SPI1_RX_DMA1_CH2) || \ |
Kojto | 90:cb3d968589d8 | 146 | (((RMP) & HAL_REMAPDMA_SPI1_RX_DMA1_CH4) == HAL_REMAPDMA_SPI1_RX_DMA1_CH4) || \ |
Kojto | 90:cb3d968589d8 | 147 | (((RMP) & HAL_REMAPDMA_SPI1_RX_DMA1_CH6) == HAL_REMAPDMA_SPI1_RX_DMA1_CH6) || \ |
Kojto | 90:cb3d968589d8 | 148 | (((RMP) & HAL_REMAPDMA_SPI1_TX_DMA1_CH3) == HAL_REMAPDMA_SPI1_TX_DMA1_CH3) || \ |
Kojto | 90:cb3d968589d8 | 149 | (((RMP) & HAL_REMAPDMA_SPI1_TX_DMA1_CH5) == HAL_REMAPDMA_SPI1_TX_DMA1_CH5) || \ |
Kojto | 90:cb3d968589d8 | 150 | (((RMP) & HAL_REMAPDMA_SPI1_TX_DMA1_CH7) == HAL_REMAPDMA_SPI1_TX_DMA1_CH7) || \ |
Kojto | 90:cb3d968589d8 | 151 | (((RMP) & HAL_REMAPDMA_I2C1_RX_DMA1_CH7) == HAL_REMAPDMA_I2C1_RX_DMA1_CH7) || \ |
Kojto | 90:cb3d968589d8 | 152 | (((RMP) & HAL_REMAPDMA_I2C1_RX_DMA1_CH3) == HAL_REMAPDMA_I2C1_RX_DMA1_CH3) || \ |
Kojto | 90:cb3d968589d8 | 153 | (((RMP) & HAL_REMAPDMA_I2C1_RX_DMA1_CH5) == HAL_REMAPDMA_I2C1_RX_DMA1_CH5) || \ |
Kojto | 90:cb3d968589d8 | 154 | (((RMP) & HAL_REMAPDMA_I2C1_TX_DMA1_CH6) == HAL_REMAPDMA_I2C1_TX_DMA1_CH6) || \ |
Kojto | 90:cb3d968589d8 | 155 | (((RMP) & HAL_REMAPDMA_I2C1_TX_DMA1_CH2) == HAL_REMAPDMA_I2C1_TX_DMA1_CH2) || \ |
Kojto | 90:cb3d968589d8 | 156 | (((RMP) & HAL_REMAPDMA_I2C1_TX_DMA1_CH4) == HAL_REMAPDMA_I2C1_TX_DMA1_CH4) || \ |
Kojto | 90:cb3d968589d8 | 157 | (((RMP) & HAL_REMAPDMA_ADC2_DMA1_CH2) == HAL_REMAPDMA_ADC2_DMA1_CH2) || \ |
Kojto | 90:cb3d968589d8 | 158 | (((RMP) & HAL_REMAPDMA_ADC2_DMA1_CH4) == HAL_REMAPDMA_ADC2_DMA1_CH4)) |
Kojto | 90:cb3d968589d8 | 159 | #else |
Kojto | 90:cb3d968589d8 | 160 | #define IS_HAL_REMAPDMA(RMP) ((((RMP) & HAL_REMAPDMA_ADC24_DMA2_CH34) == HAL_REMAPDMA_ADC24_DMA2_CH34) || \ |
Kojto | 90:cb3d968589d8 | 161 | (((RMP) & HAL_REMAPDMA_TIM16_DMA1_CH6) == HAL_REMAPDMA_TIM16_DMA1_CH6) || \ |
Kojto | 90:cb3d968589d8 | 162 | (((RMP) & HAL_REMAPDMA_TIM17_DMA1_CH7) == HAL_REMAPDMA_TIM17_DMA1_CH7) || \ |
Kojto | 90:cb3d968589d8 | 163 | (((RMP) & HAL_REMAPDMA_TIM6_DAC1_CH1_DMA1_CH3) == HAL_REMAPDMA_TIM6_DAC1_CH1_DMA1_CH3) || \ |
Kojto | 90:cb3d968589d8 | 164 | (((RMP) & HAL_REMAPDMA_TIM7_DAC1_CH2_DMA1_CH4) == HAL_REMAPDMA_TIM7_DAC1_CH2_DMA1_CH4) || \ |
Kojto | 90:cb3d968589d8 | 165 | (((RMP) & HAL_REMAPDMA_DAC2_CH1_DMA1_CH5) == HAL_REMAPDMA_DAC2_CH1_DMA1_CH5) || \ |
Kojto | 90:cb3d968589d8 | 166 | (((RMP) & HAL_REMAPDMA_TIM18_DAC2_CH1_DMA1_CH5) == HAL_REMAPDMA_TIM18_DAC2_CH1_DMA1_CH5)) |
Kojto | 90:cb3d968589d8 | 167 | #endif /* SYSCFG_CFGR3_DMA_RMP && SYSCFG_CFGR1_DMA_RMP*/ |
Kojto | 90:cb3d968589d8 | 168 | /** |
Kojto | 90:cb3d968589d8 | 169 | * @} |
Kojto | 90:cb3d968589d8 | 170 | */ |
Kojto | 90:cb3d968589d8 | 171 | #endif /* SYSCFG_CFGR1_DMA_RMP */ |
Kojto | 90:cb3d968589d8 | 172 | |
Kojto | 90:cb3d968589d8 | 173 | /** @defgroup HAL_Trigger_Remapping Trigger Remapping |
Kojto | 90:cb3d968589d8 | 174 | * Elements values convention: 0xXXYYYYYY |
Kojto | 90:cb3d968589d8 | 175 | * - YYYYYY : Position in the register |
Kojto | 90:cb3d968589d8 | 176 | * - XX : Register index |
Kojto | 90:cb3d968589d8 | 177 | * - 00: CFGR1 register in SYSCFG |
Kojto | 90:cb3d968589d8 | 178 | * - 01: CFGR3 register in SYSCFG |
Kojto | 90:cb3d968589d8 | 179 | * @{ |
Kojto | 90:cb3d968589d8 | 180 | */ |
Kojto | 90:cb3d968589d8 | 181 | #define HAL_REMAPTRIGGER_DAC1_TRIG ((uint32_t)0x00000080) /*!< DAC trigger remap (when TSEL = 001 on STM32F303xB/C and STM32F358xx devices) |
Kojto | 90:cb3d968589d8 | 182 | 0: No remap (DAC trigger is TIM8_TRGO) |
Kojto | 90:cb3d968589d8 | 183 | 1: Remap (DAC trigger is TIM3_TRGO) */ |
Kojto | 90:cb3d968589d8 | 184 | #define HAL_REMAPTRIGGER_TIM1_ITR3 ((uint32_t)0x00000040) /*!< TIM1 ITR3 trigger remap |
Kojto | 90:cb3d968589d8 | 185 | 0: No remap |
Kojto | 90:cb3d968589d8 | 186 | 1: Remap (TIM1_TRG3 = TIM17_OC) */ |
Kojto | 90:cb3d968589d8 | 187 | #if defined(SYSCFG_CFGR3_TRIGGER_RMP) |
Kojto | 90:cb3d968589d8 | 188 | #if !defined(HAL_REMAP_CFGR3_MASK) |
Kojto | 90:cb3d968589d8 | 189 | #define HAL_REMAP_CFGR3_MASK ((uint32_t)0x01000000) |
Kojto | 90:cb3d968589d8 | 190 | #endif |
Kojto | 90:cb3d968589d8 | 191 | #define HAL_REMAPTRIGGER_DAC1_TRIG3 ((uint32_t)0x01010000) /*!< DAC1_CH1 / DAC1_CH2 Trigger remap |
Kojto | 90:cb3d968589d8 | 192 | 0: Remap (DAC trigger is TIM15_TRGO) |
Kojto | 90:cb3d968589d8 | 193 | 1: Remap (DAC trigger is HRTIM1_DAC1_TRIG1) */ |
Kojto | 90:cb3d968589d8 | 194 | #define HAL_REMAPTRIGGER_DAC1_TRIG5 ((uint32_t)0x01020000) /*!< DAC1_CH1 / DAC1_CH2 Trigger remap |
Kojto | 90:cb3d968589d8 | 195 | 0: No remap |
Kojto | 90:cb3d968589d8 | 196 | 1: Remap (DAC trigger is HRTIM1_DAC1_TRIG2) */ |
Kojto | 90:cb3d968589d8 | 197 | #define IS_HAL_REMAPTRIGGER(RMP) ((((RMP) & HAL_REMAPTRIGGER_DAC1) == HAL_REMAPTRIGGER_DAC1) || \ |
Kojto | 90:cb3d968589d8 | 198 | (((RMP) & HAL_REMAPTRIGGER_TIM1_ITR3) == HAL_REMAPTRIGGER_TIM1_ITR3) || \ |
Kojto | 90:cb3d968589d8 | 199 | (((RMP) & HAL_REMAPTRIGGER_DAC1_TRIG3) == HAL_REMAPTRIGGER_DAC1_TRIG3) || \ |
Kojto | 90:cb3d968589d8 | 200 | (((RMP) & HAL_REMAPTRIGGER_DAC1_TRIG5) == HAL_REMAPTRIGGER_DAC1_TRIG5)) |
Kojto | 90:cb3d968589d8 | 201 | #else |
Kojto | 90:cb3d968589d8 | 202 | #define IS_HAL_REMAPTRIGGER(RMP) ((((RMP) & HAL_REMAPTRIGGER_DAC1) == HAL_REMAPTRIGGER_DAC1) || \ |
Kojto | 90:cb3d968589d8 | 203 | (((RMP) & HAL_REMAPTRIGGER_TIM1_ITR3) == HAL_REMAPTRIGGER_TIM1_ITR3)) |
Kojto | 90:cb3d968589d8 | 204 | #endif /* SYSCFG_CFGR3_TRIGGER_RMP */ |
Kojto | 90:cb3d968589d8 | 205 | /** |
Kojto | 90:cb3d968589d8 | 206 | * @} |
Kojto | 90:cb3d968589d8 | 207 | */ |
Kojto | 90:cb3d968589d8 | 208 | |
Kojto | 90:cb3d968589d8 | 209 | #if defined (STM32F303xE) || defined (STM32F398xx) |
Kojto | 90:cb3d968589d8 | 210 | /** @defgroup HAL_ADC_Trigger_Remapping ADC Trigger Remapping |
Kojto | 90:cb3d968589d8 | 211 | * @{ |
Kojto | 90:cb3d968589d8 | 212 | */ |
Kojto | 90:cb3d968589d8 | 213 | #define HAL_REMAPADCTRIGGER_ADC12_EXT2 SYSCFG_CFGR4_ADC12_EXT2_RMP /*!< Input trigger of ADC12 regular channel EXT2 |
Kojto | 90:cb3d968589d8 | 214 | 0: No remap (TIM1_CC3) |
Kojto | 90:cb3d968589d8 | 215 | 1: Remap (TIM20_TRGO) */ |
Kojto | 90:cb3d968589d8 | 216 | #define HAL_REMAPADCTRIGGER_ADC12_EXT3 SYSCFG_CFGR4_ADC12_EXT3_RMP /*!< Input trigger of ADC12 regular channel EXT3 |
Kojto | 90:cb3d968589d8 | 217 | 0: No remap (TIM2_CC2) |
Kojto | 90:cb3d968589d8 | 218 | 1: Remap (TIM20_TRGO2) */ |
Kojto | 90:cb3d968589d8 | 219 | #define HAL_REMAPADCTRIGGER_ADC12_EXT5 SYSCFG_CFGR4_ADC12_EXT5_RMP /*!< Input trigger of ADC12 regular channel EXT5 |
Kojto | 90:cb3d968589d8 | 220 | 0: No remap (TIM4_CC4) |
Kojto | 90:cb3d968589d8 | 221 | 1: Remap (TIM20_CC1) */ |
Kojto | 90:cb3d968589d8 | 222 | #define HAL_REMAPADCTRIGGER_ADC12_EXT13 SYSCFG_CFGR4_ADC12_EXT13_RMP /*!< Input trigger of ADC12 regular channel EXT13 |
Kojto | 90:cb3d968589d8 | 223 | 0: No remap (TIM6_TRGO) |
Kojto | 90:cb3d968589d8 | 224 | 1: Remap (TIM20_CC2) */ |
Kojto | 90:cb3d968589d8 | 225 | #define HAL_REMAPADCTRIGGER_ADC12_EXT15 SYSCFG_CFGR4_ADC12_EXT15_RMP /*!< Input trigger of ADC12 regular channel EXT15 |
Kojto | 90:cb3d968589d8 | 226 | 0: No remap (TIM3_CC4) |
Kojto | 90:cb3d968589d8 | 227 | 1: Remap (TIM20_CC3) */ |
Kojto | 90:cb3d968589d8 | 228 | #define HAL_REMAPADCTRIGGER_ADC12_JEXT3 SYSCFG_CFGR4_ADC12_JEXT3_RMP /*!< Input trigger of ADC12 injected channel JEXT3 |
Kojto | 90:cb3d968589d8 | 229 | 0: No remap (TIM2_CC1) |
Kojto | 90:cb3d968589d8 | 230 | 1: Remap (TIM20_TRGO) */ |
Kojto | 90:cb3d968589d8 | 231 | #define HAL_REMAPADCTRIGGER_ADC12_JEXT6 SYSCFG_CFGR4_ADC12_JEXT6_RMP /*!< Input trigger of ADC12 injected channel JEXT6 |
Kojto | 90:cb3d968589d8 | 232 | 0: No remap (EXTI line 15) |
Kojto | 90:cb3d968589d8 | 233 | 1: Remap (TIM20_TRGO2) */ |
Kojto | 90:cb3d968589d8 | 234 | #define HAL_REMAPADCTRIGGER_ADC12_JEXT13 SYSCFG_CFGR4_ADC12_JEXT13_RMP /*!< Input trigger of ADC12 injected channel JEXT13 |
Kojto | 90:cb3d968589d8 | 235 | 0: No remap (TIM3_CC1) |
Kojto | 90:cb3d968589d8 | 236 | 1: Remap (TIM20_CC4) */ |
Kojto | 90:cb3d968589d8 | 237 | #define HAL_REMAPADCTRIGGER_ADC34_EXT5 SYSCFG_CFGR4_ADC34_EXT5_RMP /*!< Input trigger of ADC34 regular channel EXT5 |
Kojto | 90:cb3d968589d8 | 238 | 0: No remap (EXTI line 2) |
Kojto | 90:cb3d968589d8 | 239 | 1: Remap (TIM20_TRGO) */ |
Kojto | 90:cb3d968589d8 | 240 | #define HAL_REMAPADCTRIGGER_ADC34_EXT6 SYSCFG_CFGR4_ADC34_EXT6_RMP /*!< Input trigger of ADC34 regular channel EXT6 |
Kojto | 90:cb3d968589d8 | 241 | 0: No remap (TIM4_CC1) |
Kojto | 90:cb3d968589d8 | 242 | 1: Remap (TIM20_TRGO2) */ |
Kojto | 90:cb3d968589d8 | 243 | #define HAL_REMAPADCTRIGGER_ADC34_EXT15 SYSCFG_CFGR4_ADC34_EXT15_RMP /*!< Input trigger of ADC34 regular channel EXT15 |
Kojto | 90:cb3d968589d8 | 244 | 0: No remap (TIM2_CC1) |
Kojto | 90:cb3d968589d8 | 245 | 1: Remap (TIM20_CC1) */ |
Kojto | 90:cb3d968589d8 | 246 | #define HAL_REMAPADCTRIGGER_ADC34_JEXT5 SYSCFG_CFGR4_ADC34_JEXT5_RMP /*!< Input trigger of ADC34 injected channel JEXT5 |
Kojto | 90:cb3d968589d8 | 247 | 0: No remap (TIM4_CC3) |
Kojto | 90:cb3d968589d8 | 248 | 1: Remap (TIM20_TRGO) */ |
Kojto | 90:cb3d968589d8 | 249 | #define HAL_REMAPADCTRIGGER_ADC34_JEXT11 SYSCFG_CFGR4_ADC34_JEXT11_RMP /*!< Input trigger of ADC34 injected channel JEXT11 |
Kojto | 90:cb3d968589d8 | 250 | 0: No remap (TIM1_CC3) |
Kojto | 90:cb3d968589d8 | 251 | 1: Remap (TIM20_TRGO2) */ |
Kojto | 90:cb3d968589d8 | 252 | #define HAL_REMAPADCTRIGGER_ADC34_JEXT14 SYSCFG_CFGR4_ADC34_JEXT14_RMP /*!< Input trigger of ADC34 injected channel JEXT14 |
Kojto | 90:cb3d968589d8 | 253 | 0: No remap (TIM7_TRGO) |
Kojto | 90:cb3d968589d8 | 254 | 1: Remap (TIM20_CC2) */ |
Kojto | 90:cb3d968589d8 | 255 | |
Kojto | 90:cb3d968589d8 | 256 | #define IS_HAL_REMAPADCTRIGGER(RMP) ((((RMP) & HAL_REMAPADCTRIGGER_ADC12_EXT2) == HAL_REMAPADCTRIGGER_ADC12_EXT2) || \ |
Kojto | 90:cb3d968589d8 | 257 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_EXT3) == HAL_REMAPADCTRIGGER_ADC12_EXT3) || \ |
Kojto | 90:cb3d968589d8 | 258 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_EXT5) == HAL_REMAPADCTRIGGER_ADC12_EXT5) || \ |
Kojto | 90:cb3d968589d8 | 259 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_EXT13) == HAL_REMAPADCTRIGGER_ADC12_EXT13) || \ |
Kojto | 90:cb3d968589d8 | 260 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_EXT15) == HAL_REMAPADCTRIGGER_ADC12_EXT15) || \ |
Kojto | 90:cb3d968589d8 | 261 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_JEXT3) == HAL_REMAPADCTRIGGER_ADC12_JEXT3) || \ |
Kojto | 90:cb3d968589d8 | 262 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_JEXT6) == HAL_REMAPADCTRIGGER_ADC12_JEXT6) || \ |
Kojto | 90:cb3d968589d8 | 263 | (((RMP) & HAL_REMAPADCTRIGGER_ADC12_JEXT13) == HAL_REMAPADCTRIGGER_ADC12_JEXT13) || \ |
Kojto | 90:cb3d968589d8 | 264 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_EXT5) == HAL_REMAPADCTRIGGER_ADC34_EXT5) || \ |
Kojto | 90:cb3d968589d8 | 265 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_EXT6) == HAL_REMAPADCTRIGGER_ADC34_EXT6) || \ |
Kojto | 90:cb3d968589d8 | 266 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_EXT15) == HAL_REMAPADCTRIGGER_ADC34_EXT15) || \ |
Kojto | 90:cb3d968589d8 | 267 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_JEXT5) == HAL_REMAPADCTRIGGER_ADC34_JEXT5) || \ |
Kojto | 90:cb3d968589d8 | 268 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_JEXT11) == HAL_REMAPADCTRIGGER_ADC34_JEXT11) || \ |
Kojto | 90:cb3d968589d8 | 269 | (((RMP) & HAL_REMAPADCTRIGGER_ADC34_JEXT14) == HAL_REMAPADCTRIGGER_ADC34_JEXT14)) |
Kojto | 90:cb3d968589d8 | 270 | /** |
Kojto | 90:cb3d968589d8 | 271 | * @} |
Kojto | 90:cb3d968589d8 | 272 | */ |
Kojto | 90:cb3d968589d8 | 273 | #endif /* STM32F303xE || STM32F398xx */ |
Kojto | 90:cb3d968589d8 | 274 | |
Kojto | 90:cb3d968589d8 | 275 | /** @defgroup HAL_FastModePlus_I2C I2C Fast Mode Plus |
Kojto | 90:cb3d968589d8 | 276 | * @{ |
Kojto | 90:cb3d968589d8 | 277 | */ |
Kojto | 90:cb3d968589d8 | 278 | #if defined(SYSCFG_CFGR1_I2C1_FMP) |
Kojto | 90:cb3d968589d8 | 279 | #define HAL_SYSCFG_FASTMODEPLUS_I2C1 ((uint32_t)SYSCFG_CFGR1_I2C1_FMP) /*!< I2C1 fast mode Plus driving capability activation |
Kojto | 90:cb3d968589d8 | 280 | 0: FM+ mode is not enabled on I2C1 pins selected through AF selection bits |
Kojto | 90:cb3d968589d8 | 281 | 1: FM+ mode is enabled on I2C1 pins selected through AF selection bits */ |
Kojto | 90:cb3d968589d8 | 282 | #endif /* SYSCFG_CFGR1_I2C1_FMP */ |
Kojto | 90:cb3d968589d8 | 283 | |
Kojto | 90:cb3d968589d8 | 284 | #if defined(SYSCFG_CFGR1_I2C2_FMP) |
Kojto | 90:cb3d968589d8 | 285 | #define HAL_SYSCFG_FASTMODEPLUS_I2C2 ((uint32_t)SYSCFG_CFGR1_I2C2_FMP) /*!< I2C2 fast mode Plus driving capability activation |
Kojto | 90:cb3d968589d8 | 286 | 0: FM+ mode is not enabled on I2C2 pins selected through AF selection bits |
Kojto | 90:cb3d968589d8 | 287 | 1: FM+ mode is enabled on I2C2 pins selected through AF selection bits */ |
Kojto | 90:cb3d968589d8 | 288 | #endif /* SYSCFG_CFGR1_I2C2_FMP */ |
Kojto | 90:cb3d968589d8 | 289 | |
Kojto | 90:cb3d968589d8 | 290 | #if defined(SYSCFG_CFGR1_I2C3_FMP) |
Kojto | 90:cb3d968589d8 | 291 | #define HAL_SYSCFG_FASTMODEPLUS_I2C3 ((uint32_t)SYSCFG_CFGR1_I2C3_FMP) /*!< I2C3 fast mode Plus driving capability activation |
Kojto | 90:cb3d968589d8 | 292 | 0: FM+ mode is not enabled on I2C3 pins selected through AF selection bits |
Kojto | 90:cb3d968589d8 | 293 | 1: FM+ mode is enabled on I2C3 pins selected through AF selection bits */ |
Kojto | 90:cb3d968589d8 | 294 | #endif /* SYSCFG_CFGR1_I2C3_FMP */ |
Kojto | 90:cb3d968589d8 | 295 | |
Kojto | 90:cb3d968589d8 | 296 | #if defined(SYSCFG_CFGR1_I2C_PB6_FMP) |
Kojto | 90:cb3d968589d8 | 297 | #define HAL_SYSCFG_FASTMODEPLUS_I2C_PB6 ((uint32_t)SYSCFG_CFGR1_I2C_PB6_FMP) /*!< Fast Mode Plus (FM+) driving capability activation on the pad |
Kojto | 90:cb3d968589d8 | 298 | 0: PB6 pin operates in standard mode |
Kojto | 90:cb3d968589d8 | 299 | 1: I2C FM+ mode enabled on PB6 pin, and the Speed control is bypassed */ |
Kojto | 90:cb3d968589d8 | 300 | #endif /* SYSCFG_CFGR1_I2C_PB6_FMP */ |
Kojto | 90:cb3d968589d8 | 301 | |
Kojto | 90:cb3d968589d8 | 302 | #if defined(SYSCFG_CFGR1_I2C_PB7_FMP) |
Kojto | 90:cb3d968589d8 | 303 | #define HAL_SYSCFG_FASTMODEPLUS_I2C_PB7 ((uint32_t)SYSCFG_CFGR1_I2C_PB7_FMP) /*!< Fast Mode Plus (FM+) driving capability activation on the pad |
Kojto | 90:cb3d968589d8 | 304 | 0: PB7 pin operates in standard mode |
Kojto | 90:cb3d968589d8 | 305 | 1: I2C FM+ mode enabled on PB7 pin, and the Speed control is bypassed */ |
Kojto | 90:cb3d968589d8 | 306 | #endif /* SYSCFG_CFGR1_I2C_PB7_FMP */ |
Kojto | 90:cb3d968589d8 | 307 | |
Kojto | 90:cb3d968589d8 | 308 | #if defined(SYSCFG_CFGR1_I2C_PB8_FMP) |
Kojto | 90:cb3d968589d8 | 309 | #define HAL_SYSCFG_FASTMODEPLUS_I2C_PB8 ((uint32_t)SYSCFG_CFGR1_I2C_PB8_FMP) /*!< Fast Mode Plus (FM+) driving capability activation on the pad |
Kojto | 90:cb3d968589d8 | 310 | 0: PB8 pin operates in standard mode |
Kojto | 90:cb3d968589d8 | 311 | 1: I2C FM+ mode enabled on PB8 pin, and the Speed control is bypassed */ |
Kojto | 90:cb3d968589d8 | 312 | #endif /* SYSCFG_CFGR1_I2C_PB8_FMP */ |
Kojto | 90:cb3d968589d8 | 313 | |
Kojto | 90:cb3d968589d8 | 314 | #if defined(SYSCFG_CFGR1_I2C_PB9_FMP) |
Kojto | 90:cb3d968589d8 | 315 | #define HAL_SYSCFG_FASTMODEPLUS_I2C_PB9 ((uint32_t)SYSCFG_CFGR1_I2C_PB9_FMP) /*!< Fast Mode Plus (FM+) driving capability activation on the pad |
Kojto | 90:cb3d968589d8 | 316 | 0: PB9 pin operates in standard mode |
Kojto | 90:cb3d968589d8 | 317 | 1: I2C FM+ mode enabled on PB9 pin, and the Speed control is bypassed */ |
Kojto | 90:cb3d968589d8 | 318 | #endif /* SYSCFG_CFGR1_I2C_PB9_FMP */ |
Kojto | 90:cb3d968589d8 | 319 | |
Kojto | 90:cb3d968589d8 | 320 | #if defined(SYSCFG_CFGR1_I2C1_FMP) && defined(SYSCFG_CFGR1_I2C2_FMP) && defined(SYSCFG_CFGR1_I2C3_FMP) |
Kojto | 90:cb3d968589d8 | 321 | #define IS_HAL_SYSCFG_FASTMODEPLUS_CONFIG(CONFIG) ((((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C1) == HAL_SYSCFG_FASTMODEPLUS_I2C1) || \ |
Kojto | 90:cb3d968589d8 | 322 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C2) == HAL_SYSCFG_FASTMODEPLUS_I2C2) || \ |
Kojto | 90:cb3d968589d8 | 323 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C3) == HAL_SYSCFG_FASTMODEPLUS_I2C3) || \ |
Kojto | 90:cb3d968589d8 | 324 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) || \ |
Kojto | 90:cb3d968589d8 | 325 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) || \ |
Kojto | 90:cb3d968589d8 | 326 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) || \ |
Kojto | 90:cb3d968589d8 | 327 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB9) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB9)) |
Kojto | 90:cb3d968589d8 | 328 | #elif defined(SYSCFG_CFGR1_I2C1_FMP) && defined(SYSCFG_CFGR1_I2C2_FMP) |
Kojto | 90:cb3d968589d8 | 329 | #define IS_HAL_SYSCFG_FASTMODEPLUS_CONFIG(CONFIG) ((((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C1) == HAL_SYSCFG_FASTMODEPLUS_I2C1) || \ |
Kojto | 90:cb3d968589d8 | 330 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C2) == HAL_SYSCFG_FASTMODEPLUS_I2C2) || \ |
Kojto | 90:cb3d968589d8 | 331 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) || \ |
Kojto | 90:cb3d968589d8 | 332 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) || \ |
Kojto | 90:cb3d968589d8 | 333 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) || \ |
Kojto | 90:cb3d968589d8 | 334 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB9) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB9)) |
Kojto | 90:cb3d968589d8 | 335 | #elif defined(SYSCFG_CFGR1_I2C1_FMP) |
Kojto | 90:cb3d968589d8 | 336 | #define IS_HAL_SYSCFG_FASTMODEPLUS_CONFIG(CONFIG) ((((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C1) == HAL_SYSCFG_FASTMODEPLUS_I2C1) || \ |
Kojto | 90:cb3d968589d8 | 337 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB6) || \ |
Kojto | 90:cb3d968589d8 | 338 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB7) || \ |
Kojto | 90:cb3d968589d8 | 339 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB8) || \ |
Kojto | 90:cb3d968589d8 | 340 | (((CONFIG) & HAL_SYSCFG_FASTMODEPLUS_I2C_PB9) == HAL_SYSCFG_FASTMODEPLUS_I2C_PB9)) |
Kojto | 90:cb3d968589d8 | 341 | #endif /* SYSCFG_CFGR1_I2C1_FMP && SYSCFG_CFGR1_I2C2_FMP && SYSCFG_CFGR3_I2C1_FMP */ |
Kojto | 90:cb3d968589d8 | 342 | /** |
Kojto | 90:cb3d968589d8 | 343 | * @} |
Kojto | 90:cb3d968589d8 | 344 | */ |
Kojto | 90:cb3d968589d8 | 345 | |
Kojto | 90:cb3d968589d8 | 346 | #if defined(SYSCFG_RCR_PAGE0) |
Kojto | 90:cb3d968589d8 | 347 | /* CCM-SRAM defined */ |
Kojto | 90:cb3d968589d8 | 348 | /** @defgroup HAL_Page_Write_Protection CCM RAM page write protection |
Kojto | 90:cb3d968589d8 | 349 | * @{ |
Kojto | 90:cb3d968589d8 | 350 | */ |
Kojto | 90:cb3d968589d8 | 351 | #define HAL_SYSCFG_WP_PAGE0 (SYSCFG_RCR_PAGE0) /*!< ICODE SRAM Write protection page 0 */ |
Kojto | 90:cb3d968589d8 | 352 | #define HAL_SYSCFG_WP_PAGE1 (SYSCFG_RCR_PAGE1) /*!< ICODE SRAM Write protection page 1 */ |
Kojto | 90:cb3d968589d8 | 353 | #define HAL_SYSCFG_WP_PAGE2 (SYSCFG_RCR_PAGE2) /*!< ICODE SRAM Write protection page 2 */ |
Kojto | 90:cb3d968589d8 | 354 | #define HAL_SYSCFG_WP_PAGE3 (SYSCFG_RCR_PAGE3) /*!< ICODE SRAM Write protection page 3 */ |
Kojto | 90:cb3d968589d8 | 355 | #if defined(SYSCFG_RCR_PAGE4) |
Kojto | 90:cb3d968589d8 | 356 | /* More than 4KB CCM-SRAM defined */ |
Kojto | 90:cb3d968589d8 | 357 | #define HAL_SYSCFG_WP_PAGE4 (SYSCFG_RCR_PAGE4) /*!< ICODE SRAM Write protection page 4 */ |
Kojto | 90:cb3d968589d8 | 358 | #define HAL_SYSCFG_WP_PAGE5 (SYSCFG_RCR_PAGE5) /*!< ICODE SRAM Write protection page 5 */ |
Kojto | 90:cb3d968589d8 | 359 | #define HAL_SYSCFG_WP_PAGE6 (SYSCFG_RCR_PAGE6) /*!< ICODE SRAM Write protection page 6 */ |
Kojto | 90:cb3d968589d8 | 360 | #define HAL_SYSCFG_WP_PAGE7 (SYSCFG_RCR_PAGE7) /*!< ICODE SRAM Write protection page 7 */ |
Kojto | 90:cb3d968589d8 | 361 | #endif /* SYSCFG_RCR_PAGE4 */ |
Kojto | 90:cb3d968589d8 | 362 | #if defined(SYSCFG_RCR_PAGE8) |
Kojto | 90:cb3d968589d8 | 363 | #define HAL_SYSCFG_WP_PAGE8 (SYSCFG_RCR_PAGE8) /*!< ICODE SRAM Write protection page 8 */ |
Kojto | 90:cb3d968589d8 | 364 | #define HAL_SYSCFG_WP_PAGE9 (SYSCFG_RCR_PAGE9) /*!< ICODE SRAM Write protection page 9 */ |
Kojto | 90:cb3d968589d8 | 365 | #define HAL_SYSCFG_WP_PAGE10 (SYSCFG_RCR_PAGE10) /*!< ICODE SRAM Write protection page 10 */ |
Kojto | 90:cb3d968589d8 | 366 | #define HAL_SYSCFG_WP_PAGE11 (SYSCFG_RCR_PAGE11) /*!< ICODE SRAM Write protection page 11 */ |
Kojto | 90:cb3d968589d8 | 367 | #define HAL_SYSCFG_WP_PAGE12 (SYSCFG_RCR_PAGE12) /*!< ICODE SRAM Write protection page 12 */ |
Kojto | 90:cb3d968589d8 | 368 | #define HAL_SYSCFG_WP_PAGE13 (SYSCFG_RCR_PAGE13) /*!< ICODE SRAM Write protection page 13 */ |
Kojto | 90:cb3d968589d8 | 369 | #define HAL_SYSCFG_WP_PAGE14 (SYSCFG_RCR_PAGE14) /*!< ICODE SRAM Write protection page 14 */ |
Kojto | 90:cb3d968589d8 | 370 | #define HAL_SYSCFG_WP_PAGE15 (SYSCFG_RCR_PAGE15) /*!< ICODE SRAM Write protection page 15 */ |
Kojto | 90:cb3d968589d8 | 371 | #endif /* SYSCFG_RCR_PAGE8 */ |
Kojto | 90:cb3d968589d8 | 372 | |
Kojto | 90:cb3d968589d8 | 373 | #if defined(SYSCFG_RCR_PAGE8) |
Kojto | 90:cb3d968589d8 | 374 | #define IS_HAL_SYSCFG_WP_PAGE(__PAGE__) (((__PAGE__) > 0) && ((__PAGE__) <= (uint32_t)0xFFFF)) |
Kojto | 90:cb3d968589d8 | 375 | #elif defined(SYSCFG_RCR_PAGE4) |
Kojto | 90:cb3d968589d8 | 376 | #define IS_HAL_SYSCFG_WP_PAGE(__PAGE__) (((__PAGE__) > 0) && ((__PAGE__) <= (uint32_t)0x00FF)) |
Kojto | 90:cb3d968589d8 | 377 | #else |
Kojto | 90:cb3d968589d8 | 378 | #define IS_HAL_SYSCFG_WP_PAGE(__PAGE__) (((__PAGE__) > 0) && ((__PAGE__) <= (uint32_t)0x000F)) |
Kojto | 90:cb3d968589d8 | 379 | #endif /* SYSCFG_RCR_PAGE8 */ |
Kojto | 90:cb3d968589d8 | 380 | /** |
Kojto | 90:cb3d968589d8 | 381 | * @} |
Kojto | 90:cb3d968589d8 | 382 | */ |
Kojto | 90:cb3d968589d8 | 383 | #endif /* SYSCFG_RCR_PAGE0 */ |
Kojto | 90:cb3d968589d8 | 384 | |
Kojto | 90:cb3d968589d8 | 385 | /** @defgroup HAL_SYSCFG_Interrupts SYSCFG Interrupts |
Kojto | 90:cb3d968589d8 | 386 | * @{ |
Kojto | 90:cb3d968589d8 | 387 | */ |
Kojto | 90:cb3d968589d8 | 388 | #define HAL_SYSCFG_IT_FPU_IOC (SYSCFG_CFGR1_FPU_IE_0) /*!< Floating Point Unit Invalid operation Interrupt */ |
Kojto | 90:cb3d968589d8 | 389 | #define HAL_SYSCFG_IT_FPU_DZC (SYSCFG_CFGR1_FPU_IE_1) /*!< Floating Point Unit Divide-by-zero Interrupt */ |
Kojto | 90:cb3d968589d8 | 390 | #define HAL_SYSCFG_IT_FPU_UFC (SYSCFG_CFGR1_FPU_IE_2) /*!< Floating Point Unit Underflow Interrupt */ |
Kojto | 90:cb3d968589d8 | 391 | #define HAL_SYSCFG_IT_FPU_OFC (SYSCFG_CFGR1_FPU_IE_3) /*!< Floating Point Unit Overflow Interrupt */ |
Kojto | 90:cb3d968589d8 | 392 | #define HAL_SYSCFG_IT_FPU_IDC (SYSCFG_CFGR1_FPU_IE_4) /*!< Floating Point Unit Input denormal Interrupt */ |
Kojto | 90:cb3d968589d8 | 393 | #define HAL_SYSCFG_IT_FPU_IXC (SYSCFG_CFGR1_FPU_IE_5) /*!< Floating Point Unit Inexact Interrupt */ |
Kojto | 90:cb3d968589d8 | 394 | |
Kojto | 90:cb3d968589d8 | 395 | #define IS_HAL_SYSCFG_INTERRUPT(__INTERRUPT__) ((((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_0) == SYSCFG_CFGR1_FPU_IE_0) || \ |
Kojto | 90:cb3d968589d8 | 396 | (((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_1) == SYSCFG_CFGR1_FPU_IE_1) || \ |
Kojto | 90:cb3d968589d8 | 397 | (((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_2) == SYSCFG_CFGR1_FPU_IE_2) || \ |
Kojto | 90:cb3d968589d8 | 398 | (((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_3) == SYSCFG_CFGR1_FPU_IE_3) || \ |
Kojto | 90:cb3d968589d8 | 399 | (((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_4) == SYSCFG_CFGR1_FPU_IE_4) || \ |
Kojto | 90:cb3d968589d8 | 400 | (((__INTERRUPT__) & SYSCFG_CFGR1_FPU_IE_5) == SYSCFG_CFGR1_FPU_IE_5)) |
Kojto | 90:cb3d968589d8 | 401 | |
Kojto | 90:cb3d968589d8 | 402 | /** |
Kojto | 90:cb3d968589d8 | 403 | * @} |
Kojto | 90:cb3d968589d8 | 404 | */ |
Kojto | 90:cb3d968589d8 | 405 | |
Kojto | 90:cb3d968589d8 | 406 | /** |
Kojto | 90:cb3d968589d8 | 407 | * @} |
Kojto | 90:cb3d968589d8 | 408 | */ |
Kojto | 90:cb3d968589d8 | 409 | |
Kojto | 90:cb3d968589d8 | 410 | /* Exported macro ------------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 411 | /** @defgroup HAL_Exported_Macros HAL Exported Macros |
Kojto | 90:cb3d968589d8 | 412 | * @{ |
Kojto | 90:cb3d968589d8 | 413 | */ |
Kojto | 90:cb3d968589d8 | 414 | |
Kojto | 90:cb3d968589d8 | 415 | /** @defgroup Debug_MCU_APB1_Freeze Freeze/Unfreeze APB1 Peripherals in Debug mode |
Kojto | 90:cb3d968589d8 | 416 | * @{ |
Kojto | 90:cb3d968589d8 | 417 | */ |
Kojto | 90:cb3d968589d8 | 418 | #if defined(DBGMCU_APB1_FZ_DBG_TIM2_STOP) |
Kojto | 90:cb3d968589d8 | 419 | #define __HAL_FREEZE_TIM2_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM2_STOP)) |
Kojto | 90:cb3d968589d8 | 420 | #define __HAL_UNFREEZE_TIM2_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM2_STOP)) |
Kojto | 90:cb3d968589d8 | 421 | #endif /* DBGMCU_APB1_FZ_DBG_TIM2_STOP */ |
Kojto | 90:cb3d968589d8 | 422 | |
Kojto | 90:cb3d968589d8 | 423 | #if defined(DBGMCU_APB1_FZ_DBG_TIM3_STOP) |
Kojto | 90:cb3d968589d8 | 424 | #define __HAL_FREEZE_TIM3_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM3_STOP)) |
Kojto | 90:cb3d968589d8 | 425 | #define __HAL_UNFREEZE_TIM3_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM3_STOP)) |
Kojto | 90:cb3d968589d8 | 426 | #endif /* DBGMCU_APB1_FZ_DBG_TIM3_STOP */ |
Kojto | 90:cb3d968589d8 | 427 | |
Kojto | 90:cb3d968589d8 | 428 | #if defined(DBGMCU_APB1_FZ_DBG_TIM4_STOP) |
Kojto | 90:cb3d968589d8 | 429 | #define __HAL_FREEZE_TIM4_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM4_STOP)) |
Kojto | 90:cb3d968589d8 | 430 | #define __HAL_UNFREEZE_TIM4_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM4_STOP)) |
Kojto | 90:cb3d968589d8 | 431 | #endif /* DBGMCU_APB1_FZ_DBG_TIM4_STOP */ |
Kojto | 90:cb3d968589d8 | 432 | |
Kojto | 90:cb3d968589d8 | 433 | #if defined(DBGMCU_APB1_FZ_DBG_TIM5_STOP) |
Kojto | 90:cb3d968589d8 | 434 | #define __HAL_FREEZE_TIM5_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM5_STOP)) |
Kojto | 90:cb3d968589d8 | 435 | #define __HAL_UNFREEZE_TIM5_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM5_STOP)) |
Kojto | 90:cb3d968589d8 | 436 | #endif /* DBGMCU_APB1_FZ_DBG_TIM5_STOP */ |
Kojto | 90:cb3d968589d8 | 437 | |
Kojto | 90:cb3d968589d8 | 438 | #if defined(DBGMCU_APB1_FZ_DBG_TIM6_STOP) |
Kojto | 90:cb3d968589d8 | 439 | #define __HAL_FREEZE_TIM6_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM6_STOP)) |
Kojto | 90:cb3d968589d8 | 440 | #define __HAL_UNFREEZE_TIM6_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM6_STOP)) |
Kojto | 90:cb3d968589d8 | 441 | #endif /* DBGMCU_APB1_FZ_DBG_TIM6_STOP */ |
Kojto | 90:cb3d968589d8 | 442 | |
Kojto | 90:cb3d968589d8 | 443 | #if defined(DBGMCU_APB1_FZ_DBG_TIM7_STOP) |
Kojto | 90:cb3d968589d8 | 444 | #define __HAL_FREEZE_TIM7_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM7_STOP)) |
Kojto | 90:cb3d968589d8 | 445 | #define __HAL_UNFREEZE_TIM7_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM7_STOP)) |
Kojto | 90:cb3d968589d8 | 446 | #endif /* DBGMCU_APB1_FZ_DBG_TIM7_STOP */ |
Kojto | 90:cb3d968589d8 | 447 | |
Kojto | 90:cb3d968589d8 | 448 | #if defined(DBGMCU_APB1_FZ_DBG_TIM12_STOP) |
Kojto | 90:cb3d968589d8 | 449 | #define __HAL_FREEZE_TIM12_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM12_STOP)) |
Kojto | 90:cb3d968589d8 | 450 | #define __HAL_UNFREEZE_TIM12_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM12_STOP)) |
Kojto | 90:cb3d968589d8 | 451 | #endif /* DBGMCU_APB1_FZ_DBG_TIM12_STOP */ |
Kojto | 90:cb3d968589d8 | 452 | |
Kojto | 90:cb3d968589d8 | 453 | #if defined(DBGMCU_APB1_FZ_DBG_TIM13_STOP) |
Kojto | 90:cb3d968589d8 | 454 | #define __HAL_FREEZE_TIM13_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM13_STOP)) |
Kojto | 90:cb3d968589d8 | 455 | #define __HAL_UNFREEZE_TIM13_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM13_STOP)) |
Kojto | 90:cb3d968589d8 | 456 | #endif /* DBGMCU_APB1_FZ_DBG_TIM13_STOP */ |
Kojto | 90:cb3d968589d8 | 457 | |
Kojto | 90:cb3d968589d8 | 458 | #if defined(DBGMCU_APB1_FZ_DBG_TIM14_STOP) |
Kojto | 90:cb3d968589d8 | 459 | #define __HAL_FREEZE_TIM14_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM14_STOP)) |
Kojto | 90:cb3d968589d8 | 460 | #define __HAL_UNFREEZE_TIM14_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM14_STOP)) |
Kojto | 90:cb3d968589d8 | 461 | #endif /* DBGMCU_APB1_FZ_DBG_TIM14_STOP */ |
Kojto | 90:cb3d968589d8 | 462 | |
Kojto | 90:cb3d968589d8 | 463 | #if defined(DBGMCU_APB1_FZ_DBG_TIM18_STOP) |
Kojto | 90:cb3d968589d8 | 464 | #define __HAL_FREEZE_TIM18_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_TIM18_STOP)) |
Kojto | 90:cb3d968589d8 | 465 | #define __HAL_UNFREEZE_TIM18_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_TIM18_STOP)) |
Kojto | 90:cb3d968589d8 | 466 | #endif /* DBGMCU_APB1_FZ_DBG_TIM14_STOP */ |
Kojto | 90:cb3d968589d8 | 467 | |
Kojto | 90:cb3d968589d8 | 468 | #if defined(DBGMCU_APB1_FZ_DBG_RTC_STOP) |
Kojto | 90:cb3d968589d8 | 469 | #define __HAL_FREEZE_RTC_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_RTC_STOP)) |
Kojto | 90:cb3d968589d8 | 470 | #define __HAL_UNFREEZE_RTC_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_RTC_STOP)) |
Kojto | 90:cb3d968589d8 | 471 | #endif /* DBGMCU_APB1_FZ_DBG_RTC_STOP */ |
Kojto | 90:cb3d968589d8 | 472 | |
Kojto | 90:cb3d968589d8 | 473 | #if defined(DBGMCU_APB1_FZ_DBG_WWDG_STOP) |
Kojto | 90:cb3d968589d8 | 474 | #define __HAL_FREEZE_WWDG_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_WWDG_STOP)) |
Kojto | 90:cb3d968589d8 | 475 | #define __HAL_UNFREEZE_WWDG_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_WWDG_STOP)) |
Kojto | 90:cb3d968589d8 | 476 | #endif /* DBGMCU_APB1_FZ_DBG_WWDG_STOP */ |
Kojto | 90:cb3d968589d8 | 477 | |
Kojto | 90:cb3d968589d8 | 478 | #if defined(DBGMCU_APB1_FZ_DBG_IWDG_STOP) |
Kojto | 90:cb3d968589d8 | 479 | #define __HAL_FREEZE_IWDG_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_IWDG_STOP)) |
Kojto | 90:cb3d968589d8 | 480 | #define __HAL_UNFREEZE_IWDG_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_IWDG_STOP)) |
Kojto | 90:cb3d968589d8 | 481 | #endif /* DBGMCU_APB1_FZ_DBG_IWDG_STOP */ |
Kojto | 90:cb3d968589d8 | 482 | |
Kojto | 90:cb3d968589d8 | 483 | #if defined(DBGMCU_APB1_FZ_DBG_I2C1_SMBUS_TIMEOUT) |
Kojto | 90:cb3d968589d8 | 484 | #define __HAL_FREEZE_I2C1_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_I2C1_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 485 | #define __HAL_UNFREEZE_I2C1_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_I2C1_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 486 | #endif /* DBGMCU_APB1_FZ_DBG_I2C1_SMBUS_TIMEOUT */ |
Kojto | 90:cb3d968589d8 | 487 | |
Kojto | 90:cb3d968589d8 | 488 | #if defined(DBGMCU_APB1_FZ_DBG_I2C2_SMBUS_TIMEOUT) |
Kojto | 90:cb3d968589d8 | 489 | #define __HAL_FREEZE_I2C2_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_I2C2_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 490 | #define __HAL_UNFREEZE_I2C2_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_I2C2_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 491 | #endif /* DBGMCU_APB1_FZ_DBG_I2C2_SMBUS_TIMEOUT */ |
Kojto | 90:cb3d968589d8 | 492 | |
Kojto | 90:cb3d968589d8 | 493 | #if defined(DBGMCU_APB1_FZ_DBG_I2C3_SMBUS_TIMEOUT) |
Kojto | 90:cb3d968589d8 | 494 | #define __HAL_FREEZE_I2C3_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_I2C3_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 495 | #define __HAL_UNFREEZE_I2C3_TIMEOUT_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_I2C3_SMBUS_TIMEOUT)) |
Kojto | 90:cb3d968589d8 | 496 | #endif /* DBGMCU_APB1_FZ_DBG_I2C3_SMBUS_TIMEOUT */ |
Kojto | 90:cb3d968589d8 | 497 | |
Kojto | 90:cb3d968589d8 | 498 | #if defined(DBGMCU_APB1_FZ_DBG_CAN_STOP) |
Kojto | 90:cb3d968589d8 | 499 | #define __HAL_FREEZE_CAN_DBGMCU() (DBGMCU->APB1FZ |= (DBGMCU_APB1_FZ_DBG_CAN_STOP)) |
Kojto | 90:cb3d968589d8 | 500 | #define __HAL_UNFREEZE_CAN_DBGMCU() (DBGMCU->APB1FZ &= ~(DBGMCU_APB1_FZ_DBG_CAN_STOP)) |
Kojto | 90:cb3d968589d8 | 501 | #endif /* DBGMCU_APB1_FZ_DBG_CAN_STOP */ |
Kojto | 90:cb3d968589d8 | 502 | /** |
Kojto | 90:cb3d968589d8 | 503 | * @} |
Kojto | 90:cb3d968589d8 | 504 | */ |
Kojto | 90:cb3d968589d8 | 505 | |
Kojto | 90:cb3d968589d8 | 506 | /** @defgroup Debug_MCU_APB2_Freeze Freeze/Unfreeze APB2 Peripherals in Debug mode |
Kojto | 90:cb3d968589d8 | 507 | * @{ |
Kojto | 90:cb3d968589d8 | 508 | */ |
Kojto | 90:cb3d968589d8 | 509 | #if defined(DBGMCU_APB2_FZ_DBG_TIM1_STOP) |
Kojto | 90:cb3d968589d8 | 510 | #define __HAL_FREEZE_TIM1_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM1_STOP)) |
Kojto | 90:cb3d968589d8 | 511 | #define __HAL_UNFREEZE_TIM1_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM1_STOP)) |
Kojto | 90:cb3d968589d8 | 512 | #endif /* DBGMCU_APB2_FZ_DBG_TIM1_STOP */ |
Kojto | 90:cb3d968589d8 | 513 | |
Kojto | 90:cb3d968589d8 | 514 | #if defined(DBGMCU_APB2_FZ_DBG_TIM8_STOP) |
Kojto | 90:cb3d968589d8 | 515 | #define __HAL_FREEZE_TIM8_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM8_STOP)) |
Kojto | 90:cb3d968589d8 | 516 | #define __HAL_UNFREEZE_TIM8_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM8_STOP)) |
Kojto | 90:cb3d968589d8 | 517 | #endif /* DBGMCU_APB2_FZ_DBG_TIM8_STOP */ |
Kojto | 90:cb3d968589d8 | 518 | |
Kojto | 90:cb3d968589d8 | 519 | #if defined(DBGMCU_APB2_FZ_DBG_TIM15_STOP) |
Kojto | 90:cb3d968589d8 | 520 | #define __HAL_FREEZE_TIM15_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM15_STOP)) |
Kojto | 90:cb3d968589d8 | 521 | #define __HAL_UNFREEZE_TIM15_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM15_STOP)) |
Kojto | 90:cb3d968589d8 | 522 | #endif /* DBGMCU_APB2_FZ_DBG_TIM15_STOP */ |
Kojto | 90:cb3d968589d8 | 523 | |
Kojto | 90:cb3d968589d8 | 524 | #if defined(DBGMCU_APB2_FZ_DBG_TIM16_STOP) |
Kojto | 90:cb3d968589d8 | 525 | #define __HAL_FREEZE_TIM16_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM16_STOP)) |
Kojto | 90:cb3d968589d8 | 526 | #define __HAL_UNFREEZE_TIM16_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM16_STOP)) |
Kojto | 90:cb3d968589d8 | 527 | #endif /* DBGMCU_APB2_FZ_DBG_TIM16_STOP */ |
Kojto | 90:cb3d968589d8 | 528 | |
Kojto | 90:cb3d968589d8 | 529 | #if defined(DBGMCU_APB2_FZ_DBG_TIM17_STOP) |
Kojto | 90:cb3d968589d8 | 530 | #define __HAL_FREEZE_TIM17_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM17_STOP)) |
Kojto | 90:cb3d968589d8 | 531 | #define __HAL_UNFREEZE_TIM17_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM17_STOP)) |
Kojto | 90:cb3d968589d8 | 532 | #endif /* DBGMCU_APB2_FZ_DBG_TIM17_STOP */ |
Kojto | 90:cb3d968589d8 | 533 | |
Kojto | 90:cb3d968589d8 | 534 | #if defined(DBGMCU_APB2_FZ_DBG_TIM19_STOP) |
Kojto | 90:cb3d968589d8 | 535 | #define __HAL_FREEZE_TIM19_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM19_STOP)) |
Kojto | 90:cb3d968589d8 | 536 | #define __HAL_UNFREEZE_TIM19_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM19_STOP)) |
Kojto | 90:cb3d968589d8 | 537 | #endif /* DBGMCU_APB2_FZ_DBG_TIM19_STOP */ |
Kojto | 90:cb3d968589d8 | 538 | |
Kojto | 90:cb3d968589d8 | 539 | #if defined(DBGMCU_APB2_FZ_DBG_TIM20_STOP) |
Kojto | 90:cb3d968589d8 | 540 | #define __HAL_FREEZE_TIM20_DBGMCU() (DBGMCU->APB2FZ |= (DBGMCU_APB2_FZ_DBG_TIM19_STOP)) |
Kojto | 90:cb3d968589d8 | 541 | #define __HAL_UNFREEZE_TIM20_DBGMCU() (DBGMCU->APB2FZ &= ~(DBGMCU_APB2_FZ_DBG_TIM19_STOP)) |
Kojto | 90:cb3d968589d8 | 542 | #endif /* DBGMCU_APB2_FZ_DBG_TIM20_STOP */ |
Kojto | 90:cb3d968589d8 | 543 | /** |
Kojto | 90:cb3d968589d8 | 544 | * @} |
Kojto | 90:cb3d968589d8 | 545 | */ |
Kojto | 90:cb3d968589d8 | 546 | |
Kojto | 90:cb3d968589d8 | 547 | /** @defgroup Memory_Mapping_Selection Memory Mapping Selection |
Kojto | 90:cb3d968589d8 | 548 | * @{ |
Kojto | 90:cb3d968589d8 | 549 | */ |
Kojto | 90:cb3d968589d8 | 550 | #if defined(SYSCFG_CFGR1_MEM_MODE) |
Kojto | 90:cb3d968589d8 | 551 | /** @brief Main Flash memory mapped at 0x00000000 |
Kojto | 90:cb3d968589d8 | 552 | */ |
Kojto | 90:cb3d968589d8 | 553 | #define __HAL_REMAPMEMORY_FLASH() (SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_MEM_MODE)) |
Kojto | 90:cb3d968589d8 | 554 | #endif /* SYSCFG_CFGR1_MEM_MODE */ |
Kojto | 90:cb3d968589d8 | 555 | |
Kojto | 90:cb3d968589d8 | 556 | #if defined(SYSCFG_CFGR1_MEM_MODE_0) |
Kojto | 90:cb3d968589d8 | 557 | /** @brief System Flash memory mapped at 0x00000000 |
Kojto | 90:cb3d968589d8 | 558 | */ |
Kojto | 90:cb3d968589d8 | 559 | #define __HAL_REMAPMEMORY_SYSTEMFLASH() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_MEM_MODE); \ |
Kojto | 90:cb3d968589d8 | 560 | SYSCFG->CFGR1 |= SYSCFG_CFGR1_MEM_MODE_0; \ |
Kojto | 90:cb3d968589d8 | 561 | }while(0) |
Kojto | 90:cb3d968589d8 | 562 | #endif /* SYSCFG_CFGR1_MEM_MODE_0 */ |
Kojto | 90:cb3d968589d8 | 563 | |
Kojto | 90:cb3d968589d8 | 564 | #if defined(SYSCFG_CFGR1_MEM_MODE_0) && defined(SYSCFG_CFGR1_MEM_MODE_1) |
Kojto | 90:cb3d968589d8 | 565 | /** @brief Embedded SRAM mapped at 0x00000000 |
Kojto | 90:cb3d968589d8 | 566 | */ |
Kojto | 90:cb3d968589d8 | 567 | #define __HAL_REMAPMEMORY_SRAM() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_MEM_MODE); \ |
Kojto | 90:cb3d968589d8 | 568 | SYSCFG->CFGR1 |= (SYSCFG_CFGR1_MEM_MODE_0 | SYSCFG_CFGR1_MEM_MODE_1); \ |
Kojto | 90:cb3d968589d8 | 569 | }while(0) |
Kojto | 90:cb3d968589d8 | 570 | #endif /* SYSCFG_CFGR1_MEM_MODE_0 && SYSCFG_CFGR1_MEM_MODE_1 */ |
Kojto | 90:cb3d968589d8 | 571 | |
Kojto | 90:cb3d968589d8 | 572 | #if defined(SYSCFG_CFGR1_MEM_MODE_2) |
Kojto | 90:cb3d968589d8 | 573 | #define __HAL_FMC_BANK() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_MEM_MODE); \ |
Kojto | 90:cb3d968589d8 | 574 | SYSCFG->CFGR1 |= (SYSCFG_CFGR1_MEM_MODE_2); \ |
Kojto | 90:cb3d968589d8 | 575 | }while(0) |
Kojto | 90:cb3d968589d8 | 576 | #endif /* SYSCFG_CFGR1_MEM_MODE_2 */ |
Kojto | 90:cb3d968589d8 | 577 | /** |
Kojto | 90:cb3d968589d8 | 578 | * @} |
Kojto | 90:cb3d968589d8 | 579 | */ |
Kojto | 90:cb3d968589d8 | 580 | |
Kojto | 90:cb3d968589d8 | 581 | /** @defgroup Encoder_Mode Encoder Mode |
Kojto | 90:cb3d968589d8 | 582 | * @{ |
Kojto | 90:cb3d968589d8 | 583 | */ |
Kojto | 90:cb3d968589d8 | 584 | #if defined(SYSCFG_CFGR1_ENCODER_MODE) |
Kojto | 90:cb3d968589d8 | 585 | /** @brief No Encoder mode |
Kojto | 90:cb3d968589d8 | 586 | */ |
Kojto | 90:cb3d968589d8 | 587 | #define __HAL_REMAPENCODER_NONE() (SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_ENCODER_MODE)) |
Kojto | 90:cb3d968589d8 | 588 | #endif /* SYSCFG_CFGR1_ENCODER_MODE */ |
Kojto | 90:cb3d968589d8 | 589 | |
Kojto | 90:cb3d968589d8 | 590 | #if defined(SYSCFG_CFGR1_ENCODER_MODE_0) |
Kojto | 90:cb3d968589d8 | 591 | /** @brief Encoder mode : TIM2 IC1 and TIM2 IC2 are connected to TIM15 IC1 and TIM15 IC2 respectively |
Kojto | 90:cb3d968589d8 | 592 | */ |
Kojto | 90:cb3d968589d8 | 593 | #define __HAL_REMAPENCODER_TIM2() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_ENCODER_MODE); \ |
Kojto | 90:cb3d968589d8 | 594 | SYSCFG->CFGR1 |= SYSCFG_CFGR1_ENCODER_MODE_0; \ |
Kojto | 90:cb3d968589d8 | 595 | }while(0) |
Kojto | 90:cb3d968589d8 | 596 | #endif /* SYSCFG_CFGR1_ENCODER_MODE_0 */ |
Kojto | 90:cb3d968589d8 | 597 | |
Kojto | 90:cb3d968589d8 | 598 | #if defined(SYSCFG_CFGR1_ENCODER_MODE_1) |
Kojto | 90:cb3d968589d8 | 599 | /** @brief Encoder mode : TIM3 IC1 and TIM3 IC2 are connected to TIM15 IC1 and TIM15 IC2 respectively |
Kojto | 90:cb3d968589d8 | 600 | */ |
Kojto | 90:cb3d968589d8 | 601 | #define __HAL_REMAPENCODER_TIM3() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_ENCODER_MODE); \ |
Kojto | 90:cb3d968589d8 | 602 | SYSCFG->CFGR1 |= SYSCFG_CFGR1_ENCODER_MODE_1; \ |
Kojto | 90:cb3d968589d8 | 603 | }while(0) |
Kojto | 90:cb3d968589d8 | 604 | #endif /* SYSCFG_CFGR1_ENCODER_MODE_1 */ |
Kojto | 90:cb3d968589d8 | 605 | |
Kojto | 90:cb3d968589d8 | 606 | #if defined(SYSCFG_CFGR1_ENCODER_MODE_0) && defined(SYSCFG_CFGR1_ENCODER_MODE_1) |
Kojto | 90:cb3d968589d8 | 607 | /** @brief Encoder mode : TIM4 IC1 and TIM4 IC2 are connected to TIM15 IC1 and TIM15 IC2 (STM32F303xB/C and STM32F358xx devices) |
Kojto | 90:cb3d968589d8 | 608 | */ |
Kojto | 90:cb3d968589d8 | 609 | #define __HAL_REMAPENCODER_TIM4() do {SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_ENCODER_MODE); \ |
Kojto | 90:cb3d968589d8 | 610 | SYSCFG->CFGR1 |= (SYSCFG_CFGR1_ENCODER_MODE_0 | SYSCFG_CFGR1_ENCODER_MODE_1); \ |
Kojto | 90:cb3d968589d8 | 611 | }while(0) |
Kojto | 90:cb3d968589d8 | 612 | #endif /* SYSCFG_CFGR1_ENCODER_MODE_0 && SYSCFG_CFGR1_ENCODER_MODE_1 */ |
Kojto | 90:cb3d968589d8 | 613 | /** |
Kojto | 90:cb3d968589d8 | 614 | * @} |
Kojto | 90:cb3d968589d8 | 615 | */ |
Kojto | 90:cb3d968589d8 | 616 | |
Kojto | 90:cb3d968589d8 | 617 | /** @defgroup DMA_Remap_Enable DMA Remap Enable |
Kojto | 90:cb3d968589d8 | 618 | * @{ |
Kojto | 90:cb3d968589d8 | 619 | */ |
Kojto | 90:cb3d968589d8 | 620 | #if defined(SYSCFG_CFGR3_DMA_RMP) && defined(SYSCFG_CFGR1_DMA_RMP) |
Kojto | 90:cb3d968589d8 | 621 | /** @brief DMA remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 622 | * @param __DMA_REMAP__: This parameter can be a value of @ref HAL_DMA_Remapping |
Kojto | 90:cb3d968589d8 | 623 | */ |
Kojto | 90:cb3d968589d8 | 624 | #define __HAL_REMAPDMA_CHANNEL_ENABLE(__DMA_REMAP__) do {assert_param(IS_HAL_REMAPDMA((__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 625 | (((__DMA_REMAP__) & HAL_REMAP_CFGR3_MASK) ? \ |
Kojto | 90:cb3d968589d8 | 626 | (SYSCFG->CFGR3 |= ((__DMA_REMAP__) & ~HAL_REMAP_CFGR3_MASK)) : \ |
Kojto | 90:cb3d968589d8 | 627 | (SYSCFG->CFGR1 |= (__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 628 | }while(0) |
Kojto | 90:cb3d968589d8 | 629 | #define __HAL_REMAPDMA_CHANNEL_DISABLE(__DMA_REMAP__) do {assert_param(IS_HAL_REMAPDMA((__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 630 | (((__DMA_REMAP__) & HAL_REMAP_CFGR3_MASK) ? \ |
Kojto | 90:cb3d968589d8 | 631 | (SYSCFG->CFGR3 &= (~(__DMA_REMAP__) | HAL_REMAP_CFGR3_MASK)) : \ |
Kojto | 90:cb3d968589d8 | 632 | (SYSCFG->CFGR1 &= ~(__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 633 | }while(0) |
Kojto | 90:cb3d968589d8 | 634 | #elif defined(SYSCFG_CFGR1_DMA_RMP) |
Kojto | 90:cb3d968589d8 | 635 | /** @brief DMA remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 636 | * @param __DMA_REMAP__: This parameter can be a value of @ref HAL_DMA_Remapping |
Kojto | 90:cb3d968589d8 | 637 | */ |
Kojto | 90:cb3d968589d8 | 638 | #define __HAL_REMAPDMA_CHANNEL_ENABLE(__DMA_REMAP__) do {assert_param(IS_HAL_REMAPDMA((__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 639 | SYSCFG->CFGR1 |= (__DMA_REMAP__); \ |
Kojto | 90:cb3d968589d8 | 640 | }while(0) |
Kojto | 90:cb3d968589d8 | 641 | #define __HAL_REMAPDMA_CHANNEL_DISABLE(__DMA_REMAP__) do {assert_param(IS_HAL_REMAPDMA((__DMA_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 642 | SYSCFG->CFGR1 &= ~(__DMA_REMAP__); \ |
Kojto | 90:cb3d968589d8 | 643 | }while(0) |
Kojto | 90:cb3d968589d8 | 644 | #endif /* SYSCFG_CFGR3_DMA_RMP || SYSCFG_CFGR1_DMA_RMP */ |
Kojto | 90:cb3d968589d8 | 645 | /** |
Kojto | 90:cb3d968589d8 | 646 | * @} |
Kojto | 90:cb3d968589d8 | 647 | */ |
Kojto | 90:cb3d968589d8 | 648 | |
Kojto | 90:cb3d968589d8 | 649 | /** @defgroup I2C2_Fast_Mode_Plus_Enable I2C2 Fast Mode Plus Enable |
Kojto | 90:cb3d968589d8 | 650 | * @{ |
Kojto | 90:cb3d968589d8 | 651 | */ |
Kojto | 90:cb3d968589d8 | 652 | /** @brief Fast mode Plus driving capability enable/disable macros |
Kojto | 90:cb3d968589d8 | 653 | * @param __FASTMODEPLUS__: This parameter can be a value of @ref HAL_FastModePlus_I2C |
Kojto | 90:cb3d968589d8 | 654 | */ |
Kojto | 90:cb3d968589d8 | 655 | #define __HAL_SYSCFG_FASTMODEPLUS_ENABLE(__FASTMODEPLUS__) do {assert_param(IS_HAL_SYSCFG_FASTMODEPLUS_CONFIG((__FASTMODEPLUS__))); \ |
Kojto | 90:cb3d968589d8 | 656 | SYSCFG->CFGR1 |= (__FASTMODEPLUS__); \ |
Kojto | 90:cb3d968589d8 | 657 | }while(0) |
Kojto | 90:cb3d968589d8 | 658 | |
Kojto | 90:cb3d968589d8 | 659 | #define __HAL_SYSCFG_FASTMODEPLUS_DISABLE(__FASTMODEPLUS__) do {assert_param(IS_HAL_SYSCFG_FASTMODEPLUS_CONFIG((__FASTMODEPLUS__))); \ |
Kojto | 90:cb3d968589d8 | 660 | SYSCFG->CFGR1 &= ~(__FASTMODEPLUS__); \ |
Kojto | 90:cb3d968589d8 | 661 | }while(0) |
Kojto | 90:cb3d968589d8 | 662 | /** |
Kojto | 90:cb3d968589d8 | 663 | * @} |
Kojto | 90:cb3d968589d8 | 664 | */ |
Kojto | 90:cb3d968589d8 | 665 | |
Kojto | 90:cb3d968589d8 | 666 | /** @defgroup Floating_Point_Unit_Interrupts_Enable Floating Point Unit Interrupts Enable |
Kojto | 90:cb3d968589d8 | 667 | * @{ |
Kojto | 90:cb3d968589d8 | 668 | */ |
Kojto | 90:cb3d968589d8 | 669 | /** @brief SYSCFG interrupt enable/disable macros |
Kojto | 90:cb3d968589d8 | 670 | * @param __INTERRUPT__: This parameter can be a value of @ref HAL_SYSCFG_Interrupts |
Kojto | 90:cb3d968589d8 | 671 | */ |
Kojto | 90:cb3d968589d8 | 672 | #define __HAL_SYSCFG_INTERRUPT_ENABLE(__INTERRUPT__) do {assert_param(IS_HAL_SYSCFG_INTERRUPT((__INTERRUPT__))); \ |
Kojto | 90:cb3d968589d8 | 673 | SYSCFG->CFGR1 |= (__INTERRUPT__); \ |
Kojto | 90:cb3d968589d8 | 674 | }while(0) |
Kojto | 90:cb3d968589d8 | 675 | |
Kojto | 90:cb3d968589d8 | 676 | #define __HAL_SYSCFG_INTERRUPT_DISABLE(__INTERRUPT__) do {assert_param(IS_HAL_SYSCFG_INTERRUPT((__INTERRUPT__))); \ |
Kojto | 90:cb3d968589d8 | 677 | SYSCFG->CFGR1 &= ~(__INTERRUPT__); \ |
Kojto | 90:cb3d968589d8 | 678 | }while(0) |
Kojto | 90:cb3d968589d8 | 679 | /** |
Kojto | 90:cb3d968589d8 | 680 | * @} |
Kojto | 90:cb3d968589d8 | 681 | */ |
Kojto | 90:cb3d968589d8 | 682 | |
Kojto | 90:cb3d968589d8 | 683 | #if defined(SYSCFG_CFGR1_USB_IT_RMP) |
Kojto | 90:cb3d968589d8 | 684 | /** @defgroup USB_Interrupt_Remap USB Interrupt Remap |
Kojto | 90:cb3d968589d8 | 685 | * @{ |
Kojto | 90:cb3d968589d8 | 686 | */ |
Kojto | 90:cb3d968589d8 | 687 | /** @brief USB interrupt remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 688 | */ |
Kojto | 90:cb3d968589d8 | 689 | #define __HAL_REMAPINTERRUPT_USB_ENABLE() (SYSCFG->CFGR1 |= (SYSCFG_CFGR1_USB_IT_RMP)) |
Kojto | 90:cb3d968589d8 | 690 | #define __HAL_REMAPINTERRUPT_USB_DISABLE() (SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_USB_IT_RMP)) |
Kojto | 90:cb3d968589d8 | 691 | /** |
Kojto | 90:cb3d968589d8 | 692 | * @} |
Kojto | 90:cb3d968589d8 | 693 | */ |
Kojto | 90:cb3d968589d8 | 694 | #endif /* SYSCFG_CFGR1_USB_IT_RMP */ |
Kojto | 90:cb3d968589d8 | 695 | |
Kojto | 90:cb3d968589d8 | 696 | #if defined(SYSCFG_CFGR1_VBAT) |
Kojto | 90:cb3d968589d8 | 697 | /** @defgroup VBAT_Monitoring_Enable VBAT Monitoring Enable |
Kojto | 90:cb3d968589d8 | 698 | * @{ |
Kojto | 90:cb3d968589d8 | 699 | */ |
Kojto | 90:cb3d968589d8 | 700 | /** @brief SYSCFG interrupt enable/disable macros |
Kojto | 90:cb3d968589d8 | 701 | */ |
Kojto | 90:cb3d968589d8 | 702 | #define __HAL_SYSCFG_VBAT_MONITORING_ENABLE() (SYSCFG->CFGR1 |= (SYSCFG_CFGR1_VBAT)) |
Kojto | 90:cb3d968589d8 | 703 | #define __HAL_SYSCFG_VBAT_MONITORING_DISABLE() (SYSCFG->CFGR1 &= ~(SYSCFG_CFGR1_VBAT)) |
Kojto | 90:cb3d968589d8 | 704 | /** |
Kojto | 90:cb3d968589d8 | 705 | * @} |
Kojto | 90:cb3d968589d8 | 706 | */ |
Kojto | 90:cb3d968589d8 | 707 | #endif /* SYSCFG_CFGR1_VBAT */ |
Kojto | 90:cb3d968589d8 | 708 | |
Kojto | 90:cb3d968589d8 | 709 | #if defined(SYSCFG_CFGR2_LOCKUP_LOCK) |
Kojto | 90:cb3d968589d8 | 710 | /** @defgroup Cortex_Lockup_Enable Cortex Lockup Enable |
Kojto | 90:cb3d968589d8 | 711 | * @{ |
Kojto | 90:cb3d968589d8 | 712 | */ |
Kojto | 90:cb3d968589d8 | 713 | /** @brief SYSCFG Break Lockup lock |
Kojto | 90:cb3d968589d8 | 714 | * Enables and locks the connection of Cortex-M4 LOCKUP (Hardfault) output to TIM1/15/16/17 Break input |
Kojto | 90:cb3d968589d8 | 715 | * @note The selected configuration is locked and can be unlocked by system reset |
Kojto | 90:cb3d968589d8 | 716 | */ |
Kojto | 90:cb3d968589d8 | 717 | #define __HAL_SYSCFG_BREAK_LOCKUP_LOCK() do {SYSCFG->CFGR2 &= ~(SYSCFG_CFGR2_LOCKUP_LOCK); \ |
Kojto | 90:cb3d968589d8 | 718 | SYSCFG->CFGR2 |= SYSCFG_CFGR2_LOCKUP_LOCK; \ |
Kojto | 90:cb3d968589d8 | 719 | }while(0) |
Kojto | 90:cb3d968589d8 | 720 | /** |
Kojto | 90:cb3d968589d8 | 721 | * @} |
Kojto | 90:cb3d968589d8 | 722 | */ |
Kojto | 90:cb3d968589d8 | 723 | #endif /* SYSCFG_CFGR2_LOCKUP_LOCK */ |
Kojto | 90:cb3d968589d8 | 724 | |
Kojto | 90:cb3d968589d8 | 725 | #if defined(SYSCFG_CFGR2_PVD_LOCK) |
Kojto | 90:cb3d968589d8 | 726 | /** @defgroup PVD_Lock_Enable PVD Lock |
Kojto | 90:cb3d968589d8 | 727 | * @{ |
Kojto | 90:cb3d968589d8 | 728 | */ |
Kojto | 90:cb3d968589d8 | 729 | /** @brief SYSCFG Break PVD lock |
Kojto | 90:cb3d968589d8 | 730 | * Enables and locks the PVD connection with Timer1/8/15/16/17 Break Input, , as well as the PVDE and PLS[2:0] in the PWR_CR register |
Kojto | 90:cb3d968589d8 | 731 | * @note The selected configuration is locked and can be unlocked by system reset |
Kojto | 90:cb3d968589d8 | 732 | */ |
Kojto | 90:cb3d968589d8 | 733 | #define __HAL_SYSCFG_BREAK_PVD_LOCK() do {SYSCFG->CFGR2 &= ~(SYSCFG_CFGR2_PVD_LOCK); \ |
Kojto | 90:cb3d968589d8 | 734 | SYSCFG->CFGR2 |= SYSCFG_CFGR2_PVD_LOCK; \ |
Kojto | 90:cb3d968589d8 | 735 | }while(0) |
Kojto | 90:cb3d968589d8 | 736 | /** |
Kojto | 90:cb3d968589d8 | 737 | * @} |
Kojto | 90:cb3d968589d8 | 738 | */ |
Kojto | 90:cb3d968589d8 | 739 | #endif /* SYSCFG_CFGR2_PVD_LOCK */ |
Kojto | 90:cb3d968589d8 | 740 | |
Kojto | 90:cb3d968589d8 | 741 | #if defined(SYSCFG_CFGR2_SRAM_PARITY_LOCK) |
Kojto | 90:cb3d968589d8 | 742 | /** @defgroup SRAM_Parity_Lock SRAM Parity Lock |
Kojto | 90:cb3d968589d8 | 743 | * @{ |
Kojto | 90:cb3d968589d8 | 744 | */ |
Kojto | 90:cb3d968589d8 | 745 | /** @brief SYSCFG Break SRAM PARITY lock |
Kojto | 90:cb3d968589d8 | 746 | * Enables and locks the SRAM_PARITY error signal with Break Input of TIMER1/8/15/16/17 |
Kojto | 90:cb3d968589d8 | 747 | * @note The selected configuration is locked and can be unlocked by system reset |
Kojto | 90:cb3d968589d8 | 748 | */ |
Kojto | 90:cb3d968589d8 | 749 | #define __HAL_SYSCFG_BREAK_SRAMPARITY_LOCK() do {SYSCFG->CFGR2 &= ~(SYSCFG_CFGR2_SRAM_PARITY_LOCK); \ |
Kojto | 90:cb3d968589d8 | 750 | SYSCFG->CFGR2 |= SYSCFG_CFGR2_SRAM_PARITY_LOCK; \ |
Kojto | 90:cb3d968589d8 | 751 | }while(0) |
Kojto | 90:cb3d968589d8 | 752 | /** |
Kojto | 90:cb3d968589d8 | 753 | * @} |
Kojto | 90:cb3d968589d8 | 754 | */ |
Kojto | 90:cb3d968589d8 | 755 | #endif /* SYSCFG_CFGR2_SRAM_PARITY_LOCK */ |
Kojto | 90:cb3d968589d8 | 756 | |
Kojto | 90:cb3d968589d8 | 757 | /** @defgroup Trigger_Remapping_Enable Trigger Remapping Enable |
Kojto | 90:cb3d968589d8 | 758 | * @{ |
Kojto | 90:cb3d968589d8 | 759 | */ |
Kojto | 90:cb3d968589d8 | 760 | #if defined(SYSCFG_CFGR3_TRIGGER_RMP) |
Kojto | 90:cb3d968589d8 | 761 | /** @brief Trigger remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 762 | * @param __TRIGGER_REMAP__: This parameter can be a value of @ref HAL_Trigger_Remapping |
Kojto | 90:cb3d968589d8 | 763 | */ |
Kojto | 90:cb3d968589d8 | 764 | #define __HAL_REMAPTRIGGER_ENABLE(__TRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPTRIGGER((__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 765 | (((__TRIGGER_REMAP__) & HAL_REMAP_CFGR3_MASK) ? \ |
Kojto | 90:cb3d968589d8 | 766 | (SYSCFG->CFGR3 |= ((__TRIGGER_REMAP__) & ~HAL_REMAP_CFGR3_MASK)) : \ |
Kojto | 90:cb3d968589d8 | 767 | (SYSCFG->CFGR1 |= (__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 768 | }while(0) |
Kojto | 90:cb3d968589d8 | 769 | #define __HAL_REMAPTRIGGER_DISABLE(__TRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPTRIGGER((__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 770 | (((__TRIGGER_REMAP__) & HAL_REMAP_CFGR3_MASK) ? \ |
Kojto | 90:cb3d968589d8 | 771 | (SYSCFG->CFGR3 &= (~(__TRIGGER_REMAP__) | HAL_REMAP_CFGR3_MASK)) : \ |
Kojto | 90:cb3d968589d8 | 772 | (SYSCFG->CFGR1 &= ~(__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 773 | }while(0) |
Kojto | 90:cb3d968589d8 | 774 | #else |
Kojto | 90:cb3d968589d8 | 775 | /** @brief Trigger remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 776 | * @param __TRIGGER_REMAP__: This parameter can be a value of @ref HAL_Trigger_Remapping |
Kojto | 90:cb3d968589d8 | 777 | */ |
Kojto | 90:cb3d968589d8 | 778 | #define __HAL_REMAPTRIGGER_ENABLE(__TRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPTRIGGER((__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 779 | (SYSCFG->CFGR1 |= (__TRIGGER_REMAP__)); \ |
Kojto | 90:cb3d968589d8 | 780 | }while(0) |
Kojto | 90:cb3d968589d8 | 781 | #define __HAL_REMAPTRIGGER_DISABLE(__TRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPTRIGGER((__TRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 782 | (SYSCFG->CFGR1 &= ~(__TRIGGER_REMAP__)); \ |
Kojto | 90:cb3d968589d8 | 783 | }while(0) |
Kojto | 90:cb3d968589d8 | 784 | #endif /* SYSCFG_CFGR3_TRIGGER_RMP */ |
Kojto | 90:cb3d968589d8 | 785 | /** |
Kojto | 90:cb3d968589d8 | 786 | * @} |
Kojto | 90:cb3d968589d8 | 787 | */ |
Kojto | 90:cb3d968589d8 | 788 | |
Kojto | 90:cb3d968589d8 | 789 | #if defined (STM32F302xE) || defined (STM32F303xE) || defined (STM32F398xx) |
Kojto | 90:cb3d968589d8 | 790 | /** @defgroup ADC_Trigger_Remapping_Enable ADC Trigger Remapping Enable |
Kojto | 90:cb3d968589d8 | 791 | * @{ |
Kojto | 90:cb3d968589d8 | 792 | */ |
Kojto | 90:cb3d968589d8 | 793 | /** @brief ADC trigger remapping enable/disable macros |
Kojto | 90:cb3d968589d8 | 794 | * @param __ADCTRIGGER_REMAP__: This parameter can be a value of @ref HAL_ADC_Trigger_Remapping |
Kojto | 90:cb3d968589d8 | 795 | */ |
Kojto | 90:cb3d968589d8 | 796 | #define __HAL_REMAPADCTRIGGER_ENABLE(__ADCTRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPADCTRIGGER((__ADCTRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 797 | (SYSCFG->CFGR4 |= (__ADCTRIGGER_REMAP__)); \ |
Kojto | 90:cb3d968589d8 | 798 | }while(0) |
Kojto | 90:cb3d968589d8 | 799 | #define __HAL_REMAPADCTRIGGER_DISABLE(__ADCTRIGGER_REMAP__) do {assert_param(IS_HAL_REMAPADCTRIGGER((__ADCTRIGGER_REMAP__))); \ |
Kojto | 90:cb3d968589d8 | 800 | (SYSCFG->CFGR4 &= ~(__ADCTRIGGER_REMAP__)); \ |
Kojto | 90:cb3d968589d8 | 801 | }while(0) |
Kojto | 90:cb3d968589d8 | 802 | /** |
Kojto | 90:cb3d968589d8 | 803 | * @} |
Kojto | 90:cb3d968589d8 | 804 | */ |
Kojto | 90:cb3d968589d8 | 805 | #endif /* STM32F302xE || STM32F303xE || STM32F398xx */ |
Kojto | 90:cb3d968589d8 | 806 | |
Kojto | 90:cb3d968589d8 | 807 | #if defined(SYSCFG_CFGR2_BYP_ADDR_PAR) |
Kojto | 90:cb3d968589d8 | 808 | /** @defgroup RAM_Parity_Check_Disable RAM Parity Check Disable |
Kojto | 90:cb3d968589d8 | 809 | * @{ |
Kojto | 90:cb3d968589d8 | 810 | */ |
Kojto | 90:cb3d968589d8 | 811 | /** |
Kojto | 90:cb3d968589d8 | 812 | * @brief Parity check on RAM disable macro |
Kojto | 90:cb3d968589d8 | 813 | * @note Disabling the parity check on RAM locks the configuration bit. |
Kojto | 90:cb3d968589d8 | 814 | * To re-enable the parity check on RAM perform a system reset. |
Kojto | 90:cb3d968589d8 | 815 | */ |
Kojto | 90:cb3d968589d8 | 816 | #define __HAL_SYSCFG_RAM_PARITYCHECK_DISABLE() (*(__IO uint32_t *) CFGR2_BYPADDRPAR_BB = (uint32_t)0x00000001) |
Kojto | 90:cb3d968589d8 | 817 | /** |
Kojto | 90:cb3d968589d8 | 818 | * @} |
Kojto | 90:cb3d968589d8 | 819 | */ |
Kojto | 90:cb3d968589d8 | 820 | #endif /* SYSCFG_CFGR2_BYP_ADDR_PAR */ |
Kojto | 90:cb3d968589d8 | 821 | |
Kojto | 90:cb3d968589d8 | 822 | #if defined(SYSCFG_RCR_PAGE0) |
Kojto | 90:cb3d968589d8 | 823 | /** @defgroup CCM_RAM_Page_Write_Protection_Enable CCM RAM page write protection enable |
Kojto | 90:cb3d968589d8 | 824 | * @{ |
Kojto | 90:cb3d968589d8 | 825 | */ |
Kojto | 90:cb3d968589d8 | 826 | /** @brief CCM RAM page write protection enable macro |
Kojto | 90:cb3d968589d8 | 827 | * @param __PAGE_WP__: This parameter can be a value of @ref HAL_Page_Write_Protection |
Kojto | 90:cb3d968589d8 | 828 | * @note write protection can only be disabled by a system reset |
Kojto | 90:cb3d968589d8 | 829 | */ |
Kojto | 90:cb3d968589d8 | 830 | #define __HAL_SYSCFG_SRAM_WRP_ENABLE(__PAGE_WP__) do {assert_param(IS_HAL_SYSCFG_WP_PAGE((__PAGE_WP__))); \ |
Kojto | 90:cb3d968589d8 | 831 | SYSCFG->RCR |= (__PAGE_WP__); \ |
Kojto | 90:cb3d968589d8 | 832 | }while(0) |
Kojto | 90:cb3d968589d8 | 833 | /** |
Kojto | 90:cb3d968589d8 | 834 | * @} |
Kojto | 90:cb3d968589d8 | 835 | */ |
Kojto | 90:cb3d968589d8 | 836 | #endif /* SYSCFG_RCR_PAGE0 */ |
Kojto | 90:cb3d968589d8 | 837 | |
Kojto | 90:cb3d968589d8 | 838 | /** |
Kojto | 90:cb3d968589d8 | 839 | * @} |
Kojto | 90:cb3d968589d8 | 840 | */ |
Kojto | 90:cb3d968589d8 | 841 | /* Exported functions --------------------------------------------------------*/ |
Kojto | 90:cb3d968589d8 | 842 | /** @addtogroup HAL_Exported_Functions HAL Exported Functions |
Kojto | 90:cb3d968589d8 | 843 | * @{ |
Kojto | 90:cb3d968589d8 | 844 | */ |
Kojto | 90:cb3d968589d8 | 845 | |
Kojto | 90:cb3d968589d8 | 846 | /** @addtogroup HAL_Exported_Functions_Group1 Initialization and de-initialization Functions |
Kojto | 90:cb3d968589d8 | 847 | * @brief Initialization and de-initialization functions |
Kojto | 90:cb3d968589d8 | 848 | * @{ |
Kojto | 90:cb3d968589d8 | 849 | */ |
Kojto | 90:cb3d968589d8 | 850 | /* Initialization and de-initialization functions ******************************/ |
Kojto | 90:cb3d968589d8 | 851 | HAL_StatusTypeDef HAL_Init(void); |
Kojto | 90:cb3d968589d8 | 852 | HAL_StatusTypeDef HAL_DeInit(void); |
Kojto | 90:cb3d968589d8 | 853 | void HAL_MspInit(void); |
Kojto | 90:cb3d968589d8 | 854 | void HAL_MspDeInit(void); |
Kojto | 90:cb3d968589d8 | 855 | HAL_StatusTypeDef HAL_InitTick (uint32_t TickPriority); |
Kojto | 90:cb3d968589d8 | 856 | /** |
Kojto | 90:cb3d968589d8 | 857 | * @} |
Kojto | 90:cb3d968589d8 | 858 | */ |
Kojto | 90:cb3d968589d8 | 859 | |
Kojto | 90:cb3d968589d8 | 860 | /** @addtogroup HAL_Exported_Functions_Group2 HAL Control functions |
Kojto | 90:cb3d968589d8 | 861 | * @brief HAL Control functions |
Kojto | 90:cb3d968589d8 | 862 | * @{ |
Kojto | 90:cb3d968589d8 | 863 | */ |
Kojto | 90:cb3d968589d8 | 864 | /* Peripheral Control functions ************************************************/ |
Kojto | 90:cb3d968589d8 | 865 | void HAL_IncTick(void); |
Kojto | 90:cb3d968589d8 | 866 | void HAL_Delay(__IO uint32_t Delay); |
Kojto | 90:cb3d968589d8 | 867 | void HAL_SuspendTick(void); |
Kojto | 90:cb3d968589d8 | 868 | void HAL_ResumeTick(void); |
Kojto | 90:cb3d968589d8 | 869 | uint32_t HAL_GetTick(void); |
Kojto | 90:cb3d968589d8 | 870 | uint32_t HAL_GetHalVersion(void); |
Kojto | 90:cb3d968589d8 | 871 | uint32_t HAL_GetREVID(void); |
Kojto | 90:cb3d968589d8 | 872 | uint32_t HAL_GetDEVID(void); |
Kojto | 90:cb3d968589d8 | 873 | void HAL_EnableDBGSleepMode(void); |
Kojto | 90:cb3d968589d8 | 874 | void HAL_DisableDBGSleepMode(void); |
Kojto | 90:cb3d968589d8 | 875 | void HAL_EnableDBGStopMode(void); |
Kojto | 90:cb3d968589d8 | 876 | void HAL_DisableDBGStopMode(void); |
Kojto | 90:cb3d968589d8 | 877 | void HAL_EnableDBGStandbyMode(void); |
Kojto | 90:cb3d968589d8 | 878 | void HAL_DisableDBGStandbyMode(void); |
Kojto | 90:cb3d968589d8 | 879 | /** |
Kojto | 90:cb3d968589d8 | 880 | * @} |
Kojto | 90:cb3d968589d8 | 881 | */ |
Kojto | 90:cb3d968589d8 | 882 | |
Kojto | 90:cb3d968589d8 | 883 | /** |
Kojto | 90:cb3d968589d8 | 884 | * @} |
Kojto | 90:cb3d968589d8 | 885 | */ |
Kojto | 90:cb3d968589d8 | 886 | |
Kojto | 90:cb3d968589d8 | 887 | /** |
Kojto | 90:cb3d968589d8 | 888 | * @} |
Kojto | 90:cb3d968589d8 | 889 | */ |
Kojto | 90:cb3d968589d8 | 890 | |
Kojto | 90:cb3d968589d8 | 891 | /** |
Kojto | 90:cb3d968589d8 | 892 | * @} |
Kojto | 90:cb3d968589d8 | 893 | */ |
Kojto | 90:cb3d968589d8 | 894 | |
Kojto | 90:cb3d968589d8 | 895 | #ifdef __cplusplus |
Kojto | 90:cb3d968589d8 | 896 | } |
Kojto | 90:cb3d968589d8 | 897 | #endif |
Kojto | 90:cb3d968589d8 | 898 | |
Kojto | 90:cb3d968589d8 | 899 | #endif /* __STM32F3xx_HAL_H */ |
Kojto | 90:cb3d968589d8 | 900 | |
Kojto | 90:cb3d968589d8 | 901 | /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ |