1 /**
2   ******************************************************************************
3   * @file    stm32g0b0xx.h
4   * @author  MCD Application Team
5   * @brief   CMSIS Cortex-M0+ Device Peripheral Access Layer Header File.
6   *          This file contains all the peripheral register's definitions, bits
7   *          definitions and memory mapping for stm32g0b0xx devices.
8   *
9   *          This file contains:
10   *           - Data structures and the address mapping for all peripherals
11   *           - Peripheral's registers declarations and bits definition
12   *           - Macros to access peripheral's registers hardware
13   *
14   ******************************************************************************
15   * @attention
16   *
17   * Copyright (c) 2018-2021 STMicroelectronics.
18   * All rights reserved.
19   *
20   * This software is licensed under terms that can be found in the LICENSE file
21   * in the root directory of this software component.
22   * If no LICENSE file comes with this software, it is provided AS-IS.
23   *
24   ******************************************************************************
25   */
26 
27 /** @addtogroup CMSIS_Device
28   * @{
29   */
30 
31 /** @addtogroup stm32g0b0xx
32   * @{
33   */
34 
35 #ifndef STM32G0B0xx_H
36 #define STM32G0B0xx_H
37 
38 #ifdef __cplusplus
39  extern "C" {
40 #endif /* __cplusplus */
41 
42 /** @addtogroup Configuration_section_for_CMSIS
43   * @{
44   */
45 
46 /**
47   * @brief Configuration of the Cortex-M0+ Processor and Core Peripherals
48    */
49 #define __CM0PLUS_REV             0U /*!< Core Revision r0p0                            */
50 #define __MPU_PRESENT             1U /*!< STM32G0xx  provides an MPU                    */
51 #define __VTOR_PRESENT            1U /*!< Vector  Table  Register supported             */
52 #define __NVIC_PRIO_BITS          2U /*!< STM32G0xx uses 2 Bits for the Priority Levels */
53 #define __Vendor_SysTickConfig    0U /*!< Set to 1 if different SysTick Config is used  */
54 
55 /**
56   * @}
57   */
58 
59 /** @addtogroup Peripheral_interrupt_number_definition
60   * @{
61   */
62 
63 /**
64  * @brief stm32g0b0xx Interrupt Number Definition, according to the selected device
65  *        in @ref Library_configuration_section
66  */
67 
68 /*!< Interrupt Number Definition */
69 typedef enum
70 {
71 /******  Cortex-M0+ Processor Exceptions Numbers ***************************************************************/
72   NonMaskableInt_IRQn         = -14,    /*!< 2 Non Maskable Interrupt                                          */
73   HardFault_IRQn              = -13,    /*!< 3 Cortex-M Hard Fault Interrupt                                   */
74   SVCall_IRQn                 = -5,     /*!< 11 Cortex-M SV Call Interrupt                                     */
75   PendSV_IRQn                 = -2,     /*!< 14 Cortex-M Pend SV Interrupt                                     */
76   SysTick_IRQn                = -1,     /*!< 15 Cortex-M System Tick Interrupt                                 */
77 /******  STM32G0xxxx specific Interrupt Numbers ****************************************************************/
78   WWDG_IRQn                   = 0,      /*!< Window WatchDog Interrupt                                         */
79   RTC_TAMP_IRQn               = 2,      /*!< RTC interrupt through the EXTI line 19 & 21                       */
80   FLASH_IRQn                  = 3,      /*!< FLASH global Interrupt                                            */
81   RCC_IRQn                    = 4,      /*!< RCC global Interrupt                                              */
82   EXTI0_1_IRQn                = 5,      /*!< EXTI 0 and 1 Interrupts                                           */
83   EXTI2_3_IRQn                = 6,      /*!< EXTI Line 2 and 3 Interrupts                                      */
84   EXTI4_15_IRQn               = 7,      /*!< EXTI Line 4 to 15 Interrupts                                      */
85   USB_IRQn                    = 8,      /*!< USB Interrupt                                                     */
86   DMA1_Channel1_IRQn          = 9,      /*!< DMA1 Channel 1 Interrupt                                          */
87   DMA1_Channel2_3_IRQn        = 10,     /*!< DMA1 Channel 2 and Channel 3 Interrupts                           */
88   DMA1_Ch4_7_DMA2_Ch1_5_DMAMUX1_OVR_IRQn = 11, /*!< DMA1 Ch4 to Ch7, DMA2 Ch1 to Ch5 and DMAMUX1 Overrun Interrupts */
89   ADC1_IRQn                   = 12,     /*!< ADC1 Interrupts                                                   */
90   TIM1_BRK_UP_TRG_COM_IRQn    = 13,     /*!< TIM1 Break, Update, Trigger and Commutation Interrupts            */
91   TIM1_CC_IRQn                = 14,     /*!< TIM1 Capture Compare Interrupt                                    */
92   TIM3_TIM4_IRQn              = 16,     /*!< TIM3, TIM4 global Interrupt                                       */
93   TIM6_IRQn                   = 17,     /*!< TIM6 global Interrupts                                            */
94   TIM7_IRQn                   = 18,     /*!< TIM7 global Interrupt                                             */
95   TIM14_IRQn                  = 19,     /*!< TIM14 global Interrupt                                            */
96   TIM15_IRQn                  = 20,     /*!< TIM15 global Interrupt                                            */
97   TIM16_IRQn                  = 21,     /*!< TIM16 global Interrupt                                            */
98   TIM17_IRQn                  = 22,     /*!< TIM17 global Interrupt                                            */
99   I2C1_IRQn                   = 23,     /*!< I2C1 Interrupt  (combined with EXTI 23)                           */
100   I2C2_3_IRQn                 = 24,     /*!< I2C2, I2C3 Interrupt (combined with EXTI 24 and EXTI 22)          */
101   SPI1_IRQn                   = 25,     /*!< SPI1/I2S1 Interrupt                                               */
102   SPI2_3_IRQn                 = 26,     /*!< SPI2/I2S2, SPI3/I2S3 Interrupt                                    */
103   USART1_IRQn                 = 27,     /*!< USART1 Interrupt                                                  */
104   USART2_IRQn                 = 28,     /*!< USART2 Interrupt                                                  */
105   USART3_4_5_6_IRQn           = 29,     /*!< USART3, USART4, USART5, USART6 globlal Interrupts (combined with EXTI 28) */
106 } IRQn_Type;
107 
108 /**
109   * @}
110   */
111 
112 #include "core_cm0plus.h"               /* Cortex-M0+ processor and core peripherals */
113 #include "system_stm32g0xx.h"
114 #include <stdint.h>
115 
116 /** @addtogroup Peripheral_registers_structures
117   * @{
118   */
119 
120 /**
121   * @brief Analog to Digital Converter
122   */
123 typedef struct
124 {
125   __IO uint32_t ISR;          /*!< ADC interrupt and status register,             Address offset: 0x00 */
126   __IO uint32_t IER;          /*!< ADC interrupt enable register,                 Address offset: 0x04 */
127   __IO uint32_t CR;           /*!< ADC control register,                          Address offset: 0x08 */
128   __IO uint32_t CFGR1;        /*!< ADC configuration register 1,                  Address offset: 0x0C */
129   __IO uint32_t CFGR2;        /*!< ADC configuration register 2,                  Address offset: 0x10 */
130   __IO uint32_t SMPR;         /*!< ADC sampling time register,                    Address offset: 0x14 */
131        uint32_t RESERVED1;    /*!< Reserved,                                                      0x18 */
132        uint32_t RESERVED2;    /*!< Reserved,                                                      0x1C */
133   __IO uint32_t AWD1TR;       /*!< ADC analog watchdog 1 threshold register,      Address offset: 0x20 */
134   __IO uint32_t AWD2TR;       /*!< ADC analog watchdog 2 threshold register,      Address offset: 0x24 */
135   __IO uint32_t CHSELR;       /*!< ADC group regular sequencer register,          Address offset: 0x28 */
136   __IO uint32_t AWD3TR;       /*!< ADC analog watchdog 3 threshold register,      Address offset: 0x2C */
137        uint32_t RESERVED3[4]; /*!< Reserved,                                               0x30 - 0x3C */
138   __IO uint32_t DR;           /*!< ADC group regular data register,               Address offset: 0x40 */
139        uint32_t RESERVED4[23];/*!< Reserved,                                               0x44 - 0x9C */
140   __IO uint32_t AWD2CR;       /*!< ADC analog watchdog 2 configuration register,  Address offset: 0xA0 */
141   __IO uint32_t AWD3CR;       /*!< ADC analog watchdog 3 configuration register,  Address offset: 0xA4 */
142        uint32_t RESERVED5[3]; /*!< Reserved,                                               0xA8 - 0xB0 */
143   __IO uint32_t CALFACT;      /*!< ADC Calibration factor register,               Address offset: 0xB4 */
144 } ADC_TypeDef;
145 
146 typedef struct
147 {
148   __IO uint32_t CCR;          /*!< ADC common configuration register,             Address offset: ADC1 base address + 0x308 */
149 } ADC_Common_TypeDef;
150 
151 /* Legacy registers naming */
152 #define TR1     AWD1TR
153 #define TR2     AWD2TR
154 #define TR3     AWD3TR
155 
156 
157 
158 
159 /**
160   * @brief CRC calculation unit
161   */
162 typedef struct
163 {
164   __IO uint32_t DR;             /*!< CRC Data register,                         Address offset: 0x00 */
165   __IO uint32_t IDR;            /*!< CRC Independent data register,             Address offset: 0x04 */
166   __IO uint32_t CR;             /*!< CRC Control register,                      Address offset: 0x08 */
167        uint32_t RESERVED1;      /*!< Reserved,                                                  0x0C */
168   __IO uint32_t INIT;           /*!< Initial CRC value register,                Address offset: 0x10 */
169   __IO uint32_t POL;            /*!< CRC polynomial register,                   Address offset: 0x14 */
170 } CRC_TypeDef;
171 
172 
173 /**
174   * @brief Debug MCU
175   */
176 typedef struct
177 {
178   __IO uint32_t IDCODE;      /*!< MCU device ID code,              Address offset: 0x00 */
179   __IO uint32_t CR;          /*!< Debug configuration register,    Address offset: 0x04 */
180   __IO uint32_t APBFZ1;      /*!< Debug APB freeze register 1,     Address offset: 0x08 */
181   __IO uint32_t APBFZ2;      /*!< Debug APB freeze register 2,     Address offset: 0x0C */
182 } DBG_TypeDef;
183 
184 /**
185   * @brief DMA Controller
186   */
187 typedef struct
188 {
189   __IO uint32_t CCR;         /*!< DMA channel x configuration register        */
190   __IO uint32_t CNDTR;       /*!< DMA channel x number of data register       */
191   __IO uint32_t CPAR;        /*!< DMA channel x peripheral address register   */
192   __IO uint32_t CMAR;        /*!< DMA channel x memory address register       */
193 } DMA_Channel_TypeDef;
194 
195 typedef struct
196 {
197   __IO uint32_t ISR;         /*!< DMA interrupt status register,                 Address offset: 0x00 */
198   __IO uint32_t IFCR;        /*!< DMA interrupt flag clear register,             Address offset: 0x04 */
199 } DMA_TypeDef;
200 
201 /**
202   * @brief DMA Multiplexer
203   */
204 typedef struct
205 {
206   __IO uint32_t   CCR;       /*!< DMA Multiplexer Channel x Control Register    Address offset: 0x0004 * (channel x) */
207 }DMAMUX_Channel_TypeDef;
208 
209 typedef struct
210 {
211   __IO uint32_t   CSR;       /*!< DMA Channel Status Register                    Address offset: 0x0080   */
212   __IO uint32_t   CFR;       /*!< DMA Channel Clear Flag Register                Address offset: 0x0084   */
213 }DMAMUX_ChannelStatus_TypeDef;
214 
215 typedef struct
216 {
217   __IO uint32_t   RGCR;        /*!< DMA Request Generator x Control Register     Address offset: 0x0100 + 0x0004 * (Req Gen x) */
218 }DMAMUX_RequestGen_TypeDef;
219 
220 typedef struct
221 {
222   __IO uint32_t   RGSR;        /*!< DMA Request Generator Status Register        Address offset: 0x0140   */
223   __IO uint32_t   RGCFR;       /*!< DMA Request Generator Clear Flag Register    Address offset: 0x0144   */
224 }DMAMUX_RequestGenStatus_TypeDef;
225 
226 /**
227   * @brief Asynch Interrupt/Event Controller (EXTI)
228   */
229 typedef struct
230 {
231   __IO uint32_t RTSR1;          /*!< EXTI Rising Trigger Selection Register 1,        Address offset:   0x00 */
232   __IO uint32_t FTSR1;          /*!< EXTI Falling Trigger Selection Register 1,       Address offset:   0x04 */
233   __IO uint32_t SWIER1;         /*!< EXTI Software Interrupt event Register 1,        Address offset:   0x08 */
234   __IO uint32_t RPR1;           /*!< EXTI Rising Pending Register 1,                  Address offset:   0x0C */
235   __IO uint32_t FPR1;           /*!< EXTI Falling Pending Register 1,                 Address offset:   0x10 */
236        uint32_t RESERVED1[3];   /*!< Reserved 1,                                                0x14 -- 0x1C */
237        uint32_t RESERVED2[5];   /*!< Reserved 2,                                                0x20 -- 0x30 */
238        uint32_t RESERVED3[11];  /*!< Reserved 3,                                                0x34 -- 0x5C */
239   __IO uint32_t EXTICR[4];      /*!< EXTI External Interrupt Configuration Register,            0x60 -- 0x6C */
240        uint32_t RESERVED4[4];   /*!< Reserved 4,                                                0x70 -- 0x7C */
241   __IO uint32_t IMR1;           /*!< EXTI Interrupt Mask Register 1,                  Address offset:   0x80 */
242   __IO uint32_t EMR1;           /*!< EXTI Event Mask Register 1,                      Address offset:   0x84 */
243        uint32_t RESERVED5[2];   /*!< Reserved 5,                                                0x88 -- 0x8C */
244   __IO uint32_t IMR2;           /*!< EXTI Interrupt Mask Register 2,                  Address offset:   0x90 */
245   __IO uint32_t EMR2;           /*!< EXTI Event Mask Register 2,                      Address offset:   0x94 */
246 } EXTI_TypeDef;
247 
248 /**
249   * @brief FLASH Registers
250   */
251 typedef struct
252 {
253   __IO uint32_t ACR;          /*!< FLASH Access Control register,                     Address offset: 0x00 */
254        uint32_t RESERVED1;    /*!< Reserved1,                                         Address offset: 0x04 */
255   __IO uint32_t KEYR;         /*!< FLASH Key register,                                Address offset: 0x08 */
256   __IO uint32_t OPTKEYR;      /*!< FLASH Option Key register,                         Address offset: 0x0C */
257   __IO uint32_t SR;           /*!< FLASH Status register,                             Address offset: 0x10 */
258   __IO uint32_t CR;           /*!< FLASH Control register,                            Address offset: 0x14 */
259   __IO uint32_t ECCR;          /*!< FLASH ECC bank 1 register,                        Address offset: 0x18 */
260   __IO uint32_t ECC2R;         /*!< FLASH ECC bank 2 register,                        Address offset: 0x1C */
261   __IO uint32_t OPTR;         /*!< FLASH Option register,                             Address offset: 0x20 */
262        uint32_t RESERVED3[2]; /*!< Reserved3,                                         Address offset: 0x24--0x28 */
263   __IO uint32_t WRP1AR;       /*!< FLASH Bank WRP area A address register,            Address offset: 0x2C */
264   __IO uint32_t WRP1BR;       /*!< FLASH Bank WRP area B address register,            Address offset: 0x30 */
265        uint32_t RESERVED4[2]; /*!< Reserved4,                                         Address offset: 0x34--0x38 */
266        uint32_t RESERVED5[2]; /*!< Reserved5,                                         Address offset: 0x3C--0x40 */
267        uint32_t RESERVED6[2]; /*!< Reserved6,                                         Address offset: 0x44--0x48 */
268   __IO uint32_t WRP2AR;       /*!< FLASH Bank2 WRP area A address register,           Address offset: 0x4C */
269   __IO uint32_t WRP2BR;       /*!< FLASH Bank2 WRP area B address register,           Address offset: 0x50 */
270 } FLASH_TypeDef;
271 
272 /**
273   * @brief General Purpose I/O
274   */
275 typedef struct
276 {
277   __IO uint32_t MODER;       /*!< GPIO port mode register,               Address offset: 0x00      */
278   __IO uint32_t OTYPER;      /*!< GPIO port output type register,        Address offset: 0x04      */
279   __IO uint32_t OSPEEDR;     /*!< GPIO port output speed register,       Address offset: 0x08      */
280   __IO uint32_t PUPDR;       /*!< GPIO port pull-up/pull-down register,  Address offset: 0x0C      */
281   __IO uint32_t IDR;         /*!< GPIO port input data register,         Address offset: 0x10      */
282   __IO uint32_t ODR;         /*!< GPIO port output data register,        Address offset: 0x14      */
283   __IO uint32_t BSRR;        /*!< GPIO port bit set/reset  register,     Address offset: 0x18      */
284   __IO uint32_t LCKR;        /*!< GPIO port configuration lock register, Address offset: 0x1C      */
285   __IO uint32_t AFR[2];      /*!< GPIO alternate function registers,     Address offset: 0x20-0x24 */
286   __IO uint32_t BRR;         /*!< GPIO Bit Reset register,               Address offset: 0x28      */
287 } GPIO_TypeDef;
288 
289 
290 /**
291   * @brief Inter-integrated Circuit Interface
292   */
293 typedef struct
294 {
295   __IO uint32_t CR1;         /*!< I2C Control register 1,            Address offset: 0x00 */
296   __IO uint32_t CR2;         /*!< I2C Control register 2,            Address offset: 0x04 */
297   __IO uint32_t OAR1;        /*!< I2C Own address 1 register,        Address offset: 0x08 */
298   __IO uint32_t OAR2;        /*!< I2C Own address 2 register,        Address offset: 0x0C */
299   __IO uint32_t TIMINGR;     /*!< I2C Timing register,               Address offset: 0x10 */
300   __IO uint32_t TIMEOUTR;    /*!< I2C Timeout register,              Address offset: 0x14 */
301   __IO uint32_t ISR;         /*!< I2C Interrupt and status register, Address offset: 0x18 */
302   __IO uint32_t ICR;         /*!< I2C Interrupt clear register,      Address offset: 0x1C */
303   __IO uint32_t PECR;        /*!< I2C PEC register,                  Address offset: 0x20 */
304   __IO uint32_t RXDR;        /*!< I2C Receive data register,         Address offset: 0x24 */
305   __IO uint32_t TXDR;        /*!< I2C Transmit data register,        Address offset: 0x28 */
306 } I2C_TypeDef;
307 
308 /**
309   * @brief Independent WATCHDOG
310   */
311 typedef struct
312 {
313   __IO uint32_t KR;          /*!< IWDG Key register,       Address offset: 0x00 */
314   __IO uint32_t PR;          /*!< IWDG Prescaler register, Address offset: 0x04 */
315   __IO uint32_t RLR;         /*!< IWDG Reload register,    Address offset: 0x08 */
316   __IO uint32_t SR;          /*!< IWDG Status register,    Address offset: 0x0C */
317   __IO uint32_t WINR;        /*!< IWDG Window register,    Address offset: 0x10 */
318 } IWDG_TypeDef;
319 
320 
321 
322 /**
323   * @brief Power Control
324   */
325 typedef struct
326 {
327   __IO uint32_t CR1;          /*!< PWR Power Control Register 1,                     Address offset: 0x00 */
328        uint32_t RESERVED0;    /*!< Reserved,                                         Address offset: 0x04 */
329   __IO uint32_t CR3;          /*!< PWR Power Control Register 3,                     Address offset: 0x08 */
330   __IO uint32_t CR4;          /*!< PWR Power Control Register 4,                     Address offset: 0x0C */
331   __IO uint32_t SR1;          /*!< PWR Power Status Register 1,                      Address offset: 0x10 */
332   __IO uint32_t SR2;          /*!< PWR Power Status Register 2,                      Address offset: 0x14 */
333   __IO uint32_t SCR;          /*!< PWR Power Status Clear Register,                  Address offset: 0x18 */
334        uint32_t RESERVED1;    /*!< Reserved,                                         Address offset: 0x1C */
335   __IO uint32_t PUCRA;        /*!< PWR Pull-Up Control Register of port A,           Address offset: 0x20 */
336   __IO uint32_t PDCRA;        /*!< PWR Pull-Down Control Register of port A,         Address offset: 0x24 */
337   __IO uint32_t PUCRB;        /*!< PWR Pull-Up Control Register of port B,           Address offset: 0x28 */
338   __IO uint32_t PDCRB;        /*!< PWR Pull-Down Control Register of port B,         Address offset: 0x2C */
339   __IO uint32_t PUCRC;        /*!< PWR Pull-Up Control Register of port C,           Address offset: 0x30 */
340   __IO uint32_t PDCRC;        /*!< PWR Pull-Down Control Register of port C,         Address offset: 0x34 */
341   __IO uint32_t PUCRD;        /*!< PWR Pull-Up Control Register of port D,           Address offset: 0x38 */
342   __IO uint32_t PDCRD;        /*!< PWR Pull-Down Control Register of port D,         Address offset: 0x3C */
343   __IO uint32_t PUCRE;        /*!< PWR Pull-Up Control Register of port E,           Address offset: 0x40 */
344   __IO uint32_t PDCRE;        /*!< PWR Pull-Down Control Register of port E,         Address offset: 0x44 */
345   __IO uint32_t PUCRF;        /*!< PWR Pull-Up Control Register of port F,           Address offset: 0x48 */
346   __IO uint32_t PDCRF;        /*!< PWR Pull-Down Control Register of port F,         Address offset: 0x4C */
347 } PWR_TypeDef;
348 
349 /**
350   * @brief Reset and Clock Control
351   */
352 typedef struct
353 {
354   __IO uint32_t CR;          /*!< RCC Clock Sources Control Register,                                     Address offset: 0x00 */
355   __IO uint32_t ICSCR;       /*!< RCC Internal Clock Sources Calibration Register,                        Address offset: 0x04 */
356   __IO uint32_t CFGR;        /*!< RCC Regulated Domain Clocks Configuration Register,                     Address offset: 0x08 */
357   __IO uint32_t PLLCFGR;     /*!< RCC System PLL configuration Register,                                  Address offset: 0x0C */
358   __IO uint32_t RESERVED0;   /*!< Reserved,                                                               Address offset: 0x10 */
359   __IO uint32_t CRRCR;       /*!< RCC Clock Configuration Register,                                       Address offset: 0x14 */
360   __IO uint32_t CIER;        /*!< RCC Clock Interrupt Enable Register,                                    Address offset: 0x18 */
361   __IO uint32_t CIFR;        /*!< RCC Clock Interrupt Flag Register,                                      Address offset: 0x1C */
362   __IO uint32_t CICR;        /*!< RCC Clock Interrupt Clear Register,                                     Address offset: 0x20 */
363   __IO uint32_t IOPRSTR;     /*!< RCC IO port reset register,                                             Address offset: 0x24 */
364   __IO uint32_t AHBRSTR;     /*!< RCC AHB peripherals reset register,                                     Address offset: 0x28 */
365   __IO uint32_t APBRSTR1;    /*!< RCC APB peripherals reset register 1,                                   Address offset: 0x2C */
366   __IO uint32_t APBRSTR2;    /*!< RCC APB peripherals reset register 2,                                   Address offset: 0x30 */
367   __IO uint32_t IOPENR;      /*!< RCC IO port enable register,                                            Address offset: 0x34 */
368   __IO uint32_t AHBENR;      /*!< RCC AHB peripherals clock enable register,                              Address offset: 0x38 */
369   __IO uint32_t APBENR1;     /*!< RCC APB peripherals clock enable register1,                             Address offset: 0x3C */
370   __IO uint32_t APBENR2;     /*!< RCC APB peripherals clock enable register2,                             Address offset: 0x40 */
371   __IO uint32_t IOPSMENR;    /*!< RCC IO port clocks enable in sleep mode register,                       Address offset: 0x44 */
372   __IO uint32_t AHBSMENR;    /*!< RCC AHB peripheral clocks enable in sleep mode register,                Address offset: 0x48 */
373   __IO uint32_t APBSMENR1;   /*!< RCC APB peripheral clocks enable in sleep mode register1,               Address offset: 0x4C */
374   __IO uint32_t APBSMENR2;   /*!< RCC APB peripheral clocks enable in sleep mode register2,               Address offset: 0x50 */
375   __IO uint32_t CCIPR;       /*!< RCC Peripherals Independent Clocks Configuration Register,              Address offset: 0x54 */
376   __IO uint32_t CCIPR2;      /*!< RCC Peripherals Independent Clocks Configuration Register2,             Address offset: 0x58 */
377   __IO uint32_t BDCR;        /*!< RCC Backup Domain Control Register,                                     Address offset: 0x5C */
378   __IO uint32_t CSR;         /*!< RCC Unregulated Domain Clock Control and Status Register,               Address offset: 0x60 */
379 } RCC_TypeDef;
380 
381 /**
382   * @brief Real-Time Clock
383   */
384 typedef struct
385 {
386   __IO uint32_t TR;          /*!< RTC time register,                                         Address offset: 0x00 */
387   __IO uint32_t DR;          /*!< RTC date register,                                         Address offset: 0x04 */
388   __IO uint32_t SSR;         /*!< RTC sub second register,                                   Address offset: 0x08 */
389   __IO uint32_t ICSR;        /*!< RTC initialization control and status register,            Address offset: 0x0C */
390   __IO uint32_t PRER;        /*!< RTC prescaler register,                                    Address offset: 0x10 */
391   __IO uint32_t WUTR;        /*!< RTC wakeup timer register,                                 Address offset: 0x14 */
392   __IO uint32_t CR;          /*!< RTC control register,                                      Address offset: 0x18 */
393        uint32_t RESERVED0;   /*!< Reserved                                                   Address offset: 0x1C */
394        uint32_t RESERVED1;   /*!< Reserved                                                   Address offset: 0x20 */
395   __IO uint32_t WPR;         /*!< RTC write protection register,                             Address offset: 0x24 */
396   __IO uint32_t CALR;        /*!< RTC calibration register,                                  Address offset: 0x28 */
397   __IO uint32_t SHIFTR;      /*!< RTC shift control register,                                Address offset: 0x2C */
398   __IO uint32_t TSTR;        /*!< RTC time stamp time register,                              Address offset: 0x30 */
399   __IO uint32_t TSDR;        /*!< RTC time stamp date register,                              Address offset: 0x34 */
400   __IO uint32_t TSSSR;       /*!< RTC time-stamp sub second register,                        Address offset: 0x38 */
401        uint32_t RESERVED2;   /*!< Reserved                                                   Address offset: 0x1C */
402   __IO uint32_t ALRMAR;      /*!< RTC alarm A register,                                      Address offset: 0x40 */
403   __IO uint32_t ALRMASSR;    /*!< RTC alarm A sub second register,                           Address offset: 0x44 */
404   __IO uint32_t ALRMBR;      /*!< RTC alarm B register,                                      Address offset: 0x48 */
405   __IO uint32_t ALRMBSSR;    /*!< RTC alarm B sub second register,                           Address offset: 0x4C */
406   __IO uint32_t SR;          /*!< RTC Status register,                                       Address offset: 0x50 */
407   __IO uint32_t MISR;        /*!< RTC Masked Interrupt Status register,                      Address offset: 0x54 */
408        uint32_t RESERVED3;   /*!< Reserved                                                   Address offset: 0x58 */
409   __IO uint32_t SCR;         /*!< RTC Status Clear register,                                 Address offset: 0x5C */
410   __IO uint32_t OR;          /*!< RTC option register,                                       Address offset: 0x60 */
411 } RTC_TypeDef;
412 
413 /**
414   * @brief Tamper and backup registers
415   */
416 typedef struct
417 {
418   __IO uint32_t CR1;            /*!< TAMP configuration register 1,                             Address offset: 0x00 */
419   __IO uint32_t CR2;            /*!< TAMP configuration register 2,                             Address offset: 0x04 */
420        uint32_t RESERVED0;      /*!< Reserved                                                   Address offset: 0x08 */
421   __IO uint32_t FLTCR;          /*!< Reserved                                                   Address offset: 0x0C */
422        uint32_t RESERVED1[7];   /*!< Reserved                                                   Address offset: 0x10 -- 0x28 */
423   __IO uint32_t IER;            /*!< TAMP Interrupt enable register,                            Address offset: 0x2C */
424   __IO uint32_t SR;             /*!< TAMP Status register,                                      Address offset: 0x30 */
425   __IO uint32_t MISR;           /*!< TAMP Masked Interrupt Status register,                     Address offset: 0x34 */
426        uint32_t RESERVED2;      /*!< Reserved                                                   Address offset: 0x38 */
427   __IO uint32_t SCR;            /*!< TAMP Status clear register,                                Address offset: 0x3C */
428        uint32_t RESERVED3[48];  /*!< Reserved                                                   Address offset: 0x54 -- 0xFC */
429   __IO uint32_t BKP0R;          /*!< TAMP backup register 0,                                    Address offset: 0x100 */
430   __IO uint32_t BKP1R;          /*!< TAMP backup register 1,                                    Address offset: 0x104 */
431   __IO uint32_t BKP2R;          /*!< TAMP backup register 2,                                    Address offset: 0x108 */
432   __IO uint32_t BKP3R;          /*!< TAMP backup register 3,                                    Address offset: 0x10C */
433   __IO uint32_t BKP4R;          /*!< TAMP backup register 4,                                    Address offset: 0x110 */
434 } TAMP_TypeDef;
435 
436   /**
437   * @brief Serial Peripheral Interface
438   */
439 typedef struct
440 {
441   __IO uint32_t CR1;      /*!< SPI Control register 1 (not used in I2S mode),       Address offset: 0x00 */
442   __IO uint32_t CR2;      /*!< SPI Control register 2,                              Address offset: 0x04 */
443   __IO uint32_t SR;       /*!< SPI Status register,                                 Address offset: 0x08 */
444   __IO uint32_t DR;       /*!< SPI data register,                                   Address offset: 0x0C */
445   __IO uint32_t CRCPR;    /*!< SPI CRC polynomial register (not used in I2S mode),  Address offset: 0x10 */
446   __IO uint32_t RXCRCR;   /*!< SPI Rx CRC register (not used in I2S mode),          Address offset: 0x14 */
447   __IO uint32_t TXCRCR;   /*!< SPI Tx CRC register (not used in I2S mode),          Address offset: 0x18 */
448   __IO uint32_t I2SCFGR;  /*!< SPI_I2S configuration register,                      Address offset: 0x1C */
449   __IO uint32_t I2SPR;    /*!< SPI_I2S prescaler register,                          Address offset: 0x20 */
450 } SPI_TypeDef;
451 
452 /**
453   * @brief System configuration controller
454   */
455 typedef struct
456 {
457   __IO uint32_t CFGR1;          /*!< SYSCFG configuration register 1,                   Address offset: 0x00 */
458        uint32_t RESERVED0[5];   /*!< Reserved,                                                   0x04 --0x14 */
459   __IO uint32_t CFGR2;          /*!< SYSCFG configuration register 2,                   Address offset: 0x18 */
460        uint32_t RESERVED1[25];  /*!< Reserved                                                           0x1C */
461   __IO uint32_t IT_LINE_SR[32]; /*!< SYSCFG configuration IT_LINE register,             Address offset: 0x80 */
462 } SYSCFG_TypeDef;
463 
464 /**
465   * @brief TIM
466   */
467 typedef struct
468 {
469   __IO uint32_t CR1;         /*!< TIM control register 1,                   Address offset: 0x00 */
470   __IO uint32_t CR2;         /*!< TIM control register 2,                   Address offset: 0x04 */
471   __IO uint32_t SMCR;        /*!< TIM slave mode control register,          Address offset: 0x08 */
472   __IO uint32_t DIER;        /*!< TIM DMA/interrupt enable register,        Address offset: 0x0C */
473   __IO uint32_t SR;          /*!< TIM status register,                      Address offset: 0x10 */
474   __IO uint32_t EGR;         /*!< TIM event generation register,            Address offset: 0x14 */
475   __IO uint32_t CCMR1;       /*!< TIM capture/compare mode register 1,      Address offset: 0x18 */
476   __IO uint32_t CCMR2;       /*!< TIM capture/compare mode register 2,      Address offset: 0x1C */
477   __IO uint32_t CCER;        /*!< TIM capture/compare enable register,      Address offset: 0x20 */
478   __IO uint32_t CNT;         /*!< TIM counter register,                     Address offset: 0x24 */
479   __IO uint32_t PSC;         /*!< TIM prescaler register,                   Address offset: 0x28 */
480   __IO uint32_t ARR;         /*!< TIM auto-reload register,                 Address offset: 0x2C */
481   __IO uint32_t RCR;         /*!< TIM repetition counter register,          Address offset: 0x30 */
482   __IO uint32_t CCR1;        /*!< TIM capture/compare register 1,           Address offset: 0x34 */
483   __IO uint32_t CCR2;        /*!< TIM capture/compare register 2,           Address offset: 0x38 */
484   __IO uint32_t CCR3;        /*!< TIM capture/compare register 3,           Address offset: 0x3C */
485   __IO uint32_t CCR4;        /*!< TIM capture/compare register 4,           Address offset: 0x40 */
486   __IO uint32_t BDTR;        /*!< TIM break and dead-time register,         Address offset: 0x44 */
487   __IO uint32_t DCR;         /*!< TIM DMA control register,                 Address offset: 0x48 */
488   __IO uint32_t DMAR;        /*!< TIM DMA address for full transfer,        Address offset: 0x4C */
489   __IO uint32_t OR1;         /*!< TIM option register,                      Address offset: 0x50 */
490   __IO uint32_t CCMR3;       /*!< TIM capture/compare mode register 3,      Address offset: 0x54 */
491   __IO uint32_t CCR5;        /*!< TIM capture/compare register5,            Address offset: 0x58 */
492   __IO uint32_t CCR6;        /*!< TIM capture/compare register6,            Address offset: 0x5C */
493   __IO uint32_t AF1;         /*!< TIM alternate function register 1,        Address offset: 0x60 */
494   __IO uint32_t AF2;         /*!< TIM alternate function register 2,        Address offset: 0x64 */
495   __IO uint32_t TISEL;       /*!< TIM Input Selection register,             Address offset: 0x68 */
496 } TIM_TypeDef;
497 
498 /**
499   * @brief Universal Synchronous Asynchronous Receiver Transmitter
500   */
501 typedef struct
502 {
503   __IO uint32_t CR1;         /*!< USART Control register 1,                 Address offset: 0x00  */
504   __IO uint32_t CR2;         /*!< USART Control register 2,                 Address offset: 0x04  */
505   __IO uint32_t CR3;         /*!< USART Control register 3,                 Address offset: 0x08  */
506   __IO uint32_t BRR;         /*!< USART Baud rate register,                 Address offset: 0x0C  */
507   __IO uint32_t GTPR;        /*!< USART Guard time and prescaler register,  Address offset: 0x10  */
508   __IO uint32_t RTOR;        /*!< USART Receiver Time Out register,         Address offset: 0x14  */
509   __IO uint32_t RQR;         /*!< USART Request register,                   Address offset: 0x18  */
510   __IO uint32_t ISR;         /*!< USART Interrupt and status register,      Address offset: 0x1C  */
511   __IO uint32_t ICR;         /*!< USART Interrupt flag Clear register,      Address offset: 0x20  */
512   __IO uint32_t RDR;         /*!< USART Receive Data register,              Address offset: 0x24  */
513   __IO uint32_t TDR;         /*!< USART Transmit Data register,             Address offset: 0x28  */
514   __IO uint32_t PRESC;       /*!< USART Prescaler register,                 Address offset: 0x2C  */
515 } USART_TypeDef;
516 
517 /**
518   * @brief Universal Serial Bus Full Speed Dual Role Device
519   */
520 
521 typedef struct
522 {
523   __IO uint32_t CHEP0R;          /*!< USB Channel/Endpoint 0 register,      Address offset: 0x00 */
524   __IO uint32_t CHEP1R;          /*!< USB Channel/Endpoint 1 register,      Address offset: 0x04 */
525   __IO uint32_t CHEP2R;          /*!< USB Channel/Endpoint 2 register,      Address offset: 0x08 */
526   __IO uint32_t CHEP3R;          /*!< USB Channel/Endpoint 3 register,      Address offset: 0x0C */
527   __IO uint32_t CHEP4R;          /*!< USB Channel/Endpoint 4 register,      Address offset: 0x10 */
528   __IO uint32_t CHEP5R;          /*!< USB Channel/Endpoint 5 register,      Address offset: 0x14 */
529   __IO uint32_t CHEP6R;          /*!< USB Channel/Endpoint 6 register,      Address offset: 0x18 */
530   __IO uint32_t CHEP7R;          /*!< USB Channel/Endpoint 7 register,      Address offset: 0x1C */
531   __IO uint32_t RESERVED0[8];    /*!< Reserved,                                                  */
532   __IO uint32_t CNTR;            /*!< Control register,                     Address offset: 0x40 */
533   __IO uint32_t ISTR;            /*!< Interrupt status register,            Address offset: 0x44 */
534   __IO uint32_t FNR;             /*!< Frame number register,                Address offset: 0x48 */
535   __IO uint32_t DADDR;           /*!< Device address register,              Address offset: 0x4C */
536   __IO uint32_t RESERVED1;       /*!< Reserved */
537   __IO uint32_t LPMCSR;          /*!< LPM Control and Status register,      Address offset: 0x54 */
538   __IO uint32_t BCDR;            /*!< Battery Charging detector register,   Address offset: 0x58 */
539 } USB_DRD_TypeDef;
540 
541 /**
542   * @brief Universal Serial Bus PacketMemoryArea Buffer Descriptor Table
543   */
544 typedef struct
545 {
546   __IO uint32_t TXBD;             /*!<Transmission buffer address*/
547   __IO uint32_t RXBD;             /*!<Reception buffer address */
548 } USB_DRD_PMABuffDescTypeDef;
549 
550 /**
551   * @brief Window WATCHDOG
552   */
553 typedef struct
554 {
555   __IO uint32_t CR;          /*!< WWDG Control register,       Address offset: 0x00 */
556   __IO uint32_t CFR;         /*!< WWDG Configuration register, Address offset: 0x04 */
557   __IO uint32_t SR;          /*!< WWDG Status register,        Address offset: 0x08 */
558 } WWDG_TypeDef;
559 
560 
561 /**
562   * @}
563   */
564 
565 /** @addtogroup Peripheral_memory_map
566   * @{
567   */
568 #define FLASH_BASE            (0x08000000UL)  /*!< FLASH base address */
569 #define SRAM_BASE             (0x20000000UL)  /*!< SRAM base address */
570 #define PERIPH_BASE           (0x40000000UL)  /*!< Peripheral base address */
571 #define IOPORT_BASE           (0x50000000UL)  /*!< IOPORT base address */
572 /*!< USB PMA SIZE */
573 #define USB_DRD_PMA_SIZE              2048U   /*!< USB PMA Size 2Kbyte */
574 
575 #define SRAM_SIZE_MAX         (0x00020000UL)  /*!< maximum SRAM size (up to 128 KBytes) */
576 
577 #define FLASH_SIZE            (((*((uint32_t *)FLASHSIZE_BASE)) & (0x03FFU)) << 10U)
578 
579 /*!< Peripheral memory map */
580 #define APBPERIPH_BASE        (PERIPH_BASE)
581 #define AHBPERIPH_BASE        (PERIPH_BASE + 0x00020000UL)
582 
583 /*!< APB peripherals */
584 
585 #define TIM3_BASE             (APBPERIPH_BASE + 0x00000400UL)
586 #define TIM4_BASE             (APBPERIPH_BASE + 0x00000800UL)
587 #define TIM6_BASE             (APBPERIPH_BASE + 0x00001000UL)
588 #define TIM7_BASE             (APBPERIPH_BASE + 0x00001400UL)
589 #define TIM14_BASE            (APBPERIPH_BASE + 0x00002000UL)
590 #define RTC_BASE              (APBPERIPH_BASE + 0x00002800UL)
591 #define WWDG_BASE             (APBPERIPH_BASE + 0x00002C00UL)
592 #define IWDG_BASE             (APBPERIPH_BASE + 0x00003000UL)
593 #define SPI2_BASE             (APBPERIPH_BASE + 0x00003800UL)
594 #define SPI3_BASE             (APBPERIPH_BASE + 0x00003C00UL)
595 #define USART2_BASE           (APBPERIPH_BASE + 0x00004400UL)
596 #define USART3_BASE           (APBPERIPH_BASE + 0x00004800UL)
597 #define USART4_BASE           (APBPERIPH_BASE + 0x00004C00UL)
598 #define USART5_BASE           (APBPERIPH_BASE + 0x00005000UL)
599 #define I2C1_BASE             (APBPERIPH_BASE + 0x00005400UL)
600 #define I2C2_BASE             (APBPERIPH_BASE + 0x00005800UL)
601 #define USB_BASE              (APBPERIPH_BASE + 0x00005C00UL)  /*!< USB_IP Peripheral Registers base address */
602 #define PWR_BASE              (APBPERIPH_BASE + 0x00007000UL)
603 #define I2C3_BASE             (APBPERIPH_BASE + 0x00008800UL)
604 #define USB_DRD_BASE          (APBPERIPH_BASE + 0x00005C00UL) /*!< USB_DRD_IP Peripheral Registers base address */
605 #define USB_DRD_PMAADDR       (APBPERIPH_BASE + 0x00009800UL) /*!< USB_DRD_IP Packet Memory Area base address */
606 #define TAMP_BASE             (APBPERIPH_BASE + 0x0000B000UL)
607 #define SYSCFG_BASE           (APBPERIPH_BASE + 0x00010000UL)
608 #define ADC1_BASE             (APBPERIPH_BASE + 0x00012400UL)
609 #define ADC1_COMMON_BASE      (APBPERIPH_BASE + 0x00012708UL)
610 #define ADC_BASE              (ADC1_COMMON_BASE) /* Kept for legacy purpose */
611 #define TIM1_BASE             (APBPERIPH_BASE + 0x00012C00UL)
612 #define SPI1_BASE             (APBPERIPH_BASE + 0x00013000UL)
613 #define USART1_BASE           (APBPERIPH_BASE + 0x00013800UL)
614 #define USART6_BASE           (APBPERIPH_BASE + 0x00013C00UL)
615 #define TIM15_BASE            (APBPERIPH_BASE + 0x00014000UL)
616 #define TIM16_BASE            (APBPERIPH_BASE + 0x00014400UL)
617 #define TIM17_BASE            (APBPERIPH_BASE + 0x00014800UL)
618 #define DBG_BASE              (APBPERIPH_BASE + 0x00015800UL)
619 
620 
621 /*!< AHB peripherals */
622 #define DMA1_BASE             (AHBPERIPH_BASE)
623 #define DMA2_BASE             (AHBPERIPH_BASE + 0x00000400UL)
624 #define DMAMUX1_BASE          (AHBPERIPH_BASE + 0x00000800UL)
625 #define RCC_BASE              (AHBPERIPH_BASE + 0x00001000UL)
626 #define EXTI_BASE             (AHBPERIPH_BASE + 0x00001800UL)
627 #define FLASH_R_BASE          (AHBPERIPH_BASE + 0x00002000UL)
628 #define CRC_BASE              (AHBPERIPH_BASE + 0x00003000UL)
629 
630 
631 #define DMA1_Channel1_BASE    (DMA1_BASE + 0x00000008UL)
632 #define DMA1_Channel2_BASE    (DMA1_BASE + 0x0000001CUL)
633 #define DMA1_Channel3_BASE    (DMA1_BASE + 0x00000030UL)
634 #define DMA1_Channel4_BASE    (DMA1_BASE + 0x00000044UL)
635 #define DMA1_Channel5_BASE    (DMA1_BASE + 0x00000058UL)
636 #define DMA1_Channel6_BASE    (DMA1_BASE + 0x0000006CUL)
637 #define DMA1_Channel7_BASE    (DMA1_BASE + 0x00000080UL)
638 #define DMA2_Channel1_BASE    (DMA2_BASE + 0x00000008UL)
639 #define DMA2_Channel2_BASE    (DMA2_BASE + 0x0000001CUL)
640 #define DMA2_Channel3_BASE    (DMA2_BASE + 0x00000030UL)
641 #define DMA2_Channel4_BASE    (DMA2_BASE + 0x00000044UL)
642 #define DMA2_Channel5_BASE    (DMA2_BASE + 0x00000058UL)
643 
644 #define DMAMUX1_Channel0_BASE    (DMAMUX1_BASE)
645 #define DMAMUX1_Channel1_BASE    (DMAMUX1_BASE + 0x00000004UL)
646 #define DMAMUX1_Channel2_BASE    (DMAMUX1_BASE + 0x00000008UL)
647 #define DMAMUX1_Channel3_BASE    (DMAMUX1_BASE + 0x0000000CUL)
648 #define DMAMUX1_Channel4_BASE    (DMAMUX1_BASE + 0x00000010UL)
649 #define DMAMUX1_Channel5_BASE    (DMAMUX1_BASE + 0x00000014UL)
650 #define DMAMUX1_Channel6_BASE    (DMAMUX1_BASE + 0x00000018UL)
651 #define DMAMUX1_Channel7_BASE    (DMAMUX1_BASE + 0x0000001CUL)
652 #define DMAMUX1_Channel8_BASE    (DMAMUX1_BASE + 0x00000020UL)
653 #define DMAMUX1_Channel9_BASE    (DMAMUX1_BASE + 0x00000024UL)
654 #define DMAMUX1_Channel10_BASE   (DMAMUX1_BASE + 0x00000028UL)
655 #define DMAMUX1_Channel11_BASE   (DMAMUX1_BASE + 0x0000002CUL)
656 
657 #define DMAMUX1_RequestGenerator0_BASE  (DMAMUX1_BASE + 0x00000100UL)
658 #define DMAMUX1_RequestGenerator1_BASE  (DMAMUX1_BASE + 0x00000104UL)
659 #define DMAMUX1_RequestGenerator2_BASE  (DMAMUX1_BASE + 0x00000108UL)
660 #define DMAMUX1_RequestGenerator3_BASE  (DMAMUX1_BASE + 0x0000010CUL)
661 
662 #define DMAMUX1_ChannelStatus_BASE      (DMAMUX1_BASE + 0x00000080UL)
663 #define DMAMUX1_RequestGenStatus_BASE   (DMAMUX1_BASE + 0x00000140UL)
664 
665 /*!< IOPORT */
666 #define GPIOA_BASE            (IOPORT_BASE + 0x00000000UL)
667 #define GPIOB_BASE            (IOPORT_BASE + 0x00000400UL)
668 #define GPIOC_BASE            (IOPORT_BASE + 0x00000800UL)
669 #define GPIOD_BASE            (IOPORT_BASE + 0x00000C00UL)
670 #define GPIOE_BASE            (IOPORT_BASE + 0x00001000UL)
671 #define GPIOF_BASE            (IOPORT_BASE + 0x00001400UL)
672 
673 /*!< Device Electronic Signature */
674 #define PACKAGE_BASE          (0x1FFF7500UL)        /*!< Package data register base address     */
675 #define UID_BASE              (0x1FFF7590UL)        /*!< Unique device ID register base address */
676 #define FLASHSIZE_BASE        (0x1FFF75E0UL)        /*!< Flash size data register base address  */
677 
678 /**
679   * @}
680   */
681 
682 /** @addtogroup Peripheral_declaration
683   * @{
684   */
685 #define TIM3                ((TIM_TypeDef *) TIM3_BASE)
686 #define TIM4                ((TIM_TypeDef *) TIM4_BASE)
687 #define TIM6                ((TIM_TypeDef *) TIM6_BASE)
688 #define TIM7                ((TIM_TypeDef *) TIM7_BASE)
689 #define TIM14               ((TIM_TypeDef *) TIM14_BASE)
690 #define RTC                 ((RTC_TypeDef *) RTC_BASE)
691 #define TAMP                ((TAMP_TypeDef *) TAMP_BASE)
692 #define WWDG                ((WWDG_TypeDef *) WWDG_BASE)
693 #define IWDG                ((IWDG_TypeDef *) IWDG_BASE)
694 #define SPI2                ((SPI_TypeDef *) SPI2_BASE)
695 #define SPI3                ((SPI_TypeDef *) SPI3_BASE)
696 #define USART2              ((USART_TypeDef *) USART2_BASE)
697 #define USART3              ((USART_TypeDef *) USART3_BASE)
698 #define USART4              ((USART_TypeDef *) USART4_BASE)
699 #define USART5              ((USART_TypeDef *) USART5_BASE)
700 #define USART6              ((USART_TypeDef *) USART6_BASE)
701 #define I2C1                ((I2C_TypeDef *) I2C1_BASE)
702 #define I2C2                ((I2C_TypeDef *) I2C2_BASE)
703 #define I2C3                ((I2C_TypeDef *) I2C3_BASE)
704 #define USB_DRD_FS          ((USB_DRD_TypeDef *) USB_DRD_BASE)
705 #define USB_DRD_PMA_BUFF    ((USB_DRD_PMABuffDescTypeDef*) USB_DRD_PMAADDR)
706 #define PWR                 ((PWR_TypeDef *) PWR_BASE)
707 #define RCC                 ((RCC_TypeDef *) RCC_BASE)
708 #define EXTI                ((EXTI_TypeDef *) EXTI_BASE)
709 #define SYSCFG              ((SYSCFG_TypeDef *) SYSCFG_BASE)
710 #define TIM1                ((TIM_TypeDef *) TIM1_BASE)
711 #define SPI1                ((SPI_TypeDef *) SPI1_BASE)
712 #define USART1              ((USART_TypeDef *) USART1_BASE)
713 #define TIM15               ((TIM_TypeDef *) TIM15_BASE)
714 #define TIM16               ((TIM_TypeDef *) TIM16_BASE)
715 #define TIM17               ((TIM_TypeDef *) TIM17_BASE)
716 #define DMA1                ((DMA_TypeDef *) DMA1_BASE)
717 #define DMA2                ((DMA_TypeDef *) DMA2_BASE)
718 #define FLASH               ((FLASH_TypeDef *) FLASH_R_BASE)
719 #define CRC                 ((CRC_TypeDef *) CRC_BASE)
720 #define GPIOA               ((GPIO_TypeDef *) GPIOA_BASE)
721 #define GPIOB               ((GPIO_TypeDef *) GPIOB_BASE)
722 #define GPIOC               ((GPIO_TypeDef *) GPIOC_BASE)
723 #define GPIOD               ((GPIO_TypeDef *) GPIOD_BASE)
724 #define GPIOE               ((GPIO_TypeDef *) GPIOE_BASE)
725 #define GPIOF               ((GPIO_TypeDef *) GPIOF_BASE)
726 #define ADC1                ((ADC_TypeDef *) ADC1_BASE)
727 #define ADC1_COMMON         ((ADC_Common_TypeDef *) ADC1_COMMON_BASE)
728 #define ADC                 (ADC1_COMMON) /* Kept for legacy purpose */
729 
730 
731 
732 #define DMA1_Channel1       ((DMA_Channel_TypeDef *) DMA1_Channel1_BASE)
733 #define DMA1_Channel2       ((DMA_Channel_TypeDef *) DMA1_Channel2_BASE)
734 #define DMA1_Channel3       ((DMA_Channel_TypeDef *) DMA1_Channel3_BASE)
735 #define DMA1_Channel4       ((DMA_Channel_TypeDef *) DMA1_Channel4_BASE)
736 #define DMA1_Channel5       ((DMA_Channel_TypeDef *) DMA1_Channel5_BASE)
737 #define DMA1_Channel6       ((DMA_Channel_TypeDef *) DMA1_Channel6_BASE)
738 #define DMA1_Channel7       ((DMA_Channel_TypeDef *) DMA1_Channel7_BASE)
739 #define DMA2_Channel1       ((DMA_Channel_TypeDef *) DMA2_Channel1_BASE)
740 #define DMA2_Channel2       ((DMA_Channel_TypeDef *) DMA2_Channel2_BASE)
741 #define DMA2_Channel3       ((DMA_Channel_TypeDef *) DMA2_Channel3_BASE)
742 #define DMA2_Channel4       ((DMA_Channel_TypeDef *) DMA2_Channel4_BASE)
743 #define DMA2_Channel5       ((DMA_Channel_TypeDef *) DMA2_Channel5_BASE)
744 #define DMAMUX1                ((DMAMUX_Channel_TypeDef *) DMAMUX1_BASE)
745 #define DMAMUX1_Channel0       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel0_BASE)
746 #define DMAMUX1_Channel1       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel1_BASE)
747 #define DMAMUX1_Channel2       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel2_BASE)
748 #define DMAMUX1_Channel3       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel3_BASE)
749 #define DMAMUX1_Channel4       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel4_BASE)
750 #define DMAMUX1_Channel5       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel5_BASE)
751 #define DMAMUX1_Channel6       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel6_BASE)
752 #define DMAMUX1_Channel7       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel7_BASE)
753 #define DMAMUX1_Channel8       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel8_BASE)
754 #define DMAMUX1_Channel9       ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel9_BASE)
755 #define DMAMUX1_Channel10      ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel10_BASE)
756 #define DMAMUX1_Channel11      ((DMAMUX_Channel_TypeDef *) DMAMUX1_Channel11_BASE)
757 
758 #define DMAMUX1_RequestGenerator0  ((DMAMUX_RequestGen_TypeDef *) DMAMUX1_RequestGenerator0_BASE)
759 #define DMAMUX1_RequestGenerator1  ((DMAMUX_RequestGen_TypeDef *) DMAMUX1_RequestGenerator1_BASE)
760 #define DMAMUX1_RequestGenerator2  ((DMAMUX_RequestGen_TypeDef *) DMAMUX1_RequestGenerator2_BASE)
761 #define DMAMUX1_RequestGenerator3  ((DMAMUX_RequestGen_TypeDef *) DMAMUX1_RequestGenerator3_BASE)
762 
763 #define DMAMUX1_ChannelStatus      ((DMAMUX_ChannelStatus_TypeDef *) DMAMUX1_ChannelStatus_BASE)
764 #define DMAMUX1_RequestGenStatus   ((DMAMUX_RequestGenStatus_TypeDef *) DMAMUX1_RequestGenStatus_BASE)
765 
766 #define DBG              ((DBG_TypeDef *) DBG_BASE)
767 
768 /**
769   * @}
770   */
771 
772 /** @addtogroup Exported_constants
773   * @{
774   */
775 
776   /** @addtogroup Hardware_Constant_Definition
777     * @{
778     */
779 #define LSI_STARTUP_TIME 130U /*!< LSI Maximum startup time in us */
780 
781   /**
782     * @}
783     */
784 
785   /** @addtogroup Peripheral_Registers_Bits_Definition
786   * @{
787   */
788 
789 /******************************************************************************/
790 /*                         Peripheral Registers Bits Definition               */
791 /******************************************************************************/
792 
793 /******************************************************************************/
794 /*                                                                            */
795 /*                      Analog to Digital Converter (ADC)                     */
796 /*                                                                            */
797 /******************************************************************************/
798 /********************  Bit definition for ADC_ISR register  *******************/
799 #define ADC_ISR_ADRDY_Pos              (0U)
800 #define ADC_ISR_ADRDY_Msk              (0x1UL << ADC_ISR_ADRDY_Pos)            /*!< 0x00000001 */
801 #define ADC_ISR_ADRDY                  ADC_ISR_ADRDY_Msk                       /*!< ADC ready flag */
802 #define ADC_ISR_EOSMP_Pos              (1U)
803 #define ADC_ISR_EOSMP_Msk              (0x1UL << ADC_ISR_EOSMP_Pos)            /*!< 0x00000002 */
804 #define ADC_ISR_EOSMP                  ADC_ISR_EOSMP_Msk                       /*!< ADC group regular end of sampling flag */
805 #define ADC_ISR_EOC_Pos                (2U)
806 #define ADC_ISR_EOC_Msk                (0x1UL << ADC_ISR_EOC_Pos)              /*!< 0x00000004 */
807 #define ADC_ISR_EOC                    ADC_ISR_EOC_Msk                         /*!< ADC group regular end of unitary conversion flag */
808 #define ADC_ISR_EOS_Pos                (3U)
809 #define ADC_ISR_EOS_Msk                (0x1UL << ADC_ISR_EOS_Pos)              /*!< 0x00000008 */
810 #define ADC_ISR_EOS                    ADC_ISR_EOS_Msk                         /*!< ADC group regular end of sequence conversions flag */
811 #define ADC_ISR_OVR_Pos                (4U)
812 #define ADC_ISR_OVR_Msk                (0x1UL << ADC_ISR_OVR_Pos)              /*!< 0x00000010 */
813 #define ADC_ISR_OVR                    ADC_ISR_OVR_Msk                         /*!< ADC group regular overrun flag */
814 #define ADC_ISR_AWD1_Pos               (7U)
815 #define ADC_ISR_AWD1_Msk               (0x1UL << ADC_ISR_AWD1_Pos)             /*!< 0x00000080 */
816 #define ADC_ISR_AWD1                   ADC_ISR_AWD1_Msk                        /*!< ADC analog watchdog 1 flag */
817 #define ADC_ISR_AWD2_Pos               (8U)
818 #define ADC_ISR_AWD2_Msk               (0x1UL << ADC_ISR_AWD2_Pos)             /*!< 0x00000100 */
819 #define ADC_ISR_AWD2                   ADC_ISR_AWD2_Msk                        /*!< ADC analog watchdog 2 flag */
820 #define ADC_ISR_AWD3_Pos               (9U)
821 #define ADC_ISR_AWD3_Msk               (0x1UL << ADC_ISR_AWD3_Pos)             /*!< 0x00000200 */
822 #define ADC_ISR_AWD3                   ADC_ISR_AWD3_Msk                        /*!< ADC analog watchdog 3 flag */
823 #define ADC_ISR_EOCAL_Pos              (11U)
824 #define ADC_ISR_EOCAL_Msk              (0x1UL << ADC_ISR_EOCAL_Pos)            /*!< 0x00000800 */
825 #define ADC_ISR_EOCAL                  ADC_ISR_EOCAL_Msk                       /*!< ADC end of calibration flag */
826 #define ADC_ISR_CCRDY_Pos              (13U)
827 #define ADC_ISR_CCRDY_Msk              (0x1UL << ADC_ISR_CCRDY_Pos)            /*!< 0x00002000 */
828 #define ADC_ISR_CCRDY                  ADC_ISR_CCRDY_Msk                       /*!< ADC channel configuration ready flag */
829 
830 /* Legacy defines */
831 #define ADC_ISR_EOSEQ           (ADC_ISR_EOS)
832 
833 /********************  Bit definition for ADC_IER register  *******************/
834 #define ADC_IER_ADRDYIE_Pos            (0U)
835 #define ADC_IER_ADRDYIE_Msk            (0x1UL << ADC_IER_ADRDYIE_Pos)          /*!< 0x00000001 */
836 #define ADC_IER_ADRDYIE                ADC_IER_ADRDYIE_Msk                     /*!< ADC ready interrupt */
837 #define ADC_IER_EOSMPIE_Pos            (1U)
838 #define ADC_IER_EOSMPIE_Msk            (0x1UL << ADC_IER_EOSMPIE_Pos)          /*!< 0x00000002 */
839 #define ADC_IER_EOSMPIE                ADC_IER_EOSMPIE_Msk                     /*!< ADC group regular end of sampling interrupt */
840 #define ADC_IER_EOCIE_Pos              (2U)
841 #define ADC_IER_EOCIE_Msk              (0x1UL << ADC_IER_EOCIE_Pos)            /*!< 0x00000004 */
842 #define ADC_IER_EOCIE                  ADC_IER_EOCIE_Msk                       /*!< ADC group regular end of unitary conversion interrupt */
843 #define ADC_IER_EOSIE_Pos              (3U)
844 #define ADC_IER_EOSIE_Msk              (0x1UL << ADC_IER_EOSIE_Pos)            /*!< 0x00000008 */
845 #define ADC_IER_EOSIE                  ADC_IER_EOSIE_Msk                       /*!< ADC group regular end of sequence conversions interrupt */
846 #define ADC_IER_OVRIE_Pos              (4U)
847 #define ADC_IER_OVRIE_Msk              (0x1UL << ADC_IER_OVRIE_Pos)            /*!< 0x00000010 */
848 #define ADC_IER_OVRIE                  ADC_IER_OVRIE_Msk                       /*!< ADC group regular overrun interrupt */
849 #define ADC_IER_AWD1IE_Pos             (7U)
850 #define ADC_IER_AWD1IE_Msk             (0x1UL << ADC_IER_AWD1IE_Pos)           /*!< 0x00000080 */
851 #define ADC_IER_AWD1IE                 ADC_IER_AWD1IE_Msk                      /*!< ADC analog watchdog 1 interrupt */
852 #define ADC_IER_AWD2IE_Pos             (8U)
853 #define ADC_IER_AWD2IE_Msk             (0x1UL << ADC_IER_AWD2IE_Pos)           /*!< 0x00000100 */
854 #define ADC_IER_AWD2IE                 ADC_IER_AWD2IE_Msk                      /*!< ADC analog watchdog 2 interrupt */
855 #define ADC_IER_AWD3IE_Pos             (9U)
856 #define ADC_IER_AWD3IE_Msk             (0x1UL << ADC_IER_AWD3IE_Pos)           /*!< 0x00000200 */
857 #define ADC_IER_AWD3IE                 ADC_IER_AWD3IE_Msk                      /*!< ADC analog watchdog 3 interrupt */
858 #define ADC_IER_EOCALIE_Pos            (11U)
859 #define ADC_IER_EOCALIE_Msk            (0x1UL << ADC_IER_EOCALIE_Pos)          /*!< 0x00000800 */
860 #define ADC_IER_EOCALIE                ADC_IER_EOCALIE_Msk                     /*!< ADC end of calibration interrupt */
861 #define ADC_IER_CCRDYIE_Pos            (13U)
862 #define ADC_IER_CCRDYIE_Msk            (0x1UL << ADC_IER_CCRDYIE_Pos)          /*!< 0x00002000 */
863 #define ADC_IER_CCRDYIE                ADC_IER_CCRDYIE_Msk                     /*!< ADC channel configuration ready interrupt */
864 
865 /* Legacy defines */
866 #define ADC_IER_EOSEQIE           (ADC_IER_EOSIE)
867 
868 /********************  Bit definition for ADC_CR register  ********************/
869 #define ADC_CR_ADEN_Pos                (0U)
870 #define ADC_CR_ADEN_Msk                (0x1UL << ADC_CR_ADEN_Pos)              /*!< 0x00000001 */
871 #define ADC_CR_ADEN                    ADC_CR_ADEN_Msk                         /*!< ADC enable */
872 #define ADC_CR_ADDIS_Pos               (1U)
873 #define ADC_CR_ADDIS_Msk               (0x1UL << ADC_CR_ADDIS_Pos)             /*!< 0x00000002 */
874 #define ADC_CR_ADDIS                   ADC_CR_ADDIS_Msk                        /*!< ADC disable */
875 #define ADC_CR_ADSTART_Pos             (2U)
876 #define ADC_CR_ADSTART_Msk             (0x1UL << ADC_CR_ADSTART_Pos)           /*!< 0x00000004 */
877 #define ADC_CR_ADSTART                 ADC_CR_ADSTART_Msk                      /*!< ADC group regular conversion start */
878 #define ADC_CR_ADSTP_Pos               (4U)
879 #define ADC_CR_ADSTP_Msk               (0x1UL << ADC_CR_ADSTP_Pos)             /*!< 0x00000010 */
880 #define ADC_CR_ADSTP                   ADC_CR_ADSTP_Msk                        /*!< ADC group regular conversion stop */
881 #define ADC_CR_ADVREGEN_Pos            (28U)
882 #define ADC_CR_ADVREGEN_Msk            (0x1UL << ADC_CR_ADVREGEN_Pos)          /*!< 0x10000000 */
883 #define ADC_CR_ADVREGEN                ADC_CR_ADVREGEN_Msk                     /*!< ADC voltage regulator enable */
884 #define ADC_CR_ADCAL_Pos               (31U)
885 #define ADC_CR_ADCAL_Msk               (0x1UL << ADC_CR_ADCAL_Pos)             /*!< 0x80000000 */
886 #define ADC_CR_ADCAL                   ADC_CR_ADCAL_Msk                        /*!< ADC calibration */
887 
888 /********************  Bit definition for ADC_CFGR1 register  *****************/
889 #define ADC_CFGR1_DMAEN_Pos            (0U)
890 #define ADC_CFGR1_DMAEN_Msk            (0x1UL << ADC_CFGR1_DMAEN_Pos)          /*!< 0x00000001 */
891 #define ADC_CFGR1_DMAEN                ADC_CFGR1_DMAEN_Msk                     /*!< ADC DMA transfer enable */
892 #define ADC_CFGR1_DMACFG_Pos           (1U)
893 #define ADC_CFGR1_DMACFG_Msk           (0x1UL << ADC_CFGR1_DMACFG_Pos)         /*!< 0x00000002 */
894 #define ADC_CFGR1_DMACFG               ADC_CFGR1_DMACFG_Msk                    /*!< ADC DMA transfer configuration */
895 
896 #define ADC_CFGR1_SCANDIR_Pos          (2U)
897 #define ADC_CFGR1_SCANDIR_Msk          (0x1UL << ADC_CFGR1_SCANDIR_Pos)        /*!< 0x00000004 */
898 #define ADC_CFGR1_SCANDIR              ADC_CFGR1_SCANDIR_Msk                   /*!< ADC group regular sequencer scan direction */
899 
900 #define ADC_CFGR1_RES_Pos              (3U)
901 #define ADC_CFGR1_RES_Msk              (0x3UL << ADC_CFGR1_RES_Pos)            /*!< 0x00000018 */
902 #define ADC_CFGR1_RES                  ADC_CFGR1_RES_Msk                       /*!< ADC data resolution */
903 #define ADC_CFGR1_RES_0                (0x1U << ADC_CFGR1_RES_Pos)             /*!< 0x00000008 */
904 #define ADC_CFGR1_RES_1                (0x2U << ADC_CFGR1_RES_Pos)             /*!< 0x00000010 */
905 
906 #define ADC_CFGR1_ALIGN_Pos            (5U)
907 #define ADC_CFGR1_ALIGN_Msk            (0x1UL << ADC_CFGR1_ALIGN_Pos)          /*!< 0x00000020 */
908 #define ADC_CFGR1_ALIGN                ADC_CFGR1_ALIGN_Msk                     /*!< ADC data alignment */
909 
910 #define ADC_CFGR1_EXTSEL_Pos           (6U)
911 #define ADC_CFGR1_EXTSEL_Msk           (0x7UL << ADC_CFGR1_EXTSEL_Pos)         /*!< 0x000001C0 */
912 #define ADC_CFGR1_EXTSEL               ADC_CFGR1_EXTSEL_Msk                    /*!< ADC group regular external trigger source */
913 #define ADC_CFGR1_EXTSEL_0             (0x1UL << ADC_CFGR1_EXTSEL_Pos)         /*!< 0x00000040 */
914 #define ADC_CFGR1_EXTSEL_1             (0x2UL << ADC_CFGR1_EXTSEL_Pos)         /*!< 0x00000080 */
915 #define ADC_CFGR1_EXTSEL_2             (0x4UL << ADC_CFGR1_EXTSEL_Pos)         /*!< 0x00000100 */
916 
917 #define ADC_CFGR1_EXTEN_Pos            (10U)
918 #define ADC_CFGR1_EXTEN_Msk            (0x3UL << ADC_CFGR1_EXTEN_Pos)          /*!< 0x00000C00 */
919 #define ADC_CFGR1_EXTEN                ADC_CFGR1_EXTEN_Msk                     /*!< ADC group regular external trigger polarity */
920 #define ADC_CFGR1_EXTEN_0              (0x1UL << ADC_CFGR1_EXTEN_Pos)          /*!< 0x00000400 */
921 #define ADC_CFGR1_EXTEN_1              (0x2UL << ADC_CFGR1_EXTEN_Pos)          /*!< 0x00000800 */
922 
923 #define ADC_CFGR1_OVRMOD_Pos           (12U)
924 #define ADC_CFGR1_OVRMOD_Msk           (0x1UL << ADC_CFGR1_OVRMOD_Pos)         /*!< 0x00001000 */
925 #define ADC_CFGR1_OVRMOD               ADC_CFGR1_OVRMOD_Msk                    /*!< ADC group regular overrun configuration */
926 #define ADC_CFGR1_CONT_Pos             (13U)
927 #define ADC_CFGR1_CONT_Msk             (0x1UL << ADC_CFGR1_CONT_Pos)           /*!< 0x00002000 */
928 #define ADC_CFGR1_CONT                 ADC_CFGR1_CONT_Msk                      /*!< ADC group regular continuous conversion mode */
929 #define ADC_CFGR1_WAIT_Pos             (14U)
930 #define ADC_CFGR1_WAIT_Msk             (0x1UL << ADC_CFGR1_WAIT_Pos)           /*!< 0x00004000 */
931 #define ADC_CFGR1_WAIT                 ADC_CFGR1_WAIT_Msk                      /*!< ADC low power auto wait */
932 #define ADC_CFGR1_AUTOFF_Pos           (15U)
933 #define ADC_CFGR1_AUTOFF_Msk           (0x1UL << ADC_CFGR1_AUTOFF_Pos)         /*!< 0x00008000 */
934 #define ADC_CFGR1_AUTOFF               ADC_CFGR1_AUTOFF_Msk                    /*!< ADC low power auto power off */
935 #define ADC_CFGR1_DISCEN_Pos           (16U)
936 #define ADC_CFGR1_DISCEN_Msk           (0x1UL << ADC_CFGR1_DISCEN_Pos)         /*!< 0x00010000 */
937 #define ADC_CFGR1_DISCEN               ADC_CFGR1_DISCEN_Msk                    /*!< ADC group regular sequencer discontinuous mode */
938 #define ADC_CFGR1_CHSELRMOD_Pos        (21U)
939 #define ADC_CFGR1_CHSELRMOD_Msk        (0x1UL << ADC_CFGR1_CHSELRMOD_Pos)      /*!< 0x00200000 */
940 #define ADC_CFGR1_CHSELRMOD            ADC_CFGR1_CHSELRMOD_Msk                 /*!< ADC group regular sequencer mode */
941 
942 #define ADC_CFGR1_AWD1SGL_Pos          (22U)
943 #define ADC_CFGR1_AWD1SGL_Msk          (0x1UL << ADC_CFGR1_AWD1SGL_Pos)        /*!< 0x00400000 */
944 #define ADC_CFGR1_AWD1SGL              ADC_CFGR1_AWD1SGL_Msk                   /*!< ADC analog watchdog 1 monitoring a single channel or all channels */
945 #define ADC_CFGR1_AWD1EN_Pos           (23U)
946 #define ADC_CFGR1_AWD1EN_Msk           (0x1UL << ADC_CFGR1_AWD1EN_Pos)         /*!< 0x00800000 */
947 #define ADC_CFGR1_AWD1EN               ADC_CFGR1_AWD1EN_Msk                    /*!< ADC analog watchdog 1 enable on scope ADC group regular */
948 
949 #define ADC_CFGR1_AWD1CH_Pos           (26U)
950 #define ADC_CFGR1_AWD1CH_Msk           (0x1FUL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x7C000000 */
951 #define ADC_CFGR1_AWD1CH               ADC_CFGR1_AWD1CH_Msk                    /*!< ADC analog watchdog 1 monitored channel selection */
952 #define ADC_CFGR1_AWD1CH_0             (0x01UL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x04000000 */
953 #define ADC_CFGR1_AWD1CH_1             (0x02UL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x08000000 */
954 #define ADC_CFGR1_AWD1CH_2             (0x04UL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x10000000 */
955 #define ADC_CFGR1_AWD1CH_3             (0x08UL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x20000000 */
956 #define ADC_CFGR1_AWD1CH_4             (0x10UL << ADC_CFGR1_AWD1CH_Pos)        /*!< 0x40000000 */
957 
958 /* Legacy defines */
959 #define ADC_CFGR1_AUTDLY          (ADC_CFGR1_WAIT)
960 
961 /********************  Bit definition for ADC_CFGR2 register  *****************/
962 #define ADC_CFGR2_OVSE_Pos             (0U)
963 #define ADC_CFGR2_OVSE_Msk             (0x1UL << ADC_CFGR2_OVSE_Pos)           /*!< 0x00000001 */
964 #define ADC_CFGR2_OVSE                 ADC_CFGR2_OVSE_Msk                      /*!< ADC oversampler enable on scope ADC group regular */
965 
966 #define ADC_CFGR2_OVSR_Pos             (2U)
967 #define ADC_CFGR2_OVSR_Msk             (0x7UL << ADC_CFGR2_OVSR_Pos)           /*!< 0x0000001C */
968 #define ADC_CFGR2_OVSR                 ADC_CFGR2_OVSR_Msk                      /*!< ADC oversampling ratio */
969 #define ADC_CFGR2_OVSR_0               (0x1UL << ADC_CFGR2_OVSR_Pos)           /*!< 0x00000004 */
970 #define ADC_CFGR2_OVSR_1               (0x2UL << ADC_CFGR2_OVSR_Pos)           /*!< 0x00000008 */
971 #define ADC_CFGR2_OVSR_2               (0x4UL << ADC_CFGR2_OVSR_Pos)           /*!< 0x00000010 */
972 
973 #define ADC_CFGR2_OVSS_Pos             (5U)
974 #define ADC_CFGR2_OVSS_Msk             (0xFUL << ADC_CFGR2_OVSS_Pos)           /*!< 0x000001E0 */
975 #define ADC_CFGR2_OVSS                 ADC_CFGR2_OVSS_Msk                      /*!< ADC oversampling shift */
976 #define ADC_CFGR2_OVSS_0               (0x1UL << ADC_CFGR2_OVSS_Pos)           /*!< 0x00000020 */
977 #define ADC_CFGR2_OVSS_1               (0x2UL << ADC_CFGR2_OVSS_Pos)           /*!< 0x00000040 */
978 #define ADC_CFGR2_OVSS_2               (0x4UL << ADC_CFGR2_OVSS_Pos)           /*!< 0x00000080 */
979 #define ADC_CFGR2_OVSS_3               (0x8UL << ADC_CFGR2_OVSS_Pos)           /*!< 0x00000100 */
980 
981 #define ADC_CFGR2_TOVS_Pos             (9U)
982 #define ADC_CFGR2_TOVS_Msk             (0x1UL << ADC_CFGR2_TOVS_Pos)           /*!< 0x00000200 */
983 #define ADC_CFGR2_TOVS                 ADC_CFGR2_TOVS_Msk                      /*!< ADC oversampling discontinuous mode (triggered mode) for ADC group regular */
984 
985 #define ADC_CFGR2_LFTRIG_Pos           (29U)
986 #define ADC_CFGR2_LFTRIG_Msk           (0x1UL << ADC_CFGR2_LFTRIG_Pos)         /*!< 0x20000000 */
987 #define ADC_CFGR2_LFTRIG               ADC_CFGR2_LFTRIG_Msk                    /*!< ADC low frequency trigger mode */
988 
989 #define ADC_CFGR2_CKMODE_Pos           (30U)
990 #define ADC_CFGR2_CKMODE_Msk           (0x3UL << ADC_CFGR2_CKMODE_Pos)         /*!< 0xC0000000 */
991 #define ADC_CFGR2_CKMODE               ADC_CFGR2_CKMODE_Msk                    /*!< ADC clock source and prescaler (prescaler only for clock source synchronous) */
992 #define ADC_CFGR2_CKMODE_1             (0x2UL << ADC_CFGR2_CKMODE_Pos)         /*!< 0x80000000 */
993 #define ADC_CFGR2_CKMODE_0             (0x1UL << ADC_CFGR2_CKMODE_Pos)         /*!< 0x40000000 */
994 
995 /********************  Bit definition for ADC_SMPR register  ******************/
996 #define ADC_SMPR_SMP1_Pos              (0U)
997 #define ADC_SMPR_SMP1_Msk              (0x7UL << ADC_SMPR_SMP1_Pos)            /*!< 0x00000007 */
998 #define ADC_SMPR_SMP1                  ADC_SMPR_SMP1_Msk                       /*!< ADC group of channels sampling time 1 */
999 #define ADC_SMPR_SMP1_0                (0x1UL << ADC_SMPR_SMP1_Pos)            /*!< 0x00000001 */
1000 #define ADC_SMPR_SMP1_1                (0x2UL << ADC_SMPR_SMP1_Pos)            /*!< 0x00000002 */
1001 #define ADC_SMPR_SMP1_2                (0x4UL << ADC_SMPR_SMP1_Pos)            /*!< 0x00000004 */
1002 
1003 #define ADC_SMPR_SMP2_Pos              (4U)
1004 #define ADC_SMPR_SMP2_Msk              (0x7UL << ADC_SMPR_SMP2_Pos)            /*!< 0x00000070 */
1005 #define ADC_SMPR_SMP2                  ADC_SMPR_SMP2_Msk                       /*!< ADC group of channels sampling time 2 */
1006 #define ADC_SMPR_SMP2_0                (0x1UL << ADC_SMPR_SMP2_Pos)            /*!< 0x00000010 */
1007 #define ADC_SMPR_SMP2_1                (0x2UL << ADC_SMPR_SMP2_Pos)            /*!< 0x00000020 */
1008 #define ADC_SMPR_SMP2_2                (0x4UL << ADC_SMPR_SMP2_Pos)            /*!< 0x00000040 */
1009 
1010 #define ADC_SMPR_SMPSEL_Pos            (8U)
1011 #define ADC_SMPR_SMPSEL_Msk            (0x7FFFFUL << ADC_SMPR_SMPSEL_Pos)      /*!< 0x07FFFF00 */
1012 #define ADC_SMPR_SMPSEL                ADC_SMPR_SMPSEL_Msk                     /*!< ADC all channels sampling time selection */
1013 #define ADC_SMPR_SMPSEL0_Pos           (8U)
1014 #define ADC_SMPR_SMPSEL0_Msk           (0x1UL << ADC_SMPR_SMPSEL0_Pos)         /*!< 0x00000100 */
1015 #define ADC_SMPR_SMPSEL0               ADC_SMPR_SMPSEL0_Msk                    /*!< ADC channel 0 sampling time selection */
1016 #define ADC_SMPR_SMPSEL1_Pos           (9U)
1017 #define ADC_SMPR_SMPSEL1_Msk           (0x1UL << ADC_SMPR_SMPSEL1_Pos)         /*!< 0x00000200 */
1018 #define ADC_SMPR_SMPSEL1               ADC_SMPR_SMPSEL1_Msk                    /*!< ADC channel 1 sampling time selection */
1019 #define ADC_SMPR_SMPSEL2_Pos           (10U)
1020 #define ADC_SMPR_SMPSEL2_Msk           (0x1UL << ADC_SMPR_SMPSEL2_Pos)         /*!< 0x00000400 */
1021 #define ADC_SMPR_SMPSEL2               ADC_SMPR_SMPSEL2_Msk                    /*!< ADC channel 2 sampling time selection */
1022 #define ADC_SMPR_SMPSEL3_Pos           (11U)
1023 #define ADC_SMPR_SMPSEL3_Msk           (0x1UL << ADC_SMPR_SMPSEL3_Pos)         /*!< 0x00000800 */
1024 #define ADC_SMPR_SMPSEL3               ADC_SMPR_SMPSEL3_Msk                    /*!< ADC channel 3 sampling time selection */
1025 #define ADC_SMPR_SMPSEL4_Pos           (12U)
1026 #define ADC_SMPR_SMPSEL4_Msk           (0x1UL << ADC_SMPR_SMPSEL4_Pos)         /*!< 0x00001000 */
1027 #define ADC_SMPR_SMPSEL4               ADC_SMPR_SMPSEL4_Msk                    /*!< ADC channel 4 sampling time selection */
1028 #define ADC_SMPR_SMPSEL5_Pos           (13U)
1029 #define ADC_SMPR_SMPSEL5_Msk           (0x1UL << ADC_SMPR_SMPSEL5_Pos)         /*!< 0x00002000 */
1030 #define ADC_SMPR_SMPSEL5               ADC_SMPR_SMPSEL5_Msk                    /*!< ADC channel 5 sampling time selection */
1031 #define ADC_SMPR_SMPSEL6_Pos           (14U)
1032 #define ADC_SMPR_SMPSEL6_Msk           (0x1UL << ADC_SMPR_SMPSEL6_Pos)         /*!< 0x00004000 */
1033 #define ADC_SMPR_SMPSEL6               ADC_SMPR_SMPSEL6_Msk                    /*!< ADC channel 6 sampling time selection */
1034 #define ADC_SMPR_SMPSEL7_Pos           (15U)
1035 #define ADC_SMPR_SMPSEL7_Msk           (0x1UL << ADC_SMPR_SMPSEL7_Pos)         /*!< 0x00008000 */
1036 #define ADC_SMPR_SMPSEL7               ADC_SMPR_SMPSEL7_Msk                    /*!< ADC channel 7 sampling time selection */
1037 #define ADC_SMPR_SMPSEL8_Pos           (16U)
1038 #define ADC_SMPR_SMPSEL8_Msk           (0x1UL << ADC_SMPR_SMPSEL8_Pos)         /*!< 0x00010000 */
1039 #define ADC_SMPR_SMPSEL8               ADC_SMPR_SMPSEL8_Msk                    /*!< ADC channel 8 sampling time selection */
1040 #define ADC_SMPR_SMPSEL9_Pos           (17U)
1041 #define ADC_SMPR_SMPSEL9_Msk           (0x1UL << ADC_SMPR_SMPSEL9_Pos)         /*!< 0x00020000 */
1042 #define ADC_SMPR_SMPSEL9               ADC_SMPR_SMPSEL9_Msk                    /*!< ADC channel 9 sampling time selection */
1043 #define ADC_SMPR_SMPSEL10_Pos          (18U)
1044 #define ADC_SMPR_SMPSEL10_Msk          (0x1UL << ADC_SMPR_SMPSEL10_Pos)        /*!< 0x00040000 */
1045 #define ADC_SMPR_SMPSEL10              ADC_SMPR_SMPSEL10_Msk                   /*!< ADC channel 10 sampling time selection */
1046 #define ADC_SMPR_SMPSEL11_Pos          (19U)
1047 #define ADC_SMPR_SMPSEL11_Msk          (0x1UL << ADC_SMPR_SMPSEL11_Pos)        /*!< 0x00080000 */
1048 #define ADC_SMPR_SMPSEL11              ADC_SMPR_SMPSEL11_Msk                   /*!< ADC channel 11 sampling time selection */
1049 #define ADC_SMPR_SMPSEL12_Pos          (20U)
1050 #define ADC_SMPR_SMPSEL12_Msk          (0x1UL << ADC_SMPR_SMPSEL12_Pos)        /*!< 0x00100000 */
1051 #define ADC_SMPR_SMPSEL12              ADC_SMPR_SMPSEL12_Msk                   /*!< ADC channel 12 sampling time selection */
1052 #define ADC_SMPR_SMPSEL13_Pos          (21U)
1053 #define ADC_SMPR_SMPSEL13_Msk          (0x1UL << ADC_SMPR_SMPSEL13_Pos)        /*!< 0x00200000 */
1054 #define ADC_SMPR_SMPSEL13              ADC_SMPR_SMPSEL13_Msk                   /*!< ADC channel 13 sampling time selection */
1055 #define ADC_SMPR_SMPSEL14_Pos          (22U)
1056 #define ADC_SMPR_SMPSEL14_Msk          (0x1UL << ADC_SMPR_SMPSEL14_Pos)        /*!< 0x00400000 */
1057 #define ADC_SMPR_SMPSEL14              ADC_SMPR_SMPSEL14_Msk                   /*!< ADC channel 14 sampling time selection */
1058 #define ADC_SMPR_SMPSEL15_Pos          (23U)
1059 #define ADC_SMPR_SMPSEL15_Msk          (0x1UL << ADC_SMPR_SMPSEL15_Pos)        /*!< 0x00800000 */
1060 #define ADC_SMPR_SMPSEL15              ADC_SMPR_SMPSEL15_Msk                   /*!< ADC channel 15 sampling time selection */
1061 #define ADC_SMPR_SMPSEL16_Pos          (24U)
1062 #define ADC_SMPR_SMPSEL16_Msk          (0x1UL << ADC_SMPR_SMPSEL16_Pos)        /*!< 0x01000000 */
1063 #define ADC_SMPR_SMPSEL16              ADC_SMPR_SMPSEL16_Msk                   /*!< ADC channel 16 sampling time selection */
1064 #define ADC_SMPR_SMPSEL17_Pos          (25U)
1065 #define ADC_SMPR_SMPSEL17_Msk          (0x1UL << ADC_SMPR_SMPSEL17_Pos)        /*!< 0x02000000 */
1066 #define ADC_SMPR_SMPSEL17              ADC_SMPR_SMPSEL17_Msk                   /*!< ADC channel 17 sampling time selection */
1067 #define ADC_SMPR_SMPSEL18_Pos          (26U)
1068 #define ADC_SMPR_SMPSEL18_Msk          (0x1UL << ADC_SMPR_SMPSEL18_Pos)        /*!< 0x04000000 */
1069 #define ADC_SMPR_SMPSEL18              ADC_SMPR_SMPSEL18_Msk                   /*!< ADC channel 18 sampling time selection */
1070 
1071 /********************  Bit definition for ADC_AWD1TR register  *******************/
1072 #define ADC_AWD1TR_LT1_Pos                (0U)
1073 #define ADC_AWD1TR_LT1_Msk             (0xFFFUL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000FFF */
1074 #define ADC_AWD1TR_LT1                 ADC_AWD1TR_LT1_Msk                      /*!< ADC analog watchdog 1 threshold low */
1075 #define ADC_AWD1TR_LT1_0               (0x001UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000001 */
1076 #define ADC_AWD1TR_LT1_1               (0x002UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000002 */
1077 #define ADC_AWD1TR_LT1_2               (0x004UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000004 */
1078 #define ADC_AWD1TR_LT1_3               (0x008UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000008 */
1079 #define ADC_AWD1TR_LT1_4               (0x010UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000010 */
1080 #define ADC_AWD1TR_LT1_5               (0x020UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000020 */
1081 #define ADC_AWD1TR_LT1_6               (0x040UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000040 */
1082 #define ADC_AWD1TR_LT1_7               (0x080UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000080 */
1083 #define ADC_AWD1TR_LT1_8               (0x100UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000100 */
1084 #define ADC_AWD1TR_LT1_9               (0x200UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000200 */
1085 #define ADC_AWD1TR_LT1_10              (0x400UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000400 */
1086 #define ADC_AWD1TR_LT1_11              (0x800UL << ADC_AWD1TR_LT1_Pos)         /*!< 0x00000800 */
1087 
1088 #define ADC_AWD1TR_HT1_Pos             (16U)
1089 #define ADC_AWD1TR_HT1_Msk             (0xFFFUL << ADC_AWD1TR_HT1_Pos)         /*!< 0x0FFF0000 */
1090 #define ADC_AWD1TR_HT1                 ADC_AWD1TR_HT1_Msk                      /*!< ADC Analog watchdog 1 threshold high */
1091 #define ADC_AWD1TR_HT1_0               (0x001UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00010000 */
1092 #define ADC_AWD1TR_HT1_1               (0x002UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00020000 */
1093 #define ADC_AWD1TR_HT1_2               (0x004UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00040000 */
1094 #define ADC_AWD1TR_HT1_3               (0x008UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00080000 */
1095 #define ADC_AWD1TR_HT1_4               (0x010UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00100000 */
1096 #define ADC_AWD1TR_HT1_5               (0x020UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00200000 */
1097 #define ADC_AWD1TR_HT1_6               (0x040UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00400000 */
1098 #define ADC_AWD1TR_HT1_7               (0x080UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x00800000 */
1099 #define ADC_AWD1TR_HT1_8               (0x100UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x01000000 */
1100 #define ADC_AWD1TR_HT1_9               (0x200UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x02000000 */
1101 #define ADC_AWD1TR_HT1_10              (0x400UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x04000000 */
1102 #define ADC_AWD1TR_HT1_11              (0x800UL << ADC_AWD1TR_HT1_Pos)         /*!< 0x08000000 */
1103 
1104 /* Legacy definitions */
1105 #define ADC_TR1_LT1             ADC_AWD1TR_LT1
1106 #define ADC_TR1_LT1_0           ADC_AWD1TR_LT1_0
1107 #define ADC_TR1_LT1_1           ADC_AWD1TR_LT1_1
1108 #define ADC_TR1_LT1_2           ADC_AWD1TR_LT1_2
1109 #define ADC_TR1_LT1_3           ADC_AWD1TR_LT1_3
1110 #define ADC_TR1_LT1_4           ADC_AWD1TR_LT1_4
1111 #define ADC_TR1_LT1_5           ADC_AWD1TR_LT1_5
1112 #define ADC_TR1_LT1_6           ADC_AWD1TR_LT1_6
1113 #define ADC_TR1_LT1_7           ADC_AWD1TR_LT1_7
1114 #define ADC_TR1_LT1_8           ADC_AWD1TR_LT1_8
1115 #define ADC_TR1_LT1_9           ADC_AWD1TR_LT1_9
1116 #define ADC_TR1_LT1_10          ADC_AWD1TR_LT1_10
1117 #define ADC_TR1_LT1_11          ADC_AWD1TR_LT1_11
1118 
1119 #define ADC_TR1_HT1             ADC_AWD1TR_HT1
1120 #define ADC_TR1_HT1_0           ADC_AWD1TR_HT1_0
1121 #define ADC_TR1_HT1_1           ADC_AWD1TR_HT1_1
1122 #define ADC_TR1_HT1_2           ADC_AWD1TR_HT1_2
1123 #define ADC_TR1_HT1_3           ADC_AWD1TR_HT1_3
1124 #define ADC_TR1_HT1_4           ADC_AWD1TR_HT1_4
1125 #define ADC_TR1_HT1_5           ADC_AWD1TR_HT1_5
1126 #define ADC_TR1_HT1_6           ADC_AWD1TR_HT1_6
1127 #define ADC_TR1_HT1_7           ADC_AWD1TR_HT1_7
1128 #define ADC_TR1_HT1_8           ADC_AWD1TR_HT1_8
1129 #define ADC_TR1_HT1_9           ADC_AWD1TR_HT1_9
1130 #define ADC_TR1_HT1_10          ADC_AWD1TR_HT1_10
1131 #define ADC_TR1_HT1_11          ADC_AWD1TR_HT1_11
1132 
1133 /********************  Bit definition for ADC_AWD2TR register  *******************/
1134 #define ADC_AWD2TR_LT2_Pos             (0U)
1135 #define ADC_AWD2TR_LT2_Msk             (0xFFFUL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000FFF */
1136 #define ADC_AWD2TR_LT2                 ADC_AWD2TR_LT2_Msk                      /*!< ADC analog watchdog 2 threshold low */
1137 #define ADC_AWD2TR_LT2_0               (0x001UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000001 */
1138 #define ADC_AWD2TR_LT2_1               (0x002UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000002 */
1139 #define ADC_AWD2TR_LT2_2               (0x004UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000004 */
1140 #define ADC_AWD2TR_LT2_3               (0x008UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000008 */
1141 #define ADC_AWD2TR_LT2_4               (0x010UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000010 */
1142 #define ADC_AWD2TR_LT2_5               (0x020UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000020 */
1143 #define ADC_AWD2TR_LT2_6               (0x040UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000040 */
1144 #define ADC_AWD2TR_LT2_7               (0x080UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000080 */
1145 #define ADC_AWD2TR_LT2_8               (0x100UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000100 */
1146 #define ADC_AWD2TR_LT2_9               (0x200UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000200 */
1147 #define ADC_AWD2TR_LT2_10              (0x400UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000400 */
1148 #define ADC_AWD2TR_LT2_11              (0x800UL << ADC_AWD2TR_LT2_Pos)         /*!< 0x00000800 */
1149 
1150 #define ADC_AWD2TR_HT2_Pos             (16U)
1151 #define ADC_AWD2TR_HT2_Msk             (0xFFFUL << ADC_AWD2TR_HT2_Pos)         /*!< 0x0FFF0000 */
1152 #define ADC_AWD2TR_HT2                 ADC_AWD2TR_HT2_Msk                      /*!< ADC analog watchdog 2 threshold high */
1153 #define ADC_AWD2TR_HT2_0               (0x001UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00010000 */
1154 #define ADC_AWD2TR_HT2_1               (0x002UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00020000 */
1155 #define ADC_AWD2TR_HT2_2               (0x004UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00040000 */
1156 #define ADC_AWD2TR_HT2_3               (0x008UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00080000 */
1157 #define ADC_AWD2TR_HT2_4               (0x010UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00100000 */
1158 #define ADC_AWD2TR_HT2_5               (0x020UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00200000 */
1159 #define ADC_AWD2TR_HT2_6               (0x040UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00400000 */
1160 #define ADC_AWD2TR_HT2_7               (0x080UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x00800000 */
1161 #define ADC_AWD2TR_HT2_8               (0x100UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x01000000 */
1162 #define ADC_AWD2TR_HT2_9               (0x200UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x02000000 */
1163 #define ADC_AWD2TR_HT2_10              (0x400UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x04000000 */
1164 #define ADC_AWD2TR_HT2_11              (0x800UL << ADC_AWD2TR_HT2_Pos)         /*!< 0x08000000 */
1165 
1166 /* Legacy definitions */
1167 #define ADC_TR2_LT2             ADC_AWD2TR_LT2
1168 #define ADC_TR2_LT2_0           ADC_AWD2TR_LT2_0
1169 #define ADC_TR2_LT2_1           ADC_AWD2TR_LT2_1
1170 #define ADC_TR2_LT2_2           ADC_AWD2TR_LT2_2
1171 #define ADC_TR2_LT2_3           ADC_AWD2TR_LT2_3
1172 #define ADC_TR2_LT2_4           ADC_AWD2TR_LT2_4
1173 #define ADC_TR2_LT2_5           ADC_AWD2TR_LT2_5
1174 #define ADC_TR2_LT2_6           ADC_AWD2TR_LT2_6
1175 #define ADC_TR2_LT2_7           ADC_AWD2TR_LT2_7
1176 #define ADC_TR2_LT2_8           ADC_AWD2TR_LT2_8
1177 #define ADC_TR2_LT2_9           ADC_AWD2TR_LT2_9
1178 #define ADC_TR2_LT2_10          ADC_AWD2TR_LT2_10
1179 #define ADC_TR2_LT2_11          ADC_AWD2TR_LT2_11
1180 
1181 #define ADC_TR2_HT2             ADC_AWD2TR_HT2
1182 #define ADC_TR2_HT2_0           ADC_AWD2TR_HT2_0
1183 #define ADC_TR2_HT2_1           ADC_AWD2TR_HT2_1
1184 #define ADC_TR2_HT2_2           ADC_AWD2TR_HT2_2
1185 #define ADC_TR2_HT2_3           ADC_AWD2TR_HT2_3
1186 #define ADC_TR2_HT2_4           ADC_AWD2TR_HT2_4
1187 #define ADC_TR2_HT2_5           ADC_AWD2TR_HT2_5
1188 #define ADC_TR2_HT2_6           ADC_AWD2TR_HT2_6
1189 #define ADC_TR2_HT2_7           ADC_AWD2TR_HT2_7
1190 #define ADC_TR2_HT2_8           ADC_AWD2TR_HT2_8
1191 #define ADC_TR2_HT2_9           ADC_AWD2TR_HT2_9
1192 #define ADC_TR2_HT2_10          ADC_AWD2TR_HT2_10
1193 #define ADC_TR2_HT2_11          ADC_AWD2TR_HT2_11
1194 
1195 /********************  Bit definition for ADC_CHSELR register  ****************/
1196 #define ADC_CHSELR_CHSEL_Pos           (0U)
1197 #define ADC_CHSELR_CHSEL_Msk           (0x7FFFFUL << ADC_CHSELR_CHSEL_Pos)     /*!< 0x0007FFFF */
1198 #define ADC_CHSELR_CHSEL               ADC_CHSELR_CHSEL_Msk                    /*!< ADC group regular sequencer channels, available when ADC_CFGR1_CHSELRMOD is reset */
1199 #define ADC_CHSELR_CHSEL18_Pos         (18U)
1200 #define ADC_CHSELR_CHSEL18_Msk         (0x1UL << ADC_CHSELR_CHSEL18_Pos)       /*!< 0x00040000 */
1201 #define ADC_CHSELR_CHSEL18             ADC_CHSELR_CHSEL18_Msk                  /*!< ADC group regular sequencer channel 18, available when ADC_CFGR1_CHSELRMOD is reset */
1202 #define ADC_CHSELR_CHSEL17_Pos         (17U)
1203 #define ADC_CHSELR_CHSEL17_Msk         (0x1UL << ADC_CHSELR_CHSEL17_Pos)       /*!< 0x00020000 */
1204 #define ADC_CHSELR_CHSEL17             ADC_CHSELR_CHSEL17_Msk                  /*!< ADC group regular sequencer channel 17, available when ADC_CFGR1_CHSELRMOD is reset */
1205 #define ADC_CHSELR_CHSEL16_Pos         (16U)
1206 #define ADC_CHSELR_CHSEL16_Msk         (0x1UL << ADC_CHSELR_CHSEL16_Pos)       /*!< 0x00010000 */
1207 #define ADC_CHSELR_CHSEL16             ADC_CHSELR_CHSEL16_Msk                  /*!< ADC group regular sequencer channel 16, available when ADC_CFGR1_CHSELRMOD is reset */
1208 #define ADC_CHSELR_CHSEL15_Pos         (15U)
1209 #define ADC_CHSELR_CHSEL15_Msk         (0x1UL << ADC_CHSELR_CHSEL15_Pos)       /*!< 0x00008000 */
1210 #define ADC_CHSELR_CHSEL15             ADC_CHSELR_CHSEL15_Msk                  /*!< ADC group regular sequencer channel 15, available when ADC_CFGR1_CHSELRMOD is reset */
1211 #define ADC_CHSELR_CHSEL14_Pos         (14U)
1212 #define ADC_CHSELR_CHSEL14_Msk         (0x1UL << ADC_CHSELR_CHSEL14_Pos)       /*!< 0x00004000 */
1213 #define ADC_CHSELR_CHSEL14             ADC_CHSELR_CHSEL14_Msk                  /*!< ADC group regular sequencer channel 14, available when ADC_CFGR1_CHSELRMOD is reset */
1214 #define ADC_CHSELR_CHSEL13_Pos         (13U)
1215 #define ADC_CHSELR_CHSEL13_Msk         (0x1UL << ADC_CHSELR_CHSEL13_Pos)       /*!< 0x00002000 */
1216 #define ADC_CHSELR_CHSEL13             ADC_CHSELR_CHSEL13_Msk                  /*!< ADC group regular sequencer channel 13, available when ADC_CFGR1_CHSELRMOD is reset */
1217 #define ADC_CHSELR_CHSEL12_Pos         (12U)
1218 #define ADC_CHSELR_CHSEL12_Msk         (0x1UL << ADC_CHSELR_CHSEL12_Pos)       /*!< 0x00001000 */
1219 #define ADC_CHSELR_CHSEL12             ADC_CHSELR_CHSEL12_Msk                  /*!< ADC group regular sequencer channel 12, available when ADC_CFGR1_CHSELRMOD is reset */
1220 #define ADC_CHSELR_CHSEL11_Pos         (11U)
1221 #define ADC_CHSELR_CHSEL11_Msk         (0x1UL << ADC_CHSELR_CHSEL11_Pos)       /*!< 0x00000800 */
1222 #define ADC_CHSELR_CHSEL11             ADC_CHSELR_CHSEL11_Msk                  /*!< ADC group regular sequencer channel 11, available when ADC_CFGR1_CHSELRMOD is reset */
1223 #define ADC_CHSELR_CHSEL10_Pos         (10U)
1224 #define ADC_CHSELR_CHSEL10_Msk         (0x1UL << ADC_CHSELR_CHSEL10_Pos)       /*!< 0x00000400 */
1225 #define ADC_CHSELR_CHSEL10             ADC_CHSELR_CHSEL10_Msk                  /*!< ADC group regular sequencer channel 10, available when ADC_CFGR1_CHSELRMOD is reset */
1226 #define ADC_CHSELR_CHSEL9_Pos          (9U)
1227 #define ADC_CHSELR_CHSEL9_Msk          (0x1UL << ADC_CHSELR_CHSEL9_Pos)        /*!< 0x00000200 */
1228 #define ADC_CHSELR_CHSEL9              ADC_CHSELR_CHSEL9_Msk                   /*!< ADC group regular sequencer channel 9, available when ADC_CFGR1_CHSELRMOD is reset */
1229 #define ADC_CHSELR_CHSEL8_Pos          (8U)
1230 #define ADC_CHSELR_CHSEL8_Msk          (0x1UL << ADC_CHSELR_CHSEL8_Pos)        /*!< 0x00000100 */
1231 #define ADC_CHSELR_CHSEL8              ADC_CHSELR_CHSEL8_Msk                   /*!< ADC group regular sequencer channel 8, available when ADC_CFGR1_CHSELRMOD is reset */
1232 #define ADC_CHSELR_CHSEL7_Pos          (7U)
1233 #define ADC_CHSELR_CHSEL7_Msk          (0x1UL << ADC_CHSELR_CHSEL7_Pos)        /*!< 0x00000080 */
1234 #define ADC_CHSELR_CHSEL7              ADC_CHSELR_CHSEL7_Msk                   /*!< ADC group regular sequencer channel 7, available when ADC_CFGR1_CHSELRMOD is reset */
1235 #define ADC_CHSELR_CHSEL6_Pos          (6U)
1236 #define ADC_CHSELR_CHSEL6_Msk          (0x1UL << ADC_CHSELR_CHSEL6_Pos)        /*!< 0x00000040 */
1237 #define ADC_CHSELR_CHSEL6              ADC_CHSELR_CHSEL6_Msk                   /*!< ADC group regular sequencer channel 6, available when ADC_CFGR1_CHSELRMOD is reset */
1238 #define ADC_CHSELR_CHSEL5_Pos          (5U)
1239 #define ADC_CHSELR_CHSEL5_Msk          (0x1UL << ADC_CHSELR_CHSEL5_Pos)        /*!< 0x00000020 */
1240 #define ADC_CHSELR_CHSEL5              ADC_CHSELR_CHSEL5_Msk                   /*!< ADC group regular sequencer channel 5, available when ADC_CFGR1_CHSELRMOD is reset */
1241 #define ADC_CHSELR_CHSEL4_Pos          (4U)
1242 #define ADC_CHSELR_CHSEL4_Msk          (0x1UL << ADC_CHSELR_CHSEL4_Pos)        /*!< 0x00000010 */
1243 #define ADC_CHSELR_CHSEL4              ADC_CHSELR_CHSEL4_Msk                   /*!< ADC group regular sequencer channel 4, available when ADC_CFGR1_CHSELRMOD is reset */
1244 #define ADC_CHSELR_CHSEL3_Pos          (3U)
1245 #define ADC_CHSELR_CHSEL3_Msk          (0x1UL << ADC_CHSELR_CHSEL3_Pos)        /*!< 0x00000008 */
1246 #define ADC_CHSELR_CHSEL3              ADC_CHSELR_CHSEL3_Msk                   /*!< ADC group regular sequencer channel 3, available when ADC_CFGR1_CHSELRMOD is reset */
1247 #define ADC_CHSELR_CHSEL2_Pos          (2U)
1248 #define ADC_CHSELR_CHSEL2_Msk          (0x1UL << ADC_CHSELR_CHSEL2_Pos)        /*!< 0x00000004 */
1249 #define ADC_CHSELR_CHSEL2              ADC_CHSELR_CHSEL2_Msk                   /*!< ADC group regular sequencer channel 2, available when ADC_CFGR1_CHSELRMOD is reset */
1250 #define ADC_CHSELR_CHSEL1_Pos          (1U)
1251 #define ADC_CHSELR_CHSEL1_Msk          (0x1UL << ADC_CHSELR_CHSEL1_Pos)        /*!< 0x00000002 */
1252 #define ADC_CHSELR_CHSEL1              ADC_CHSELR_CHSEL1_Msk                   /*!< ADC group regular sequencer channel 1, available when ADC_CFGR1_CHSELRMOD is reset */
1253 #define ADC_CHSELR_CHSEL0_Pos          (0U)
1254 #define ADC_CHSELR_CHSEL0_Msk          (0x1UL << ADC_CHSELR_CHSEL0_Pos)        /*!< 0x00000001 */
1255 #define ADC_CHSELR_CHSEL0              ADC_CHSELR_CHSEL0_Msk                   /*!< ADC group regular sequencer channel 0, available when ADC_CFGR1_CHSELRMOD is reset */
1256 
1257 #define ADC_CHSELR_SQ_ALL_Pos          (0U)
1258 #define ADC_CHSELR_SQ_ALL_Msk          (0xFFFFFFFFUL << ADC_CHSELR_SQ_ALL_Pos) /*!< 0xFFFFFFFF */
1259 #define ADC_CHSELR_SQ_ALL              ADC_CHSELR_SQ_ALL_Msk                   /*!< ADC group regular sequencer all ranks, available when ADC_CFGR1_CHSELRMOD is set */
1260 
1261 #define ADC_CHSELR_SQ8_Pos             (28U)
1262 #define ADC_CHSELR_SQ8_Msk             (0xFUL << ADC_CHSELR_SQ8_Pos)           /*!< 0xF0000000 */
1263 #define ADC_CHSELR_SQ8                 ADC_CHSELR_SQ8_Msk                      /*!< ADC group regular sequencer rank 8, available when ADC_CFGR1_CHSELRMOD is set */
1264 #define ADC_CHSELR_SQ8_0               (0x1UL << ADC_CHSELR_SQ8_Pos)           /*!< 0x10000000 */
1265 #define ADC_CHSELR_SQ8_1               (0x2UL << ADC_CHSELR_SQ8_Pos)           /*!< 0x20000000 */
1266 #define ADC_CHSELR_SQ8_2               (0x4UL << ADC_CHSELR_SQ8_Pos)           /*!< 0x40000000 */
1267 #define ADC_CHSELR_SQ8_3               (0x8UL << ADC_CHSELR_SQ8_Pos)           /*!< 0x80000000 */
1268 
1269 #define ADC_CHSELR_SQ7_Pos             (24U)
1270 #define ADC_CHSELR_SQ7_Msk             (0xFUL << ADC_CHSELR_SQ7_Pos)           /*!< 0x0F000000 */
1271 #define ADC_CHSELR_SQ7                 ADC_CHSELR_SQ7_Msk                      /*!< ADC group regular sequencer rank 7, available when ADC_CFGR1_CHSELRMOD is set */
1272 #define ADC_CHSELR_SQ7_0               (0x1UL << ADC_CHSELR_SQ7_Pos)           /*!< 0x01000000 */
1273 #define ADC_CHSELR_SQ7_1               (0x2UL << ADC_CHSELR_SQ7_Pos)           /*!< 0x02000000 */
1274 #define ADC_CHSELR_SQ7_2               (0x4UL << ADC_CHSELR_SQ7_Pos)           /*!< 0x04000000 */
1275 #define ADC_CHSELR_SQ7_3               (0x8UL << ADC_CHSELR_SQ7_Pos)           /*!< 0x08000000 */
1276 
1277 #define ADC_CHSELR_SQ6_Pos             (20U)
1278 #define ADC_CHSELR_SQ6_Msk             (0xFUL << ADC_CHSELR_SQ6_Pos)           /*!< 0x00F00000 */
1279 #define ADC_CHSELR_SQ6                 ADC_CHSELR_SQ6_Msk                      /*!< ADC group regular sequencer rank 6, available when ADC_CFGR1_CHSELRMOD is set */
1280 #define ADC_CHSELR_SQ6_0               (0x1UL << ADC_CHSELR_SQ6_Pos)           /*!< 0x00100000 */
1281 #define ADC_CHSELR_SQ6_1               (0x2UL << ADC_CHSELR_SQ6_Pos)           /*!< 0x00200000 */
1282 #define ADC_CHSELR_SQ6_2               (0x4UL << ADC_CHSELR_SQ6_Pos)           /*!< 0x00400000 */
1283 #define ADC_CHSELR_SQ6_3               (0x8UL << ADC_CHSELR_SQ6_Pos)           /*!< 0x00800000 */
1284 
1285 #define ADC_CHSELR_SQ5_Pos             (16U)
1286 #define ADC_CHSELR_SQ5_Msk             (0xFUL << ADC_CHSELR_SQ5_Pos)           /*!< 0x000F0000 */
1287 #define ADC_CHSELR_SQ5                 ADC_CHSELR_SQ5_Msk                      /*!< ADC group regular sequencer rank 5, available when ADC_CFGR1_CHSELRMOD is set */
1288 #define ADC_CHSELR_SQ5_0               (0x1UL << ADC_CHSELR_SQ5_Pos)           /*!< 0x00010000 */
1289 #define ADC_CHSELR_SQ5_1               (0x2UL << ADC_CHSELR_SQ5_Pos)           /*!< 0x00020000 */
1290 #define ADC_CHSELR_SQ5_2               (0x4UL << ADC_CHSELR_SQ5_Pos)           /*!< 0x00040000 */
1291 #define ADC_CHSELR_SQ5_3               (0x8UL << ADC_CHSELR_SQ5_Pos)           /*!< 0x00080000 */
1292 
1293 #define ADC_CHSELR_SQ4_Pos             (12U)
1294 #define ADC_CHSELR_SQ4_Msk             (0xFUL << ADC_CHSELR_SQ4_Pos)           /*!< 0x0000F000 */
1295 #define ADC_CHSELR_SQ4                 ADC_CHSELR_SQ4_Msk                      /*!< ADC group regular sequencer rank 4, available when ADC_CFGR1_CHSELRMOD is set */
1296 #define ADC_CHSELR_SQ4_0               (0x1UL << ADC_CHSELR_SQ4_Pos)           /*!< 0x00001000 */
1297 #define ADC_CHSELR_SQ4_1               (0x2UL << ADC_CHSELR_SQ4_Pos)           /*!< 0x00002000 */
1298 #define ADC_CHSELR_SQ4_2               (0x4UL << ADC_CHSELR_SQ4_Pos)           /*!< 0x00004000 */
1299 #define ADC_CHSELR_SQ4_3               (0x8UL << ADC_CHSELR_SQ4_Pos)           /*!< 0x00008000 */
1300 
1301 #define ADC_CHSELR_SQ3_Pos             (8U)
1302 #define ADC_CHSELR_SQ3_Msk             (0xFUL << ADC_CHSELR_SQ3_Pos)           /*!< 0x00000F00 */
1303 #define ADC_CHSELR_SQ3                 ADC_CHSELR_SQ3_Msk                      /*!< ADC group regular sequencer rank 3, available when ADC_CFGR1_CHSELRMOD is set */
1304 #define ADC_CHSELR_SQ3_0               (0x1UL << ADC_CHSELR_SQ3_Pos)           /*!< 0x00000100 */
1305 #define ADC_CHSELR_SQ3_1               (0x2UL << ADC_CHSELR_SQ3_Pos)           /*!< 0x00000200 */
1306 #define ADC_CHSELR_SQ3_2               (0x4UL << ADC_CHSELR_SQ3_Pos)           /*!< 0x00000400 */
1307 #define ADC_CHSELR_SQ3_3               (0x8UL << ADC_CHSELR_SQ3_Pos)           /*!< 0x00000800 */
1308 
1309 #define ADC_CHSELR_SQ2_Pos             (4U)
1310 #define ADC_CHSELR_SQ2_Msk             (0xFUL << ADC_CHSELR_SQ2_Pos)           /*!< 0x000000F0 */
1311 #define ADC_CHSELR_SQ2                 ADC_CHSELR_SQ2_Msk                      /*!< ADC group regular sequencer rank 2, available when ADC_CFGR1_CHSELRMOD is set */
1312 #define ADC_CHSELR_SQ2_0               (0x1UL << ADC_CHSELR_SQ2_Pos)           /*!< 0x00000010 */
1313 #define ADC_CHSELR_SQ2_1               (0x2UL << ADC_CHSELR_SQ2_Pos)           /*!< 0x00000020 */
1314 #define ADC_CHSELR_SQ2_2               (0x4UL << ADC_CHSELR_SQ2_Pos)           /*!< 0x00000040 */
1315 #define ADC_CHSELR_SQ2_3               (0x8UL << ADC_CHSELR_SQ2_Pos)           /*!< 0x00000080 */
1316 
1317 #define ADC_CHSELR_SQ1_Pos             (0U)
1318 #define ADC_CHSELR_SQ1_Msk             (0xFUL << ADC_CHSELR_SQ1_Pos)           /*!< 0x0000000F */
1319 #define ADC_CHSELR_SQ1                 ADC_CHSELR_SQ1_Msk                      /*!< ADC group regular sequencer rank 1, available when ADC_CFGR1_CHSELRMOD is set */
1320 #define ADC_CHSELR_SQ1_0               (0x1UL << ADC_CHSELR_SQ1_Pos)           /*!< 0x00000001 */
1321 #define ADC_CHSELR_SQ1_1               (0x2UL << ADC_CHSELR_SQ1_Pos)           /*!< 0x00000002 */
1322 #define ADC_CHSELR_SQ1_2               (0x4UL << ADC_CHSELR_SQ1_Pos)           /*!< 0x00000004 */
1323 #define ADC_CHSELR_SQ1_3               (0x8UL << ADC_CHSELR_SQ1_Pos)           /*!< 0x00000008 */
1324 
1325 /********************  Bit definition for ADC_AWD3TR register  *******************/
1326 #define ADC_AWD3TR_LT3_Pos             (0U)
1327 #define ADC_AWD3TR_LT3_Msk             (0xFFFUL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000FFF */
1328 #define ADC_AWD3TR_LT3                 ADC_AWD3TR_LT3_Msk                      /*!< ADC analog watchdog 3 threshold low */
1329 #define ADC_AWD3TR_LT3_0               (0x001UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000001 */
1330 #define ADC_AWD3TR_LT3_1               (0x002UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000002 */
1331 #define ADC_AWD3TR_LT3_2               (0x004UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000004 */
1332 #define ADC_AWD3TR_LT3_3               (0x008UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000008 */
1333 #define ADC_AWD3TR_LT3_4               (0x010UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000010 */
1334 #define ADC_AWD3TR_LT3_5               (0x020UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000020 */
1335 #define ADC_AWD3TR_LT3_6               (0x040UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000040 */
1336 #define ADC_AWD3TR_LT3_7               (0x080UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000080 */
1337 #define ADC_AWD3TR_LT3_8               (0x100UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000100 */
1338 #define ADC_AWD3TR_LT3_9               (0x200UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000200 */
1339 #define ADC_AWD3TR_LT3_10              (0x400UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000400 */
1340 #define ADC_AWD3TR_LT3_11              (0x800UL << ADC_AWD3TR_LT3_Pos)         /*!< 0x00000800 */
1341 
1342 #define ADC_AWD3TR_HT3_Pos             (16U)
1343 #define ADC_AWD3TR_HT3_Msk             (0xFFFUL << ADC_AWD3TR_HT3_Pos)         /*!< 0x0FFF0000 */
1344 #define ADC_AWD3TR_HT3                 ADC_AWD3TR_HT3_Msk                      /*!< ADC analog watchdog 3 threshold high */
1345 #define ADC_AWD3TR_HT3_0               (0x001UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00010000 */
1346 #define ADC_AWD3TR_HT3_1               (0x002UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00020000 */
1347 #define ADC_AWD3TR_HT3_2               (0x004UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00040000 */
1348 #define ADC_AWD3TR_HT3_3               (0x008UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00080000 */
1349 #define ADC_AWD3TR_HT3_4               (0x010UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00100000 */
1350 #define ADC_AWD3TR_HT3_5               (0x020UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00200000 */
1351 #define ADC_AWD3TR_HT3_6               (0x040UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00400000 */
1352 #define ADC_AWD3TR_HT3_7               (0x080UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x00800000 */
1353 #define ADC_AWD3TR_HT3_8               (0x100UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x01000000 */
1354 #define ADC_AWD3TR_HT3_9               (0x200UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x02000000 */
1355 #define ADC_AWD3TR_HT3_10              (0x400UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x04000000 */
1356 #define ADC_AWD3TR_HT3_11              (0x800UL << ADC_AWD3TR_HT3_Pos)         /*!< 0x08000000 */
1357 
1358 /* Legacy definitions */
1359 #define ADC_TR3_LT3             ADC_AWD3TR_LT3
1360 #define ADC_TR3_LT3_0           ADC_AWD3TR_LT3_0
1361 #define ADC_TR3_LT3_1           ADC_AWD3TR_LT3_1
1362 #define ADC_TR3_LT3_2           ADC_AWD3TR_LT3_2
1363 #define ADC_TR3_LT3_3           ADC_AWD3TR_LT3_3
1364 #define ADC_TR3_LT3_4           ADC_AWD3TR_LT3_4
1365 #define ADC_TR3_LT3_5           ADC_AWD3TR_LT3_5
1366 #define ADC_TR3_LT3_6           ADC_AWD3TR_LT3_6
1367 #define ADC_TR3_LT3_7           ADC_AWD3TR_LT3_7
1368 #define ADC_TR3_LT3_8           ADC_AWD3TR_LT3_8
1369 #define ADC_TR3_LT3_9           ADC_AWD3TR_LT3_9
1370 #define ADC_TR3_LT3_10          ADC_AWD3TR_LT3_10
1371 #define ADC_TR3_LT3_11          ADC_AWD3TR_LT3_11
1372 
1373 #define ADC_TR3_HT3             ADC_AWD3TR_HT3
1374 #define ADC_TR3_HT3_0           ADC_AWD3TR_HT3_0
1375 #define ADC_TR3_HT3_1           ADC_AWD3TR_HT3_1
1376 #define ADC_TR3_HT3_2           ADC_AWD3TR_HT3_2
1377 #define ADC_TR3_HT3_3           ADC_AWD3TR_HT3_3
1378 #define ADC_TR3_HT3_4           ADC_AWD3TR_HT3_4
1379 #define ADC_TR3_HT3_5           ADC_AWD3TR_HT3_5
1380 #define ADC_TR3_HT3_6           ADC_AWD3TR_HT3_6
1381 #define ADC_TR3_HT3_7           ADC_AWD3TR_HT3_7
1382 #define ADC_TR3_HT3_8           ADC_AWD3TR_HT3_8
1383 #define ADC_TR3_HT3_9           ADC_AWD3TR_HT3_9
1384 #define ADC_TR3_HT3_10          ADC_AWD3TR_HT3_10
1385 #define ADC_TR3_HT3_11          ADC_AWD3TR_HT3_11
1386 
1387 /********************  Bit definition for ADC_DR register  ********************/
1388 #define ADC_DR_DATA_Pos                (0U)
1389 #define ADC_DR_DATA_Msk                (0xFFFFUL << ADC_DR_DATA_Pos)           /*!< 0x0000FFFF */
1390 #define ADC_DR_DATA                    ADC_DR_DATA_Msk                         /*!< ADC group regular conversion data */
1391 #define ADC_DR_DATA_0                  (0x0001UL << ADC_DR_DATA_Pos)           /*!< 0x00000001 */
1392 #define ADC_DR_DATA_1                  (0x0002UL << ADC_DR_DATA_Pos)           /*!< 0x00000002 */
1393 #define ADC_DR_DATA_2                  (0x0004UL << ADC_DR_DATA_Pos)           /*!< 0x00000004 */
1394 #define ADC_DR_DATA_3                  (0x0008UL << ADC_DR_DATA_Pos)           /*!< 0x00000008 */
1395 #define ADC_DR_DATA_4                  (0x0010UL << ADC_DR_DATA_Pos)           /*!< 0x00000010 */
1396 #define ADC_DR_DATA_5                  (0x0020UL << ADC_DR_DATA_Pos)           /*!< 0x00000020 */
1397 #define ADC_DR_DATA_6                  (0x0040UL << ADC_DR_DATA_Pos)           /*!< 0x00000040 */
1398 #define ADC_DR_DATA_7                  (0x0080UL << ADC_DR_DATA_Pos)           /*!< 0x00000080 */
1399 #define ADC_DR_DATA_8                  (0x0100UL << ADC_DR_DATA_Pos)           /*!< 0x00000100 */
1400 #define ADC_DR_DATA_9                  (0x0200UL << ADC_DR_DATA_Pos)           /*!< 0x00000200 */
1401 #define ADC_DR_DATA_10                 (0x0400UL << ADC_DR_DATA_Pos)           /*!< 0x00000400 */
1402 #define ADC_DR_DATA_11                 (0x0800UL << ADC_DR_DATA_Pos)           /*!< 0x00000800 */
1403 #define ADC_DR_DATA_12                 (0x1000UL << ADC_DR_DATA_Pos)           /*!< 0x00001000 */
1404 #define ADC_DR_DATA_13                 (0x2000UL << ADC_DR_DATA_Pos)           /*!< 0x00002000 */
1405 #define ADC_DR_DATA_14                 (0x4000UL << ADC_DR_DATA_Pos)           /*!< 0x00004000 */
1406 #define ADC_DR_DATA_15                 (0x8000UL << ADC_DR_DATA_Pos)           /*!< 0x00008000 */
1407 
1408 /********************  Bit definition for ADC_AWD2CR register  ****************/
1409 #define ADC_AWD2CR_AWD2CH_Pos          (0U)
1410 #define ADC_AWD2CR_AWD2CH_Msk          (0x7FFFFUL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x0007FFFF */
1411 #define ADC_AWD2CR_AWD2CH              ADC_AWD2CR_AWD2CH_Msk                   /*!< ADC analog watchdog 2 monitored channel selection */
1412 #define ADC_AWD2CR_AWD2CH_0            (0x00001UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000001 */
1413 #define ADC_AWD2CR_AWD2CH_1            (0x00002UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000002 */
1414 #define ADC_AWD2CR_AWD2CH_2            (0x00004UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000004 */
1415 #define ADC_AWD2CR_AWD2CH_3            (0x00008UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000008 */
1416 #define ADC_AWD2CR_AWD2CH_4            (0x00010UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000010 */
1417 #define ADC_AWD2CR_AWD2CH_5            (0x00020UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000020 */
1418 #define ADC_AWD2CR_AWD2CH_6            (0x00040UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000040 */
1419 #define ADC_AWD2CR_AWD2CH_7            (0x00080UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000080 */
1420 #define ADC_AWD2CR_AWD2CH_8            (0x00100UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000100 */
1421 #define ADC_AWD2CR_AWD2CH_9            (0x00200UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000200 */
1422 #define ADC_AWD2CR_AWD2CH_10           (0x00400UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000400 */
1423 #define ADC_AWD2CR_AWD2CH_11           (0x00800UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00000800 */
1424 #define ADC_AWD2CR_AWD2CH_12           (0x01000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00001000 */
1425 #define ADC_AWD2CR_AWD2CH_13           (0x02000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00002000 */
1426 #define ADC_AWD2CR_AWD2CH_14           (0x04000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00004000 */
1427 #define ADC_AWD2CR_AWD2CH_15           (0x08000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00008000 */
1428 #define ADC_AWD2CR_AWD2CH_16           (0x10000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00010000 */
1429 #define ADC_AWD2CR_AWD2CH_17           (0x20000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00020000 */
1430 #define ADC_AWD2CR_AWD2CH_18           (0x40000UL << ADC_AWD2CR_AWD2CH_Pos)    /*!< 0x00040000 */
1431 
1432 /********************  Bit definition for ADC_AWD3CR register  ****************/
1433 #define ADC_AWD3CR_AWD3CH_Pos          (0U)
1434 #define ADC_AWD3CR_AWD3CH_Msk          (0x7FFFFUL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x0007FFFF */
1435 #define ADC_AWD3CR_AWD3CH              ADC_AWD3CR_AWD3CH_Msk                   /*!< ADC analog watchdog 3 monitored channel selection */
1436 #define ADC_AWD3CR_AWD3CH_0            (0x00001UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000001 */
1437 #define ADC_AWD3CR_AWD3CH_1            (0x00002UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000002 */
1438 #define ADC_AWD3CR_AWD3CH_2            (0x00004UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000004 */
1439 #define ADC_AWD3CR_AWD3CH_3            (0x00008UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000008 */
1440 #define ADC_AWD3CR_AWD3CH_4            (0x00010UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000010 */
1441 #define ADC_AWD3CR_AWD3CH_5            (0x00020UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000020 */
1442 #define ADC_AWD3CR_AWD3CH_6            (0x00040UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000040 */
1443 #define ADC_AWD3CR_AWD3CH_7            (0x00080UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000080 */
1444 #define ADC_AWD3CR_AWD3CH_8            (0x00100UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000100 */
1445 #define ADC_AWD3CR_AWD3CH_9            (0x00200UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000200 */
1446 #define ADC_AWD3CR_AWD3CH_10           (0x00400UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000400 */
1447 #define ADC_AWD3CR_AWD3CH_11           (0x00800UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00000800 */
1448 #define ADC_AWD3CR_AWD3CH_12           (0x01000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00001000 */
1449 #define ADC_AWD3CR_AWD3CH_13           (0x02000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00002000 */
1450 #define ADC_AWD3CR_AWD3CH_14           (0x04000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00004000 */
1451 #define ADC_AWD3CR_AWD3CH_15           (0x08000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00008000 */
1452 #define ADC_AWD3CR_AWD3CH_16           (0x10000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00010000 */
1453 #define ADC_AWD3CR_AWD3CH_17           (0x20000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00020000 */
1454 #define ADC_AWD3CR_AWD3CH_18           (0x40000UL << ADC_AWD3CR_AWD3CH_Pos)    /*!< 0x00040000 */
1455 
1456 /********************  Bit definition for ADC_CALFACT register  ***************/
1457 #define ADC_CALFACT_CALFACT_Pos        (0U)
1458 #define ADC_CALFACT_CALFACT_Msk        (0x7FUL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x0000007F */
1459 #define ADC_CALFACT_CALFACT            ADC_CALFACT_CALFACT_Msk                 /*!< ADC calibration factor in single-ended mode */
1460 #define ADC_CALFACT_CALFACT_0          (0x01UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000001 */
1461 #define ADC_CALFACT_CALFACT_1          (0x02UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000002 */
1462 #define ADC_CALFACT_CALFACT_2          (0x04UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000004 */
1463 #define ADC_CALFACT_CALFACT_3          (0x08UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000008 */
1464 #define ADC_CALFACT_CALFACT_4          (0x10UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000010 */
1465 #define ADC_CALFACT_CALFACT_5          (0x20UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000020 */
1466 #define ADC_CALFACT_CALFACT_6          (0x40UL << ADC_CALFACT_CALFACT_Pos)     /*!< 0x00000040 */
1467 
1468 /*************************  ADC Common registers  *****************************/
1469 /********************  Bit definition for ADC_CCR register  *******************/
1470 #define ADC_CCR_PRESC_Pos              (18U)
1471 #define ADC_CCR_PRESC_Msk              (0xFUL << ADC_CCR_PRESC_Pos)            /*!< 0x003C0000 */
1472 #define ADC_CCR_PRESC                  ADC_CCR_PRESC_Msk                       /*!< ADC common clock prescaler, only for clock source asynchronous */
1473 #define ADC_CCR_PRESC_0                (0x1UL << ADC_CCR_PRESC_Pos)            /*!< 0x00040000 */
1474 #define ADC_CCR_PRESC_1                (0x2UL << ADC_CCR_PRESC_Pos)            /*!< 0x00080000 */
1475 #define ADC_CCR_PRESC_2                (0x4UL << ADC_CCR_PRESC_Pos)            /*!< 0x00100000 */
1476 #define ADC_CCR_PRESC_3                (0x8UL << ADC_CCR_PRESC_Pos)            /*!< 0x00200000 */
1477 
1478 #define ADC_CCR_VREFEN_Pos             (22U)
1479 #define ADC_CCR_VREFEN_Msk             (0x1UL << ADC_CCR_VREFEN_Pos)           /*!< 0x00400000 */
1480 #define ADC_CCR_VREFEN                 ADC_CCR_VREFEN_Msk                      /*!< ADC internal path to VrefInt enable */
1481 #define ADC_CCR_TSEN_Pos               (23U)
1482 #define ADC_CCR_TSEN_Msk               (0x1UL << ADC_CCR_TSEN_Pos)             /*!< 0x00800000 */
1483 #define ADC_CCR_TSEN                   ADC_CCR_TSEN_Msk                        /*!< ADC internal path to temperature sensor enable */
1484 #define ADC_CCR_VBATEN_Pos             (24U)
1485 #define ADC_CCR_VBATEN_Msk             (0x1UL << ADC_CCR_VBATEN_Pos)           /*!< 0x01000000 */
1486 #define ADC_CCR_VBATEN                 ADC_CCR_VBATEN_Msk                      /*!< ADC internal path to battery voltage enable */
1487 
1488 /* Legacy */
1489 #define ADC_CCR_LFMEN_Pos              (25U)
1490 #define ADC_CCR_LFMEN_Msk              (0x1UL << ADC_CCR_LFMEN_Pos)            /*!< 0x02000000 */
1491 #define ADC_CCR_LFMEN                  ADC_CCR_LFMEN_Msk                       /*!< Legacy feature, useless on STM32G0 (ADC common clock low frequency mode is automatically managed by ADC peripheral on STM32G0) */
1492 
1493 
1494 /******************************************************************************/
1495 /*                                                                            */
1496 /*                          CRC calculation unit                              */
1497 /*                                                                            */
1498 /******************************************************************************/
1499 /*******************  Bit definition for CRC_DR register  *********************/
1500 #define CRC_DR_DR_Pos            (0U)
1501 #define CRC_DR_DR_Msk            (0xFFFFFFFFUL << CRC_DR_DR_Pos)                /*!< 0xFFFFFFFF */
1502 #define CRC_DR_DR                CRC_DR_DR_Msk                                  /*!< Data register bits */
1503 
1504 /*******************  Bit definition for CRC_IDR register  ********************/
1505 #define CRC_IDR_IDR_Pos          (0U)
1506 #define CRC_IDR_IDR_Msk          (0xFFFFFFFFUL << CRC_IDR_IDR_Pos)              /*!< 0xFFFFFFFF */
1507 #define CRC_IDR_IDR              CRC_IDR_IDR_Msk                                /*!< General-purpose 32-bits data register bits */
1508 
1509 /********************  Bit definition for CRC_CR register  ********************/
1510 #define CRC_CR_RESET_Pos         (0U)
1511 #define CRC_CR_RESET_Msk         (0x1UL << CRC_CR_RESET_Pos)                    /*!< 0x00000001 */
1512 #define CRC_CR_RESET             CRC_CR_RESET_Msk                               /*!< RESET the CRC computation unit bit */
1513 #define CRC_CR_POLYSIZE_Pos      (3U)
1514 #define CRC_CR_POLYSIZE_Msk      (0x3UL << CRC_CR_POLYSIZE_Pos)                 /*!< 0x00000018 */
1515 #define CRC_CR_POLYSIZE          CRC_CR_POLYSIZE_Msk                            /*!< Polynomial size bits */
1516 #define CRC_CR_POLYSIZE_0        (0x1UL << CRC_CR_POLYSIZE_Pos)                 /*!< 0x00000008 */
1517 #define CRC_CR_POLYSIZE_1        (0x2UL << CRC_CR_POLYSIZE_Pos)                 /*!< 0x00000010 */
1518 #define CRC_CR_REV_IN_Pos        (5U)
1519 #define CRC_CR_REV_IN_Msk        (0x3UL << CRC_CR_REV_IN_Pos)                   /*!< 0x00000060 */
1520 #define CRC_CR_REV_IN            CRC_CR_REV_IN_Msk                              /*!< REV_IN Reverse Input Data bits */
1521 #define CRC_CR_REV_IN_0          (0x1UL << CRC_CR_REV_IN_Pos)                   /*!< 0x00000020 */
1522 #define CRC_CR_REV_IN_1          (0x2UL << CRC_CR_REV_IN_Pos)                   /*!< 0x00000040 */
1523 #define CRC_CR_REV_OUT_Pos       (7U)
1524 #define CRC_CR_REV_OUT_Msk       (0x1UL << CRC_CR_REV_OUT_Pos)                  /*!< 0x00000080 */
1525 #define CRC_CR_REV_OUT           CRC_CR_REV_OUT_Msk                             /*!< REV_OUT Reverse Output Data bits */
1526 
1527 /*******************  Bit definition for CRC_INIT register  *******************/
1528 #define CRC_INIT_INIT_Pos        (0U)
1529 #define CRC_INIT_INIT_Msk        (0xFFFFFFFFUL << CRC_INIT_INIT_Pos)            /*!< 0xFFFFFFFF */
1530 #define CRC_INIT_INIT            CRC_INIT_INIT_Msk                              /*!< Initial CRC value bits */
1531 
1532 /*******************  Bit definition for CRC_POL register  ********************/
1533 #define CRC_POL_POL_Pos          (0U)
1534 #define CRC_POL_POL_Msk          (0xFFFFFFFFUL << CRC_POL_POL_Pos)              /*!< 0xFFFFFFFF */
1535 #define CRC_POL_POL              CRC_POL_POL_Msk                                /*!< Coefficients of the polynomial */
1536 
1537 
1538 
1539 /******************************************************************************/
1540 /*                                                                            */
1541 /*                                 Debug MCU                                  */
1542 /*                                                                            */
1543 /******************************************************************************/
1544 
1545 /******************************************************************************/
1546 /*                                                                            */
1547 /*                           DMA Controller (DMA)                             */
1548 /*                                                                            */
1549 /******************************************************************************/
1550 
1551 /*******************  Bit definition for DMA_ISR register  ********************/
1552 #define DMA_ISR_GIF1_Pos       (0U)
1553 #define DMA_ISR_GIF1_Msk       (0x1UL << DMA_ISR_GIF1_Pos)                     /*!< 0x00000001 */
1554 #define DMA_ISR_GIF1           DMA_ISR_GIF1_Msk                                /*!< Channel 1 Global interrupt flag */
1555 #define DMA_ISR_TCIF1_Pos      (1U)
1556 #define DMA_ISR_TCIF1_Msk      (0x1UL << DMA_ISR_TCIF1_Pos)                    /*!< 0x00000002 */
1557 #define DMA_ISR_TCIF1          DMA_ISR_TCIF1_Msk                               /*!< Channel 1 Transfer Complete flag */
1558 #define DMA_ISR_HTIF1_Pos      (2U)
1559 #define DMA_ISR_HTIF1_Msk      (0x1UL << DMA_ISR_HTIF1_Pos)                    /*!< 0x00000004 */
1560 #define DMA_ISR_HTIF1          DMA_ISR_HTIF1_Msk                               /*!< Channel 1 Half Transfer flag */
1561 #define DMA_ISR_TEIF1_Pos      (3U)
1562 #define DMA_ISR_TEIF1_Msk      (0x1UL << DMA_ISR_TEIF1_Pos)                    /*!< 0x00000008 */
1563 #define DMA_ISR_TEIF1          DMA_ISR_TEIF1_Msk                               /*!< Channel 1 Transfer Error flag */
1564 #define DMA_ISR_GIF2_Pos       (4U)
1565 #define DMA_ISR_GIF2_Msk       (0x1UL << DMA_ISR_GIF2_Pos)                     /*!< 0x00000010 */
1566 #define DMA_ISR_GIF2           DMA_ISR_GIF2_Msk                                /*!< Channel 2 Global interrupt flag */
1567 #define DMA_ISR_TCIF2_Pos      (5U)
1568 #define DMA_ISR_TCIF2_Msk      (0x1UL << DMA_ISR_TCIF2_Pos)                    /*!< 0x00000020 */
1569 #define DMA_ISR_TCIF2          DMA_ISR_TCIF2_Msk                               /*!< Channel 2 Transfer Complete flag */
1570 #define DMA_ISR_HTIF2_Pos      (6U)
1571 #define DMA_ISR_HTIF2_Msk      (0x1UL << DMA_ISR_HTIF2_Pos)                    /*!< 0x00000040 */
1572 #define DMA_ISR_HTIF2          DMA_ISR_HTIF2_Msk                               /*!< Channel 2 Half Transfer flag */
1573 #define DMA_ISR_TEIF2_Pos      (7U)
1574 #define DMA_ISR_TEIF2_Msk      (0x1UL << DMA_ISR_TEIF2_Pos)                    /*!< 0x00000080 */
1575 #define DMA_ISR_TEIF2          DMA_ISR_TEIF2_Msk                               /*!< Channel 2 Transfer Error flag */
1576 #define DMA_ISR_GIF3_Pos       (8U)
1577 #define DMA_ISR_GIF3_Msk       (0x1UL << DMA_ISR_GIF3_Pos)                     /*!< 0x00000100 */
1578 #define DMA_ISR_GIF3           DMA_ISR_GIF3_Msk                                /*!< Channel 3 Global interrupt flag */
1579 #define DMA_ISR_TCIF3_Pos      (9U)
1580 #define DMA_ISR_TCIF3_Msk      (0x1UL << DMA_ISR_TCIF3_Pos)                    /*!< 0x00000200 */
1581 #define DMA_ISR_TCIF3          DMA_ISR_TCIF3_Msk                               /*!< Channel 3 Transfer Complete flag */
1582 #define DMA_ISR_HTIF3_Pos      (10U)
1583 #define DMA_ISR_HTIF3_Msk      (0x1UL << DMA_ISR_HTIF3_Pos)                    /*!< 0x00000400 */
1584 #define DMA_ISR_HTIF3          DMA_ISR_HTIF3_Msk                               /*!< Channel 3 Half Transfer flag */
1585 #define DMA_ISR_TEIF3_Pos      (11U)
1586 #define DMA_ISR_TEIF3_Msk      (0x1UL << DMA_ISR_TEIF3_Pos)                    /*!< 0x00000800 */
1587 #define DMA_ISR_TEIF3          DMA_ISR_TEIF3_Msk                               /*!< Channel 3 Transfer Error flag */
1588 #define DMA_ISR_GIF4_Pos       (12U)
1589 #define DMA_ISR_GIF4_Msk       (0x1UL << DMA_ISR_GIF4_Pos)                     /*!< 0x00001000 */
1590 #define DMA_ISR_GIF4           DMA_ISR_GIF4_Msk                                /*!< Channel 4 Global interrupt flag */
1591 #define DMA_ISR_TCIF4_Pos      (13U)
1592 #define DMA_ISR_TCIF4_Msk      (0x1UL << DMA_ISR_TCIF4_Pos)                    /*!< 0x00002000 */
1593 #define DMA_ISR_TCIF4          DMA_ISR_TCIF4_Msk                               /*!< Channel 4 Transfer Complete flag */
1594 #define DMA_ISR_HTIF4_Pos      (14U)
1595 #define DMA_ISR_HTIF4_Msk      (0x1UL << DMA_ISR_HTIF4_Pos)                    /*!< 0x00004000 */
1596 #define DMA_ISR_HTIF4          DMA_ISR_HTIF4_Msk                               /*!< Channel 4 Half Transfer flag */
1597 #define DMA_ISR_TEIF4_Pos      (15U)
1598 #define DMA_ISR_TEIF4_Msk      (0x1UL << DMA_ISR_TEIF4_Pos)                    /*!< 0x00008000 */
1599 #define DMA_ISR_TEIF4          DMA_ISR_TEIF4_Msk                               /*!< Channel 4 Transfer Error flag */
1600 #define DMA_ISR_GIF5_Pos       (16U)
1601 #define DMA_ISR_GIF5_Msk       (0x1UL << DMA_ISR_GIF5_Pos)                     /*!< 0x00010000 */
1602 #define DMA_ISR_GIF5           DMA_ISR_GIF5_Msk                                /*!< Channel 5 Global interrupt flag */
1603 #define DMA_ISR_TCIF5_Pos      (17U)
1604 #define DMA_ISR_TCIF5_Msk      (0x1UL << DMA_ISR_TCIF5_Pos)                    /*!< 0x00020000 */
1605 #define DMA_ISR_TCIF5          DMA_ISR_TCIF5_Msk                               /*!< Channel 5 Transfer Complete flag */
1606 #define DMA_ISR_HTIF5_Pos      (18U)
1607 #define DMA_ISR_HTIF5_Msk      (0x1UL << DMA_ISR_HTIF5_Pos)                    /*!< 0x00040000 */
1608 #define DMA_ISR_HTIF5          DMA_ISR_HTIF5_Msk                               /*!< Channel 5 Half Transfer flag */
1609 #define DMA_ISR_TEIF5_Pos      (19U)
1610 #define DMA_ISR_TEIF5_Msk      (0x1UL << DMA_ISR_TEIF5_Pos)                    /*!< 0x00080000 */
1611 #define DMA_ISR_TEIF5          DMA_ISR_TEIF5_Msk                               /*!< Channel 5 Transfer Error flag */
1612 #define DMA_ISR_GIF6_Pos       (20U)
1613 #define DMA_ISR_GIF6_Msk       (0x1UL << DMA_ISR_GIF6_Pos)                     /*!< 0x00100000 */
1614 #define DMA_ISR_GIF6           DMA_ISR_GIF6_Msk                                /*!< Channel 6 Global interrupt flag */
1615 #define DMA_ISR_TCIF6_Pos      (21U)
1616 #define DMA_ISR_TCIF6_Msk      (0x1UL << DMA_ISR_TCIF6_Pos)                    /*!< 0x00200000 */
1617 #define DMA_ISR_TCIF6          DMA_ISR_TCIF6_Msk                               /*!< Channel 6 Transfer Complete flag */
1618 #define DMA_ISR_HTIF6_Pos      (22U)
1619 #define DMA_ISR_HTIF6_Msk      (0x1UL << DMA_ISR_HTIF6_Pos)                    /*!< 0x00400000 */
1620 #define DMA_ISR_HTIF6          DMA_ISR_HTIF6_Msk                               /*!< Channel 6 Half Transfer flag */
1621 #define DMA_ISR_TEIF6_Pos      (23U)
1622 #define DMA_ISR_TEIF6_Msk      (0x1UL << DMA_ISR_TEIF6_Pos)                    /*!< 0x00800000 */
1623 #define DMA_ISR_TEIF6          DMA_ISR_TEIF6_Msk                               /*!< Channel 6 Transfer Error flag */
1624 #define DMA_ISR_GIF7_Pos       (24U)
1625 #define DMA_ISR_GIF7_Msk       (0x1UL << DMA_ISR_GIF7_Pos)                     /*!< 0x01000000 */
1626 #define DMA_ISR_GIF7           DMA_ISR_GIF7_Msk                                /*!< Channel 7 Global interrupt flag */
1627 #define DMA_ISR_TCIF7_Pos      (25U)
1628 #define DMA_ISR_TCIF7_Msk      (0x1UL << DMA_ISR_TCIF7_Pos)                    /*!< 0x02000000 */
1629 #define DMA_ISR_TCIF7          DMA_ISR_TCIF7_Msk                               /*!< Channel 7 Transfer Complete flag */
1630 #define DMA_ISR_HTIF7_Pos      (26U)
1631 #define DMA_ISR_HTIF7_Msk      (0x1UL << DMA_ISR_HTIF7_Pos)                    /*!< 0x04000000 */
1632 #define DMA_ISR_HTIF7          DMA_ISR_HTIF7_Msk                               /*!< Channel 7 Half Transfer flag */
1633 #define DMA_ISR_TEIF7_Pos      (27U)
1634 #define DMA_ISR_TEIF7_Msk      (0x1UL << DMA_ISR_TEIF7_Pos)                    /*!< 0x08000000 */
1635 #define DMA_ISR_TEIF7          DMA_ISR_TEIF7_Msk                               /*!< Channel 7 Transfer Error flag */
1636 
1637 /*******************  Bit definition for DMA_IFCR register  *******************/
1638 #define DMA_IFCR_CGIF1_Pos     (0U)
1639 #define DMA_IFCR_CGIF1_Msk     (0x1UL << DMA_IFCR_CGIF1_Pos)                   /*!< 0x00000001 */
1640 #define DMA_IFCR_CGIF1         DMA_IFCR_CGIF1_Msk                              /*!< Channel 1 Global interrupt clearr */
1641 #define DMA_IFCR_CTCIF1_Pos    (1U)
1642 #define DMA_IFCR_CTCIF1_Msk    (0x1UL << DMA_IFCR_CTCIF1_Pos)                  /*!< 0x00000002 */
1643 #define DMA_IFCR_CTCIF1        DMA_IFCR_CTCIF1_Msk                             /*!< Channel 1 Transfer Complete clear */
1644 #define DMA_IFCR_CHTIF1_Pos    (2U)
1645 #define DMA_IFCR_CHTIF1_Msk    (0x1UL << DMA_IFCR_CHTIF1_Pos)                  /*!< 0x00000004 */
1646 #define DMA_IFCR_CHTIF1        DMA_IFCR_CHTIF1_Msk                             /*!< Channel 1 Half Transfer clear */
1647 #define DMA_IFCR_CTEIF1_Pos    (3U)
1648 #define DMA_IFCR_CTEIF1_Msk    (0x1UL << DMA_IFCR_CTEIF1_Pos)                  /*!< 0x00000008 */
1649 #define DMA_IFCR_CTEIF1        DMA_IFCR_CTEIF1_Msk                             /*!< Channel 1 Transfer Error clear */
1650 #define DMA_IFCR_CGIF2_Pos     (4U)
1651 #define DMA_IFCR_CGIF2_Msk     (0x1UL << DMA_IFCR_CGIF2_Pos)                   /*!< 0x00000010 */
1652 #define DMA_IFCR_CGIF2         DMA_IFCR_CGIF2_Msk                              /*!< Channel 2 Global interrupt clear */
1653 #define DMA_IFCR_CTCIF2_Pos    (5U)
1654 #define DMA_IFCR_CTCIF2_Msk    (0x1UL << DMA_IFCR_CTCIF2_Pos)                  /*!< 0x00000020 */
1655 #define DMA_IFCR_CTCIF2        DMA_IFCR_CTCIF2_Msk                             /*!< Channel 2 Transfer Complete clear */
1656 #define DMA_IFCR_CHTIF2_Pos    (6U)
1657 #define DMA_IFCR_CHTIF2_Msk    (0x1UL << DMA_IFCR_CHTIF2_Pos)                  /*!< 0x00000040 */
1658 #define DMA_IFCR_CHTIF2        DMA_IFCR_CHTIF2_Msk                             /*!< Channel 2 Half Transfer clear */
1659 #define DMA_IFCR_CTEIF2_Pos    (7U)
1660 #define DMA_IFCR_CTEIF2_Msk    (0x1UL << DMA_IFCR_CTEIF2_Pos)                  /*!< 0x00000080 */
1661 #define DMA_IFCR_CTEIF2        DMA_IFCR_CTEIF2_Msk                             /*!< Channel 2 Transfer Error clear */
1662 #define DMA_IFCR_CGIF3_Pos     (8U)
1663 #define DMA_IFCR_CGIF3_Msk     (0x1UL << DMA_IFCR_CGIF3_Pos)                   /*!< 0x00000100 */
1664 #define DMA_IFCR_CGIF3         DMA_IFCR_CGIF3_Msk                              /*!< Channel 3 Global interrupt clear */
1665 #define DMA_IFCR_CTCIF3_Pos    (9U)
1666 #define DMA_IFCR_CTCIF3_Msk    (0x1UL << DMA_IFCR_CTCIF3_Pos)                  /*!< 0x00000200 */
1667 #define DMA_IFCR_CTCIF3        DMA_IFCR_CTCIF3_Msk                             /*!< Channel 3 Transfer Complete clear */
1668 #define DMA_IFCR_CHTIF3_Pos    (10U)
1669 #define DMA_IFCR_CHTIF3_Msk    (0x1UL << DMA_IFCR_CHTIF3_Pos)                  /*!< 0x00000400 */
1670 #define DMA_IFCR_CHTIF3        DMA_IFCR_CHTIF3_Msk                             /*!< Channel 3 Half Transfer clear */
1671 #define DMA_IFCR_CTEIF3_Pos    (11U)
1672 #define DMA_IFCR_CTEIF3_Msk    (0x1UL << DMA_IFCR_CTEIF3_Pos)                  /*!< 0x00000800 */
1673 #define DMA_IFCR_CTEIF3        DMA_IFCR_CTEIF3_Msk                             /*!< Channel 3 Transfer Error clear */
1674 #define DMA_IFCR_CGIF4_Pos     (12U)
1675 #define DMA_IFCR_CGIF4_Msk     (0x1UL << DMA_IFCR_CGIF4_Pos)                   /*!< 0x00001000 */
1676 #define DMA_IFCR_CGIF4         DMA_IFCR_CGIF4_Msk                              /*!< Channel 4 Global interrupt clear */
1677 #define DMA_IFCR_CTCIF4_Pos    (13U)
1678 #define DMA_IFCR_CTCIF4_Msk    (0x1UL << DMA_IFCR_CTCIF4_Pos)                  /*!< 0x00002000 */
1679 #define DMA_IFCR_CTCIF4        DMA_IFCR_CTCIF4_Msk                             /*!< Channel 4 Transfer Complete clear */
1680 #define DMA_IFCR_CHTIF4_Pos    (14U)
1681 #define DMA_IFCR_CHTIF4_Msk    (0x1UL << DMA_IFCR_CHTIF4_Pos)                  /*!< 0x00004000 */
1682 #define DMA_IFCR_CHTIF4        DMA_IFCR_CHTIF4_Msk                             /*!< Channel 4 Half Transfer clear */
1683 #define DMA_IFCR_CTEIF4_Pos    (15U)
1684 #define DMA_IFCR_CTEIF4_Msk    (0x1UL << DMA_IFCR_CTEIF4_Pos)                  /*!< 0x00008000 */
1685 #define DMA_IFCR_CTEIF4        DMA_IFCR_CTEIF4_Msk                             /*!< Channel 4 Transfer Error clear */
1686 #define DMA_IFCR_CGIF5_Pos     (16U)
1687 #define DMA_IFCR_CGIF5_Msk     (0x1UL << DMA_IFCR_CGIF5_Pos)                   /*!< 0x00010000 */
1688 #define DMA_IFCR_CGIF5         DMA_IFCR_CGIF5_Msk                              /*!< Channel 5 Global interrupt clear */
1689 #define DMA_IFCR_CTCIF5_Pos    (17U)
1690 #define DMA_IFCR_CTCIF5_Msk    (0x1UL << DMA_IFCR_CTCIF5_Pos)                  /*!< 0x00020000 */
1691 #define DMA_IFCR_CTCIF5        DMA_IFCR_CTCIF5_Msk                             /*!< Channel 5 Transfer Complete clear */
1692 #define DMA_IFCR_CHTIF5_Pos    (18U)
1693 #define DMA_IFCR_CHTIF5_Msk    (0x1UL << DMA_IFCR_CHTIF5_Pos)                  /*!< 0x00040000 */
1694 #define DMA_IFCR_CHTIF5        DMA_IFCR_CHTIF5_Msk                             /*!< Channel 5 Half Transfer clear */
1695 #define DMA_IFCR_CTEIF5_Pos    (19U)
1696 #define DMA_IFCR_CTEIF5_Msk    (0x1UL << DMA_IFCR_CTEIF5_Pos)                  /*!< 0x00080000 */
1697 #define DMA_IFCR_CTEIF5        DMA_IFCR_CTEIF5_Msk                             /*!< Channel 5 Transfer Error clear */
1698 #define DMA_IFCR_CGIF6_Pos     (20U)
1699 #define DMA_IFCR_CGIF6_Msk     (0x1UL << DMA_IFCR_CGIF6_Pos)                   /*!< 0x00100000 */
1700 #define DMA_IFCR_CGIF6         DMA_IFCR_CGIF6_Msk                              /*!< Channel 6 Global interrupt clear */
1701 #define DMA_IFCR_CTCIF6_Pos    (21U)
1702 #define DMA_IFCR_CTCIF6_Msk    (0x1UL << DMA_IFCR_CTCIF6_Pos)                  /*!< 0x00200000 */
1703 #define DMA_IFCR_CTCIF6        DMA_IFCR_CTCIF6_Msk                             /*!< Channel 6 Transfer Complete clear */
1704 #define DMA_IFCR_CHTIF6_Pos    (22U)
1705 #define DMA_IFCR_CHTIF6_Msk    (0x1UL << DMA_IFCR_CHTIF6_Pos)                  /*!< 0x00400000 */
1706 #define DMA_IFCR_CHTIF6        DMA_IFCR_CHTIF6_Msk                             /*!< Channel 6 Half Transfer clear */
1707 #define DMA_IFCR_CTEIF6_Pos    (23U)
1708 #define DMA_IFCR_CTEIF6_Msk    (0x1UL << DMA_IFCR_CTEIF6_Pos)                  /*!< 0x00800000 */
1709 #define DMA_IFCR_CTEIF6        DMA_IFCR_CTEIF6_Msk                             /*!< Channel 6 Transfer Error clear */
1710 #define DMA_IFCR_CGIF7_Pos     (24U)
1711 #define DMA_IFCR_CGIF7_Msk     (0x1UL << DMA_IFCR_CGIF7_Pos)                   /*!< 0x01000000 */
1712 #define DMA_IFCR_CGIF7         DMA_IFCR_CGIF7_Msk                              /*!< Channel 7 Global interrupt clear */
1713 #define DMA_IFCR_CTCIF7_Pos    (25U)
1714 #define DMA_IFCR_CTCIF7_Msk    (0x1UL << DMA_IFCR_CTCIF7_Pos)                  /*!< 0x02000000 */
1715 #define DMA_IFCR_CTCIF7        DMA_IFCR_CTCIF7_Msk                             /*!< Channel 7 Transfer Complete clear */
1716 #define DMA_IFCR_CHTIF7_Pos    (26U)
1717 #define DMA_IFCR_CHTIF7_Msk    (0x1UL << DMA_IFCR_CHTIF7_Pos)                  /*!< 0x04000000 */
1718 #define DMA_IFCR_CHTIF7        DMA_IFCR_CHTIF7_Msk                             /*!< Channel 7 Half Transfer clear */
1719 #define DMA_IFCR_CTEIF7_Pos    (27U)
1720 #define DMA_IFCR_CTEIF7_Msk    (0x1UL << DMA_IFCR_CTEIF7_Pos)                  /*!< 0x08000000 */
1721 #define DMA_IFCR_CTEIF7        DMA_IFCR_CTEIF7_Msk                             /*!< Channel 7 Transfer Error clear */
1722 
1723 /*******************  Bit definition for DMA_CCR register  ********************/
1724 #define DMA_CCR_EN_Pos         (0U)
1725 #define DMA_CCR_EN_Msk         (0x1UL << DMA_CCR_EN_Pos)                       /*!< 0x00000001 */
1726 #define DMA_CCR_EN             DMA_CCR_EN_Msk                                  /*!< Channel enable                      */
1727 #define DMA_CCR_TCIE_Pos       (1U)
1728 #define DMA_CCR_TCIE_Msk       (0x1UL << DMA_CCR_TCIE_Pos)                     /*!< 0x00000002 */
1729 #define DMA_CCR_TCIE           DMA_CCR_TCIE_Msk                                /*!< Transfer complete interrupt enable  */
1730 #define DMA_CCR_HTIE_Pos       (2U)
1731 #define DMA_CCR_HTIE_Msk       (0x1UL << DMA_CCR_HTIE_Pos)                     /*!< 0x00000004 */
1732 #define DMA_CCR_HTIE           DMA_CCR_HTIE_Msk                                /*!< Half Transfer interrupt enable      */
1733 #define DMA_CCR_TEIE_Pos       (3U)
1734 #define DMA_CCR_TEIE_Msk       (0x1UL << DMA_CCR_TEIE_Pos)                     /*!< 0x00000008 */
1735 #define DMA_CCR_TEIE           DMA_CCR_TEIE_Msk                                /*!< Transfer error interrupt enable     */
1736 #define DMA_CCR_DIR_Pos        (4U)
1737 #define DMA_CCR_DIR_Msk        (0x1UL << DMA_CCR_DIR_Pos)                      /*!< 0x00000010 */
1738 #define DMA_CCR_DIR            DMA_CCR_DIR_Msk                                 /*!< Data transfer direction             */
1739 #define DMA_CCR_CIRC_Pos       (5U)
1740 #define DMA_CCR_CIRC_Msk       (0x1UL << DMA_CCR_CIRC_Pos)                     /*!< 0x00000020 */
1741 #define DMA_CCR_CIRC           DMA_CCR_CIRC_Msk                                /*!< Circular mode                       */
1742 #define DMA_CCR_PINC_Pos       (6U)
1743 #define DMA_CCR_PINC_Msk       (0x1UL << DMA_CCR_PINC_Pos)                     /*!< 0x00000040 */
1744 #define DMA_CCR_PINC           DMA_CCR_PINC_Msk                                /*!< Peripheral increment mode           */
1745 #define DMA_CCR_MINC_Pos       (7U)
1746 #define DMA_CCR_MINC_Msk       (0x1UL << DMA_CCR_MINC_Pos)                     /*!< 0x00000080 */
1747 #define DMA_CCR_MINC           DMA_CCR_MINC_Msk                                /*!< Memory increment mode               */
1748 
1749 #define DMA_CCR_PSIZE_Pos      (8U)
1750 #define DMA_CCR_PSIZE_Msk      (0x3UL << DMA_CCR_PSIZE_Pos)                    /*!< 0x00000300 */
1751 #define DMA_CCR_PSIZE          DMA_CCR_PSIZE_Msk                               /*!< PSIZE[1:0] bits (Peripheral size)   */
1752 #define DMA_CCR_PSIZE_0        (0x1UL << DMA_CCR_PSIZE_Pos)                    /*!< 0x00000100 */
1753 #define DMA_CCR_PSIZE_1        (0x2UL << DMA_CCR_PSIZE_Pos)                    /*!< 0x00000200 */
1754 
1755 #define DMA_CCR_MSIZE_Pos      (10U)
1756 #define DMA_CCR_MSIZE_Msk      (0x3UL << DMA_CCR_MSIZE_Pos)                    /*!< 0x00000C00 */
1757 #define DMA_CCR_MSIZE          DMA_CCR_MSIZE_Msk                               /*!< MSIZE[1:0] bits (Memory size)       */
1758 #define DMA_CCR_MSIZE_0        (0x1UL << DMA_CCR_MSIZE_Pos)                    /*!< 0x00000400 */
1759 #define DMA_CCR_MSIZE_1        (0x2UL << DMA_CCR_MSIZE_Pos)                    /*!< 0x00000800 */
1760 
1761 #define DMA_CCR_PL_Pos         (12U)
1762 #define DMA_CCR_PL_Msk         (0x3UL << DMA_CCR_PL_Pos)                       /*!< 0x00003000 */
1763 #define DMA_CCR_PL             DMA_CCR_PL_Msk                                  /*!< PL[1:0] bits(Channel Priority level)*/
1764 #define DMA_CCR_PL_0           (0x1UL << DMA_CCR_PL_Pos)                       /*!< 0x00001000 */
1765 #define DMA_CCR_PL_1           (0x2UL << DMA_CCR_PL_Pos)                        /*!< 0x00002000 */
1766 
1767 #define DMA_CCR_MEM2MEM_Pos    (14U)
1768 #define DMA_CCR_MEM2MEM_Msk    (0x1UL << DMA_CCR_MEM2MEM_Pos)                  /*!< 0x00004000 */
1769 #define DMA_CCR_MEM2MEM        DMA_CCR_MEM2MEM_Msk                             /*!< Memory to memory mode               */
1770 
1771 /******************  Bit definition for DMA_CNDTR register  *******************/
1772 #define DMA_CNDTR_NDT_Pos      (0U)
1773 #define DMA_CNDTR_NDT_Msk      (0xFFFFUL << DMA_CNDTR_NDT_Pos)                 /*!< 0x0000FFFF */
1774 #define DMA_CNDTR_NDT          DMA_CNDTR_NDT_Msk                               /*!< Number of data to Transfer          */
1775 
1776 /******************  Bit definition for DMA_CPAR register  ********************/
1777 #define DMA_CPAR_PA_Pos        (0U)
1778 #define DMA_CPAR_PA_Msk        (0xFFFFFFFFUL << DMA_CPAR_PA_Pos)               /*!< 0xFFFFFFFF */
1779 #define DMA_CPAR_PA            DMA_CPAR_PA_Msk                                 /*!< Peripheral Address                  */
1780 
1781 /******************  Bit definition for DMA_CMAR register  ********************/
1782 #define DMA_CMAR_MA_Pos        (0U)
1783 #define DMA_CMAR_MA_Msk        (0xFFFFFFFFUL << DMA_CMAR_MA_Pos)               /*!< 0xFFFFFFFF */
1784 #define DMA_CMAR_MA            DMA_CMAR_MA_Msk                                 /*!< Memory Address                      */
1785 
1786 /******************************************************************************/
1787 /*                                                                            */
1788 /*                             DMAMUX Controller                              */
1789 /*                                                                            */
1790 /******************************************************************************/
1791 /********************  Bits definition for DMAMUX_CxCR register  **************/
1792 #define DMAMUX_CxCR_DMAREQ_ID_Pos              (0U)
1793 #define DMAMUX_CxCR_DMAREQ_ID_Msk              (0x7FUL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x0000007F */
1794 #define DMAMUX_CxCR_DMAREQ_ID                  DMAMUX_CxCR_DMAREQ_ID_Msk             /*!< DMA Request ID   */
1795 #define DMAMUX_CxCR_DMAREQ_ID_0                (0x01UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000001 */
1796 #define DMAMUX_CxCR_DMAREQ_ID_1                (0x02UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000002 */
1797 #define DMAMUX_CxCR_DMAREQ_ID_2                (0x04UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000004 */
1798 #define DMAMUX_CxCR_DMAREQ_ID_3                (0x08UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000008 */
1799 #define DMAMUX_CxCR_DMAREQ_ID_4                (0x10UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000010 */
1800 #define DMAMUX_CxCR_DMAREQ_ID_5                (0x20UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000020 */
1801 #define DMAMUX_CxCR_DMAREQ_ID_6                (0x40UL << DMAMUX_CxCR_DMAREQ_ID_Pos) /*!< 0x00000040 */
1802 #define DMAMUX_CxCR_SOIE_Pos                   (8U)
1803 #define DMAMUX_CxCR_SOIE_Msk                   (0x1UL << DMAMUX_CxCR_SOIE_Pos)  /*!< 0x00000100 */
1804 #define DMAMUX_CxCR_SOIE                       DMAMUX_CxCR_SOIE_Msk             /*!< Synchro overrun interrupt enable     */
1805 #define DMAMUX_CxCR_EGE_Pos                    (9U)
1806 #define DMAMUX_CxCR_EGE_Msk                    (0x1UL << DMAMUX_CxCR_EGE_Pos)   /*!< 0x00000200 */
1807 #define DMAMUX_CxCR_EGE                        DMAMUX_CxCR_EGE_Msk              /*!< Event generation interrupt enable    */
1808 #define DMAMUX_CxCR_SE_Pos                     (16U)
1809 #define DMAMUX_CxCR_SE_Msk                     (0x1UL << DMAMUX_CxCR_SE_Pos)    /*!< 0x00010000 */
1810 #define DMAMUX_CxCR_SE                         DMAMUX_CxCR_SE_Msk               /*!< Synchronization enable               */
1811 #define DMAMUX_CxCR_SPOL_Pos                   (17U)
1812 #define DMAMUX_CxCR_SPOL_Msk                   (0x3UL << DMAMUX_CxCR_SPOL_Pos)  /*!< 0x00060000 */
1813 #define DMAMUX_CxCR_SPOL                       DMAMUX_CxCR_SPOL_Msk             /*!< Synchronization polarity             */
1814 #define DMAMUX_CxCR_SPOL_0                     (0x1UL << DMAMUX_CxCR_SPOL_Pos)  /*!< 0x00020000 */
1815 #define DMAMUX_CxCR_SPOL_1                     (0x2UL << DMAMUX_CxCR_SPOL_Pos)  /*!< 0x00040000 */
1816 #define DMAMUX_CxCR_NBREQ_Pos                  (19U)
1817 #define DMAMUX_CxCR_NBREQ_Msk                  (0x1FUL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00F80000 */
1818 #define DMAMUX_CxCR_NBREQ                      DMAMUX_CxCR_NBREQ_Msk             /*!< Number of request                    */
1819 #define DMAMUX_CxCR_NBREQ_0                    (0x01UL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00080000 */
1820 #define DMAMUX_CxCR_NBREQ_1                    (0x02UL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00100000 */
1821 #define DMAMUX_CxCR_NBREQ_2                    (0x04UL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00200000 */
1822 #define DMAMUX_CxCR_NBREQ_3                    (0x08UL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00400000 */
1823 #define DMAMUX_CxCR_NBREQ_4                    (0x10UL << DMAMUX_CxCR_NBREQ_Pos) /*!< 0x00800000 */
1824 #define DMAMUX_CxCR_SYNC_ID_Pos                (24U)
1825 #define DMAMUX_CxCR_SYNC_ID_Msk                (0x1FUL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x1F000000 */
1826 #define DMAMUX_CxCR_SYNC_ID                    DMAMUX_CxCR_SYNC_ID_Msk             /*!< Synchronization ID                   */
1827 #define DMAMUX_CxCR_SYNC_ID_0                  (0x01UL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x01000000 */
1828 #define DMAMUX_CxCR_SYNC_ID_1                  (0x02UL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x02000000 */
1829 #define DMAMUX_CxCR_SYNC_ID_2                  (0x04UL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x04000000 */
1830 #define DMAMUX_CxCR_SYNC_ID_3                  (0x08UL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x08000000 */
1831 #define DMAMUX_CxCR_SYNC_ID_4                  (0x10UL << DMAMUX_CxCR_SYNC_ID_Pos) /*!< 0x10000000 */
1832 
1833 /*******************  Bits definition for DMAMUX_CSR register  **************/
1834 #define DMAMUX_CSR_SOF0_Pos                    (0U)
1835 #define DMAMUX_CSR_SOF0_Msk                    (0x1UL << DMAMUX_CSR_SOF0_Pos)  /*!< 0x00000001 */
1836 #define DMAMUX_CSR_SOF0                        DMAMUX_CSR_SOF0_Msk             /*!< Synchronization Overrun Flag 0       */
1837 #define DMAMUX_CSR_SOF1_Pos                    (1U)
1838 #define DMAMUX_CSR_SOF1_Msk                    (0x1UL << DMAMUX_CSR_SOF1_Pos)  /*!< 0x00000002 */
1839 #define DMAMUX_CSR_SOF1                        DMAMUX_CSR_SOF1_Msk             /*!< Synchronization Overrun Flag 1       */
1840 #define DMAMUX_CSR_SOF2_Pos                    (2U)
1841 #define DMAMUX_CSR_SOF2_Msk                    (0x1UL << DMAMUX_CSR_SOF2_Pos)  /*!< 0x00000004 */
1842 #define DMAMUX_CSR_SOF2                        DMAMUX_CSR_SOF2_Msk             /*!< Synchronization Overrun Flag 2       */
1843 #define DMAMUX_CSR_SOF3_Pos                    (3U)
1844 #define DMAMUX_CSR_SOF3_Msk                    (0x1UL << DMAMUX_CSR_SOF3_Pos)  /*!< 0x00000008 */
1845 #define DMAMUX_CSR_SOF3                        DMAMUX_CSR_SOF3_Msk             /*!< Synchronization Overrun Flag 3       */
1846 #define DMAMUX_CSR_SOF4_Pos                    (4U)
1847 #define DMAMUX_CSR_SOF4_Msk                    (0x1UL << DMAMUX_CSR_SOF4_Pos)  /*!< 0x00000010 */
1848 #define DMAMUX_CSR_SOF4                        DMAMUX_CSR_SOF4_Msk             /*!< Synchronization Overrun Flag 4       */
1849 #define DMAMUX_CSR_SOF5_Pos                    (5U)
1850 #define DMAMUX_CSR_SOF5_Msk                    (0x1UL << DMAMUX_CSR_SOF5_Pos)  /*!< 0x00000020 */
1851 #define DMAMUX_CSR_SOF5                        DMAMUX_CSR_SOF5_Msk             /*!< Synchronization Overrun Flag 5       */
1852 #define DMAMUX_CSR_SOF6_Pos                    (6U)
1853 #define DMAMUX_CSR_SOF6_Msk                    (0x1UL << DMAMUX_CSR_SOF6_Pos)  /*!< 0x00000040 */
1854 #define DMAMUX_CSR_SOF6                        DMAMUX_CSR_SOF6_Msk             /*!< Synchronization Overrun Flag 6       */
1855 #define DMAMUX_CSR_SOF7_Pos                    (7U)
1856 #define DMAMUX_CSR_SOF7_Msk                    (0x1UL << DMAMUX_CSR_SOF7_Pos)  /*!< 0x00000080 */
1857 #define DMAMUX_CSR_SOF7                        DMAMUX_CSR_SOF7_Msk             /*!< Synchronization Overrun Flag 7       */
1858 #define DMAMUX_CSR_SOF8_Pos                    (8U)
1859 #define DMAMUX_CSR_SOF8_Msk                    (0x1UL << DMAMUX_CSR_SOF8_Pos)  /*!< 0x00000100 */
1860 #define DMAMUX_CSR_SOF8                        DMAMUX_CSR_SOF8_Msk             /*!< Synchronization Overrun Flag 8       */
1861 #define DMAMUX_CSR_SOF9_Pos                    (9U)
1862 #define DMAMUX_CSR_SOF9_Msk                    (0x1UL << DMAMUX_CSR_SOF9_Pos)  /*!< 0x00000200 */
1863 #define DMAMUX_CSR_SOF9                        DMAMUX_CSR_SOF9_Msk             /*!< Synchronization Overrun Flag 9       */
1864 #define DMAMUX_CSR_SOF10_Pos                   (10U)
1865 #define DMAMUX_CSR_SOF10_Msk                   (0x1UL << DMAMUX_CSR_SOF10_Pos)  /*!< 0x00000400 */
1866 #define DMAMUX_CSR_SOF10                       DMAMUX_CSR_SOF10_Msk             /*!< Synchronization Overrun Flag 10      */
1867 #define DMAMUX_CSR_SOF11_Pos                   (11U)
1868 #define DMAMUX_CSR_SOF11_Msk                   (0x1UL << DMAMUX_CSR_SOF11_Pos)  /*!< 0x00000800 */
1869 #define DMAMUX_CSR_SOF11                       DMAMUX_CSR_SOF11_Msk             /*!< Synchronization Overrun Flag 11      */
1870 
1871 /********************  Bits definition for DMAMUX_CFR register  **************/
1872 #define DMAMUX_CFR_CSOF0_Pos                   (0U)
1873 #define DMAMUX_CFR_CSOF0_Msk                   (0x1UL << DMAMUX_CFR_CSOF0_Pos)  /*!< 0x00000001 */
1874 #define DMAMUX_CFR_CSOF0                       DMAMUX_CFR_CSOF0_Msk             /*!< Clear Overrun Flag 0                 */
1875 #define DMAMUX_CFR_CSOF1_Pos                   (1U)
1876 #define DMAMUX_CFR_CSOF1_Msk                   (0x1UL << DMAMUX_CFR_CSOF1_Pos)  /*!< 0x00000002 */
1877 #define DMAMUX_CFR_CSOF1                       DMAMUX_CFR_CSOF1_Msk             /*!< Clear Overrun Flag 1                 */
1878 #define DMAMUX_CFR_CSOF2_Pos                   (2U)
1879 #define DMAMUX_CFR_CSOF2_Msk                   (0x1UL << DMAMUX_CFR_CSOF2_Pos)  /*!< 0x00000004 */
1880 #define DMAMUX_CFR_CSOF2                       DMAMUX_CFR_CSOF2_Msk             /*!< Clear Overrun Flag 2                 */
1881 #define DMAMUX_CFR_CSOF3_Pos                   (3U)
1882 #define DMAMUX_CFR_CSOF3_Msk                   (0x1UL << DMAMUX_CFR_CSOF3_Pos)  /*!< 0x00000008 */
1883 #define DMAMUX_CFR_CSOF3                       DMAMUX_CFR_CSOF3_Msk             /*!< Clear Overrun Flag 3                 */
1884 #define DMAMUX_CFR_CSOF4_Pos                   (4U)
1885 #define DMAMUX_CFR_CSOF4_Msk                   (0x1UL << DMAMUX_CFR_CSOF4_Pos)  /*!< 0x00000010 */
1886 #define DMAMUX_CFR_CSOF4                       DMAMUX_CFR_CSOF4_Msk             /*!< Clear Overrun Flag 4                 */
1887 #define DMAMUX_CFR_CSOF5_Pos                   (5U)
1888 #define DMAMUX_CFR_CSOF5_Msk                   (0x1UL << DMAMUX_CFR_CSOF5_Pos)  /*!< 0x00000020 */
1889 #define DMAMUX_CFR_CSOF5                       DMAMUX_CFR_CSOF5_Msk             /*!< Clear Overrun Flag 5                 */
1890 #define DMAMUX_CFR_CSOF6_Pos                   (6U)
1891 #define DMAMUX_CFR_CSOF6_Msk                   (0x1UL << DMAMUX_CFR_CSOF6_Pos)  /*!< 0x00000040 */
1892 #define DMAMUX_CFR_CSOF6                       DMAMUX_CFR_CSOF6_Msk             /*!< Clear Overrun Flag 6                 */
1893 #define DMAMUX_CFR_CSOF7_Pos                   (7U)
1894 #define DMAMUX_CFR_CSOF7_Msk                   (0x1UL << DMAMUX_CFR_CSOF7_Pos)  /*!< 0x00000080 */
1895 #define DMAMUX_CFR_CSOF7                       DMAMUX_CFR_CSOF7_Msk             /*!< Clear Overrun Flag 7                 */
1896 #define DMAMUX_CFR_CSOF8_Pos                   (8U)
1897 #define DMAMUX_CFR_CSOF8_Msk                   (0x1UL << DMAMUX_CFR_CSOF8_Pos)  /*!< 0x00000100 */
1898 #define DMAMUX_CFR_CSOF8                       DMAMUX_CFR_CSOF8_Msk             /*!< Clear Overrun Flag 8                 */
1899 #define DMAMUX_CFR_CSOF9_Pos                   (9U)
1900 #define DMAMUX_CFR_CSOF9_Msk                   (0x1UL << DMAMUX_CFR_CSOF9_Pos)  /*!< 0x00000200 */
1901 #define DMAMUX_CFR_CSOF9                       DMAMUX_CFR_CSOF9_Msk             /*!< Clear Overrun Flag 9                 */
1902 #define DMAMUX_CFR_CSOF10_Pos                  (10U)
1903 #define DMAMUX_CFR_CSOF10_Msk                  (0x1UL << DMAMUX_CFR_CSOF10_Pos)  /*!< 0x00000400 */
1904 #define DMAMUX_CFR_CSOF10                      DMAMUX_CFR_CSOF10_Msk             /*!< Clear Overrun Flag 10               */
1905 #define DMAMUX_CFR_CSOF11_Pos                  (11U)
1906 #define DMAMUX_CFR_CSOF11_Msk                  (0x1UL << DMAMUX_CFR_CSOF11_Pos)  /*!< 0x00000800 */
1907 #define DMAMUX_CFR_CSOF11                      DMAMUX_CFR_CSOF11_Msk             /*!< Clear Overrun Flag 11               */
1908 
1909 /********************  Bits definition for DMAMUX_RGxCR register  ************/
1910 #define DMAMUX_RGxCR_SIG_ID_Pos                (0U)
1911 #define DMAMUX_RGxCR_SIG_ID_Msk                (0x1FUL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x0000001F */
1912 #define DMAMUX_RGxCR_SIG_ID                    DMAMUX_RGxCR_SIG_ID_Msk             /*!< Signal ID                         */
1913 #define DMAMUX_RGxCR_SIG_ID_0                  (0x01UL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x00000001 */
1914 #define DMAMUX_RGxCR_SIG_ID_1                  (0x02UL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x00000002 */
1915 #define DMAMUX_RGxCR_SIG_ID_2                  (0x04UL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x00000004 */
1916 #define DMAMUX_RGxCR_SIG_ID_3                  (0x08UL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x00000008 */
1917 #define DMAMUX_RGxCR_SIG_ID_4                  (0x10UL << DMAMUX_RGxCR_SIG_ID_Pos) /*!< 0x00000010 */
1918 #define DMAMUX_RGxCR_OIE_Pos                   (8U)
1919 #define DMAMUX_RGxCR_OIE_Msk                   (0x1UL << DMAMUX_RGxCR_OIE_Pos)  /*!< 0x00000100 */
1920 #define DMAMUX_RGxCR_OIE                       DMAMUX_RGxCR_OIE_Msk             /*!< Overrun interrupt enable             */
1921 #define DMAMUX_RGxCR_GE_Pos                    (16U)
1922 #define DMAMUX_RGxCR_GE_Msk                    (0x1UL << DMAMUX_RGxCR_GE_Pos)   /*!< 0x00010000 */
1923 #define DMAMUX_RGxCR_GE                        DMAMUX_RGxCR_GE_Msk              /*!< Generation enable                    */
1924 #define DMAMUX_RGxCR_GPOL_Pos                  (17U)
1925 #define DMAMUX_RGxCR_GPOL_Msk                  (0x3UL << DMAMUX_RGxCR_GPOL_Pos) /*!< 0x00060000 */
1926 #define DMAMUX_RGxCR_GPOL                      DMAMUX_RGxCR_GPOL_Msk            /*!< Generation polarity                  */
1927 #define DMAMUX_RGxCR_GPOL_0                    (0x1UL << DMAMUX_RGxCR_GPOL_Pos) /*!< 0x00020000 */
1928 #define DMAMUX_RGxCR_GPOL_1                    (0x2UL << DMAMUX_RGxCR_GPOL_Pos) /*!< 0x00040000 */
1929 #define DMAMUX_RGxCR_GNBREQ_Pos                (19U)
1930 #define DMAMUX_RGxCR_GNBREQ_Msk                (0x1FUL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00F80000 */
1931 #define DMAMUX_RGxCR_GNBREQ                    DMAMUX_RGxCR_GNBREQ_Msk             /*!< Number of request                 */
1932 #define DMAMUX_RGxCR_GNBREQ_0                  (0x01UL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00080000 */
1933 #define DMAMUX_RGxCR_GNBREQ_1                  (0x02UL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00100000 */
1934 #define DMAMUX_RGxCR_GNBREQ_2                  (0x04UL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00200000 */
1935 #define DMAMUX_RGxCR_GNBREQ_3                  (0x08UL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00400000 */
1936 #define DMAMUX_RGxCR_GNBREQ_4                  (0x10UL << DMAMUX_RGxCR_GNBREQ_Pos) /*!< 0x00800000 */
1937 
1938 /********************  Bits definition for DMAMUX_RGSR register  **************/
1939 #define DMAMUX_RGSR_OF0_Pos                    (0U)
1940 #define DMAMUX_RGSR_OF0_Msk                    (0x1UL << DMAMUX_RGSR_OF0_Pos)   /*!< 0x00000001 */
1941 #define DMAMUX_RGSR_OF0                        DMAMUX_RGSR_OF0_Msk              /*!< Overrun flag 0                       */
1942 #define DMAMUX_RGSR_OF1_Pos                    (1U)
1943 #define DMAMUX_RGSR_OF1_Msk                    (0x1UL << DMAMUX_RGSR_OF1_Pos)   /*!< 0x00000002 */
1944 #define DMAMUX_RGSR_OF1                        DMAMUX_RGSR_OF1_Msk              /*!< Overrun flag 1                       */
1945 #define DMAMUX_RGSR_OF2_Pos                    (2U)
1946 #define DMAMUX_RGSR_OF2_Msk                    (0x1UL << DMAMUX_RGSR_OF2_Pos)   /*!< 0x00000004 */
1947 #define DMAMUX_RGSR_OF2                        DMAMUX_RGSR_OF2_Msk              /*!< Overrun flag 2                       */
1948 #define DMAMUX_RGSR_OF3_Pos                    (3U)
1949 #define DMAMUX_RGSR_OF3_Msk                    (0x1UL << DMAMUX_RGSR_OF3_Pos)   /*!< 0x00000008 */
1950 #define DMAMUX_RGSR_OF3                        DMAMUX_RGSR_OF3_Msk              /*!< Overrun flag 3                       */
1951 
1952 /********************  Bits definition for DMAMUX_RGCFR register  **************/
1953 #define DMAMUX_RGCFR_COF0_Pos                  (0U)
1954 #define DMAMUX_RGCFR_COF0_Msk                  (0x1UL << DMAMUX_RGCFR_COF0_Pos) /*!< 0x00000001 */
1955 #define DMAMUX_RGCFR_COF0                      DMAMUX_RGCFR_COF0_Msk            /*!< Clear Overrun flag 0                 */
1956 #define DMAMUX_RGCFR_COF1_Pos                  (1U)
1957 #define DMAMUX_RGCFR_COF1_Msk                  (0x1UL << DMAMUX_RGCFR_COF1_Pos) /*!< 0x00000002 */
1958 #define DMAMUX_RGCFR_COF1                      DMAMUX_RGCFR_COF1_Msk            /*!< Clear Overrun flag 1                 */
1959 #define DMAMUX_RGCFR_COF2_Pos                  (2U)
1960 #define DMAMUX_RGCFR_COF2_Msk                  (0x1UL << DMAMUX_RGCFR_COF2_Pos) /*!< 0x00000004 */
1961 #define DMAMUX_RGCFR_COF2                      DMAMUX_RGCFR_COF2_Msk            /*!< Clear Overrun flag 2                 */
1962 #define DMAMUX_RGCFR_COF3_Pos                  (3U)
1963 #define DMAMUX_RGCFR_COF3_Msk                  (0x1UL << DMAMUX_RGCFR_COF3_Pos) /*!< 0x00000008 */
1964 #define DMAMUX_RGCFR_COF3                      DMAMUX_RGCFR_COF3_Msk            /*!< Clear Overrun flag 3                 */
1965 
1966 /******************************************************************************/
1967 /*                                                                            */
1968 /*                    External Interrupt/Event Controller                     */
1969 /*                                                                            */
1970 /******************************************************************************/
1971 /******************  Bit definition for EXTI_RTSR1 register  ******************/
1972 #define EXTI_RTSR1_RT0_Pos           (0U)
1973 #define EXTI_RTSR1_RT0_Msk           (0x1UL << EXTI_RTSR1_RT0_Pos)             /*!< 0x00000001 */
1974 #define EXTI_RTSR1_RT0               EXTI_RTSR1_RT0_Msk                        /*!< Rising trigger configuration for input line 0 */
1975 #define EXTI_RTSR1_RT1_Pos           (1U)
1976 #define EXTI_RTSR1_RT1_Msk           (0x1UL << EXTI_RTSR1_RT1_Pos)             /*!< 0x00000002 */
1977 #define EXTI_RTSR1_RT1               EXTI_RTSR1_RT1_Msk                        /*!< Rising trigger configuration for input line 1 */
1978 #define EXTI_RTSR1_RT2_Pos           (2U)
1979 #define EXTI_RTSR1_RT2_Msk           (0x1UL << EXTI_RTSR1_RT2_Pos)             /*!< 0x00000004 */
1980 #define EXTI_RTSR1_RT2               EXTI_RTSR1_RT2_Msk                        /*!< Rising trigger configuration for input line 2 */
1981 #define EXTI_RTSR1_RT3_Pos           (3U)
1982 #define EXTI_RTSR1_RT3_Msk           (0x1UL << EXTI_RTSR1_RT3_Pos)             /*!< 0x00000008 */
1983 #define EXTI_RTSR1_RT3               EXTI_RTSR1_RT3_Msk                        /*!< Rising trigger configuration for input line 3 */
1984 #define EXTI_RTSR1_RT4_Pos           (4U)
1985 #define EXTI_RTSR1_RT4_Msk           (0x1UL << EXTI_RTSR1_RT4_Pos)             /*!< 0x00000010 */
1986 #define EXTI_RTSR1_RT4               EXTI_RTSR1_RT4_Msk                        /*!< Rising trigger configuration for input line 4 */
1987 #define EXTI_RTSR1_RT5_Pos           (5U)
1988 #define EXTI_RTSR1_RT5_Msk           (0x1UL << EXTI_RTSR1_RT5_Pos)             /*!< 0x00000020 */
1989 #define EXTI_RTSR1_RT5               EXTI_RTSR1_RT5_Msk                        /*!< Rising trigger configuration for input line 5 */
1990 #define EXTI_RTSR1_RT6_Pos           (6U)
1991 #define EXTI_RTSR1_RT6_Msk           (0x1UL << EXTI_RTSR1_RT6_Pos)             /*!< 0x00000040 */
1992 #define EXTI_RTSR1_RT6               EXTI_RTSR1_RT6_Msk                        /*!< Rising trigger configuration for input line 6 */
1993 #define EXTI_RTSR1_RT7_Pos           (7U)
1994 #define EXTI_RTSR1_RT7_Msk           (0x1UL << EXTI_RTSR1_RT7_Pos)             /*!< 0x00000080 */
1995 #define EXTI_RTSR1_RT7               EXTI_RTSR1_RT7_Msk                        /*!< Rising trigger configuration for input line 7 */
1996 #define EXTI_RTSR1_RT8_Pos           (8U)
1997 #define EXTI_RTSR1_RT8_Msk           (0x1UL << EXTI_RTSR1_RT8_Pos)             /*!< 0x00000100 */
1998 #define EXTI_RTSR1_RT8               EXTI_RTSR1_RT8_Msk                        /*!< Rising trigger configuration for input line 8 */
1999 #define EXTI_RTSR1_RT9_Pos           (9U)
2000 #define EXTI_RTSR1_RT9_Msk           (0x1UL << EXTI_RTSR1_RT9_Pos)             /*!< 0x00000200 */
2001 #define EXTI_RTSR1_RT9               EXTI_RTSR1_RT9_Msk                        /*!< Rising trigger configuration for input line 9 */
2002 #define EXTI_RTSR1_RT10_Pos          (10U)
2003 #define EXTI_RTSR1_RT10_Msk          (0x1UL << EXTI_RTSR1_RT10_Pos)            /*!< 0x00000400 */
2004 #define EXTI_RTSR1_RT10              EXTI_RTSR1_RT10_Msk                       /*!< Rising trigger configuration for input line 10 */
2005 #define EXTI_RTSR1_RT11_Pos          (11U)
2006 #define EXTI_RTSR1_RT11_Msk          (0x1UL << EXTI_RTSR1_RT11_Pos)            /*!< 0x00000800 */
2007 #define EXTI_RTSR1_RT11              EXTI_RTSR1_RT11_Msk                       /*!< Rising trigger configuration for input line 11 */
2008 #define EXTI_RTSR1_RT12_Pos          (12U)
2009 #define EXTI_RTSR1_RT12_Msk          (0x1UL << EXTI_RTSR1_RT12_Pos)            /*!< 0x00001000 */
2010 #define EXTI_RTSR1_RT12              EXTI_RTSR1_RT12_Msk                       /*!< Rising trigger configuration for input line 12 */
2011 #define EXTI_RTSR1_RT13_Pos          (13U)
2012 #define EXTI_RTSR1_RT13_Msk          (0x1UL << EXTI_RTSR1_RT13_Pos)            /*!< 0x00002000 */
2013 #define EXTI_RTSR1_RT13              EXTI_RTSR1_RT13_Msk                       /*!< Rising trigger configuration for input line 13 */
2014 #define EXTI_RTSR1_RT14_Pos          (14U)
2015 #define EXTI_RTSR1_RT14_Msk          (0x1UL << EXTI_RTSR1_RT14_Pos)            /*!< 0x00004000 */
2016 #define EXTI_RTSR1_RT14              EXTI_RTSR1_RT14_Msk                       /*!< Rising trigger configuration for input line 14 */
2017 #define EXTI_RTSR1_RT15_Pos          (15U)
2018 #define EXTI_RTSR1_RT15_Msk          (0x1UL << EXTI_RTSR1_RT15_Pos)            /*!< 0x00008000 */
2019 #define EXTI_RTSR1_RT15              EXTI_RTSR1_RT15_Msk                       /*!< Rising trigger configuration for input line 15 */
2020 
2021 /******************  Bit definition for EXTI_FTSR1 register  ******************/
2022 #define EXTI_FTSR1_FT0_Pos           (0U)
2023 #define EXTI_FTSR1_FT0_Msk           (0x1UL << EXTI_FTSR1_FT0_Pos)             /*!< 0x00000001 */
2024 #define EXTI_FTSR1_FT0               EXTI_FTSR1_FT0_Msk                        /*!< Falling trigger configuration for input line 0 */
2025 #define EXTI_FTSR1_FT1_Pos           (1U)
2026 #define EXTI_FTSR1_FT1_Msk           (0x1UL << EXTI_FTSR1_FT1_Pos)             /*!< 0x00000002 */
2027 #define EXTI_FTSR1_FT1               EXTI_FTSR1_FT1_Msk                        /*!< Falling trigger configuration for input line 1 */
2028 #define EXTI_FTSR1_FT2_Pos           (2U)
2029 #define EXTI_FTSR1_FT2_Msk           (0x1UL << EXTI_FTSR1_FT2_Pos)             /*!< 0x00000004 */
2030 #define EXTI_FTSR1_FT2               EXTI_FTSR1_FT2_Msk                        /*!< Falling trigger configuration for input line 2 */
2031 #define EXTI_FTSR1_FT3_Pos           (3U)
2032 #define EXTI_FTSR1_FT3_Msk           (0x1UL << EXTI_FTSR1_FT3_Pos)             /*!< 0x00000008 */
2033 #define EXTI_FTSR1_FT3               EXTI_FTSR1_FT3_Msk                        /*!< Falling trigger configuration for input line 3 */
2034 #define EXTI_FTSR1_FT4_Pos           (4U)
2035 #define EXTI_FTSR1_FT4_Msk           (0x1UL << EXTI_FTSR1_FT4_Pos)             /*!< 0x00000010 */
2036 #define EXTI_FTSR1_FT4               EXTI_FTSR1_FT4_Msk                        /*!< Falling trigger configuration for input line 4 */
2037 #define EXTI_FTSR1_FT5_Pos           (5U)
2038 #define EXTI_FTSR1_FT5_Msk           (0x1UL << EXTI_FTSR1_FT5_Pos)             /*!< 0x00000020 */
2039 #define EXTI_FTSR1_FT5               EXTI_FTSR1_FT5_Msk                        /*!< Falling trigger configuration for input line 5 */
2040 #define EXTI_FTSR1_FT6_Pos           (6U)
2041 #define EXTI_FTSR1_FT6_Msk           (0x1UL << EXTI_FTSR1_FT6_Pos)             /*!< 0x00000040 */
2042 #define EXTI_FTSR1_FT6               EXTI_FTSR1_FT6_Msk                        /*!< Falling trigger configuration for input line 6 */
2043 #define EXTI_FTSR1_FT7_Pos           (7U)
2044 #define EXTI_FTSR1_FT7_Msk           (0x1UL << EXTI_FTSR1_FT7_Pos)             /*!< 0x00000080 */
2045 #define EXTI_FTSR1_FT7               EXTI_FTSR1_FT7_Msk                        /*!< Falling trigger configuration for input line 7 */
2046 #define EXTI_FTSR1_FT8_Pos           (8U)
2047 #define EXTI_FTSR1_FT8_Msk           (0x1UL << EXTI_FTSR1_FT8_Pos)             /*!< 0x00000100 */
2048 #define EXTI_FTSR1_FT8               EXTI_FTSR1_FT8_Msk                        /*!< Falling trigger configuration for input line 8 */
2049 #define EXTI_FTSR1_FT9_Pos           (9U)
2050 #define EXTI_FTSR1_FT9_Msk           (0x1UL << EXTI_FTSR1_FT9_Pos)             /*!< 0x00000200 */
2051 #define EXTI_FTSR1_FT9               EXTI_FTSR1_FT9_Msk                        /*!< Falling trigger configuration for input line 9 */
2052 #define EXTI_FTSR1_FT10_Pos          (10U)
2053 #define EXTI_FTSR1_FT10_Msk          (0x1UL << EXTI_FTSR1_FT10_Pos)            /*!< 0x00000400 */
2054 #define EXTI_FTSR1_FT10              EXTI_FTSR1_FT10_Msk                       /*!< Falling trigger configuration for input line 10 */
2055 #define EXTI_FTSR1_FT11_Pos          (11U)
2056 #define EXTI_FTSR1_FT11_Msk          (0x1UL << EXTI_FTSR1_FT11_Pos)            /*!< 0x00000800 */
2057 #define EXTI_FTSR1_FT11              EXTI_FTSR1_FT11_Msk                       /*!< Falling trigger configuration for input line 11 */
2058 #define EXTI_FTSR1_FT12_Pos          (12U)
2059 #define EXTI_FTSR1_FT12_Msk          (0x1UL << EXTI_FTSR1_FT12_Pos)            /*!< 0x00001000 */
2060 #define EXTI_FTSR1_FT12              EXTI_FTSR1_FT12_Msk                       /*!< Falling trigger configuration for input line 12 */
2061 #define EXTI_FTSR1_FT13_Pos          (13U)
2062 #define EXTI_FTSR1_FT13_Msk          (0x1UL << EXTI_FTSR1_FT13_Pos)            /*!< 0x00002000 */
2063 #define EXTI_FTSR1_FT13              EXTI_FTSR1_FT13_Msk                       /*!< Falling trigger configuration for input line 13 */
2064 #define EXTI_FTSR1_FT14_Pos          (14U)
2065 #define EXTI_FTSR1_FT14_Msk          (0x1UL << EXTI_FTSR1_FT14_Pos)            /*!< 0x00004000 */
2066 #define EXTI_FTSR1_FT14              EXTI_FTSR1_FT14_Msk                       /*!< Falling trigger configuration for input line 14 */
2067 #define EXTI_FTSR1_FT15_Pos          (15U)
2068 #define EXTI_FTSR1_FT15_Msk          (0x1UL << EXTI_FTSR1_FT15_Pos)            /*!< 0x00008000 */
2069 #define EXTI_FTSR1_FT15              EXTI_FTSR1_FT15_Msk                       /*!< Falling trigger configuration for input line 15 */
2070 
2071 /******************  Bit definition for EXTI_SWIER1 register  *****************/
2072 #define EXTI_SWIER1_SWI0_Pos         (0U)
2073 #define EXTI_SWIER1_SWI0_Msk         (0x1UL << EXTI_SWIER1_SWI0_Pos)           /*!< 0x00000001 */
2074 #define EXTI_SWIER1_SWI0             EXTI_SWIER1_SWI0_Msk                      /*!< Software Interrupt on line 0 */
2075 #define EXTI_SWIER1_SWI1_Pos         (1U)
2076 #define EXTI_SWIER1_SWI1_Msk         (0x1UL << EXTI_SWIER1_SWI1_Pos)           /*!< 0x00000002 */
2077 #define EXTI_SWIER1_SWI1             EXTI_SWIER1_SWI1_Msk                      /*!< Software Interrupt on line 1 */
2078 #define EXTI_SWIER1_SWI2_Pos         (2U)
2079 #define EXTI_SWIER1_SWI2_Msk         (0x1UL << EXTI_SWIER1_SWI2_Pos)           /*!< 0x00000004 */
2080 #define EXTI_SWIER1_SWI2             EXTI_SWIER1_SWI2_Msk                      /*!< Software Interrupt on line 2 */
2081 #define EXTI_SWIER1_SWI3_Pos         (3U)
2082 #define EXTI_SWIER1_SWI3_Msk         (0x1UL << EXTI_SWIER1_SWI3_Pos)           /*!< 0x00000008 */
2083 #define EXTI_SWIER1_SWI3             EXTI_SWIER1_SWI3_Msk                      /*!< Software Interrupt on line 3 */
2084 #define EXTI_SWIER1_SWI4_Pos         (4U)
2085 #define EXTI_SWIER1_SWI4_Msk         (0x1UL << EXTI_SWIER1_SWI4_Pos)           /*!< 0x00000010 */
2086 #define EXTI_SWIER1_SWI4             EXTI_SWIER1_SWI4_Msk                      /*!< Software Interrupt on line 4 */
2087 #define EXTI_SWIER1_SWI5_Pos         (5U)
2088 #define EXTI_SWIER1_SWI5_Msk         (0x1UL << EXTI_SWIER1_SWI5_Pos)           /*!< 0x00000020 */
2089 #define EXTI_SWIER1_SWI5             EXTI_SWIER1_SWI5_Msk                      /*!< Software Interrupt on line 5 */
2090 #define EXTI_SWIER1_SWI6_Pos         (6U)
2091 #define EXTI_SWIER1_SWI6_Msk         (0x1UL << EXTI_SWIER1_SWI6_Pos)           /*!< 0x00000040 */
2092 #define EXTI_SWIER1_SWI6             EXTI_SWIER1_SWI6_Msk                      /*!< Software Interrupt on line 6 */
2093 #define EXTI_SWIER1_SWI7_Pos         (7U)
2094 #define EXTI_SWIER1_SWI7_Msk         (0x1UL << EXTI_SWIER1_SWI7_Pos)           /*!< 0x00000080 */
2095 #define EXTI_SWIER1_SWI7             EXTI_SWIER1_SWI7_Msk                      /*!< Software Interrupt on line 7 */
2096 #define EXTI_SWIER1_SWI8_Pos         (8U)
2097 #define EXTI_SWIER1_SWI8_Msk         (0x1UL << EXTI_SWIER1_SWI8_Pos)           /*!< 0x00000100 */
2098 #define EXTI_SWIER1_SWI8             EXTI_SWIER1_SWI8_Msk                      /*!< Software Interrupt on line 8 */
2099 #define EXTI_SWIER1_SWI9_Pos         (9U)
2100 #define EXTI_SWIER1_SWI9_Msk         (0x1UL << EXTI_SWIER1_SWI9_Pos)           /*!< 0x00000200 */
2101 #define EXTI_SWIER1_SWI9             EXTI_SWIER1_SWI9_Msk                      /*!< Software Interrupt on line 9 */
2102 #define EXTI_SWIER1_SWI10_Pos        (10U)
2103 #define EXTI_SWIER1_SWI10_Msk        (0x1UL << EXTI_SWIER1_SWI10_Pos)          /*!< 0x00000400 */
2104 #define EXTI_SWIER1_SWI10            EXTI_SWIER1_SWI10_Msk                     /*!< Software Interrupt on line 10 */
2105 #define EXTI_SWIER1_SWI11_Pos        (11U)
2106 #define EXTI_SWIER1_SWI11_Msk        (0x1UL << EXTI_SWIER1_SWI11_Pos)          /*!< 0x00000800 */
2107 #define EXTI_SWIER1_SWI11            EXTI_SWIER1_SWI11_Msk                     /*!< Software Interrupt on line 11 */
2108 #define EXTI_SWIER1_SWI12_Pos        (12U)
2109 #define EXTI_SWIER1_SWI12_Msk        (0x1UL << EXTI_SWIER1_SWI12_Pos)          /*!< 0x00001000 */
2110 #define EXTI_SWIER1_SWI12            EXTI_SWIER1_SWI12_Msk                     /*!< Software Interrupt on line 12 */
2111 #define EXTI_SWIER1_SWI13_Pos        (13U)
2112 #define EXTI_SWIER1_SWI13_Msk        (0x1UL << EXTI_SWIER1_SWI13_Pos)          /*!< 0x00002000 */
2113 #define EXTI_SWIER1_SWI13            EXTI_SWIER1_SWI13_Msk                     /*!< Software Interrupt on line 13 */
2114 #define EXTI_SWIER1_SWI14_Pos        (14U)
2115 #define EXTI_SWIER1_SWI14_Msk        (0x1UL << EXTI_SWIER1_SWI14_Pos)          /*!< 0x00004000 */
2116 #define EXTI_SWIER1_SWI14            EXTI_SWIER1_SWI14_Msk                     /*!< Software Interrupt on line 14 */
2117 #define EXTI_SWIER1_SWI15_Pos        (15U)
2118 #define EXTI_SWIER1_SWI15_Msk        (0x1UL << EXTI_SWIER1_SWI15_Pos)          /*!< 0x00008000 */
2119 #define EXTI_SWIER1_SWI15            EXTI_SWIER1_SWI15_Msk                     /*!< Software Interrupt on line 15 */
2120 
2121 /*******************  Bit definition for EXTI_RPR1 register  ******************/
2122 #define EXTI_RPR1_RPIF0_Pos          (0U)
2123 #define EXTI_RPR1_RPIF0_Msk          (0x1UL << EXTI_RPR1_RPIF0_Pos)            /*!< 0x00000001 */
2124 #define EXTI_RPR1_RPIF0              EXTI_RPR1_RPIF0_Msk                       /*!< Rising Pending Interrupt Flag on line 0 */
2125 #define EXTI_RPR1_RPIF1_Pos          (1U)
2126 #define EXTI_RPR1_RPIF1_Msk          (0x1UL << EXTI_RPR1_RPIF1_Pos)            /*!< 0x00000002 */
2127 #define EXTI_RPR1_RPIF1              EXTI_RPR1_RPIF1_Msk                       /*!< Rising Pending Interrupt Flag on line 1 */
2128 #define EXTI_RPR1_RPIF2_Pos          (2U)
2129 #define EXTI_RPR1_RPIF2_Msk          (0x1UL << EXTI_RPR1_RPIF2_Pos)            /*!< 0x00000004 */
2130 #define EXTI_RPR1_RPIF2              EXTI_RPR1_RPIF2_Msk                       /*!< Rising Pending Interrupt Flag on line 2 */
2131 #define EXTI_RPR1_RPIF3_Pos          (3U)
2132 #define EXTI_RPR1_RPIF3_Msk          (0x1UL << EXTI_RPR1_RPIF3_Pos)            /*!< 0x00000008 */
2133 #define EXTI_RPR1_RPIF3              EXTI_RPR1_RPIF3_Msk                       /*!< Rising Pending Interrupt Flag on line 3 */
2134 #define EXTI_RPR1_RPIF4_Pos          (4U)
2135 #define EXTI_RPR1_RPIF4_Msk          (0x1UL << EXTI_RPR1_RPIF4_Pos)            /*!< 0x00000010 */
2136 #define EXTI_RPR1_RPIF4              EXTI_RPR1_RPIF4_Msk                       /*!< Rising Pending Interrupt Flag on line 4 */
2137 #define EXTI_RPR1_RPIF5_Pos          (5U)
2138 #define EXTI_RPR1_RPIF5_Msk          (0x1UL << EXTI_RPR1_RPIF5_Pos)            /*!< 0x00000020 */
2139 #define EXTI_RPR1_RPIF5              EXTI_RPR1_RPIF5_Msk                       /*!< Rising Pending Interrupt Flag on line 5 */
2140 #define EXTI_RPR1_RPIF6_Pos          (6U)
2141 #define EXTI_RPR1_RPIF6_Msk          (0x1UL << EXTI_RPR1_RPIF6_Pos)            /*!< 0x00000040 */
2142 #define EXTI_RPR1_RPIF6              EXTI_RPR1_RPIF6_Msk                       /*!< Rising Pending Interrupt Flag on line 6 */
2143 #define EXTI_RPR1_RPIF7_Pos          (7U)
2144 #define EXTI_RPR1_RPIF7_Msk          (0x1UL << EXTI_RPR1_RPIF7_Pos)            /*!< 0x00000080 */
2145 #define EXTI_RPR1_RPIF7              EXTI_RPR1_RPIF7_Msk                       /*!< Rising Pending Interrupt Flag on line 7 */
2146 #define EXTI_RPR1_RPIF8_Pos          (8U)
2147 #define EXTI_RPR1_RPIF8_Msk          (0x1UL << EXTI_RPR1_RPIF8_Pos)            /*!< 0x00000100 */
2148 #define EXTI_RPR1_RPIF8              EXTI_RPR1_RPIF8_Msk                       /*!< Rising Pending Interrupt Flag on line 8 */
2149 #define EXTI_RPR1_RPIF9_Pos          (9U)
2150 #define EXTI_RPR1_RPIF9_Msk          (0x1UL << EXTI_RPR1_RPIF9_Pos)            /*!< 0x00000200 */
2151 #define EXTI_RPR1_RPIF9              EXTI_RPR1_RPIF9_Msk                       /*!< Rising Pending Interrupt Flag on line 9 */
2152 #define EXTI_RPR1_RPIF10_Pos         (10U)
2153 #define EXTI_RPR1_RPIF10_Msk         (0x1UL << EXTI_RPR1_RPIF10_Pos)           /*!< 0x00000400 */
2154 #define EXTI_RPR1_RPIF10             EXTI_RPR1_RPIF10_Msk                      /*!< Rising Pending Interrupt Flag on line 10 */
2155 #define EXTI_RPR1_RPIF11_Pos         (11U)
2156 #define EXTI_RPR1_RPIF11_Msk         (0x1UL << EXTI_RPR1_RPIF11_Pos)           /*!< 0x00000800 */
2157 #define EXTI_RPR1_RPIF11             EXTI_RPR1_RPIF11_Msk                      /*!< Rising Pending Interrupt Flag on line 11 */
2158 #define EXTI_RPR1_RPIF12_Pos         (12U)
2159 #define EXTI_RPR1_RPIF12_Msk         (0x1UL << EXTI_RPR1_RPIF12_Pos)           /*!< 0x00001000 */
2160 #define EXTI_RPR1_RPIF12             EXTI_RPR1_RPIF12_Msk                      /*!< Rising Pending Interrupt Flag on line 12 */
2161 #define EXTI_RPR1_RPIF13_Pos         (13U)
2162 #define EXTI_RPR1_RPIF13_Msk         (0x1UL << EXTI_RPR1_RPIF13_Pos)           /*!< 0x00002000 */
2163 #define EXTI_RPR1_RPIF13             EXTI_RPR1_RPIF13_Msk                      /*!< Rising Pending Interrupt Flag on line 13 */
2164 #define EXTI_RPR1_RPIF14_Pos         (14U)
2165 #define EXTI_RPR1_RPIF14_Msk         (0x1UL << EXTI_RPR1_RPIF14_Pos)           /*!< 0x00004000 */
2166 #define EXTI_RPR1_RPIF14             EXTI_RPR1_RPIF14_Msk                      /*!< Rising Pending Interrupt Flag on line 14 */
2167 #define EXTI_RPR1_RPIF15_Pos         (15U)
2168 #define EXTI_RPR1_RPIF15_Msk         (0x1UL << EXTI_RPR1_RPIF15_Pos)           /*!< 0x00008000 */
2169 #define EXTI_RPR1_RPIF15             EXTI_RPR1_RPIF15_Msk                      /*!< Rising Pending Interrupt Flag on line 15 */
2170 
2171 /*******************  Bit definition for EXTI_FPR1 register  ******************/
2172 #define EXTI_FPR1_FPIF0_Pos          (0U)
2173 #define EXTI_FPR1_FPIF0_Msk          (0x1UL << EXTI_FPR1_FPIF0_Pos)            /*!< 0x00000001 */
2174 #define EXTI_FPR1_FPIF0              EXTI_FPR1_FPIF0_Msk                       /*!< Falling Pending Interrupt Flag on line 0 */
2175 #define EXTI_FPR1_FPIF1_Pos          (1U)
2176 #define EXTI_FPR1_FPIF1_Msk          (0x1UL << EXTI_FPR1_FPIF1_Pos)            /*!< 0x00000002 */
2177 #define EXTI_FPR1_FPIF1              EXTI_FPR1_FPIF1_Msk                       /*!< Falling Pending Interrupt Flag on line 1 */
2178 #define EXTI_FPR1_FPIF2_Pos          (2U)
2179 #define EXTI_FPR1_FPIF2_Msk          (0x1UL << EXTI_FPR1_FPIF2_Pos)            /*!< 0x00000004 */
2180 #define EXTI_FPR1_FPIF2              EXTI_FPR1_FPIF2_Msk                       /*!< Falling Pending Interrupt Flag on line 2 */
2181 #define EXTI_FPR1_FPIF3_Pos          (3U)
2182 #define EXTI_FPR1_FPIF3_Msk          (0x1UL << EXTI_FPR1_FPIF3_Pos)            /*!< 0x00000008 */
2183 #define EXTI_FPR1_FPIF3              EXTI_FPR1_FPIF3_Msk                       /*!< Falling Pending Interrupt Flag on line 3 */
2184 #define EXTI_FPR1_FPIF4_Pos          (4U)
2185 #define EXTI_FPR1_FPIF4_Msk          (0x1UL << EXTI_FPR1_FPIF4_Pos)            /*!< 0x00000010 */
2186 #define EXTI_FPR1_FPIF4              EXTI_FPR1_FPIF4_Msk                       /*!< Falling Pending Interrupt Flag on line 4 */
2187 #define EXTI_FPR1_FPIF5_Pos          (5U)
2188 #define EXTI_FPR1_FPIF5_Msk          (0x1UL << EXTI_FPR1_FPIF5_Pos)            /*!< 0x00000020 */
2189 #define EXTI_FPR1_FPIF5              EXTI_FPR1_FPIF5_Msk                       /*!< Falling Pending Interrupt Flag on line 5 */
2190 #define EXTI_FPR1_FPIF6_Pos          (6U)
2191 #define EXTI_FPR1_FPIF6_Msk          (0x1UL << EXTI_FPR1_FPIF6_Pos)            /*!< 0x00000040 */
2192 #define EXTI_FPR1_FPIF6              EXTI_FPR1_FPIF6_Msk                       /*!< Falling Pending Interrupt Flag on line 6 */
2193 #define EXTI_FPR1_FPIF7_Pos          (7U)
2194 #define EXTI_FPR1_FPIF7_Msk          (0x1UL << EXTI_FPR1_FPIF7_Pos)            /*!< 0x00000080 */
2195 #define EXTI_FPR1_FPIF7              EXTI_FPR1_FPIF7_Msk                       /*!< Falling Pending Interrupt Flag on line 7 */
2196 #define EXTI_FPR1_FPIF8_Pos          (8U)
2197 #define EXTI_FPR1_FPIF8_Msk          (0x1UL << EXTI_FPR1_FPIF8_Pos)            /*!< 0x00000100 */
2198 #define EXTI_FPR1_FPIF8              EXTI_FPR1_FPIF8_Msk                       /*!< Falling Pending Interrupt Flag on line 8 */
2199 #define EXTI_FPR1_FPIF9_Pos          (9U)
2200 #define EXTI_FPR1_FPIF9_Msk          (0x1UL << EXTI_FPR1_FPIF9_Pos)            /*!< 0x00000200 */
2201 #define EXTI_FPR1_FPIF9              EXTI_FPR1_FPIF9_Msk                       /*!< Falling Pending Interrupt Flag on line 9 */
2202 #define EXTI_FPR1_FPIF10_Pos         (10U)
2203 #define EXTI_FPR1_FPIF10_Msk         (0x1UL << EXTI_FPR1_FPIF10_Pos)           /*!< 0x00000400 */
2204 #define EXTI_FPR1_FPIF10             EXTI_FPR1_FPIF10_Msk                      /*!< Falling Pending Interrupt Flag on line 10 */
2205 #define EXTI_FPR1_FPIF11_Pos         (11U)
2206 #define EXTI_FPR1_FPIF11_Msk         (0x1UL << EXTI_FPR1_FPIF11_Pos)           /*!< 0x00000800 */
2207 #define EXTI_FPR1_FPIF11             EXTI_FPR1_FPIF11_Msk                      /*!< Falling Pending Interrupt Flag on line 11 */
2208 #define EXTI_FPR1_FPIF12_Pos         (12U)
2209 #define EXTI_FPR1_FPIF12_Msk         (0x1UL << EXTI_FPR1_FPIF12_Pos)           /*!< 0x00001000 */
2210 #define EXTI_FPR1_FPIF12             EXTI_FPR1_FPIF12_Msk                      /*!< Falling Pending Interrupt Flag on line 12 */
2211 #define EXTI_FPR1_FPIF13_Pos         (13U)
2212 #define EXTI_FPR1_FPIF13_Msk         (0x1UL << EXTI_FPR1_FPIF13_Pos)           /*!< 0x00002000 */
2213 #define EXTI_FPR1_FPIF13             EXTI_FPR1_FPIF13_Msk                      /*!< Falling Pending Interrupt Flag on line 13 */
2214 #define EXTI_FPR1_FPIF14_Pos         (14U)
2215 #define EXTI_FPR1_FPIF14_Msk         (0x1UL << EXTI_FPR1_FPIF14_Pos)           /*!< 0x00004000 */
2216 #define EXTI_FPR1_FPIF14             EXTI_FPR1_FPIF14_Msk                      /*!< Falling Pending Interrupt Flag on line 14 */
2217 #define EXTI_FPR1_FPIF15_Pos         (15U)
2218 #define EXTI_FPR1_FPIF15_Msk         (0x1UL << EXTI_FPR1_FPIF15_Pos)           /*!< 0x00008000 */
2219 #define EXTI_FPR1_FPIF15             EXTI_FPR1_FPIF15_Msk                      /*!< Falling Pending Interrupt Flag on line 15 */
2220 
2221 /*****************  Bit definition for EXTI_EXTICR1 register  **************/
2222 #define EXTI_EXTICR1_EXTI0_Pos       (0U)
2223 #define EXTI_EXTICR1_EXTI0_Msk       (0x7UL << EXTI_EXTICR1_EXTI0_Pos)         /*!< 0x00000007 */
2224 #define EXTI_EXTICR1_EXTI0           EXTI_EXTICR1_EXTI0_Msk                    /*!< EXTI 0 configuration */
2225 #define EXTI_EXTICR1_EXTI0_0         (0x1UL << EXTI_EXTICR1_EXTI0_Pos)         /*!< 0x00000001 */
2226 #define EXTI_EXTICR1_EXTI0_1         (0x2UL << EXTI_EXTICR1_EXTI0_Pos)         /*!< 0x00000002 */
2227 #define EXTI_EXTICR1_EXTI0_2         (0x4UL << EXTI_EXTICR1_EXTI0_Pos)         /*!< 0x00000004 */
2228 #define EXTI_EXTICR1_EXTI1_Pos       (8U)
2229 #define EXTI_EXTICR1_EXTI1_Msk       (0x7UL << EXTI_EXTICR1_EXTI1_Pos)         /*!< 0x00000700 */
2230 #define EXTI_EXTICR1_EXTI1           EXTI_EXTICR1_EXTI1_Msk                    /*!< EXTI 1 configuration */
2231 #define EXTI_EXTICR1_EXTI1_0         (0x1UL << EXTI_EXTICR1_EXTI1_Pos)         /*!< 0x00000100 */
2232 #define EXTI_EXTICR1_EXTI1_1         (0x2UL << EXTI_EXTICR1_EXTI1_Pos)         /*!< 0x00000200 */
2233 #define EXTI_EXTICR1_EXTI1_2         (0x4UL << EXTI_EXTICR1_EXTI1_Pos)         /*!< 0x00000400 */
2234 #define EXTI_EXTICR1_EXTI2_Pos       (16U)
2235 #define EXTI_EXTICR1_EXTI2_Msk       (0x7UL << EXTI_EXTICR1_EXTI2_Pos)         /*!< 0x00070000 */
2236 #define EXTI_EXTICR1_EXTI2           EXTI_EXTICR1_EXTI2_Msk                    /*!< EXTI 2 configuration */
2237 #define EXTI_EXTICR1_EXTI2_0         (0x1UL << EXTI_EXTICR1_EXTI2_Pos)         /*!< 0x00010000 */
2238 #define EXTI_EXTICR1_EXTI2_1         (0x2UL << EXTI_EXTICR1_EXTI2_Pos)         /*!< 0x00020000 */
2239 #define EXTI_EXTICR1_EXTI2_2         (0x4UL << EXTI_EXTICR1_EXTI2_Pos)         /*!< 0x00040000 */
2240 #define EXTI_EXTICR1_EXTI3_Pos       (24U)
2241 #define EXTI_EXTICR1_EXTI3_Msk       (0x7UL << EXTI_EXTICR1_EXTI3_Pos)         /*!< 0x07000000 */
2242 #define EXTI_EXTICR1_EXTI3           EXTI_EXTICR1_EXTI3_Msk                    /*!< EXTI 3 configuration */
2243 #define EXTI_EXTICR1_EXTI3_0         (0x1UL << EXTI_EXTICR1_EXTI3_Pos)         /*!< 0x01000000 */
2244 #define EXTI_EXTICR1_EXTI3_1         (0x2UL << EXTI_EXTICR1_EXTI3_Pos)         /*!< 0x02000000 */
2245 #define EXTI_EXTICR1_EXTI3_2         (0x4UL << EXTI_EXTICR1_EXTI3_Pos)         /*!< 0x04000000 */
2246 
2247 /*****************  Bit definition for EXTI_EXTICR2 register  **************/
2248 #define EXTI_EXTICR2_EXTI4_Pos       (0U)
2249 #define EXTI_EXTICR2_EXTI4_Msk       (0x7UL << EXTI_EXTICR2_EXTI4_Pos)         /*!< 0x00000007 */
2250 #define EXTI_EXTICR2_EXTI4           EXTI_EXTICR2_EXTI4_Msk                    /*!< EXTI 4 configuration */
2251 #define EXTI_EXTICR2_EXTI4_0         (0x1UL << EXTI_EXTICR2_EXTI4_Pos)         /*!< 0x00000001 */
2252 #define EXTI_EXTICR2_EXTI4_1         (0x2UL << EXTI_EXTICR2_EXTI4_Pos)         /*!< 0x00000002 */
2253 #define EXTI_EXTICR2_EXTI4_2         (0x4UL << EXTI_EXTICR2_EXTI4_Pos)         /*!< 0x00000004 */
2254 #define EXTI_EXTICR2_EXTI5_Pos       (8U)
2255 #define EXTI_EXTICR2_EXTI5_Msk       (0x7UL << EXTI_EXTICR2_EXTI5_Pos)         /*!< 0x00000700 */
2256 #define EXTI_EXTICR2_EXTI5           EXTI_EXTICR2_EXTI5_Msk                    /*!< EXTI 5 configuration */
2257 #define EXTI_EXTICR2_EXTI5_0         (0x1UL << EXTI_EXTICR2_EXTI5_Pos)         /*!< 0x00000100 */
2258 #define EXTI_EXTICR2_EXTI5_1         (0x2UL << EXTI_EXTICR2_EXTI5_Pos)         /*!< 0x00000200 */
2259 #define EXTI_EXTICR2_EXTI5_2         (0x4UL << EXTI_EXTICR2_EXTI5_Pos)         /*!< 0x00000400 */
2260 #define EXTI_EXTICR2_EXTI6_Pos       (16U)
2261 #define EXTI_EXTICR2_EXTI6_Msk       (0x7UL << EXTI_EXTICR2_EXTI6_Pos)         /*!< 0x00070000 */
2262 #define EXTI_EXTICR2_EXTI6           EXTI_EXTICR2_EXTI6_Msk                    /*!< EXTI 6 configuration */
2263 #define EXTI_EXTICR2_EXTI6_0         (0x1UL << EXTI_EXTICR2_EXTI6_Pos)         /*!< 0x00010000 */
2264 #define EXTI_EXTICR2_EXTI6_1         (0x2UL << EXTI_EXTICR2_EXTI6_Pos)         /*!< 0x00020000 */
2265 #define EXTI_EXTICR2_EXTI6_2         (0x4UL << EXTI_EXTICR2_EXTI6_Pos)         /*!< 0x00040000 */
2266 #define EXTI_EXTICR2_EXTI7_Pos       (24U)
2267 #define EXTI_EXTICR2_EXTI7_Msk       (0x7UL << EXTI_EXTICR2_EXTI7_Pos)         /*!< 0x07000000 */
2268 #define EXTI_EXTICR2_EXTI7           EXTI_EXTICR2_EXTI7_Msk                    /*!< EXTI 7 configuration */
2269 #define EXTI_EXTICR2_EXTI7_0         (0x1UL << EXTI_EXTICR2_EXTI7_Pos)         /*!< 0x01000000 */
2270 #define EXTI_EXTICR2_EXTI7_1         (0x2UL << EXTI_EXTICR2_EXTI7_Pos)         /*!< 0x02000000 */
2271 #define EXTI_EXTICR2_EXTI7_2         (0x4UL << EXTI_EXTICR2_EXTI7_Pos)         /*!< 0x04000000 */
2272 
2273 /*****************  Bit definition for EXTI_EXTICR3 register  **************/
2274 #define EXTI_EXTICR3_EXTI8_Pos       (0U)
2275 #define EXTI_EXTICR3_EXTI8_Msk       (0x7UL << EXTI_EXTICR3_EXTI8_Pos)         /*!< 0x00000007 */
2276 #define EXTI_EXTICR3_EXTI8           EXTI_EXTICR3_EXTI8_Msk                    /*!< EXTI 8 configuration */
2277 #define EXTI_EXTICR3_EXTI8_0         (0x1UL << EXTI_EXTICR3_EXTI8_Pos)         /*!< 0x00000001 */
2278 #define EXTI_EXTICR3_EXTI8_1         (0x2UL << EXTI_EXTICR3_EXTI8_Pos)         /*!< 0x00000002 */
2279 #define EXTI_EXTICR3_EXTI8_2         (0x4UL << EXTI_EXTICR3_EXTI8_Pos)         /*!< 0x00000004 */
2280 #define EXTI_EXTICR3_EXTI9_Pos       (8U)
2281 #define EXTI_EXTICR3_EXTI9_Msk       (0x7UL << EXTI_EXTICR3_EXTI9_Pos)         /*!< 0x00000700 */
2282 #define EXTI_EXTICR3_EXTI9           EXTI_EXTICR3_EXTI9_Msk                    /*!< EXTI 9 configuration */
2283 #define EXTI_EXTICR3_EXTI9_0         (0x1UL << EXTI_EXTICR3_EXTI9_Pos)         /*!< 0x00000100 */
2284 #define EXTI_EXTICR3_EXTI9_1         (0x2UL << EXTI_EXTICR3_EXTI9_Pos)         /*!< 0x00000200 */
2285 #define EXTI_EXTICR3_EXTI9_2         (0x4UL << EXTI_EXTICR3_EXTI9_Pos)         /*!< 0x00000400 */
2286 #define EXTI_EXTICR3_EXTI10_Pos      (16U)
2287 #define EXTI_EXTICR3_EXTI10_Msk      (0x7UL << EXTI_EXTICR3_EXTI10_Pos)        /*!< 0x00070000 */
2288 #define EXTI_EXTICR3_EXTI10          EXTI_EXTICR3_EXTI10_Msk                   /*!< EXTI 10 configuration */
2289 #define EXTI_EXTICR3_EXTI10_0        (0x1UL << EXTI_EXTICR3_EXTI10_Pos)        /*!< 0x00010000 */
2290 #define EXTI_EXTICR3_EXTI10_1        (0x2UL << EXTI_EXTICR3_EXTI10_Pos)        /*!< 0x00020000 */
2291 #define EXTI_EXTICR3_EXTI10_2        (0x4UL << EXTI_EXTICR3_EXTI10_Pos)        /*!< 0x00040000 */
2292 #define EXTI_EXTICR3_EXTI11_Pos      (24U)
2293 #define EXTI_EXTICR3_EXTI11_Msk      (0x7UL << EXTI_EXTICR3_EXTI11_Pos)        /*!< 0x07000000 */
2294 #define EXTI_EXTICR3_EXTI11          EXTI_EXTICR3_EXTI11_Msk                   /*!< EXTI 11 configuration */
2295 #define EXTI_EXTICR3_EXTI11_0        (0x1UL << EXTI_EXTICR3_EXTI11_Pos)        /*!< 0x01000000 */
2296 #define EXTI_EXTICR3_EXTI11_1        (0x2UL << EXTI_EXTICR3_EXTI11_Pos)        /*!< 0x02000000 */
2297 #define EXTI_EXTICR3_EXTI11_2        (0x4UL << EXTI_EXTICR3_EXTI11_Pos)        /*!< 0x04000000 */
2298 
2299 /*****************  Bit definition for EXTI_EXTICR4 register  **************/
2300 #define EXTI_EXTICR4_EXTI12_Pos      (0U)
2301 #define EXTI_EXTICR4_EXTI12_Msk      (0x7UL << EXTI_EXTICR4_EXTI12_Pos)        /*!< 0x00000007 */
2302 #define EXTI_EXTICR4_EXTI12          EXTI_EXTICR4_EXTI12_Msk                   /*!< EXTI 12 configuration */
2303 #define EXTI_EXTICR4_EXTI12_0        (0x1UL << EXTI_EXTICR4_EXTI12_Pos)        /*!< 0x00000001 */
2304 #define EXTI_EXTICR4_EXTI12_1        (0x2UL << EXTI_EXTICR4_EXTI12_Pos)        /*!< 0x00000002 */
2305 #define EXTI_EXTICR4_EXTI12_2        (0x4UL << EXTI_EXTICR4_EXTI12_Pos)        /*!< 0x00000004 */
2306 #define EXTI_EXTICR4_EXTI13_Pos      (8U)
2307 #define EXTI_EXTICR4_EXTI13_Msk      (0x7UL << EXTI_EXTICR4_EXTI13_Pos)        /*!< 0x00000700 */
2308 #define EXTI_EXTICR4_EXTI13          EXTI_EXTICR4_EXTI13_Msk                   /*!< EXTI 13 configuration */
2309 #define EXTI_EXTICR4_EXTI13_0        (0x1UL << EXTI_EXTICR4_EXTI13_Pos)        /*!< 0x00000100 */
2310 #define EXTI_EXTICR4_EXTI13_1        (0x2UL << EXTI_EXTICR4_EXTI13_Pos)       /*!< 0x00000200 */
2311 #define EXTI_EXTICR4_EXTI13_2        (0x4UL << EXTI_EXTICR4_EXTI13_Pos)         /*!< 0x00000400 */
2312 #define EXTI_EXTICR4_EXTI14_Pos      (16U)
2313 #define EXTI_EXTICR4_EXTI14_Msk      (0x7UL << EXTI_EXTICR4_EXTI14_Pos)        /*!< 0x00070000 */
2314 #define EXTI_EXTICR4_EXTI14          EXTI_EXTICR4_EXTI14_Msk                   /*!< EXTI 14 configuration */
2315 #define EXTI_EXTICR4_EXTI14_0        (0x1UL << EXTI_EXTICR4_EXTI14_Pos)        /*!< 0x00010000 */
2316 #define EXTI_EXTICR4_EXTI14_1        (0x2UL << EXTI_EXTICR4_EXTI14_Pos)        /*!< 0x00020000 */
2317 #define EXTI_EXTICR4_EXTI14_2        (0x4UL << EXTI_EXTICR4_EXTI14_Pos)        /*!< 0x00040000 */
2318 #define EXTI_EXTICR4_EXTI15_Pos      (24U)
2319 #define EXTI_EXTICR4_EXTI15_Msk      (0x7UL << EXTI_EXTICR4_EXTI15_Pos)        /*!< 0x07000000 */
2320 #define EXTI_EXTICR4_EXTI15          EXTI_EXTICR4_EXTI15_Msk                   /*!< EXTI 15 configuration */
2321 #define EXTI_EXTICR4_EXTI15_0        (0x1UL << EXTI_EXTICR4_EXTI15_Pos)        /*!< 0x01000000 */
2322 #define EXTI_EXTICR4_EXTI15_1        (0x2UL << EXTI_EXTICR4_EXTI15_Pos)        /*!< 0x02000000 */
2323 #define EXTI_EXTICR4_EXTI15_2        (0x4UL << EXTI_EXTICR4_EXTI15_Pos)        /*!< 0x04000000 */
2324 
2325 /*******************  Bit definition for EXTI_IMR1 register  ******************/
2326 #define EXTI_IMR1_IM0_Pos            (0U)
2327 #define EXTI_IMR1_IM0_Msk            (0x1UL << EXTI_IMR1_IM0_Pos)              /*!< 0x00000001 */
2328 #define EXTI_IMR1_IM0                EXTI_IMR1_IM0_Msk                         /*!< Interrupt Mask on line 0 */
2329 #define EXTI_IMR1_IM1_Pos            (1U)
2330 #define EXTI_IMR1_IM1_Msk            (0x1UL << EXTI_IMR1_IM1_Pos)              /*!< 0x00000002 */
2331 #define EXTI_IMR1_IM1                EXTI_IMR1_IM1_Msk                         /*!< Interrupt Mask on line 1 */
2332 #define EXTI_IMR1_IM2_Pos            (2U)
2333 #define EXTI_IMR1_IM2_Msk            (0x1UL << EXTI_IMR1_IM2_Pos)              /*!< 0x00000004 */
2334 #define EXTI_IMR1_IM2                EXTI_IMR1_IM2_Msk                         /*!< Interrupt Mask on line 2 */
2335 #define EXTI_IMR1_IM3_Pos            (3U)
2336 #define EXTI_IMR1_IM3_Msk            (0x1UL << EXTI_IMR1_IM3_Pos)              /*!< 0x00000008 */
2337 #define EXTI_IMR1_IM3                EXTI_IMR1_IM3_Msk                         /*!< Interrupt Mask on line 3 */
2338 #define EXTI_IMR1_IM4_Pos            (4U)
2339 #define EXTI_IMR1_IM4_Msk            (0x1UL << EXTI_IMR1_IM4_Pos)              /*!< 0x00000010 */
2340 #define EXTI_IMR1_IM4                EXTI_IMR1_IM4_Msk                         /*!< Interrupt Mask on line 4 */
2341 #define EXTI_IMR1_IM5_Pos            (5U)
2342 #define EXTI_IMR1_IM5_Msk            (0x1UL << EXTI_IMR1_IM5_Pos)              /*!< 0x00000020 */
2343 #define EXTI_IMR1_IM5                EXTI_IMR1_IM5_Msk                         /*!< Interrupt Mask on line 5 */
2344 #define EXTI_IMR1_IM6_Pos            (6U)
2345 #define EXTI_IMR1_IM6_Msk            (0x1UL << EXTI_IMR1_IM6_Pos)              /*!< 0x00000040 */
2346 #define EXTI_IMR1_IM6                EXTI_IMR1_IM6_Msk                         /*!< Interrupt Mask on line 6 */
2347 #define EXTI_IMR1_IM7_Pos            (7U)
2348 #define EXTI_IMR1_IM7_Msk            (0x1UL << EXTI_IMR1_IM7_Pos)              /*!< 0x00000080 */
2349 #define EXTI_IMR1_IM7                EXTI_IMR1_IM7_Msk                         /*!< Interrupt Mask on line 7 */
2350 #define EXTI_IMR1_IM8_Pos            (8U)
2351 #define EXTI_IMR1_IM8_Msk            (0x1UL << EXTI_IMR1_IM8_Pos)              /*!< 0x00000100 */
2352 #define EXTI_IMR1_IM8                EXTI_IMR1_IM8_Msk                         /*!< Interrupt Mask on line 8 */
2353 #define EXTI_IMR1_IM9_Pos            (9U)
2354 #define EXTI_IMR1_IM9_Msk            (0x1UL << EXTI_IMR1_IM9_Pos)              /*!< 0x00000200 */
2355 #define EXTI_IMR1_IM9                EXTI_IMR1_IM9_Msk                         /*!< Interrupt Mask on line 9 */
2356 #define EXTI_IMR1_IM10_Pos           (10U)
2357 #define EXTI_IMR1_IM10_Msk           (0x1UL << EXTI_IMR1_IM10_Pos)             /*!< 0x00000400 */
2358 #define EXTI_IMR1_IM10               EXTI_IMR1_IM10_Msk                        /*!< Interrupt Mask on line 10 */
2359 #define EXTI_IMR1_IM11_Pos           (11U)
2360 #define EXTI_IMR1_IM11_Msk           (0x1UL << EXTI_IMR1_IM11_Pos)             /*!< 0x00000800 */
2361 #define EXTI_IMR1_IM11               EXTI_IMR1_IM11_Msk                        /*!< Interrupt Mask on line 11 */
2362 #define EXTI_IMR1_IM12_Pos           (12U)
2363 #define EXTI_IMR1_IM12_Msk           (0x1UL << EXTI_IMR1_IM12_Pos)             /*!< 0x00001000 */
2364 #define EXTI_IMR1_IM12               EXTI_IMR1_IM12_Msk                        /*!< Interrupt Mask on line 12 */
2365 #define EXTI_IMR1_IM13_Pos           (13U)
2366 #define EXTI_IMR1_IM13_Msk           (0x1UL << EXTI_IMR1_IM13_Pos)             /*!< 0x00002000 */
2367 #define EXTI_IMR1_IM13               EXTI_IMR1_IM13_Msk                        /*!< Interrupt Mask on line 13 */
2368 #define EXTI_IMR1_IM14_Pos           (14U)
2369 #define EXTI_IMR1_IM14_Msk           (0x1UL << EXTI_IMR1_IM14_Pos)             /*!< 0x00004000 */
2370 #define EXTI_IMR1_IM14               EXTI_IMR1_IM14_Msk                        /*!< Interrupt Mask on line 14 */
2371 #define EXTI_IMR1_IM15_Pos           (15U)
2372 #define EXTI_IMR1_IM15_Msk           (0x1UL << EXTI_IMR1_IM15_Pos)             /*!< 0x00008000 */
2373 #define EXTI_IMR1_IM15               EXTI_IMR1_IM15_Msk                        /*!< Interrupt Mask on line 15 */
2374 #define EXTI_IMR1_IM19_Pos           (19U)
2375 #define EXTI_IMR1_IM19_Msk           (0x1UL << EXTI_IMR1_IM19_Pos)             /*!< 0x00080000 */
2376 #define EXTI_IMR1_IM19               EXTI_IMR1_IM19_Msk                        /*!< Interrupt Mask on line 19 */
2377 #define EXTI_IMR1_IM21_Pos           (21U)
2378 #define EXTI_IMR1_IM21_Msk           (0x1UL << EXTI_IMR1_IM21_Pos)             /*!< 0x00200000 */
2379 #define EXTI_IMR1_IM21               EXTI_IMR1_IM21_Msk                        /*!< Interrupt Mask on line 21 */
2380 #define EXTI_IMR1_IM22_Pos           (22U)
2381 #define EXTI_IMR1_IM22_Msk           (0x1UL << EXTI_IMR1_IM22_Pos)             /*!< 0x00400000 */
2382 #define EXTI_IMR1_IM22               EXTI_IMR1_IM22_Msk                        /*!< Interrupt Mask on line 22 */
2383 #define EXTI_IMR1_IM23_Pos           (23U)
2384 #define EXTI_IMR1_IM23_Msk           (0x1UL << EXTI_IMR1_IM23_Pos)             /*!< 0x00800000 */
2385 #define EXTI_IMR1_IM23               EXTI_IMR1_IM23_Msk                        /*!< Interrupt Mask on line 23 */
2386 #define EXTI_IMR1_IM24_Pos           (24U)
2387 #define EXTI_IMR1_IM24_Msk           (0x1UL << EXTI_IMR1_IM24_Pos)             /*!< 0x01000000 */
2388 #define EXTI_IMR1_IM24               EXTI_IMR1_IM24_Msk                        /*!< Interrupt Mask on line 24 */
2389 #define EXTI_IMR1_IM25_Pos           (25U)
2390 #define EXTI_IMR1_IM25_Msk           (0x1UL << EXTI_IMR1_IM25_Pos)             /*!< 0x02000000 */
2391 #define EXTI_IMR1_IM25               EXTI_IMR1_IM25_Msk                        /*!< Interrupt Mask on line 25 */
2392 #define EXTI_IMR1_IM26_Pos           (26U)
2393 #define EXTI_IMR1_IM26_Msk           (0x1UL << EXTI_IMR1_IM26_Pos)             /*!< 0x04000000 */
2394 #define EXTI_IMR1_IM26               EXTI_IMR1_IM26_Msk                        /*!< Interrupt Mask on line 26 */
2395 #define EXTI_IMR1_IM31_Pos           (31U)
2396 #define EXTI_IMR1_IM31_Msk           (0x1UL << EXTI_IMR1_IM31_Pos)              /*!< 0x80000000 */
2397 #define EXTI_IMR1_IM31               EXTI_IMR1_IM31_Msk                        /*!< Interrupt Mask on line 31 */
2398 #define EXTI_IMR1_IM_Pos             (0U)
2399 #define EXTI_IMR1_IM_Msk             (0x87E8FFFFUL << EXTI_IMR1_IM_Pos)        /*!< 0x87E8FFFF */
2400 #define EXTI_IMR1_IM                 EXTI_IMR1_IM_Msk                          /*!< Interrupt Mask All */
2401 
2402 /*******************  Bit definition for EXTI_IMR2 register  ******************/
2403 #define EXTI_IMR2_IM36_Pos           (4U)
2404 #define EXTI_IMR2_IM36_Msk           (0x1UL << EXTI_IMR2_IM36_Pos)             /*!< 0x00000010 */
2405 #define EXTI_IMR2_IM36               EXTI_IMR2_IM36_Msk                        /*!< Interrupt Mask on line 36 */
2406 #define EXTI_IMR2_IM_Pos             (0U)
2407 #define EXTI_IMR2_IM_Msk             (0x10UL << EXTI_IMR2_IM_Pos)               /*!< 0x00000010 */
2408 #define EXTI_IMR2_IM                 EXTI_IMR2_IM_Msk                          /*!< Interrupt Mask All */
2409 
2410 /*******************  Bit definition for EXTI_EMR1 register  ******************/
2411 #define EXTI_EMR1_EM0_Pos            (0U)
2412 #define EXTI_EMR1_EM0_Msk            (0x1UL << EXTI_EMR1_EM0_Pos)              /*!< 0x00000001 */
2413 #define EXTI_EMR1_EM0                EXTI_EMR1_EM0_Msk                         /*!< Event Mask on line 0 */
2414 #define EXTI_EMR1_EM1_Pos            (1U)
2415 #define EXTI_EMR1_EM1_Msk            (0x1UL << EXTI_EMR1_EM1_Pos)              /*!< 0x00000002 */
2416 #define EXTI_EMR1_EM1                EXTI_EMR1_EM1_Msk                         /*!< Event Mask on line 1 */
2417 #define EXTI_EMR1_EM2_Pos            (2U)
2418 #define EXTI_EMR1_EM2_Msk            (0x1UL << EXTI_EMR1_EM2_Pos)              /*!< 0x00000004 */
2419 #define EXTI_EMR1_EM2                EXTI_EMR1_EM2_Msk                         /*!< Event Mask on line 2 */
2420 #define EXTI_EMR1_EM3_Pos            (3U)
2421 #define EXTI_EMR1_EM3_Msk            (0x1UL << EXTI_EMR1_EM3_Pos)              /*!< 0x00000008 */
2422 #define EXTI_EMR1_EM3                EXTI_EMR1_EM3_Msk                         /*!< Event Mask on line 3 */
2423 #define EXTI_EMR1_EM4_Pos            (4U)
2424 #define EXTI_EMR1_EM4_Msk            (0x1UL << EXTI_EMR1_EM4_Pos)              /*!< 0x00000010 */
2425 #define EXTI_EMR1_EM4                EXTI_EMR1_EM4_Msk                         /*!< Event Mask on line 4 */
2426 #define EXTI_EMR1_EM5_Pos            (5U)
2427 #define EXTI_EMR1_EM5_Msk            (0x1UL << EXTI_EMR1_EM5_Pos)              /*!< 0x00000020 */
2428 #define EXTI_EMR1_EM5                EXTI_EMR1_EM5_Msk                         /*!< Event Mask on line 5 */
2429 #define EXTI_EMR1_EM6_Pos            (6U)
2430 #define EXTI_EMR1_EM6_Msk            (0x1UL << EXTI_EMR1_EM6_Pos)              /*!< 0x00000040 */
2431 #define EXTI_EMR1_EM6                EXTI_EMR1_EM6_Msk                         /*!< Event Mask on line 6 */
2432 #define EXTI_EMR1_EM7_Pos            (7U)
2433 #define EXTI_EMR1_EM7_Msk            (0x1UL << EXTI_EMR1_EM7_Pos)              /*!< 0x00000080 */
2434 #define EXTI_EMR1_EM7                EXTI_EMR1_EM7_Msk                         /*!< Event Mask on line 7 */
2435 #define EXTI_EMR1_EM8_Pos            (8U)
2436 #define EXTI_EMR1_EM8_Msk            (0x1UL << EXTI_EMR1_EM8_Pos)              /*!< 0x00000100 */
2437 #define EXTI_EMR1_EM8                EXTI_EMR1_EM8_Msk                         /*!< Event Mask on line 8 */
2438 #define EXTI_EMR1_EM9_Pos            (9U)
2439 #define EXTI_EMR1_EM9_Msk            (0x1UL << EXTI_EMR1_EM9_Pos)              /*!< 0x00000200 */
2440 #define EXTI_EMR1_EM9                EXTI_EMR1_EM9_Msk                         /*!< Event Mask on line 9 */
2441 #define EXTI_EMR1_EM10_Pos           (10U)
2442 #define EXTI_EMR1_EM10_Msk           (0x1UL << EXTI_EMR1_EM10_Pos)             /*!< 0x00000400 */
2443 #define EXTI_EMR1_EM10               EXTI_EMR1_EM10_Msk                        /*!< Event Mask on line 10 */
2444 #define EXTI_EMR1_EM11_Pos           (11U)
2445 #define EXTI_EMR1_EM11_Msk           (0x1UL << EXTI_EMR1_EM11_Pos)             /*!< 0x00000800 */
2446 #define EXTI_EMR1_EM11               EXTI_EMR1_EM11_Msk                        /*!< Event Mask on line 11 */
2447 #define EXTI_EMR1_EM12_Pos           (12U)
2448 #define EXTI_EMR1_EM12_Msk           (0x1UL << EXTI_EMR1_EM12_Pos)             /*!< 0x00001000 */
2449 #define EXTI_EMR1_EM12               EXTI_EMR1_EM12_Msk                        /*!< Event Mask on line 12 */
2450 #define EXTI_EMR1_EM13_Pos           (13U)
2451 #define EXTI_EMR1_EM13_Msk           (0x1UL << EXTI_EMR1_EM13_Pos)             /*!< 0x00002000 */
2452 #define EXTI_EMR1_EM13               EXTI_EMR1_EM13_Msk                        /*!< Event Mask on line 13 */
2453 #define EXTI_EMR1_EM14_Pos           (14U)
2454 #define EXTI_EMR1_EM14_Msk           (0x1UL << EXTI_EMR1_EM14_Pos)             /*!< 0x00004000 */
2455 #define EXTI_EMR1_EM14               EXTI_EMR1_EM14_Msk                        /*!< Event Mask on line 14 */
2456 #define EXTI_EMR1_EM15_Pos           (15U)
2457 #define EXTI_EMR1_EM15_Msk           (0x1UL << EXTI_EMR1_EM15_Pos)             /*!< 0x00008000 */
2458 #define EXTI_EMR1_EM15               EXTI_EMR1_EM15_Msk                        /*!< Event Mask on line 15 */
2459 #define EXTI_EMR1_EM19_Pos           (19U)
2460 #define EXTI_EMR1_EM19_Msk           (0x1UL << EXTI_EMR1_EM19_Pos)             /*!< 0x00080000 */
2461 #define EXTI_EMR1_EM19               EXTI_EMR1_EM19_Msk                        /*!< Event Mask on line 19 */
2462 #define EXTI_EMR1_EM21_Pos           (21U)
2463 #define EXTI_EMR1_EM21_Msk           (0x1UL << EXTI_EMR1_EM21_Pos)             /*!< 0x00200000 */
2464 #define EXTI_EMR1_EM21               EXTI_EMR1_EM21_Msk                        /*!< Event Mask on line 21 */
2465 #define EXTI_EMR1_EM22_Pos           (22U)
2466 #define EXTI_EMR1_EM22_Msk           (0x1UL << EXTI_EMR1_EM22_Pos)             /*!< 0x00400000 */
2467 #define EXTI_EMR1_EM22               EXTI_EMR1_EM22_Msk                        /*!< Event Mask on line 22 */
2468 #define EXTI_EMR1_EM23_Pos           (23U)
2469 #define EXTI_EMR1_EM23_Msk           (0x1UL << EXTI_EMR1_EM23_Pos)             /*!< 0x00800000 */
2470 #define EXTI_EMR1_EM23               EXTI_EMR1_EM23_Msk                        /*!< Event Mask on line 23 */
2471 #define EXTI_EMR1_EM24_Pos           (24U)
2472 #define EXTI_EMR1_EM24_Msk           (0x1UL << EXTI_EMR1_EM24_Pos)             /*!< 0x01000000 */
2473 #define EXTI_EMR1_EM24               EXTI_EMR1_EM24_Msk                        /*!< Event Mask on line 24 */
2474 #define EXTI_EMR1_EM25_Pos           (25U)
2475 #define EXTI_EMR1_EM25_Msk           (0x1UL << EXTI_EMR1_EM25_Pos)             /*!< 0x02000000 */
2476 #define EXTI_EMR1_EM25               EXTI_EMR1_EM25_Msk                        /*!< Event Mask on line 25 */
2477 #define EXTI_EMR1_EM26_Pos           (26U)
2478 #define EXTI_EMR1_EM26_Msk           (0x1UL << EXTI_EMR1_EM26_Pos)             /*!< 0x04000000 */
2479 #define EXTI_EMR1_EM26               EXTI_EMR1_EM26_Msk                        /*!< Event Mask on line 26 */
2480 #define EXTI_EMR1_EM31_Pos           (31U)
2481 #define EXTI_EMR1_EM31_Msk           (0x1UL << EXTI_EMR1_EM31_Pos)             /*!< 0x80000000 */
2482 #define EXTI_EMR1_EM31               EXTI_EMR1_EM31_Msk                        /*!< Event Mask on line 31 */
2483 
2484 /*******************  Bit definition for EXTI_EMR2 register  ******************/
2485 #define EXTI_EMR2_EM36_Pos           (4U)
2486 #define EXTI_EMR2_EM36_Msk           (0x1UL << EXTI_EMR2_EM36_Pos)             /*!< 0x00000010 */
2487 #define EXTI_EMR2_EM36               EXTI_EMR2_EM36_Msk                        /*!< Event Mask on line 36 */
2488 
2489 /******************************************************************************/
2490 /*                                                                            */
2491 /*                 Flexible Datarate Controller Area Network                  */
2492 /*                                                                            */
2493 /******************************************************************************/
2494 /*!<FDCAN control and status registers */
2495 /*****************  Bit definition for FDCAN_CREL register  *******************/
2496 #define FDCAN_CREL_DAY_Pos        (0U)
2497 #define FDCAN_CREL_DAY_Msk        (0xFFUL << FDCAN_CREL_DAY_Pos)               /*!< 0x000000FF */
2498 #define FDCAN_CREL_DAY            FDCAN_CREL_DAY_Msk                           /*!<Timestamp Day                           */
2499 #define FDCAN_CREL_MON_Pos        (8U)
2500 #define FDCAN_CREL_MON_Msk        (0xFFUL << FDCAN_CREL_MON_Pos)               /*!< 0x0000FF00 */
2501 #define FDCAN_CREL_MON            FDCAN_CREL_MON_Msk                           /*!<Timestamp Month                         */
2502 #define FDCAN_CREL_YEAR_Pos       (16U)
2503 #define FDCAN_CREL_YEAR_Msk       (0xFUL << FDCAN_CREL_YEAR_Pos)               /*!< 0x000F0000 */
2504 #define FDCAN_CREL_YEAR           FDCAN_CREL_YEAR_Msk                          /*!<Timestamp Year                          */
2505 #define FDCAN_CREL_SUBSTEP_Pos    (20U)
2506 #define FDCAN_CREL_SUBSTEP_Msk    (0xFUL << FDCAN_CREL_SUBSTEP_Pos)            /*!< 0x00F00000 */
2507 #define FDCAN_CREL_SUBSTEP        FDCAN_CREL_SUBSTEP_Msk                       /*!<Sub-step of Core release                */
2508 #define FDCAN_CREL_STEP_Pos       (24U)
2509 #define FDCAN_CREL_STEP_Msk       (0xFUL << FDCAN_CREL_STEP_Pos)               /*!< 0x0F000000 */
2510 #define FDCAN_CREL_STEP           FDCAN_CREL_STEP_Msk                          /*!<Step of Core release                    */
2511 #define FDCAN_CREL_REL_Pos        (28U)
2512 #define FDCAN_CREL_REL_Msk        (0xFUL << FDCAN_CREL_REL_Pos)                /*!< 0xF0000000 */
2513 #define FDCAN_CREL_REL            FDCAN_CREL_REL_Msk                           /*!<Core release                            */
2514 
2515 /*****************  Bit definition for FDCAN_ENDN register  *******************/
2516 #define FDCAN_ENDN_ETV_Pos        (0U)
2517 #define FDCAN_ENDN_ETV_Msk        (0xFFFFFFFFUL << FDCAN_ENDN_ETV_Pos)         /*!< 0xFFFFFFFF */
2518 #define FDCAN_ENDN_ETV            FDCAN_ENDN_ETV_Msk                           /*!<Endianness Test Value                    */
2519 
2520 /*****************  Bit definition for FDCAN_DBTP register  *******************/
2521 #define FDCAN_DBTP_DSJW_Pos       (0U)
2522 #define FDCAN_DBTP_DSJW_Msk       (0xFUL << FDCAN_DBTP_DSJW_Pos)               /*!< 0x0000000F */
2523 #define FDCAN_DBTP_DSJW           FDCAN_DBTP_DSJW_Msk                          /*!<Synchronization Jump Width              */
2524 #define FDCAN_DBTP_DTSEG2_Pos     (4U)
2525 #define FDCAN_DBTP_DTSEG2_Msk     (0xFUL << FDCAN_DBTP_DTSEG2_Pos)             /*!< 0x000000F0 */
2526 #define FDCAN_DBTP_DTSEG2         FDCAN_DBTP_DTSEG2_Msk                        /*!<Data time segment after sample point    */
2527 #define FDCAN_DBTP_DTSEG1_Pos     (8U)
2528 #define FDCAN_DBTP_DTSEG1_Msk     (0x1FUL << FDCAN_DBTP_DTSEG1_Pos)            /*!< 0x00001F00 */
2529 #define FDCAN_DBTP_DTSEG1         FDCAN_DBTP_DTSEG1_Msk                        /*!<Data time segment before sample point   */
2530 #define FDCAN_DBTP_DBRP_Pos       (16U)
2531 #define FDCAN_DBTP_DBRP_Msk       (0x1FUL << FDCAN_DBTP_DBRP_Pos)              /*!< 0x001F0000 */
2532 #define FDCAN_DBTP_DBRP           FDCAN_DBTP_DBRP_Msk                          /*!<Data BIt Rate Prescaler                 */
2533 #define FDCAN_DBTP_TDC_Pos        (23U)
2534 #define FDCAN_DBTP_TDC_Msk        (0x1UL << FDCAN_DBTP_TDC_Pos)                /*!< 0x00800000 */
2535 #define FDCAN_DBTP_TDC            FDCAN_DBTP_TDC_Msk                           /*!<Transceiver Delay Compensation          */
2536 
2537 /*****************  Bit definition for FDCAN_TEST register  *******************/
2538 #define FDCAN_TEST_LBCK_Pos       (4U)
2539 #define FDCAN_TEST_LBCK_Msk       (0x1UL << FDCAN_TEST_LBCK_Pos)               /*!< 0x00000010 */
2540 #define FDCAN_TEST_LBCK           FDCAN_TEST_LBCK_Msk                          /*!<Loop Back mode                           */
2541 #define FDCAN_TEST_TX_Pos         (5U)
2542 #define FDCAN_TEST_TX_Msk         (0x3UL << FDCAN_TEST_TX_Pos)                 /*!< 0x00000060 */
2543 #define FDCAN_TEST_TX             FDCAN_TEST_TX_Msk                            /*!<Control of Transmit Pin                  */
2544 #define FDCAN_TEST_RX_Pos         (7U)
2545 #define FDCAN_TEST_RX_Msk         (0x1UL << FDCAN_TEST_RX_Pos)                 /*!< 0x00000080 */
2546 #define FDCAN_TEST_RX             FDCAN_TEST_RX_Msk                            /*!<Receive Pin                              */
2547 
2548 /*****************  Bit definition for FDCAN_RWD register  ********************/
2549 #define FDCAN_RWD_WDC_Pos         (0U)
2550 #define FDCAN_RWD_WDC_Msk         (0xFFUL << FDCAN_RWD_WDC_Pos)                /*!< 0x000000FF */
2551 #define FDCAN_RWD_WDC             FDCAN_RWD_WDC_Msk                            /*!<Watchdog configuration                   */
2552 #define FDCAN_RWD_WDV_Pos         (8U)
2553 #define FDCAN_RWD_WDV_Msk         (0xFFUL << FDCAN_RWD_WDV_Pos)                /*!< 0x0000FF00 */
2554 #define FDCAN_RWD_WDV             FDCAN_RWD_WDV_Msk                            /*!<Watchdog value                           */
2555 
2556 /*****************  Bit definition for FDCAN_CCCR register  ********************/
2557 #define FDCAN_CCCR_INIT_Pos       (0U)
2558 #define FDCAN_CCCR_INIT_Msk       (0x1UL << FDCAN_CCCR_INIT_Pos)               /*!< 0x00000001 */
2559 #define FDCAN_CCCR_INIT           FDCAN_CCCR_INIT_Msk                          /*!<Initialization                           */
2560 #define FDCAN_CCCR_CCE_Pos        (1U)
2561 #define FDCAN_CCCR_CCE_Msk        (0x1UL << FDCAN_CCCR_CCE_Pos)                /*!< 0x00000002 */
2562 #define FDCAN_CCCR_CCE            FDCAN_CCCR_CCE_Msk                           /*!<Configuration Change Enable              */
2563 #define FDCAN_CCCR_ASM_Pos        (2U)
2564 #define FDCAN_CCCR_ASM_Msk        (0x1UL << FDCAN_CCCR_ASM_Pos)                /*!< 0x00000004 */
2565 #define FDCAN_CCCR_ASM            FDCAN_CCCR_ASM_Msk                           /*!<ASM Restricted Operation Mode            */
2566 #define FDCAN_CCCR_CSA_Pos        (3U)
2567 #define FDCAN_CCCR_CSA_Msk        (0x1UL << FDCAN_CCCR_CSA_Pos)                /*!< 0x00000008 */
2568 #define FDCAN_CCCR_CSA            FDCAN_CCCR_CSA_Msk                           /*!<Clock Stop Acknowledge                   */
2569 #define FDCAN_CCCR_CSR_Pos        (4U)
2570 #define FDCAN_CCCR_CSR_Msk        (0x1UL << FDCAN_CCCR_CSR_Pos)                /*!< 0x00000010 */
2571 #define FDCAN_CCCR_CSR            FDCAN_CCCR_CSR_Msk                           /*!<Clock Stop Request                       */
2572 #define FDCAN_CCCR_MON_Pos        (5U)
2573 #define FDCAN_CCCR_MON_Msk        (0x1UL << FDCAN_CCCR_MON_Pos)                /*!< 0x00000020 */
2574 #define FDCAN_CCCR_MON            FDCAN_CCCR_MON_Msk                           /*!<Bus Monitoring Mode                      */
2575 #define FDCAN_CCCR_DAR_Pos        (6U)
2576 #define FDCAN_CCCR_DAR_Msk        (0x1UL << FDCAN_CCCR_DAR_Pos)                /*!< 0x00000040 */
2577 #define FDCAN_CCCR_DAR            FDCAN_CCCR_DAR_Msk                           /*!<Disable Automatic Retransmission         */
2578 #define FDCAN_CCCR_TEST_Pos       (7U)
2579 #define FDCAN_CCCR_TEST_Msk       (0x1UL << FDCAN_CCCR_TEST_Pos)               /*!< 0x00000080 */
2580 #define FDCAN_CCCR_TEST           FDCAN_CCCR_TEST_Msk                          /*!<Test Mode Enable                         */
2581 #define FDCAN_CCCR_FDOE_Pos       (8U)
2582 #define FDCAN_CCCR_FDOE_Msk       (0x1UL << FDCAN_CCCR_FDOE_Pos)               /*!< 0x00000100 */
2583 #define FDCAN_CCCR_FDOE           FDCAN_CCCR_FDOE_Msk                          /*!<FD Operation Enable                      */
2584 #define FDCAN_CCCR_BRSE_Pos       (9U)
2585 #define FDCAN_CCCR_BRSE_Msk       (0x1UL << FDCAN_CCCR_BRSE_Pos)               /*!< 0x00000200 */
2586 #define FDCAN_CCCR_BRSE           FDCAN_CCCR_BRSE_Msk                          /*!<FDCAN Bit Rate Switching                 */
2587 #define FDCAN_CCCR_PXHD_Pos       (12U)
2588 #define FDCAN_CCCR_PXHD_Msk       (0x1UL << FDCAN_CCCR_PXHD_Pos)               /*!< 0x00001000 */
2589 #define FDCAN_CCCR_PXHD           FDCAN_CCCR_PXHD_Msk                          /*!<Protocol Exception Handling Disable      */
2590 #define FDCAN_CCCR_EFBI_Pos       (13U)
2591 #define FDCAN_CCCR_EFBI_Msk       (0x1UL << FDCAN_CCCR_EFBI_Pos)               /*!< 0x00002000 */
2592 #define FDCAN_CCCR_EFBI           FDCAN_CCCR_EFBI_Msk                          /*!<Edge Filtering during Bus Integration    */
2593 #define FDCAN_CCCR_TXP_Pos        (14U)
2594 #define FDCAN_CCCR_TXP_Msk        (0x1UL << FDCAN_CCCR_TXP_Pos)                /*!< 0x00004000 */
2595 #define FDCAN_CCCR_TXP            FDCAN_CCCR_TXP_Msk                           /*!<Two CAN bit times Pause                  */
2596 #define FDCAN_CCCR_NISO_Pos       (15U)
2597 #define FDCAN_CCCR_NISO_Msk       (0x1UL << FDCAN_CCCR_NISO_Pos)               /*!< 0x00008000 */
2598 #define FDCAN_CCCR_NISO           FDCAN_CCCR_NISO_Msk                          /*!<Non ISO Operation                        */
2599 
2600 /*****************  Bit definition for FDCAN_NBTP register  ********************/
2601 #define FDCAN_NBTP_NTSEG2_Pos     (0U)
2602 #define FDCAN_NBTP_NTSEG2_Msk     (0x7FUL << FDCAN_NBTP_NTSEG2_Pos)            /*!< 0x0000007F */
2603 #define FDCAN_NBTP_NTSEG2         FDCAN_NBTP_NTSEG2_Msk                        /*!<Nominal Time segment after sample point  */
2604 #define FDCAN_NBTP_NTSEG1_Pos     (8U)
2605 #define FDCAN_NBTP_NTSEG1_Msk     (0xFFUL << FDCAN_NBTP_NTSEG1_Pos)            /*!< 0x0000FF00 */
2606 #define FDCAN_NBTP_NTSEG1         FDCAN_NBTP_NTSEG1_Msk                        /*!<Nominal Time segment before sample point */
2607 #define FDCAN_NBTP_NBRP_Pos       (16U)
2608 #define FDCAN_NBTP_NBRP_Msk       (0x1FFUL << FDCAN_NBTP_NBRP_Pos)             /*!< 0x01FF0000 */
2609 #define FDCAN_NBTP_NBRP           FDCAN_NBTP_NBRP_Msk                          /*!<Bit Rate Prescaler                       */
2610 #define FDCAN_NBTP_NSJW_Pos       (25U)
2611 #define FDCAN_NBTP_NSJW_Msk       (0x7FUL << FDCAN_NBTP_NSJW_Pos)              /*!< 0xFE000000 */
2612 #define FDCAN_NBTP_NSJW           FDCAN_NBTP_NSJW_Msk                          /*!<Nominal (Re)Synchronization Jump Width   */
2613 
2614 /*****************  Bit definition for FDCAN_TSCC register  ********************/
2615 #define FDCAN_TSCC_TSS_Pos        (0U)
2616 #define FDCAN_TSCC_TSS_Msk        (0x3UL << FDCAN_TSCC_TSS_Pos)                /*!< 0x00000003 */
2617 #define FDCAN_TSCC_TSS            FDCAN_TSCC_TSS_Msk                           /*!<Timestamp Select                         */
2618 #define FDCAN_TSCC_TCP_Pos        (16U)
2619 #define FDCAN_TSCC_TCP_Msk        (0xFUL << FDCAN_TSCC_TCP_Pos)                /*!< 0x000F0000 */
2620 #define FDCAN_TSCC_TCP            FDCAN_TSCC_TCP_Msk                           /*!<Timestamp Counter Prescaler              */
2621 
2622 /*****************  Bit definition for FDCAN_TSCV register  ********************/
2623 #define FDCAN_TSCV_TSC_Pos        (0U)
2624 #define FDCAN_TSCV_TSC_Msk        (0xFFFFUL << FDCAN_TSCV_TSC_Pos)             /*!< 0x0000FFFF */
2625 #define FDCAN_TSCV_TSC            FDCAN_TSCV_TSC_Msk                           /*!<Timestamp Counter                        */
2626 
2627 /*****************  Bit definition for FDCAN_TOCC register  ********************/
2628 #define FDCAN_TOCC_ETOC_Pos       (0U)
2629 #define FDCAN_TOCC_ETOC_Msk       (0x1UL << FDCAN_TOCC_ETOC_Pos)               /*!< 0x00000001 */
2630 #define FDCAN_TOCC_ETOC           FDCAN_TOCC_ETOC_Msk                          /*!<Enable Timeout Counter                   */
2631 #define FDCAN_TOCC_TOS_Pos        (1U)
2632 #define FDCAN_TOCC_TOS_Msk        (0x3UL << FDCAN_TOCC_TOS_Pos)                /*!< 0x00000006 */
2633 #define FDCAN_TOCC_TOS            FDCAN_TOCC_TOS_Msk                           /*!<Timeout Select                           */
2634 #define FDCAN_TOCC_TOP_Pos        (16U)
2635 #define FDCAN_TOCC_TOP_Msk        (0xFFFFUL << FDCAN_TOCC_TOP_Pos)             /*!< 0xFFFF0000 */
2636 #define FDCAN_TOCC_TOP            FDCAN_TOCC_TOP_Msk                           /*!<Timeout Period                           */
2637 
2638 /*****************  Bit definition for FDCAN_TOCV register  ********************/
2639 #define FDCAN_TOCV_TOC_Pos        (0U)
2640 #define FDCAN_TOCV_TOC_Msk        (0xFFFFUL << FDCAN_TOCV_TOC_Pos)             /*!< 0x0000FFFF */
2641 #define FDCAN_TOCV_TOC            FDCAN_TOCV_TOC_Msk                           /*!<Timeout Counter                          */
2642 
2643 /*****************  Bit definition for FDCAN_ECR register  *********************/
2644 #define FDCAN_ECR_TEC_Pos         (0U)
2645 #define FDCAN_ECR_TEC_Msk         (0xFFUL << FDCAN_ECR_TEC_Pos)                /*!< 0x000000FF */
2646 #define FDCAN_ECR_TEC             FDCAN_ECR_TEC_Msk                            /*!<Transmit Error Counter                   */
2647 #define FDCAN_ECR_REC_Pos         (8U)
2648 #define FDCAN_ECR_REC_Msk         (0x7FUL << FDCAN_ECR_REC_Pos)                /*!< 0x00007F00 */
2649 #define FDCAN_ECR_REC             FDCAN_ECR_REC_Msk                            /*!<Receive Error Counter                    */
2650 #define FDCAN_ECR_RP_Pos          (15U)
2651 #define FDCAN_ECR_RP_Msk          (0x1UL << FDCAN_ECR_RP_Pos)                  /*!< 0x00008000 */
2652 #define FDCAN_ECR_RP              FDCAN_ECR_RP_Msk                             /*!<Receive Error Passive                    */
2653 #define FDCAN_ECR_CEL_Pos         (16U)
2654 #define FDCAN_ECR_CEL_Msk         (0xFFUL << FDCAN_ECR_CEL_Pos)                /*!< 0x00FF0000 */
2655 #define FDCAN_ECR_CEL             FDCAN_ECR_CEL_Msk                            /*!<CAN Error Logging                        */
2656 
2657 /*****************  Bit definition for FDCAN_PSR register  *********************/
2658 #define FDCAN_PSR_LEC_Pos         (0U)
2659 #define FDCAN_PSR_LEC_Msk         (0x7UL << FDCAN_PSR_LEC_Pos)                 /*!< 0x00000007 */
2660 #define FDCAN_PSR_LEC             FDCAN_PSR_LEC_Msk                            /*!<Last Error Code                          */
2661 #define FDCAN_PSR_ACT_Pos         (3U)
2662 #define FDCAN_PSR_ACT_Msk         (0x3UL << FDCAN_PSR_ACT_Pos)                 /*!< 0x00000018 */
2663 #define FDCAN_PSR_ACT             FDCAN_PSR_ACT_Msk                            /*!<Activity                                 */
2664 #define FDCAN_PSR_EP_Pos          (5U)
2665 #define FDCAN_PSR_EP_Msk          (0x1UL << FDCAN_PSR_EP_Pos)                  /*!< 0x00000020 */
2666 #define FDCAN_PSR_EP              FDCAN_PSR_EP_Msk                             /*!<Error Passive                            */
2667 #define FDCAN_PSR_EW_Pos          (6U)
2668 #define FDCAN_PSR_EW_Msk          (0x1UL << FDCAN_PSR_EW_Pos)                  /*!< 0x00000040 */
2669 #define FDCAN_PSR_EW              FDCAN_PSR_EW_Msk                             /*!<Warning Status                           */
2670 #define FDCAN_PSR_BO_Pos          (7U)
2671 #define FDCAN_PSR_BO_Msk          (0x1UL << FDCAN_PSR_BO_Pos)                  /*!< 0x00000080 */
2672 #define FDCAN_PSR_BO              FDCAN_PSR_BO_Msk                             /*!<Bus_Off Status                           */
2673 #define FDCAN_PSR_DLEC_Pos        (8U)
2674 #define FDCAN_PSR_DLEC_Msk        (0x7UL << FDCAN_PSR_DLEC_Pos)                /*!< 0x00000700 */
2675 #define FDCAN_PSR_DLEC            FDCAN_PSR_DLEC_Msk                           /*!<Data Last Error Code                     */
2676 #define FDCAN_PSR_RESI_Pos        (11U)
2677 #define FDCAN_PSR_RESI_Msk        (0x1UL << FDCAN_PSR_RESI_Pos)                /*!< 0x00000800 */
2678 #define FDCAN_PSR_RESI            FDCAN_PSR_RESI_Msk                           /*!<ESI flag of last received FDCAN Message  */
2679 #define FDCAN_PSR_RBRS_Pos        (12U)
2680 #define FDCAN_PSR_RBRS_Msk        (0x1UL << FDCAN_PSR_RBRS_Pos)                /*!< 0x00001000 */
2681 #define FDCAN_PSR_RBRS            FDCAN_PSR_RBRS_Msk                           /*!<BRS flag of last received FDCAN Message  */
2682 #define FDCAN_PSR_REDL_Pos        (13U)
2683 #define FDCAN_PSR_REDL_Msk        (0x1UL << FDCAN_PSR_REDL_Pos)                /*!< 0x00002000 */
2684 #define FDCAN_PSR_REDL            FDCAN_PSR_REDL_Msk                           /*!<Received FDCAN Message                   */
2685 #define FDCAN_PSR_PXE_Pos         (14U)
2686 #define FDCAN_PSR_PXE_Msk         (0x1UL << FDCAN_PSR_PXE_Pos)                 /*!< 0x00004000 */
2687 #define FDCAN_PSR_PXE             FDCAN_PSR_PXE_Msk                            /*!<Protocol Exception Event                 */
2688 #define FDCAN_PSR_TDCV_Pos        (16U)
2689 #define FDCAN_PSR_TDCV_Msk        (0x7FUL << FDCAN_PSR_TDCV_Pos)               /*!< 0x007F0000 */
2690 #define FDCAN_PSR_TDCV            FDCAN_PSR_TDCV_Msk                           /*!<Transmitter Delay Compensation Value     */
2691 
2692 /*****************  Bit definition for FDCAN_TDCR register  ********************/
2693 #define FDCAN_TDCR_TDCF_Pos       (0U)
2694 #define FDCAN_TDCR_TDCF_Msk       (0x7FUL << FDCAN_TDCR_TDCF_Pos)              /*!< 0x0000007F */
2695 #define FDCAN_TDCR_TDCF           FDCAN_TDCR_TDCF_Msk                          /*!<Transmitter Delay Compensation Filter    */
2696 #define FDCAN_TDCR_TDCO_Pos       (8U)
2697 #define FDCAN_TDCR_TDCO_Msk       (0x7FUL << FDCAN_TDCR_TDCO_Pos)              /*!< 0x00007F00 */
2698 #define FDCAN_TDCR_TDCO           FDCAN_TDCR_TDCO_Msk                          /*!<Transmitter Delay Compensation Offset    */
2699 
2700 /*****************  Bit definition for FDCAN_IR register  **********************/
2701 #define FDCAN_IR_RF0N_Pos         (0U)
2702 #define FDCAN_IR_RF0N_Msk         (0x1UL << FDCAN_IR_RF0N_Pos)                 /*!< 0x00000001 */
2703 #define FDCAN_IR_RF0N             FDCAN_IR_RF0N_Msk                            /*!<Rx FIFO 0 New Message                    */
2704 #define FDCAN_IR_RF0F_Pos         (1U)
2705 #define FDCAN_IR_RF0F_Msk         (0x1UL << FDCAN_IR_RF0F_Pos)                 /*!< 0x00000002 */
2706 #define FDCAN_IR_RF0F             FDCAN_IR_RF0F_Msk                            /*!<Rx FIFO 0 Full                           */
2707 #define FDCAN_IR_RF0L_Pos         (2U)
2708 #define FDCAN_IR_RF0L_Msk         (0x1UL << FDCAN_IR_RF0L_Pos)                 /*!< 0x00000004 */
2709 #define FDCAN_IR_RF0L             FDCAN_IR_RF0L_Msk                            /*!<Rx FIFO 0 Message Lost                   */
2710 #define FDCAN_IR_RF1N_Pos         (3U)
2711 #define FDCAN_IR_RF1N_Msk         (0x1UL << FDCAN_IR_RF1N_Pos)                 /*!< 0x00000008 */
2712 #define FDCAN_IR_RF1N             FDCAN_IR_RF1N_Msk                            /*!<Rx FIFO 1 New Message                    */
2713 #define FDCAN_IR_RF1F_Pos         (4U)
2714 #define FDCAN_IR_RF1F_Msk         (0x1UL << FDCAN_IR_RF1F_Pos)                 /*!< 0x00000010 */
2715 #define FDCAN_IR_RF1F             FDCAN_IR_RF1F_Msk                            /*!<Rx FIFO 1 Full                           */
2716 #define FDCAN_IR_RF1L_Pos         (5U)
2717 #define FDCAN_IR_RF1L_Msk         (0x1UL << FDCAN_IR_RF1L_Pos)                 /*!< 0x00000020 */
2718 #define FDCAN_IR_RF1L             FDCAN_IR_RF1L_Msk                            /*!<Rx FIFO 1 Message Lost                   */
2719 #define FDCAN_IR_HPM_Pos          (6U)
2720 #define FDCAN_IR_HPM_Msk          (0x1UL << FDCAN_IR_HPM_Pos)                  /*!< 0x00000040 */
2721 #define FDCAN_IR_HPM              FDCAN_IR_HPM_Msk                             /*!<High Priority Message                    */
2722 #define FDCAN_IR_TC_Pos           (7U)
2723 #define FDCAN_IR_TC_Msk           (0x1UL << FDCAN_IR_TC_Pos)                   /*!< 0x00000080 */
2724 #define FDCAN_IR_TC               FDCAN_IR_TC_Msk                              /*!<Transmission Completed                   */
2725 #define FDCAN_IR_TCF_Pos          (8U)
2726 #define FDCAN_IR_TCF_Msk          (0x1UL << FDCAN_IR_TCF_Pos)                  /*!< 0x00000100 */
2727 #define FDCAN_IR_TCF              FDCAN_IR_TCF_Msk                             /*!<Transmission Cancellation Finished       */
2728 #define FDCAN_IR_TFE_Pos          (9U)
2729 #define FDCAN_IR_TFE_Msk          (0x1UL << FDCAN_IR_TFE_Pos)                  /*!< 0x00000200 */
2730 #define FDCAN_IR_TFE              FDCAN_IR_TFE_Msk                             /*!<Tx FIFO Empty                            */
2731 #define FDCAN_IR_TEFN_Pos         (10U)
2732 #define FDCAN_IR_TEFN_Msk         (0x1UL << FDCAN_IR_TEFN_Pos)                 /*!< 0x00000400 */
2733 #define FDCAN_IR_TEFN             FDCAN_IR_TEFN_Msk                            /*!<Tx Event FIFO New Entry                  */
2734 #define FDCAN_IR_TEFF_Pos         (11U)
2735 #define FDCAN_IR_TEFF_Msk         (0x1UL << FDCAN_IR_TEFF_Pos)                 /*!< 0x00000800 */
2736 #define FDCAN_IR_TEFF             FDCAN_IR_TEFF_Msk                            /*!<Tx Event FIFO Full                       */
2737 #define FDCAN_IR_TEFL_Pos         (12U)
2738 #define FDCAN_IR_TEFL_Msk         (0x1UL << FDCAN_IR_TEFL_Pos)                 /*!< 0x00001000 */
2739 #define FDCAN_IR_TEFL             FDCAN_IR_TEFL_Msk                            /*!<Tx Event FIFO Element Lost               */
2740 #define FDCAN_IR_TSW_Pos          (13U)
2741 #define FDCAN_IR_TSW_Msk          (0x1UL << FDCAN_IR_TSW_Pos)                  /*!< 0x00002000 */
2742 #define FDCAN_IR_TSW              FDCAN_IR_TSW_Msk                             /*!<Timestamp Wraparound                     */
2743 #define FDCAN_IR_MRAF_Pos         (14U)
2744 #define FDCAN_IR_MRAF_Msk         (0x1UL << FDCAN_IR_MRAF_Pos)                 /*!< 0x00004000 */
2745 #define FDCAN_IR_MRAF             FDCAN_IR_MRAF_Msk                            /*!<Message RAM Access Failure               */
2746 #define FDCAN_IR_TOO_Pos          (15U)
2747 #define FDCAN_IR_TOO_Msk          (0x1UL << FDCAN_IR_TOO_Pos)                  /*!< 0x00008000 */
2748 #define FDCAN_IR_TOO              FDCAN_IR_TOO_Msk                             /*!<Timeout Occurred                         */
2749 #define FDCAN_IR_ELO_Pos          (16U)
2750 #define FDCAN_IR_ELO_Msk          (0x1UL << FDCAN_IR_ELO_Pos)                  /*!< 0x00010000 */
2751 #define FDCAN_IR_ELO              FDCAN_IR_ELO_Msk                             /*!<Error Logging Overflow                   */
2752 #define FDCAN_IR_EP_Pos           (17U)
2753 #define FDCAN_IR_EP_Msk           (0x1UL << FDCAN_IR_EP_Pos)                   /*!< 0x00020000 */
2754 #define FDCAN_IR_EP               FDCAN_IR_EP_Msk                              /*!<Error Passive                            */
2755 #define FDCAN_IR_EW_Pos           (18U)
2756 #define FDCAN_IR_EW_Msk           (0x1UL << FDCAN_IR_EW_Pos)                   /*!< 0x00040000 */
2757 #define FDCAN_IR_EW               FDCAN_IR_EW_Msk                              /*!<Warning Status                           */
2758 #define FDCAN_IR_BO_Pos           (19U)
2759 #define FDCAN_IR_BO_Msk           (0x1UL << FDCAN_IR_BO_Pos)                   /*!< 0x00080000 */
2760 #define FDCAN_IR_BO               FDCAN_IR_BO_Msk                              /*!<Bus_Off Status                           */
2761 #define FDCAN_IR_WDI_Pos          (20U)
2762 #define FDCAN_IR_WDI_Msk          (0x1UL << FDCAN_IR_WDI_Pos)                  /*!< 0x00100000 */
2763 #define FDCAN_IR_WDI              FDCAN_IR_WDI_Msk                             /*!<Watchdog Interrupt                       */
2764 #define FDCAN_IR_PEA_Pos          (21U)
2765 #define FDCAN_IR_PEA_Msk          (0x1UL << FDCAN_IR_PEA_Pos)                  /*!< 0x00200000 */
2766 #define FDCAN_IR_PEA              FDCAN_IR_PEA_Msk                             /*!<Protocol Error in Arbitration Phase      */
2767 #define FDCAN_IR_PED_Pos          (22U)
2768 #define FDCAN_IR_PED_Msk          (0x1UL << FDCAN_IR_PED_Pos)                  /*!< 0x00400000 */
2769 #define FDCAN_IR_PED              FDCAN_IR_PED_Msk                             /*!<Protocol Error in Data Phase             */
2770 #define FDCAN_IR_ARA_Pos          (23U)
2771 #define FDCAN_IR_ARA_Msk          (0x1UL << FDCAN_IR_ARA_Pos)                  /*!< 0x00800000 */
2772 #define FDCAN_IR_ARA              FDCAN_IR_ARA_Msk                             /*!<Access to Reserved Address               */
2773 
2774 /*****************  Bit definition for FDCAN_IE register  **********************/
2775 #define FDCAN_IE_RF0NE_Pos        (0U)
2776 #define FDCAN_IE_RF0NE_Msk        (0x1UL << FDCAN_IE_RF0NE_Pos)                /*!< 0x00000001 */
2777 #define FDCAN_IE_RF0NE            FDCAN_IE_RF0NE_Msk                           /*!<Rx FIFO 0 New Message Enable             */
2778 #define FDCAN_IE_RF0FE_Pos        (1U)
2779 #define FDCAN_IE_RF0FE_Msk        (0x1UL << FDCAN_IE_RF0FE_Pos)                /*!< 0x00000002 */
2780 #define FDCAN_IE_RF0FE            FDCAN_IE_RF0FE_Msk                           /*!<Rx FIFO 0 Full Enable                    */
2781 #define FDCAN_IE_RF0LE_Pos        (2U)
2782 #define FDCAN_IE_RF0LE_Msk        (0x1UL << FDCAN_IE_RF0LE_Pos)                /*!< 0x00000004 */
2783 #define FDCAN_IE_RF0LE            FDCAN_IE_RF0LE_Msk                           /*!<Rx FIFO 0 Message Lost Enable            */
2784 #define FDCAN_IE_RF1NE_Pos        (3U)
2785 #define FDCAN_IE_RF1NE_Msk        (0x1UL << FDCAN_IE_RF1NE_Pos)                /*!< 0x00000008 */
2786 #define FDCAN_IE_RF1NE            FDCAN_IE_RF1NE_Msk                           /*!<Rx FIFO 1 New Message Enable             */
2787 #define FDCAN_IE_RF1FE_Pos        (4U)
2788 #define FDCAN_IE_RF1FE_Msk        (0x1UL << FDCAN_IE_RF1FE_Pos)                /*!< 0x00000010 */
2789 #define FDCAN_IE_RF1FE            FDCAN_IE_RF1FE_Msk                           /*!<Rx FIFO 1 Full Enable                    */
2790 #define FDCAN_IE_RF1LE_Pos        (5U)
2791 #define FDCAN_IE_RF1LE_Msk        (0x1UL << FDCAN_IE_RF1LE_Pos)                /*!< 0x00000020 */
2792 #define FDCAN_IE_RF1LE            FDCAN_IE_RF1LE_Msk                           /*!<Rx FIFO 1 Message Lost Enable            */
2793 #define FDCAN_IE_HPME_Pos         (6U)
2794 #define FDCAN_IE_HPME_Msk         (0x1UL << FDCAN_IE_HPME_Pos)                 /*!< 0x00000040 */
2795 #define FDCAN_IE_HPME             FDCAN_IE_HPME_Msk                            /*!<High Priority Message Enable             */
2796 #define FDCAN_IE_TCE_Pos          (7U)
2797 #define FDCAN_IE_TCE_Msk          (0x1UL << FDCAN_IE_TCE_Pos)                  /*!< 0x00000080 */
2798 #define FDCAN_IE_TCE              FDCAN_IE_TCE_Msk                             /*!<Transmission Completed Enable            */
2799 #define FDCAN_IE_TCFE_Pos         (8U)
2800 #define FDCAN_IE_TCFE_Msk         (0x1UL << FDCAN_IE_TCFE_Pos)                 /*!< 0x00000100 */
2801 #define FDCAN_IE_TCFE             FDCAN_IE_TCFE_Msk                            /*!<Transmission Cancellation Finished Enable*/
2802 #define FDCAN_IE_TFEE_Pos         (9U)
2803 #define FDCAN_IE_TFEE_Msk         (0x1UL << FDCAN_IE_TFEE_Pos)                 /*!< 0x00000200 */
2804 #define FDCAN_IE_TFEE             FDCAN_IE_TFEE_Msk                            /*!<Tx FIFO Empty Enable                     */
2805 #define FDCAN_IE_TEFNE_Pos        (10U)
2806 #define FDCAN_IE_TEFNE_Msk        (0x1UL << FDCAN_IE_TEFNE_Pos)                /*!< 0x00000400 */
2807 #define FDCAN_IE_TEFNE            FDCAN_IE_TEFNE_Msk                           /*!<Tx Event FIFO New Entry Enable           */
2808 #define FDCAN_IE_TEFFE_Pos        (11U)
2809 #define FDCAN_IE_TEFFE_Msk        (0x1UL << FDCAN_IE_TEFFE_Pos)                /*!< 0x00000800 */
2810 #define FDCAN_IE_TEFFE            FDCAN_IE_TEFFE_Msk                           /*!<Tx Event FIFO Full Enable                */
2811 #define FDCAN_IE_TEFLE_Pos        (12U)
2812 #define FDCAN_IE_TEFLE_Msk        (0x1UL << FDCAN_IE_TEFLE_Pos)                /*!< 0x00001000 */
2813 #define FDCAN_IE_TEFLE            FDCAN_IE_TEFLE_Msk                           /*!<Tx Event FIFO Element Lost Enable        */
2814 #define FDCAN_IE_TSWE_Pos         (13U)
2815 #define FDCAN_IE_TSWE_Msk         (0x1UL << FDCAN_IE_TSWE_Pos)                 /*!< 0x00002000 */
2816 #define FDCAN_IE_TSWE             FDCAN_IE_TSWE_Msk                            /*!<Timestamp Wraparound Enable              */
2817 #define FDCAN_IE_MRAFE_Pos        (14U)
2818 #define FDCAN_IE_MRAFE_Msk        (0x1UL << FDCAN_IE_MRAFE_Pos)                /*!< 0x00004000 */
2819 #define FDCAN_IE_MRAFE            FDCAN_IE_MRAFE_Msk                           /*!<Message RAM Access Failure Enable        */
2820 #define FDCAN_IE_TOOE_Pos         (15U)
2821 #define FDCAN_IE_TOOE_Msk         (0x1UL << FDCAN_IE_TOOE_Pos)                 /*!< 0x00008000 */
2822 #define FDCAN_IE_TOOE             FDCAN_IE_TOOE_Msk                            /*!<Timeout Occurred Enable                  */
2823 #define FDCAN_IE_ELOE_Pos         (16U)
2824 #define FDCAN_IE_ELOE_Msk         (0x1UL << FDCAN_IE_ELOE_Pos)                 /*!< 0x00010000 */
2825 #define FDCAN_IE_ELOE             FDCAN_IE_ELOE_Msk                            /*!<Error Logging Overflow Enable            */
2826 #define FDCAN_IE_EPE_Pos          (17U)
2827 #define FDCAN_IE_EPE_Msk          (0x1UL << FDCAN_IE_EPE_Pos)                  /*!< 0x00020000 */
2828 #define FDCAN_IE_EPE              FDCAN_IE_EPE_Msk                             /*!<Error Passive Enable                     */
2829 #define FDCAN_IE_EWE_Pos          (18U)
2830 #define FDCAN_IE_EWE_Msk          (0x1UL << FDCAN_IE_EWE_Pos)                  /*!< 0x00040000 */
2831 #define FDCAN_IE_EWE              FDCAN_IE_EWE_Msk                             /*!<Warning Status Enable                    */
2832 #define FDCAN_IE_BOE_Pos          (19U)
2833 #define FDCAN_IE_BOE_Msk          (0x1UL << FDCAN_IE_BOE_Pos)                  /*!< 0x00080000 */
2834 #define FDCAN_IE_BOE              FDCAN_IE_BOE_Msk                             /*!<Bus_Off Status Enable                    */
2835 #define FDCAN_IE_WDIE_Pos         (20U)
2836 #define FDCAN_IE_WDIE_Msk         (0x1UL << FDCAN_IE_WDIE_Pos)                 /*!< 0x00100000 */
2837 #define FDCAN_IE_WDIE             FDCAN_IE_WDIE_Msk                            /*!<Watchdog Interrupt Enable                */
2838 #define FDCAN_IE_PEAE_Pos         (21U)
2839 #define FDCAN_IE_PEAE_Msk         (0x1UL << FDCAN_IE_PEAE_Pos)                 /*!< 0x00200000 */
2840 #define FDCAN_IE_PEAE             FDCAN_IE_PEAE_Msk                            /*!<Protocol Error in Arbitration Phase Enable*/
2841 #define FDCAN_IE_PEDE_Pos         (22U)
2842 #define FDCAN_IE_PEDE_Msk         (0x1UL << FDCAN_IE_PEDE_Pos)                 /*!< 0x00400000 */
2843 #define FDCAN_IE_PEDE             FDCAN_IE_PEDE_Msk                            /*!<Protocol Error in Data Phase Enable      */
2844 #define FDCAN_IE_ARAE_Pos         (23U)
2845 #define FDCAN_IE_ARAE_Msk         (0x1UL << FDCAN_IE_ARAE_Pos)                 /*!< 0x00800000 */
2846 #define FDCAN_IE_ARAE             FDCAN_IE_ARAE_Msk                            /*!<Access to Reserved Address Enable        */
2847 
2848 /*****************  Bit definition for FDCAN_ILS register  **********************/
2849 #define FDCAN_ILS_RXFIFO0_Pos     (0U)
2850 #define FDCAN_ILS_RXFIFO0_Msk     (0x1UL << FDCAN_ILS_RXFIFO0_Pos)             /*!< 0x00000001 */
2851 #define FDCAN_ILS_RXFIFO0         FDCAN_ILS_RXFIFO0_Msk                        /*!<Rx FIFO 0 Message Lost
2852                                                                                    Rx FIFO 0 is Full
2853                                                                                    Rx FIFO 0 Has New Message                */
2854 #define FDCAN_ILS_RXFIFO1_Pos     (1U)
2855 #define FDCAN_ILS_RXFIFO1_Msk     (0x1UL << FDCAN_ILS_RXFIFO1_Pos)             /*!< 0x00000002 */
2856 #define FDCAN_ILS_RXFIFO1         FDCAN_ILS_RXFIFO1_Msk                        /*!<Rx FIFO 1 Message Lost
2857                                                                                    Rx FIFO 1 is Full
2858                                                                                    Rx FIFO 1 Has New Message                */
2859 #define FDCAN_ILS_SMSG_Pos        (2U)
2860 #define FDCAN_ILS_SMSG_Msk        (0x1UL << FDCAN_ILS_SMSG_Pos)                /*!< 0x00000004 */
2861 #define FDCAN_ILS_SMSG            FDCAN_ILS_SMSG_Msk                           /*!<Transmission Cancellation Finished
2862                                                                                    Transmission Completed
2863                                                                                    High Priority Message                    */
2864 #define FDCAN_ILS_TFERR_Pos       (3U)
2865 #define FDCAN_ILS_TFERR_Msk       (0x1UL << FDCAN_ILS_TFERR_Pos)               /*!< 0x00000008 */
2866 #define FDCAN_ILS_TFERR           FDCAN_ILS_TFERR_Msk                          /*!<Tx Event FIFO Element Lost
2867                                                                                    Tx Event FIFO Full
2868                                                                                    Tx Event FIFO New Entry
2869                                                                                    Tx FIFO Empty Interrupt Line             */
2870 #define FDCAN_ILS_MISC_Pos        (4U)
2871 #define FDCAN_ILS_MISC_Msk        (0x1UL << FDCAN_ILS_MISC_Pos)                /*!< 0x00000010 */
2872 #define FDCAN_ILS_MISC            FDCAN_ILS_MISC_Msk                           /*!<Timeout Occurred
2873                                                                                     Message RAM Access Failure
2874                                                                                     Timestamp Wraparound                    */
2875 #define FDCAN_ILS_BERR_Pos        (5U)
2876 #define FDCAN_ILS_BERR_Msk        (0x1UL << FDCAN_ILS_BERR_Pos)                /*!< 0x00000020 */
2877 #define FDCAN_ILS_BERR            FDCAN_ILS_BERR_Msk                           /*!<Error Passive
2878                                                                                    Error Logging Overflow                   */
2879 #define FDCAN_ILS_PERR_Pos        (6U)
2880 #define FDCAN_ILS_PERR_Msk        (0x1UL << FDCAN_ILS_PERR_Pos)                /*!< 0x00000040 */
2881 #define FDCAN_ILS_PERR            FDCAN_ILS_PERR_Msk                           /*!<Access to Reserved Address Line
2882                                                                                    Protocol Error in Data Phase Line
2883                                                                                    Protocol Error in Arbitration Phase Line
2884                                                                                    Watchdog Interrupt Line
2885                                                                                    Bus_Off Status
2886                                                                                    Warning Status                           */
2887 
2888 /*****************  Bit definition for FDCAN_ILE register  **********************/
2889 #define FDCAN_ILE_EINT0_Pos       (0U)
2890 #define FDCAN_ILE_EINT0_Msk       (0x1UL << FDCAN_ILE_EINT0_Pos)               /*!< 0x00000001 */
2891 #define FDCAN_ILE_EINT0           FDCAN_ILE_EINT0_Msk                          /*!<Enable Interrupt Line 0                  */
2892 #define FDCAN_ILE_EINT1_Pos       (1U)
2893 #define FDCAN_ILE_EINT1_Msk       (0x1UL << FDCAN_ILE_EINT1_Pos)               /*!< 0x00000002 */
2894 #define FDCAN_ILE_EINT1           FDCAN_ILE_EINT1_Msk                          /*!<Enable Interrupt Line 1                  */
2895 
2896 /*****************  Bit definition for FDCAN_RXGFC register  ********************/
2897 #define FDCAN_RXGFC_RRFE_Pos      (0U)
2898 #define FDCAN_RXGFC_RRFE_Msk      (0x1UL << FDCAN_RXGFC_RRFE_Pos)              /*!< 0x00000001 */
2899 #define FDCAN_RXGFC_RRFE          FDCAN_RXGFC_RRFE_Msk                         /*!<Reject Remote Frames Extended            */
2900 #define FDCAN_RXGFC_RRFS_Pos      (1U)
2901 #define FDCAN_RXGFC_RRFS_Msk      (0x1UL << FDCAN_RXGFC_RRFS_Pos)              /*!< 0x00000002 */
2902 #define FDCAN_RXGFC_RRFS          FDCAN_RXGFC_RRFS_Msk                         /*!<Reject Remote Frames Standard            */
2903 #define FDCAN_RXGFC_ANFE_Pos      (2U)
2904 #define FDCAN_RXGFC_ANFE_Msk      (0x3UL << FDCAN_RXGFC_ANFE_Pos)              /*!< 0x0000000C */
2905 #define FDCAN_RXGFC_ANFE          FDCAN_RXGFC_ANFE_Msk                         /*!<Accept Non-matching Frames Extended      */
2906 #define FDCAN_RXGFC_ANFS_Pos      (4U)
2907 #define FDCAN_RXGFC_ANFS_Msk      (0x3UL << FDCAN_RXGFC_ANFS_Pos)              /*!< 0x00000030 */
2908 #define FDCAN_RXGFC_ANFS          FDCAN_RXGFC_ANFS_Msk                         /*!<Accept Non-matching Frames Standard      */
2909 #define FDCAN_RXGFC_F1OM_Pos      (8U)
2910 #define FDCAN_RXGFC_F1OM_Msk      (0x1UL << FDCAN_RXGFC_F1OM_Pos)              /*!< 0x00000100 */
2911 #define FDCAN_RXGFC_F1OM          FDCAN_RXGFC_F1OM_Msk                         /*!<FIFO 1 operation mode                    */
2912 #define FDCAN_RXGFC_F0OM_Pos      (9U)
2913 #define FDCAN_RXGFC_F0OM_Msk      (0x1UL << FDCAN_RXGFC_F0OM_Pos)              /*!< 0x00000200 */
2914 #define FDCAN_RXGFC_F0OM          FDCAN_RXGFC_F0OM_Msk                         /*!<FIFO 0 operation mode                    */
2915 #define FDCAN_RXGFC_LSS_Pos       (16U)
2916 #define FDCAN_RXGFC_LSS_Msk       (0x1FUL << FDCAN_RXGFC_LSS_Pos)              /*!< 0x001F0000 */
2917 #define FDCAN_RXGFC_LSS           FDCAN_RXGFC_LSS_Msk                          /*!<List Size Standard                       */
2918 #define FDCAN_RXGFC_LSE_Pos       (24U)
2919 #define FDCAN_RXGFC_LSE_Msk       (0xFUL << FDCAN_RXGFC_LSE_Pos)               /*!< 0x0F000000 */
2920 #define FDCAN_RXGFC_LSE           FDCAN_RXGFC_LSE_Msk                          /*!<List Size Extended                       */
2921 
2922 /*****************  Bit definition for FDCAN_XIDAM register  ********************/
2923 #define FDCAN_XIDAM_EIDM_Pos      (0U)
2924 #define FDCAN_XIDAM_EIDM_Msk      (0x1FFFFFFFUL << FDCAN_XIDAM_EIDM_Pos)       /*!< 0x1FFFFFFF */
2925 #define FDCAN_XIDAM_EIDM          FDCAN_XIDAM_EIDM_Msk                         /*!<Extended ID Mask                         */
2926 
2927 /*****************  Bit definition for FDCAN_HPMS register  *********************/
2928 #define FDCAN_HPMS_BIDX_Pos       (0U)
2929 #define FDCAN_HPMS_BIDX_Msk       (0x7UL << FDCAN_HPMS_BIDX_Pos)               /*!< 0x00000007 */
2930 #define FDCAN_HPMS_BIDX           FDCAN_HPMS_BIDX_Msk                          /*!<Buffer Index                             */
2931 #define FDCAN_HPMS_MSI_Pos        (6U)
2932 #define FDCAN_HPMS_MSI_Msk        (0x3UL << FDCAN_HPMS_MSI_Pos)                /*!< 0x000000C0 */
2933 #define FDCAN_HPMS_MSI            FDCAN_HPMS_MSI_Msk                           /*!<Message Storage Indicator                */
2934 #define FDCAN_HPMS_FIDX_Pos       (8U)
2935 #define FDCAN_HPMS_FIDX_Msk       (0x1FUL << FDCAN_HPMS_FIDX_Pos)              /*!< 0x00001F00 */
2936 #define FDCAN_HPMS_FIDX           FDCAN_HPMS_FIDX_Msk                          /*!<Filter Index                             */
2937 #define FDCAN_HPMS_FLST_Pos       (15U)
2938 #define FDCAN_HPMS_FLST_Msk       (0x1UL << FDCAN_HPMS_FLST_Pos)               /*!< 0x00008000 */
2939 #define FDCAN_HPMS_FLST           FDCAN_HPMS_FLST_Msk                          /*!<Filter List                              */
2940 
2941 /*****************  Bit definition for FDCAN_RXF0S register  ********************/
2942 #define FDCAN_RXF0S_F0FL_Pos      (0U)
2943 #define FDCAN_RXF0S_F0FL_Msk      (0xFUL << FDCAN_RXF0S_F0FL_Pos)              /*!< 0x0000000F */
2944 #define FDCAN_RXF0S_F0FL          FDCAN_RXF0S_F0FL_Msk                         /*!<Rx FIFO 0 Fill Level                     */
2945 #define FDCAN_RXF0S_F0GI_Pos      (8U)
2946 #define FDCAN_RXF0S_F0GI_Msk      (0x3UL << FDCAN_RXF0S_F0GI_Pos)              /*!< 0x00000300 */
2947 #define FDCAN_RXF0S_F0GI          FDCAN_RXF0S_F0GI_Msk                         /*!<Rx FIFO 0 Get Index                      */
2948 #define FDCAN_RXF0S_F0PI_Pos      (16U)
2949 #define FDCAN_RXF0S_F0PI_Msk      (0x3UL << FDCAN_RXF0S_F0PI_Pos)              /*!< 0x00030000 */
2950 #define FDCAN_RXF0S_F0PI          FDCAN_RXF0S_F0PI_Msk                         /*!<Rx FIFO 0 Put Index                      */
2951 #define FDCAN_RXF0S_F0F_Pos       (24U)
2952 #define FDCAN_RXF0S_F0F_Msk       (0x1UL << FDCAN_RXF0S_F0F_Pos)               /*!< 0x01000000 */
2953 #define FDCAN_RXF0S_F0F           FDCAN_RXF0S_F0F_Msk                          /*!<Rx FIFO 0 Full                           */
2954 #define FDCAN_RXF0S_RF0L_Pos      (25U)
2955 #define FDCAN_RXF0S_RF0L_Msk      (0x1UL << FDCAN_RXF0S_RF0L_Pos)              /*!< 0x02000000 */
2956 #define FDCAN_RXF0S_RF0L          FDCAN_RXF0S_RF0L_Msk                         /*!<Rx FIFO 0 Message Lost                   */
2957 
2958 /*****************  Bit definition for FDCAN_RXF0A register  ********************/
2959 #define FDCAN_RXF0A_F0AI_Pos      (0U)
2960 #define FDCAN_RXF0A_F0AI_Msk      (0x7UL << FDCAN_RXF0A_F0AI_Pos)              /*!< 0x00000007 */
2961 #define FDCAN_RXF0A_F0AI          FDCAN_RXF0A_F0AI_Msk                         /*!<Rx FIFO 0 Acknowledge Index              */
2962 
2963 /*****************  Bit definition for FDCAN_RXF1S register  ********************/
2964 #define FDCAN_RXF1S_F1FL_Pos      (0U)
2965 #define FDCAN_RXF1S_F1FL_Msk      (0xFUL << FDCAN_RXF1S_F1FL_Pos)              /*!< 0x0000000F */
2966 #define FDCAN_RXF1S_F1FL          FDCAN_RXF1S_F1FL_Msk                         /*!<Rx FIFO 1 Fill Level                     */
2967 #define FDCAN_RXF1S_F1GI_Pos      (8U)
2968 #define FDCAN_RXF1S_F1GI_Msk      (0x3UL << FDCAN_RXF1S_F1GI_Pos)              /*!< 0x00000300 */
2969 #define FDCAN_RXF1S_F1GI          FDCAN_RXF1S_F1GI_Msk                         /*!<Rx FIFO 1 Get Index                      */
2970 #define FDCAN_RXF1S_F1PI_Pos      (16U)
2971 #define FDCAN_RXF1S_F1PI_Msk      (0x3UL << FDCAN_RXF1S_F1PI_Pos)              /*!< 0x00030000 */
2972 #define FDCAN_RXF1S_F1PI          FDCAN_RXF1S_F1PI_Msk                         /*!<Rx FIFO 1 Put Index                      */
2973 #define FDCAN_RXF1S_F1F_Pos       (24U)
2974 #define FDCAN_RXF1S_F1F_Msk       (0x1UL << FDCAN_RXF1S_F1F_Pos)               /*!< 0x01000000 */
2975 #define FDCAN_RXF1S_F1F           FDCAN_RXF1S_F1F_Msk                          /*!<Rx FIFO 1 Full                           */
2976 #define FDCAN_RXF1S_RF1L_Pos      (25U)
2977 #define FDCAN_RXF1S_RF1L_Msk      (0x1UL << FDCAN_RXF1S_RF1L_Pos)              /*!< 0x02000000 */
2978 #define FDCAN_RXF1S_RF1L          FDCAN_RXF1S_RF1L_Msk                         /*!<Rx FIFO 1 Message Lost                   */
2979 
2980 /*****************  Bit definition for FDCAN_RXF1A register  ********************/
2981 #define FDCAN_RXF1A_F1AI_Pos      (0U)
2982 #define FDCAN_RXF1A_F1AI_Msk      (0x7UL << FDCAN_RXF1A_F1AI_Pos)              /*!< 0x00000007 */
2983 #define FDCAN_RXF1A_F1AI          FDCAN_RXF1A_F1AI_Msk                         /*!<Rx FIFO 1 Acknowledge Index              */
2984 
2985 /*****************  Bit definition for FDCAN_TXBC register  *********************/
2986 #define FDCAN_TXBC_TFQM_Pos       (24U)
2987 #define FDCAN_TXBC_TFQM_Msk       (0x1UL << FDCAN_TXBC_TFQM_Pos)               /*!< 0x01000000 */
2988 #define FDCAN_TXBC_TFQM           FDCAN_TXBC_TFQM_Msk                          /*!<Tx FIFO/Queue Mode                       */
2989 
2990 /*****************  Bit definition for FDCAN_TXFQS register  *********************/
2991 #define FDCAN_TXFQS_TFFL_Pos      (0U)
2992 #define FDCAN_TXFQS_TFFL_Msk      (0x7UL << FDCAN_TXFQS_TFFL_Pos)              /*!< 0x00000007 */
2993 #define FDCAN_TXFQS_TFFL          FDCAN_TXFQS_TFFL_Msk                         /*!<Tx FIFO Free Level                       */
2994 #define FDCAN_TXFQS_TFGI_Pos      (8U)
2995 #define FDCAN_TXFQS_TFGI_Msk      (0x3UL << FDCAN_TXFQS_TFGI_Pos)              /*!< 0x00000300 */
2996 #define FDCAN_TXFQS_TFGI          FDCAN_TXFQS_TFGI_Msk                         /*!<Tx FIFO Get Index                        */
2997 #define FDCAN_TXFQS_TFQPI_Pos     (16U)
2998 #define FDCAN_TXFQS_TFQPI_Msk     (0x3UL << FDCAN_TXFQS_TFQPI_Pos)             /*!< 0x00030000 */
2999 #define FDCAN_TXFQS_TFQPI         FDCAN_TXFQS_TFQPI_Msk                        /*!<Tx FIFO/Queue Put Index                  */
3000 #define FDCAN_TXFQS_TFQF_Pos      (21U)
3001 #define FDCAN_TXFQS_TFQF_Msk      (0x1UL << FDCAN_TXFQS_TFQF_Pos)              /*!< 0x00200000 */
3002 #define FDCAN_TXFQS_TFQF          FDCAN_TXFQS_TFQF_Msk                         /*!<Tx FIFO/Queue Full                       */
3003 
3004 /*****************  Bit definition for FDCAN_TXBRP register  *********************/
3005 #define FDCAN_TXBRP_TRP_Pos       (0U)
3006 #define FDCAN_TXBRP_TRP_Msk       (0x7UL << FDCAN_TXBRP_TRP_Pos)               /*!< 0x00000007 */
3007 #define FDCAN_TXBRP_TRP           FDCAN_TXBRP_TRP_Msk                          /*!<Transmission Request Pending             */
3008 
3009 /*****************  Bit definition for FDCAN_TXBAR register  *********************/
3010 #define FDCAN_TXBAR_AR_Pos        (0U)
3011 #define FDCAN_TXBAR_AR_Msk        (0x7UL << FDCAN_TXBAR_AR_Pos)                /*!< 0x00000007 */
3012 #define FDCAN_TXBAR_AR            FDCAN_TXBAR_AR_Msk                           /*!<Add Request                              */
3013 
3014 /*****************  Bit definition for FDCAN_TXBCR register  *********************/
3015 #define FDCAN_TXBCR_CR_Pos        (0U)
3016 #define FDCAN_TXBCR_CR_Msk        (0x7UL << FDCAN_TXBCR_CR_Pos)                /*!< 0x00000007 */
3017 #define FDCAN_TXBCR_CR            FDCAN_TXBCR_CR_Msk                           /*!<Cancellation Request                     */
3018 
3019 /*****************  Bit definition for FDCAN_TXBTO register  *********************/
3020 #define FDCAN_TXBTO_TO_Pos        (0U)
3021 #define FDCAN_TXBTO_TO_Msk        (0x7UL << FDCAN_TXBTO_TO_Pos)                /*!< 0x00000007 */
3022 #define FDCAN_TXBTO_TO            FDCAN_TXBTO_TO_Msk                           /*!<Transmission Occurred                    */
3023 
3024 /*****************  Bit definition for FDCAN_TXBCF register  *********************/
3025 #define FDCAN_TXBCF_CF_Pos        (0U)
3026 #define FDCAN_TXBCF_CF_Msk        (0x7UL << FDCAN_TXBCF_CF_Pos)                /*!< 0x00000007 */
3027 #define FDCAN_TXBCF_CF            FDCAN_TXBCF_CF_Msk                           /*!<Cancellation Finished                    */
3028 
3029 /*****************  Bit definition for FDCAN_TXBTIE register  ********************/
3030 #define FDCAN_TXBTIE_TIE_Pos      (0U)
3031 #define FDCAN_TXBTIE_TIE_Msk      (0x7UL << FDCAN_TXBTIE_TIE_Pos)              /*!< 0x00000007 */
3032 #define FDCAN_TXBTIE_TIE          FDCAN_TXBTIE_TIE_Msk                         /*!<Transmission Interrupt Enable            */
3033 
3034 /*****************  Bit definition for FDCAN_ TXBCIE register  *******************/
3035 #define FDCAN_TXBCIE_CFIE_Pos     (0U)
3036 #define FDCAN_TXBCIE_CFIE_Msk     (0x7UL << FDCAN_TXBCIE_CFIE_Pos)             /*!< 0x00000007 */
3037 #define FDCAN_TXBCIE_CFIE         FDCAN_TXBCIE_CFIE_Msk                        /*!<Cancellation Finished Interrupt Enable   */
3038 
3039 /*****************  Bit definition for FDCAN_TXEFS register  *********************/
3040 #define FDCAN_TXEFS_EFFL_Pos      (0U)
3041 #define FDCAN_TXEFS_EFFL_Msk      (0x7UL << FDCAN_TXEFS_EFFL_Pos)              /*!< 0x00000007 */
3042 #define FDCAN_TXEFS_EFFL          FDCAN_TXEFS_EFFL_Msk                         /*!<Event FIFO Fill Level                    */
3043 #define FDCAN_TXEFS_EFGI_Pos      (8U)
3044 #define FDCAN_TXEFS_EFGI_Msk      (0x3UL << FDCAN_TXEFS_EFGI_Pos)              /*!< 0x00000300 */
3045 #define FDCAN_TXEFS_EFGI          FDCAN_TXEFS_EFGI_Msk                         /*!<Event FIFO Get Index                     */
3046 #define FDCAN_TXEFS_EFPI_Pos      (16U)
3047 #define FDCAN_TXEFS_EFPI_Msk      (0x3UL << FDCAN_TXEFS_EFPI_Pos)              /*!< 0x00030000 */
3048 #define FDCAN_TXEFS_EFPI          FDCAN_TXEFS_EFPI_Msk                         /*!<Event FIFO Put Index                     */
3049 #define FDCAN_TXEFS_EFF_Pos       (24U)
3050 #define FDCAN_TXEFS_EFF_Msk       (0x1UL << FDCAN_TXEFS_EFF_Pos)               /*!< 0x01000000 */
3051 #define FDCAN_TXEFS_EFF           FDCAN_TXEFS_EFF_Msk                          /*!<Event FIFO Full                          */
3052 #define FDCAN_TXEFS_TEFL_Pos      (25U)
3053 #define FDCAN_TXEFS_TEFL_Msk      (0x1UL << FDCAN_TXEFS_TEFL_Pos)              /*!< 0x02000000 */
3054 #define FDCAN_TXEFS_TEFL          FDCAN_TXEFS_TEFL_Msk                         /*!<Tx Event FIFO Element Lost               */
3055 
3056 /*****************  Bit definition for FDCAN_TXEFA register  *********************/
3057 #define FDCAN_TXEFA_EFAI_Pos      (0U)
3058 #define FDCAN_TXEFA_EFAI_Msk      (0x3UL << FDCAN_TXEFA_EFAI_Pos)              /*!< 0x00000003 */
3059 #define FDCAN_TXEFA_EFAI          FDCAN_TXEFA_EFAI_Msk                         /*!<Event FIFO Acknowledge Index             */
3060 
3061 
3062 /*!<FDCAN config registers */
3063 /*****************  Bit definition for FDCAN_CKDIV register  *********************/
3064 #define FDCAN_CKDIV_PDIV_Pos      (0U)
3065 #define FDCAN_CKDIV_PDIV_Msk      (0xFUL << FDCAN_CKDIV_PDIV_Pos)              /*!< 0x0000000F */
3066 #define FDCAN_CKDIV_PDIV          FDCAN_CKDIV_PDIV_Msk                         /*!<Input Clock Divider                      */
3067 
3068 /******************************************************************************/
3069 /*                                                                            */
3070 /*                                    FLASH                                   */
3071 /*                                                                            */
3072 /******************************************************************************/
3073 /* Note: No specific macro feature on this device */
3074 #define FLASH_DBANK_SUPPORT              /*!< Flash feature available only on specific devices: dualbank */
3075 
3076 /*******************  Bits definition for FLASH_ACR register  *****************/
3077 #define FLASH_ACR_LATENCY_Pos                  (0U)
3078 #define FLASH_ACR_LATENCY_Msk                  (0x7UL << FLASH_ACR_LATENCY_Pos) /*!< 0x00000007 */
3079 #define FLASH_ACR_LATENCY                      FLASH_ACR_LATENCY_Msk
3080 #define FLASH_ACR_LATENCY_0                    (0x1UL << FLASH_ACR_LATENCY_Pos) /*!< 0x00000001 */
3081 #define FLASH_ACR_LATENCY_1                    (0x2UL << FLASH_ACR_LATENCY_Pos) /*!< 0x00000002 */
3082 #define FLASH_ACR_LATENCY_2                    (0x4UL << FLASH_ACR_LATENCY_Pos) /*!< 0x00000004 */
3083 #define FLASH_ACR_PRFTEN_Pos                   (8U)
3084 #define FLASH_ACR_PRFTEN_Msk                   (0x1UL << FLASH_ACR_PRFTEN_Pos)  /*!< 0x00000100 */
3085 #define FLASH_ACR_PRFTEN                       FLASH_ACR_PRFTEN_Msk
3086 #define FLASH_ACR_ICEN_Pos                     (9U)
3087 #define FLASH_ACR_ICEN_Msk                     (0x1UL << FLASH_ACR_ICEN_Pos)    /*!< 0x00000200 */
3088 #define FLASH_ACR_ICEN                         FLASH_ACR_ICEN_Msk
3089 #define FLASH_ACR_ICRST_Pos                    (11U)
3090 #define FLASH_ACR_ICRST_Msk                    (0x1UL << FLASH_ACR_ICRST_Pos)   /*!< 0x00000800 */
3091 #define FLASH_ACR_ICRST                        FLASH_ACR_ICRST_Msk
3092 #define FLASH_ACR_PROGEMPTY_Pos                (16U)
3093 #define FLASH_ACR_PROGEMPTY_Msk                (0x1UL << FLASH_ACR_PROGEMPTY_Pos) /*!< 0x00010000 */
3094 #define FLASH_ACR_PROGEMPTY                    FLASH_ACR_PROGEMPTY_Msk
3095 
3096 /*******************  Bits definition for FLASH_SR register  ******************/
3097 #define FLASH_SR_EOP_Pos                       (0U)
3098 #define FLASH_SR_EOP_Msk                       (0x1UL << FLASH_SR_EOP_Pos)      /*!< 0x00000001 */
3099 #define FLASH_SR_EOP                           FLASH_SR_EOP_Msk
3100 #define FLASH_SR_OPERR_Pos                     (1U)
3101 #define FLASH_SR_OPERR_Msk                     (0x1UL << FLASH_SR_OPERR_Pos)    /*!< 0x00000002 */
3102 #define FLASH_SR_OPERR                         FLASH_SR_OPERR_Msk
3103 #define FLASH_SR_PROGERR_Pos                   (3U)
3104 #define FLASH_SR_PROGERR_Msk                   (0x1UL << FLASH_SR_PROGERR_Pos)  /*!< 0x00000008 */
3105 #define FLASH_SR_PROGERR                       FLASH_SR_PROGERR_Msk
3106 #define FLASH_SR_WRPERR_Pos                    (4U)
3107 #define FLASH_SR_WRPERR_Msk                    (0x1UL << FLASH_SR_WRPERR_Pos)   /*!< 0x00000010 */
3108 #define FLASH_SR_WRPERR                        FLASH_SR_WRPERR_Msk
3109 #define FLASH_SR_PGAERR_Pos                    (5U)
3110 #define FLASH_SR_PGAERR_Msk                    (0x1UL << FLASH_SR_PGAERR_Pos)   /*!< 0x00000020 */
3111 #define FLASH_SR_PGAERR                        FLASH_SR_PGAERR_Msk
3112 #define FLASH_SR_SIZERR_Pos                    (6U)
3113 #define FLASH_SR_SIZERR_Msk                    (0x1UL << FLASH_SR_SIZERR_Pos)   /*!< 0x00000040 */
3114 #define FLASH_SR_SIZERR                        FLASH_SR_SIZERR_Msk
3115 #define FLASH_SR_PGSERR_Pos                    (7U)
3116 #define FLASH_SR_PGSERR_Msk                    (0x1UL << FLASH_SR_PGSERR_Pos)   /*!< 0x00000080 */
3117 #define FLASH_SR_PGSERR                        FLASH_SR_PGSERR_Msk
3118 #define FLASH_SR_MISERR_Pos                    (8U)
3119 #define FLASH_SR_MISERR_Msk                    (0x1UL << FLASH_SR_MISERR_Pos)   /*!< 0x00000100 */
3120 #define FLASH_SR_MISERR                        FLASH_SR_MISERR_Msk
3121 #define FLASH_SR_FASTERR_Pos                   (9U)
3122 #define FLASH_SR_FASTERR_Msk                   (0x1UL << FLASH_SR_FASTERR_Pos)  /*!< 0x00000200 */
3123 #define FLASH_SR_FASTERR                       FLASH_SR_FASTERR_Msk
3124 #define FLASH_SR_OPTVERR_Pos                   (15U)
3125 #define FLASH_SR_OPTVERR_Msk                   (0x1UL << FLASH_SR_OPTVERR_Pos)  /*!< 0x00008000 */
3126 #define FLASH_SR_OPTVERR                       FLASH_SR_OPTVERR_Msk
3127 #define FLASH_SR_BSY1_Pos                      (16U)
3128 #define FLASH_SR_BSY1_Msk                      (0x1UL << FLASH_SR_BSY1_Pos)     /*!< 0x00010000 */
3129 #define FLASH_SR_BSY1                          FLASH_SR_BSY1_Msk
3130 #define FLASH_SR_BSY2_Pos                      (17U)
3131 #define FLASH_SR_BSY2_Msk                      (0x1UL << FLASH_SR_BSY2_Pos)     /*!< 0x00020000 */
3132 #define FLASH_SR_BSY2                          FLASH_SR_BSY2_Msk
3133 #define FLASH_SR_CFGBSY_Pos                    (18U)
3134 #define FLASH_SR_CFGBSY_Msk                    (0x1UL << FLASH_SR_CFGBSY_Pos)   /*!< 0x00040000 */
3135 #define FLASH_SR_CFGBSY                        FLASH_SR_CFGBSY_Msk
3136 #define FLASH_SR_PESD_Pos                      (19U)
3137 #define FLASH_SR_PESD_Msk                      (0x1UL << FLASH_SR_PESD_Pos)   /*!< 0x00080000 */
3138 #define FLASH_SR_PESD                          FLASH_SR_PESD_Msk
3139 
3140 /*******************  Bits definition for FLASH_CR register  ******************/
3141 #define FLASH_CR_PG_Pos                        (0U)
3142 #define FLASH_CR_PG_Msk                        (0x1UL << FLASH_CR_PG_Pos)         /*!< 0x00000001 */
3143 #define FLASH_CR_PG                            FLASH_CR_PG_Msk
3144 #define FLASH_CR_PER_Pos                       (1U)
3145 #define FLASH_CR_PER_Msk                       (0x1UL << FLASH_CR_PER_Pos)        /*!< 0x00000002 */
3146 #define FLASH_CR_PER                           FLASH_CR_PER_Msk
3147 #define FLASH_CR_MER1_Pos                      (2U)
3148 #define FLASH_CR_MER1_Msk                      (0x1UL << FLASH_CR_MER1_Pos)       /*!< 0x00000004 */
3149 #define FLASH_CR_MER1                          FLASH_CR_MER1_Msk
3150 #define FLASH_CR_PNB_Pos                       (3U)
3151 #define FLASH_CR_PNB_Msk                       (0x3FFUL << FLASH_CR_PNB_Pos)       /*!< 0x00001FF8 */
3152 #define FLASH_CR_PNB                           FLASH_CR_PNB_Msk
3153 #define FLASH_CR_BKER_Pos                      (13U)
3154 #define FLASH_CR_BKER_Msk                      (0x1UL << FLASH_CR_BKER_Pos)       /*!< 0x00002000 */
3155 #define FLASH_CR_BKER                          FLASH_CR_BKER_Msk
3156 #define FLASH_CR_MER2_Pos                      (15U)
3157 #define FLASH_CR_MER2_Msk                      (0x1UL << FLASH_CR_MER2_Pos)       /*!< 0x00008000 */
3158 #define FLASH_CR_MER2                          FLASH_CR_MER2_Msk
3159 #define FLASH_CR_STRT_Pos                      (16U)
3160 #define FLASH_CR_STRT_Msk                      (0x1UL << FLASH_CR_STRT_Pos)       /*!< 0x00010000 */
3161 #define FLASH_CR_STRT                          FLASH_CR_STRT_Msk
3162 #define FLASH_CR_OPTSTRT_Pos                   (17U)
3163 #define FLASH_CR_OPTSTRT_Msk                   (0x1UL << FLASH_CR_OPTSTRT_Pos)    /*!< 0x00020000 */
3164 #define FLASH_CR_OPTSTRT                       FLASH_CR_OPTSTRT_Msk
3165 #define FLASH_CR_FSTPG_Pos                     (18U)
3166 #define FLASH_CR_FSTPG_Msk                     (0x1UL << FLASH_CR_FSTPG_Pos)      /*!< 0x00040000 */
3167 #define FLASH_CR_FSTPG                         FLASH_CR_FSTPG_Msk
3168 #define FLASH_CR_EOPIE_Pos                     (24U)
3169 #define FLASH_CR_EOPIE_Msk                     (0x1UL << FLASH_CR_EOPIE_Pos)      /*!< 0x01000000 */
3170 #define FLASH_CR_EOPIE                         FLASH_CR_EOPIE_Msk
3171 #define FLASH_CR_ERRIE_Pos                     (25U)
3172 #define FLASH_CR_ERRIE_Msk                     (0x1UL << FLASH_CR_ERRIE_Pos)      /*!< 0x02000000 */
3173 #define FLASH_CR_ERRIE                         FLASH_CR_ERRIE_Msk
3174 #define FLASH_CR_OBL_LAUNCH_Pos                (27U)
3175 #define FLASH_CR_OBL_LAUNCH_Msk                (0x1UL << FLASH_CR_OBL_LAUNCH_Pos) /*!< 0x08000000 */
3176 #define FLASH_CR_OBL_LAUNCH                    FLASH_CR_OBL_LAUNCH_Msk
3177 #define FLASH_CR_OPTLOCK_Pos                   (30U)
3178 #define FLASH_CR_OPTLOCK_Msk                   (0x1UL << FLASH_CR_OPTLOCK_Pos)    /*!< 0x40000000 */
3179 #define FLASH_CR_OPTLOCK                       FLASH_CR_OPTLOCK_Msk
3180 #define FLASH_CR_LOCK_Pos                      (31U)
3181 #define FLASH_CR_LOCK_Msk                      (0x1UL << FLASH_CR_LOCK_Pos)       /*!< 0x80000000 */
3182 #define FLASH_CR_LOCK                          FLASH_CR_LOCK_Msk
3183 
3184 /*******************  Bits definition for FLASH_ECCR register  ****************/
3185 #define FLASH_ECCR_ADDR_ECC_Pos                (0U)
3186 #define FLASH_ECCR_ADDR_ECC_Msk                (0x7FFFUL << FLASH_ECCR_ADDR_ECC_Pos)  /*!< 0x00007FFF */
3187 #define FLASH_ECCR_ADDR_ECC                    FLASH_ECCR_ADDR_ECC_Msk
3188 #define FLASH_ECCR_SYSF_ECC_Pos                (20U)
3189 #define FLASH_ECCR_SYSF_ECC_Msk                (0x1UL << FLASH_ECCR_SYSF_ECC_Pos)     /*!< 0x00100000 */
3190 #define FLASH_ECCR_SYSF_ECC                    FLASH_ECCR_SYSF_ECC_Msk
3191 #define FLASH_ECCR_ECCCIE_Pos                  (24U)
3192 #define FLASH_ECCR_ECCCIE_Msk                  (0x1UL << FLASH_ECCR_ECCCIE_Pos)       /*!< 0x01000000 */
3193 #define FLASH_ECCR_ECCCIE                      FLASH_ECCR_ECCCIE_Msk
3194 #define FLASH_ECCR_ECCC_Pos                    (30U)
3195 #define FLASH_ECCR_ECCC_Msk                    (0x1UL << FLASH_ECCR_ECCC_Pos)         /*!< 0x40000000 */
3196 #define FLASH_ECCR_ECCC                        FLASH_ECCR_ECCC_Msk
3197 #define FLASH_ECCR_ECCD_Pos                    (31U)
3198 #define FLASH_ECCR_ECCD_Msk                    (0x1UL << FLASH_ECCR_ECCD_Pos)         /*!< 0x80000000 */
3199 #define FLASH_ECCR_ECCD                        FLASH_ECCR_ECCD_Msk
3200 
3201 /*******************  Bits definition for FLASH_ECC2R register  ****************/
3202 #define FLASH_ECC2R_ADDR_ECC_Pos                (0U)
3203 #define FLASH_ECC2R_ADDR_ECC_Msk                (0x7FFFUL << FLASH_ECC2R_ADDR_ECC_Pos)  /*!< 0x00007FFF */
3204 #define FLASH_ECC2R_ADDR_ECC                    FLASH_ECC2R_ADDR_ECC_Msk
3205 #define FLASH_ECC2R_SYSF_ECC_Pos                (20U)
3206 #define FLASH_ECC2R_SYSF_ECC_Msk                (0x1UL << FLASH_ECC2R_SYSF_ECC_Pos)     /*!< 0x00100000 */
3207 #define FLASH_ECC2R_SYSF_ECC                    FLASH_ECC2R_SYSF_ECC_Msk
3208 #define FLASH_ECC2R_ECCCIE_Pos                  (24U)
3209 #define FLASH_ECC2R_ECCCIE_Msk                  (0x1UL << FLASH_ECC2R_ECCCIE_Pos)       /*!< 0x01000000 */
3210 #define FLASH_ECC2R_ECCCIE                      FLASH_ECC2R_ECCCIE_Msk
3211 #define FLASH_ECC2R_ECCC_Pos                    (30U)
3212 #define FLASH_ECC2R_ECCC_Msk                    (0x1UL << FLASH_ECC2R_ECCC_Pos)         /*!< 0x40000000 */
3213 #define FLASH_ECC2R_ECCC                        FLASH_ECC2R_ECCC_Msk
3214 #define FLASH_ECC2R_ECCD_Pos                    (31U)
3215 #define FLASH_ECC2R_ECCD_Msk                    (0x1UL << FLASH_ECC2R_ECCD_Pos)         /*!< 0x80000000 */
3216 #define FLASH_ECC2R_ECCD                        FLASH_ECC2R_ECCD_Msk
3217 
3218 /*******************  Bits definition for FLASH_OPTR register  ****************/
3219 #define FLASH_OPTR_RDP_Pos                     (0U)
3220 #define FLASH_OPTR_RDP_Msk                     (0xFFUL << FLASH_OPTR_RDP_Pos)             /*!< 0x000000FF */
3221 #define FLASH_OPTR_RDP                         FLASH_OPTR_RDP_Msk
3222 #define FLASH_OPTR_nRST_STOP_Pos               (13U)
3223 #define FLASH_OPTR_nRST_STOP_Msk               (0x1UL << FLASH_OPTR_nRST_STOP_Pos)        /*!< 0x00002000 */
3224 #define FLASH_OPTR_nRST_STOP                   FLASH_OPTR_nRST_STOP_Msk
3225 #define FLASH_OPTR_nRST_STDBY_Pos              (14U)
3226 #define FLASH_OPTR_nRST_STDBY_Msk              (0x1UL << FLASH_OPTR_nRST_STDBY_Pos)       /*!< 0x00004000 */
3227 #define FLASH_OPTR_nRST_STDBY                  FLASH_OPTR_nRST_STDBY_Msk
3228 #define FLASH_OPTR_IWDG_SW_Pos                 (16U)
3229 #define FLASH_OPTR_IWDG_SW_Msk                 (0x1UL << FLASH_OPTR_IWDG_SW_Pos)          /*!< 0x00010000 */
3230 #define FLASH_OPTR_IWDG_SW                     FLASH_OPTR_IWDG_SW_Msk
3231 #define FLASH_OPTR_IWDG_STOP_Pos               (17U)
3232 #define FLASH_OPTR_IWDG_STOP_Msk               (0x1UL << FLASH_OPTR_IWDG_STOP_Pos)        /*!< 0x00020000 */
3233 #define FLASH_OPTR_IWDG_STOP                   FLASH_OPTR_IWDG_STOP_Msk
3234 #define FLASH_OPTR_IWDG_STDBY_Pos              (18U)
3235 #define FLASH_OPTR_IWDG_STDBY_Msk              (0x1UL << FLASH_OPTR_IWDG_STDBY_Pos)       /*!< 0x00040000 */
3236 #define FLASH_OPTR_IWDG_STDBY                  FLASH_OPTR_IWDG_STDBY_Msk
3237 #define FLASH_OPTR_WWDG_SW_Pos                 (19U)
3238 #define FLASH_OPTR_WWDG_SW_Msk                 (0x1UL << FLASH_OPTR_WWDG_SW_Pos)          /*!< 0x00080000 */
3239 #define FLASH_OPTR_WWDG_SW                     FLASH_OPTR_WWDG_SW_Msk
3240 #define FLASH_OPTR_nSWAP_BANK_Pos              (20U)
3241 #define FLASH_OPTR_nSWAP_BANK_Msk              (0x1UL << FLASH_OPTR_nSWAP_BANK_Pos)        /*!< 0x00100000 */
3242 #define FLASH_OPTR_nSWAP_BANK                  FLASH_OPTR_nSWAP_BANK_Msk
3243 #define FLASH_OPTR_DUAL_BANK_Pos               (21U)
3244 #define FLASH_OPTR_DUAL_BANK_Msk               (0x1UL << FLASH_OPTR_DUAL_BANK_Pos)        /*!< 0x00200000 */
3245 #define FLASH_OPTR_DUAL_BANK                   FLASH_OPTR_DUAL_BANK_Msk
3246 #define FLASH_OPTR_RAM_PARITY_CHECK_Pos        (22U)
3247 #define FLASH_OPTR_RAM_PARITY_CHECK_Msk        (0x1UL << FLASH_OPTR_RAM_PARITY_CHECK_Pos) /*!< 0x00400000 */
3248 #define FLASH_OPTR_RAM_PARITY_CHECK            FLASH_OPTR_RAM_PARITY_CHECK_Msk
3249 #define FLASH_OPTR_nBOOT_SEL_Pos               (24U)
3250 #define FLASH_OPTR_nBOOT_SEL_Msk               (0x1UL << FLASH_OPTR_nBOOT_SEL_Pos)        /*!< 0x01000000 */
3251 #define FLASH_OPTR_nBOOT_SEL                   FLASH_OPTR_nBOOT_SEL_Msk
3252 #define FLASH_OPTR_nBOOT1_Pos                  (25U)
3253 #define FLASH_OPTR_nBOOT1_Msk                  (0x1UL << FLASH_OPTR_nBOOT1_Pos)           /*!< 0x02000000 */
3254 #define FLASH_OPTR_nBOOT1                      FLASH_OPTR_nBOOT1_Msk
3255 #define FLASH_OPTR_nBOOT0_Pos                  (26U)
3256 #define FLASH_OPTR_nBOOT0_Msk                  (0x1UL << FLASH_OPTR_nBOOT0_Pos)           /*!< 0x04000000 */
3257 #define FLASH_OPTR_nBOOT0                      FLASH_OPTR_nBOOT0_Msk
3258 
3259 /******************  Bits definition for FLASH_WRP1AR register  ***************/
3260 #define FLASH_WRP1AR_WRP1A_STRT_Pos            (0U)
3261 #define FLASH_WRP1AR_WRP1A_STRT_Msk            (0x7FUL << FLASH_WRP1AR_WRP1A_STRT_Pos) /*!< 0x0000007F */
3262 #define FLASH_WRP1AR_WRP1A_STRT                FLASH_WRP1AR_WRP1A_STRT_Msk
3263 #define FLASH_WRP1AR_WRP1A_END_Pos             (16U)
3264 #define FLASH_WRP1AR_WRP1A_END_Msk             (0x7FUL << FLASH_WRP1AR_WRP1A_END_Pos) /*!< 0x007F0000 */
3265 #define FLASH_WRP1AR_WRP1A_END                 FLASH_WRP1AR_WRP1A_END_Msk
3266 
3267 /******************  Bits definition for FLASH_WRP1BR register  ***************/
3268 #define FLASH_WRP1BR_WRP1B_STRT_Pos            (0U)
3269 #define FLASH_WRP1BR_WRP1B_STRT_Msk            (0x7FUL << FLASH_WRP1BR_WRP1B_STRT_Pos) /*!< 0x0000007F */
3270 #define FLASH_WRP1BR_WRP1B_STRT                FLASH_WRP1BR_WRP1B_STRT_Msk
3271 #define FLASH_WRP1BR_WRP1B_END_Pos             (16U)
3272 #define FLASH_WRP1BR_WRP1B_END_Msk             (0x7FUL << FLASH_WRP1BR_WRP1B_END_Pos) /*!< 0x007F0000 */
3273 #define FLASH_WRP1BR_WRP1B_END                 FLASH_WRP1BR_WRP1B_END_Msk
3274 
3275 
3276 /******************  Bits definition for FLASH_WRP2AR register  ***************/
3277 #define FLASH_WRP2AR_WRP2A_STRT_Pos            (0U)
3278 #define FLASH_WRP2AR_WRP2A_STRT_Msk            (0x7FUL << FLASH_WRP2AR_WRP2A_STRT_Pos)  /*!< 0x0000007F */
3279 #define FLASH_WRP2AR_WRP2A_STRT                FLASH_WRP2AR_WRP2A_STRT_Msk
3280 #define FLASH_WRP2AR_WRP2A_END_Pos             (16U)
3281 #define FLASH_WRP2AR_WRP2A_END_Msk             (0x7FUL << FLASH_WRP2AR_WRP2A_END_Pos)   /*!< 0x007F0000 */
3282 #define FLASH_WRP2AR_WRP2A_END                 FLASH_WRP2AR_WRP2A_END_Msk
3283 
3284 /******************  Bits definition for FLASH_WRP2BSR register  ***************/
3285 #define FLASH_WRP2BR_WRP2B_STRT_Pos            (0U)
3286 #define FLASH_WRP2BR_WRP2B_STRT_Msk            (0x7FUL << FLASH_WRP2BR_WRP2B_STRT_Pos)  /*!< 0x0000007F */
3287 #define FLASH_WRP2BR_WRP2B_STRT                FLASH_WRP2BR_WRP2B_STRT_Msk
3288 #define FLASH_WRP2BR_WRP2B_END_Pos             (16U)
3289 #define FLASH_WRP2BR_WRP2B_END_Msk             (0x7FUL << FLASH_WRP2BR_WRP2B_END_Pos)   /*!< 0x007F0000 */
3290 #define FLASH_WRP2BR_WRP2B_END                 FLASH_WRP2BR_WRP2B_END_Msk
3291 
3292 /******************************************************************************/
3293 /*                                                                            */
3294 /*                            General Purpose I/O                             */
3295 /*                                                                            */
3296 /******************************************************************************/
3297 /******************  Bits definition for GPIO_MODER register  *****************/
3298 #define GPIO_MODER_MODE0_Pos           (0U)
3299 #define GPIO_MODER_MODE0_Msk           (0x3UL << GPIO_MODER_MODE0_Pos)          /*!< 0x00000003 */
3300 #define GPIO_MODER_MODE0               GPIO_MODER_MODE0_Msk
3301 #define GPIO_MODER_MODE0_0             (0x1UL << GPIO_MODER_MODE0_Pos)          /*!< 0x00000001 */
3302 #define GPIO_MODER_MODE0_1             (0x2UL << GPIO_MODER_MODE0_Pos)          /*!< 0x00000002 */
3303 #define GPIO_MODER_MODE1_Pos           (2U)
3304 #define GPIO_MODER_MODE1_Msk           (0x3UL << GPIO_MODER_MODE1_Pos)          /*!< 0x0000000C */
3305 #define GPIO_MODER_MODE1               GPIO_MODER_MODE1_Msk
3306 #define GPIO_MODER_MODE1_0             (0x1UL << GPIO_MODER_MODE1_Pos)          /*!< 0x00000004 */
3307 #define GPIO_MODER_MODE1_1             (0x2UL << GPIO_MODER_MODE1_Pos)          /*!< 0x00000008 */
3308 #define GPIO_MODER_MODE2_Pos           (4U)
3309 #define GPIO_MODER_MODE2_Msk           (0x3UL << GPIO_MODER_MODE2_Pos)          /*!< 0x00000030 */
3310 #define GPIO_MODER_MODE2               GPIO_MODER_MODE2_Msk
3311 #define GPIO_MODER_MODE2_0             (0x1UL << GPIO_MODER_MODE2_Pos)          /*!< 0x00000010 */
3312 #define GPIO_MODER_MODE2_1             (0x2UL << GPIO_MODER_MODE2_Pos)          /*!< 0x00000020 */
3313 #define GPIO_MODER_MODE3_Pos           (6U)
3314 #define GPIO_MODER_MODE3_Msk           (0x3UL << GPIO_MODER_MODE3_Pos)          /*!< 0x000000C0 */
3315 #define GPIO_MODER_MODE3               GPIO_MODER_MODE3_Msk
3316 #define GPIO_MODER_MODE3_0             (0x1UL << GPIO_MODER_MODE3_Pos)          /*!< 0x00000040 */
3317 #define GPIO_MODER_MODE3_1             (0x2UL << GPIO_MODER_MODE3_Pos)          /*!< 0x00000080 */
3318 #define GPIO_MODER_MODE4_Pos           (8U)
3319 #define GPIO_MODER_MODE4_Msk           (0x3UL << GPIO_MODER_MODE4_Pos)          /*!< 0x00000300 */
3320 #define GPIO_MODER_MODE4               GPIO_MODER_MODE4_Msk
3321 #define GPIO_MODER_MODE4_0             (0x1UL << GPIO_MODER_MODE4_Pos)          /*!< 0x00000100 */
3322 #define GPIO_MODER_MODE4_1             (0x2UL << GPIO_MODER_MODE4_Pos)          /*!< 0x00000200 */
3323 #define GPIO_MODER_MODE5_Pos           (10U)
3324 #define GPIO_MODER_MODE5_Msk           (0x3UL << GPIO_MODER_MODE5_Pos)          /*!< 0x00000C00 */
3325 #define GPIO_MODER_MODE5               GPIO_MODER_MODE5_Msk
3326 #define GPIO_MODER_MODE5_0             (0x1UL << GPIO_MODER_MODE5_Pos)          /*!< 0x00000400 */
3327 #define GPIO_MODER_MODE5_1             (0x2UL << GPIO_MODER_MODE5_Pos)          /*!< 0x00000800 */
3328 #define GPIO_MODER_MODE6_Pos           (12U)
3329 #define GPIO_MODER_MODE6_Msk           (0x3UL << GPIO_MODER_MODE6_Pos)          /*!< 0x00003000 */
3330 #define GPIO_MODER_MODE6               GPIO_MODER_MODE6_Msk
3331 #define GPIO_MODER_MODE6_0             (0x1UL << GPIO_MODER_MODE6_Pos)          /*!< 0x00001000 */
3332 #define GPIO_MODER_MODE6_1             (0x2UL << GPIO_MODER_MODE6_Pos)          /*!< 0x00002000 */
3333 #define GPIO_MODER_MODE7_Pos           (14U)
3334 #define GPIO_MODER_MODE7_Msk           (0x3UL << GPIO_MODER_MODE7_Pos)          /*!< 0x0000C000 */
3335 #define GPIO_MODER_MODE7               GPIO_MODER_MODE7_Msk
3336 #define GPIO_MODER_MODE7_0             (0x1UL << GPIO_MODER_MODE7_Pos)          /*!< 0x00004000 */
3337 #define GPIO_MODER_MODE7_1             (0x2UL << GPIO_MODER_MODE7_Pos)          /*!< 0x00008000 */
3338 #define GPIO_MODER_MODE8_Pos           (16U)
3339 #define GPIO_MODER_MODE8_Msk           (0x3UL << GPIO_MODER_MODE8_Pos)          /*!< 0x00030000 */
3340 #define GPIO_MODER_MODE8               GPIO_MODER_MODE8_Msk
3341 #define GPIO_MODER_MODE8_0             (0x1UL << GPIO_MODER_MODE8_Pos)          /*!< 0x00010000 */
3342 #define GPIO_MODER_MODE8_1             (0x2UL << GPIO_MODER_MODE8_Pos)          /*!< 0x00020000 */
3343 #define GPIO_MODER_MODE9_Pos           (18U)
3344 #define GPIO_MODER_MODE9_Msk           (0x3UL << GPIO_MODER_MODE9_Pos)          /*!< 0x000C0000 */
3345 #define GPIO_MODER_MODE9               GPIO_MODER_MODE9_Msk
3346 #define GPIO_MODER_MODE9_0             (0x1UL << GPIO_MODER_MODE9_Pos)          /*!< 0x00040000 */
3347 #define GPIO_MODER_MODE9_1             (0x2UL << GPIO_MODER_MODE9_Pos)          /*!< 0x00080000 */
3348 #define GPIO_MODER_MODE10_Pos          (20U)
3349 #define GPIO_MODER_MODE10_Msk          (0x3UL << GPIO_MODER_MODE10_Pos)         /*!< 0x00300000 */
3350 #define GPIO_MODER_MODE10              GPIO_MODER_MODE10_Msk
3351 #define GPIO_MODER_MODE10_0            (0x1UL << GPIO_MODER_MODE10_Pos)         /*!< 0x00100000 */
3352 #define GPIO_MODER_MODE10_1            (0x2UL << GPIO_MODER_MODE10_Pos)         /*!< 0x00200000 */
3353 #define GPIO_MODER_MODE11_Pos          (22U)
3354 #define GPIO_MODER_MODE11_Msk          (0x3UL << GPIO_MODER_MODE11_Pos)         /*!< 0x00C00000 */
3355 #define GPIO_MODER_MODE11              GPIO_MODER_MODE11_Msk
3356 #define GPIO_MODER_MODE11_0            (0x1UL << GPIO_MODER_MODE11_Pos)         /*!< 0x00400000 */
3357 #define GPIO_MODER_MODE11_1            (0x2UL << GPIO_MODER_MODE11_Pos)         /*!< 0x00800000 */
3358 #define GPIO_MODER_MODE12_Pos          (24U)
3359 #define GPIO_MODER_MODE12_Msk          (0x3UL << GPIO_MODER_MODE12_Pos)         /*!< 0x03000000 */
3360 #define GPIO_MODER_MODE12              GPIO_MODER_MODE12_Msk
3361 #define GPIO_MODER_MODE12_0            (0x1UL << GPIO_MODER_MODE12_Pos)         /*!< 0x01000000 */
3362 #define GPIO_MODER_MODE12_1            (0x2UL << GPIO_MODER_MODE12_Pos)         /*!< 0x02000000 */
3363 #define GPIO_MODER_MODE13_Pos          (26U)
3364 #define GPIO_MODER_MODE13_Msk          (0x3UL << GPIO_MODER_MODE13_Pos)         /*!< 0x0C000000 */
3365 #define GPIO_MODER_MODE13              GPIO_MODER_MODE13_Msk
3366 #define GPIO_MODER_MODE13_0            (0x1UL << GPIO_MODER_MODE13_Pos)         /*!< 0x04000000 */
3367 #define GPIO_MODER_MODE13_1            (0x2UL << GPIO_MODER_MODE13_Pos)         /*!< 0x08000000 */
3368 #define GPIO_MODER_MODE14_Pos          (28U)
3369 #define GPIO_MODER_MODE14_Msk          (0x3UL << GPIO_MODER_MODE14_Pos)         /*!< 0x30000000 */
3370 #define GPIO_MODER_MODE14              GPIO_MODER_MODE14_Msk
3371 #define GPIO_MODER_MODE14_0            (0x1UL << GPIO_MODER_MODE14_Pos)         /*!< 0x10000000 */
3372 #define GPIO_MODER_MODE14_1            (0x2UL << GPIO_MODER_MODE14_Pos)         /*!< 0x20000000 */
3373 #define GPIO_MODER_MODE15_Pos          (30U)
3374 #define GPIO_MODER_MODE15_Msk          (0x3UL << GPIO_MODER_MODE15_Pos)         /*!< 0xC0000000 */
3375 #define GPIO_MODER_MODE15              GPIO_MODER_MODE15_Msk
3376 #define GPIO_MODER_MODE15_0            (0x1UL << GPIO_MODER_MODE15_Pos)         /*!< 0x40000000 */
3377 #define GPIO_MODER_MODE15_1            (0x2UL << GPIO_MODER_MODE15_Pos)         /*!< 0x80000000 */
3378 
3379 /******************  Bits definition for GPIO_OTYPER register  ****************/
3380 #define GPIO_OTYPER_OT0_Pos            (0U)
3381 #define GPIO_OTYPER_OT0_Msk            (0x1UL << GPIO_OTYPER_OT0_Pos)           /*!< 0x00000001 */
3382 #define GPIO_OTYPER_OT0                GPIO_OTYPER_OT0_Msk
3383 #define GPIO_OTYPER_OT1_Pos            (1U)
3384 #define GPIO_OTYPER_OT1_Msk            (0x1UL << GPIO_OTYPER_OT1_Pos)           /*!< 0x00000002 */
3385 #define GPIO_OTYPER_OT1                GPIO_OTYPER_OT1_Msk
3386 #define GPIO_OTYPER_OT2_Pos            (2U)
3387 #define GPIO_OTYPER_OT2_Msk            (0x1UL << GPIO_OTYPER_OT2_Pos)           /*!< 0x00000004 */
3388 #define GPIO_OTYPER_OT2                GPIO_OTYPER_OT2_Msk
3389 #define GPIO_OTYPER_OT3_Pos            (3U)
3390 #define GPIO_OTYPER_OT3_Msk            (0x1UL << GPIO_OTYPER_OT3_Pos)           /*!< 0x00000008 */
3391 #define GPIO_OTYPER_OT3                GPIO_OTYPER_OT3_Msk
3392 #define GPIO_OTYPER_OT4_Pos            (4U)
3393 #define GPIO_OTYPER_OT4_Msk            (0x1UL << GPIO_OTYPER_OT4_Pos)           /*!< 0x00000010 */
3394 #define GPIO_OTYPER_OT4                GPIO_OTYPER_OT4_Msk
3395 #define GPIO_OTYPER_OT5_Pos            (5U)
3396 #define GPIO_OTYPER_OT5_Msk            (0x1UL << GPIO_OTYPER_OT5_Pos)           /*!< 0x00000020 */
3397 #define GPIO_OTYPER_OT5                GPIO_OTYPER_OT5_Msk
3398 #define GPIO_OTYPER_OT6_Pos            (6U)
3399 #define GPIO_OTYPER_OT6_Msk            (0x1UL << GPIO_OTYPER_OT6_Pos)           /*!< 0x00000040 */
3400 #define GPIO_OTYPER_OT6                GPIO_OTYPER_OT6_Msk
3401 #define GPIO_OTYPER_OT7_Pos            (7U)
3402 #define GPIO_OTYPER_OT7_Msk            (0x1UL << GPIO_OTYPER_OT7_Pos)           /*!< 0x00000080 */
3403 #define GPIO_OTYPER_OT7                GPIO_OTYPER_OT7_Msk
3404 #define GPIO_OTYPER_OT8_Pos            (8U)
3405 #define GPIO_OTYPER_OT8_Msk            (0x1UL << GPIO_OTYPER_OT8_Pos)           /*!< 0x00000100 */
3406 #define GPIO_OTYPER_OT8                GPIO_OTYPER_OT8_Msk
3407 #define GPIO_OTYPER_OT9_Pos            (9U)
3408 #define GPIO_OTYPER_OT9_Msk            (0x1UL << GPIO_OTYPER_OT9_Pos)           /*!< 0x00000200 */
3409 #define GPIO_OTYPER_OT9                GPIO_OTYPER_OT9_Msk
3410 #define GPIO_OTYPER_OT10_Pos           (10U)
3411 #define GPIO_OTYPER_OT10_Msk           (0x1UL << GPIO_OTYPER_OT10_Pos)          /*!< 0x00000400 */
3412 #define GPIO_OTYPER_OT10               GPIO_OTYPER_OT10_Msk
3413 #define GPIO_OTYPER_OT11_Pos           (11U)
3414 #define GPIO_OTYPER_OT11_Msk           (0x1UL << GPIO_OTYPER_OT11_Pos)          /*!< 0x00000800 */
3415 #define GPIO_OTYPER_OT11               GPIO_OTYPER_OT11_Msk
3416 #define GPIO_OTYPER_OT12_Pos           (12U)
3417 #define GPIO_OTYPER_OT12_Msk           (0x1UL << GPIO_OTYPER_OT12_Pos)          /*!< 0x00001000 */
3418 #define GPIO_OTYPER_OT12               GPIO_OTYPER_OT12_Msk
3419 #define GPIO_OTYPER_OT13_Pos           (13U)
3420 #define GPIO_OTYPER_OT13_Msk           (0x1UL << GPIO_OTYPER_OT13_Pos)          /*!< 0x00002000 */
3421 #define GPIO_OTYPER_OT13               GPIO_OTYPER_OT13_Msk
3422 #define GPIO_OTYPER_OT14_Pos           (14U)
3423 #define GPIO_OTYPER_OT14_Msk           (0x1UL << GPIO_OTYPER_OT14_Pos)          /*!< 0x00004000 */
3424 #define GPIO_OTYPER_OT14               GPIO_OTYPER_OT14_Msk
3425 #define GPIO_OTYPER_OT15_Pos           (15U)
3426 #define GPIO_OTYPER_OT15_Msk           (0x1UL << GPIO_OTYPER_OT15_Pos)          /*!< 0x00008000 */
3427 #define GPIO_OTYPER_OT15               GPIO_OTYPER_OT15_Msk
3428 
3429 /******************  Bits definition for GPIO_OSPEEDR register  ***************/
3430 #define GPIO_OSPEEDR_OSPEED0_Pos       (0U)
3431 #define GPIO_OSPEEDR_OSPEED0_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED0_Pos)      /*!< 0x00000003 */
3432 #define GPIO_OSPEEDR_OSPEED0           GPIO_OSPEEDR_OSPEED0_Msk
3433 #define GPIO_OSPEEDR_OSPEED0_0         (0x1UL << GPIO_OSPEEDR_OSPEED0_Pos)      /*!< 0x00000001 */
3434 #define GPIO_OSPEEDR_OSPEED0_1         (0x2UL << GPIO_OSPEEDR_OSPEED0_Pos)      /*!< 0x00000002 */
3435 #define GPIO_OSPEEDR_OSPEED1_Pos       (2U)
3436 #define GPIO_OSPEEDR_OSPEED1_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED1_Pos)      /*!< 0x0000000C */
3437 #define GPIO_OSPEEDR_OSPEED1           GPIO_OSPEEDR_OSPEED1_Msk
3438 #define GPIO_OSPEEDR_OSPEED1_0         (0x1UL << GPIO_OSPEEDR_OSPEED1_Pos)      /*!< 0x00000004 */
3439 #define GPIO_OSPEEDR_OSPEED1_1         (0x2UL << GPIO_OSPEEDR_OSPEED1_Pos)      /*!< 0x00000008 */
3440 #define GPIO_OSPEEDR_OSPEED2_Pos       (4U)
3441 #define GPIO_OSPEEDR_OSPEED2_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED2_Pos)      /*!< 0x00000030 */
3442 #define GPIO_OSPEEDR_OSPEED2           GPIO_OSPEEDR_OSPEED2_Msk
3443 #define GPIO_OSPEEDR_OSPEED2_0         (0x1UL << GPIO_OSPEEDR_OSPEED2_Pos)      /*!< 0x00000010 */
3444 #define GPIO_OSPEEDR_OSPEED2_1         (0x2UL << GPIO_OSPEEDR_OSPEED2_Pos)      /*!< 0x00000020 */
3445 #define GPIO_OSPEEDR_OSPEED3_Pos       (6U)
3446 #define GPIO_OSPEEDR_OSPEED3_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED3_Pos)      /*!< 0x000000C0 */
3447 #define GPIO_OSPEEDR_OSPEED3           GPIO_OSPEEDR_OSPEED3_Msk
3448 #define GPIO_OSPEEDR_OSPEED3_0         (0x1UL << GPIO_OSPEEDR_OSPEED3_Pos)      /*!< 0x00000040 */
3449 #define GPIO_OSPEEDR_OSPEED3_1         (0x2UL << GPIO_OSPEEDR_OSPEED3_Pos)      /*!< 0x00000080 */
3450 #define GPIO_OSPEEDR_OSPEED4_Pos       (8U)
3451 #define GPIO_OSPEEDR_OSPEED4_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED4_Pos)      /*!< 0x00000300 */
3452 #define GPIO_OSPEEDR_OSPEED4           GPIO_OSPEEDR_OSPEED4_Msk
3453 #define GPIO_OSPEEDR_OSPEED4_0         (0x1UL << GPIO_OSPEEDR_OSPEED4_Pos)      /*!< 0x00000100 */
3454 #define GPIO_OSPEEDR_OSPEED4_1         (0x2UL << GPIO_OSPEEDR_OSPEED4_Pos)      /*!< 0x00000200 */
3455 #define GPIO_OSPEEDR_OSPEED5_Pos       (10U)
3456 #define GPIO_OSPEEDR_OSPEED5_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED5_Pos)      /*!< 0x00000C00 */
3457 #define GPIO_OSPEEDR_OSPEED5           GPIO_OSPEEDR_OSPEED5_Msk
3458 #define GPIO_OSPEEDR_OSPEED5_0         (0x1UL << GPIO_OSPEEDR_OSPEED5_Pos)      /*!< 0x00000400 */
3459 #define GPIO_OSPEEDR_OSPEED5_1         (0x2UL << GPIO_OSPEEDR_OSPEED5_Pos)      /*!< 0x00000800 */
3460 #define GPIO_OSPEEDR_OSPEED6_Pos       (12U)
3461 #define GPIO_OSPEEDR_OSPEED6_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED6_Pos)      /*!< 0x00003000 */
3462 #define GPIO_OSPEEDR_OSPEED6           GPIO_OSPEEDR_OSPEED6_Msk
3463 #define GPIO_OSPEEDR_OSPEED6_0         (0x1UL << GPIO_OSPEEDR_OSPEED6_Pos)      /*!< 0x00001000 */
3464 #define GPIO_OSPEEDR_OSPEED6_1         (0x2UL << GPIO_OSPEEDR_OSPEED6_Pos)      /*!< 0x00002000 */
3465 #define GPIO_OSPEEDR_OSPEED7_Pos       (14U)
3466 #define GPIO_OSPEEDR_OSPEED7_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED7_Pos)      /*!< 0x0000C000 */
3467 #define GPIO_OSPEEDR_OSPEED7           GPIO_OSPEEDR_OSPEED7_Msk
3468 #define GPIO_OSPEEDR_OSPEED7_0         (0x1UL << GPIO_OSPEEDR_OSPEED7_Pos)      /*!< 0x00004000 */
3469 #define GPIO_OSPEEDR_OSPEED7_1         (0x2UL << GPIO_OSPEEDR_OSPEED7_Pos)      /*!< 0x00008000 */
3470 #define GPIO_OSPEEDR_OSPEED8_Pos       (16U)
3471 #define GPIO_OSPEEDR_OSPEED8_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED8_Pos)      /*!< 0x00030000 */
3472 #define GPIO_OSPEEDR_OSPEED8           GPIO_OSPEEDR_OSPEED8_Msk
3473 #define GPIO_OSPEEDR_OSPEED8_0         (0x1UL << GPIO_OSPEEDR_OSPEED8_Pos)      /*!< 0x00010000 */
3474 #define GPIO_OSPEEDR_OSPEED8_1         (0x2UL << GPIO_OSPEEDR_OSPEED8_Pos)      /*!< 0x00020000 */
3475 #define GPIO_OSPEEDR_OSPEED9_Pos       (18U)
3476 #define GPIO_OSPEEDR_OSPEED9_Msk       (0x3UL << GPIO_OSPEEDR_OSPEED9_Pos)      /*!< 0x000C0000 */
3477 #define GPIO_OSPEEDR_OSPEED9           GPIO_OSPEEDR_OSPEED9_Msk
3478 #define GPIO_OSPEEDR_OSPEED9_0         (0x1UL << GPIO_OSPEEDR_OSPEED9_Pos)      /*!< 0x00040000 */
3479 #define GPIO_OSPEEDR_OSPEED9_1         (0x2UL << GPIO_OSPEEDR_OSPEED9_Pos)      /*!< 0x00080000 */
3480 #define GPIO_OSPEEDR_OSPEED10_Pos      (20U)
3481 #define GPIO_OSPEEDR_OSPEED10_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED10_Pos)     /*!< 0x00300000 */
3482 #define GPIO_OSPEEDR_OSPEED10          GPIO_OSPEEDR_OSPEED10_Msk
3483 #define GPIO_OSPEEDR_OSPEED10_0        (0x1UL << GPIO_OSPEEDR_OSPEED10_Pos)     /*!< 0x00100000 */
3484 #define GPIO_OSPEEDR_OSPEED10_1        (0x2UL << GPIO_OSPEEDR_OSPEED10_Pos)     /*!< 0x00200000 */
3485 #define GPIO_OSPEEDR_OSPEED11_Pos      (22U)
3486 #define GPIO_OSPEEDR_OSPEED11_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED11_Pos)     /*!< 0x00C00000 */
3487 #define GPIO_OSPEEDR_OSPEED11          GPIO_OSPEEDR_OSPEED11_Msk
3488 #define GPIO_OSPEEDR_OSPEED11_0        (0x1UL << GPIO_OSPEEDR_OSPEED11_Pos)     /*!< 0x00400000 */
3489 #define GPIO_OSPEEDR_OSPEED11_1        (0x2UL << GPIO_OSPEEDR_OSPEED11_Pos)     /*!< 0x00800000 */
3490 #define GPIO_OSPEEDR_OSPEED12_Pos      (24U)
3491 #define GPIO_OSPEEDR_OSPEED12_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED12_Pos)     /*!< 0x03000000 */
3492 #define GPIO_OSPEEDR_OSPEED12          GPIO_OSPEEDR_OSPEED12_Msk
3493 #define GPIO_OSPEEDR_OSPEED12_0        (0x1UL << GPIO_OSPEEDR_OSPEED12_Pos)     /*!< 0x01000000 */
3494 #define GPIO_OSPEEDR_OSPEED12_1        (0x2UL << GPIO_OSPEEDR_OSPEED12_Pos)     /*!< 0x02000000 */
3495 #define GPIO_OSPEEDR_OSPEED13_Pos      (26U)
3496 #define GPIO_OSPEEDR_OSPEED13_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED13_Pos)     /*!< 0x0C000000 */
3497 #define GPIO_OSPEEDR_OSPEED13          GPIO_OSPEEDR_OSPEED13_Msk
3498 #define GPIO_OSPEEDR_OSPEED13_0        (0x1UL << GPIO_OSPEEDR_OSPEED13_Pos)     /*!< 0x04000000 */
3499 #define GPIO_OSPEEDR_OSPEED13_1        (0x2UL << GPIO_OSPEEDR_OSPEED13_Pos)     /*!< 0x08000000 */
3500 #define GPIO_OSPEEDR_OSPEED14_Pos      (28U)
3501 #define GPIO_OSPEEDR_OSPEED14_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED14_Pos)     /*!< 0x30000000 */
3502 #define GPIO_OSPEEDR_OSPEED14          GPIO_OSPEEDR_OSPEED14_Msk
3503 #define GPIO_OSPEEDR_OSPEED14_0        (0x1UL << GPIO_OSPEEDR_OSPEED14_Pos)     /*!< 0x10000000 */
3504 #define GPIO_OSPEEDR_OSPEED14_1        (0x2UL << GPIO_OSPEEDR_OSPEED14_Pos)     /*!< 0x20000000 */
3505 #define GPIO_OSPEEDR_OSPEED15_Pos      (30U)
3506 #define GPIO_OSPEEDR_OSPEED15_Msk      (0x3UL << GPIO_OSPEEDR_OSPEED15_Pos)     /*!< 0xC0000000 */
3507 #define GPIO_OSPEEDR_OSPEED15          GPIO_OSPEEDR_OSPEED15_Msk
3508 #define GPIO_OSPEEDR_OSPEED15_0        (0x1UL << GPIO_OSPEEDR_OSPEED15_Pos)     /*!< 0x40000000 */
3509 #define GPIO_OSPEEDR_OSPEED15_1        (0x2UL << GPIO_OSPEEDR_OSPEED15_Pos)     /*!< 0x80000000 */
3510 
3511 /******************  Bits definition for GPIO_PUPDR register  *****************/
3512 #define GPIO_PUPDR_PUPD0_Pos           (0U)
3513 #define GPIO_PUPDR_PUPD0_Msk           (0x3UL << GPIO_PUPDR_PUPD0_Pos)          /*!< 0x00000003 */
3514 #define GPIO_PUPDR_PUPD0               GPIO_PUPDR_PUPD0_Msk
3515 #define GPIO_PUPDR_PUPD0_0             (0x1UL << GPIO_PUPDR_PUPD0_Pos)          /*!< 0x00000001 */
3516 #define GPIO_PUPDR_PUPD0_1             (0x2UL << GPIO_PUPDR_PUPD0_Pos)          /*!< 0x00000002 */
3517 #define GPIO_PUPDR_PUPD1_Pos           (2U)
3518 #define GPIO_PUPDR_PUPD1_Msk           (0x3UL << GPIO_PUPDR_PUPD1_Pos)          /*!< 0x0000000C */
3519 #define GPIO_PUPDR_PUPD1               GPIO_PUPDR_PUPD1_Msk
3520 #define GPIO_PUPDR_PUPD1_0             (0x1UL << GPIO_PUPDR_PUPD1_Pos)          /*!< 0x00000004 */
3521 #define GPIO_PUPDR_PUPD1_1             (0x2UL << GPIO_PUPDR_PUPD1_Pos)          /*!< 0x00000008 */
3522 #define GPIO_PUPDR_PUPD2_Pos           (4U)
3523 #define GPIO_PUPDR_PUPD2_Msk           (0x3UL << GPIO_PUPDR_PUPD2_Pos)          /*!< 0x00000030 */
3524 #define GPIO_PUPDR_PUPD2               GPIO_PUPDR_PUPD2_Msk
3525 #define GPIO_PUPDR_PUPD2_0             (0x1UL << GPIO_PUPDR_PUPD2_Pos)          /*!< 0x00000010 */
3526 #define GPIO_PUPDR_PUPD2_1             (0x2UL << GPIO_PUPDR_PUPD2_Pos)          /*!< 0x00000020 */
3527 #define GPIO_PUPDR_PUPD3_Pos           (6U)
3528 #define GPIO_PUPDR_PUPD3_Msk           (0x3UL << GPIO_PUPDR_PUPD3_Pos)          /*!< 0x000000C0 */
3529 #define GPIO_PUPDR_PUPD3               GPIO_PUPDR_PUPD3_Msk
3530 #define GPIO_PUPDR_PUPD3_0             (0x1UL << GPIO_PUPDR_PUPD3_Pos)          /*!< 0x00000040 */
3531 #define GPIO_PUPDR_PUPD3_1             (0x2UL << GPIO_PUPDR_PUPD3_Pos)          /*!< 0x00000080 */
3532 #define GPIO_PUPDR_PUPD4_Pos           (8U)
3533 #define GPIO_PUPDR_PUPD4_Msk           (0x3UL << GPIO_PUPDR_PUPD4_Pos)          /*!< 0x00000300 */
3534 #define GPIO_PUPDR_PUPD4               GPIO_PUPDR_PUPD4_Msk
3535 #define GPIO_PUPDR_PUPD4_0             (0x1UL << GPIO_PUPDR_PUPD4_Pos)          /*!< 0x00000100 */
3536 #define GPIO_PUPDR_PUPD4_1             (0x2UL << GPIO_PUPDR_PUPD4_Pos)          /*!< 0x00000200 */
3537 #define GPIO_PUPDR_PUPD5_Pos           (10U)
3538 #define GPIO_PUPDR_PUPD5_Msk           (0x3UL << GPIO_PUPDR_PUPD5_Pos)          /*!< 0x00000C00 */
3539 #define GPIO_PUPDR_PUPD5               GPIO_PUPDR_PUPD5_Msk
3540 #define GPIO_PUPDR_PUPD5_0             (0x1UL << GPIO_PUPDR_PUPD5_Pos)          /*!< 0x00000400 */
3541 #define GPIO_PUPDR_PUPD5_1             (0x2UL << GPIO_PUPDR_PUPD5_Pos)          /*!< 0x00000800 */
3542 #define GPIO_PUPDR_PUPD6_Pos           (12U)
3543 #define GPIO_PUPDR_PUPD6_Msk           (0x3UL << GPIO_PUPDR_PUPD6_Pos)          /*!< 0x00003000 */
3544 #define GPIO_PUPDR_PUPD6               GPIO_PUPDR_PUPD6_Msk
3545 #define GPIO_PUPDR_PUPD6_0             (0x1UL << GPIO_PUPDR_PUPD6_Pos)          /*!< 0x00001000 */
3546 #define GPIO_PUPDR_PUPD6_1             (0x2UL << GPIO_PUPDR_PUPD6_Pos)          /*!< 0x00002000 */
3547 #define GPIO_PUPDR_PUPD7_Pos           (14U)
3548 #define GPIO_PUPDR_PUPD7_Msk           (0x3UL << GPIO_PUPDR_PUPD7_Pos)          /*!< 0x0000C000 */
3549 #define GPIO_PUPDR_PUPD7               GPIO_PUPDR_PUPD7_Msk
3550 #define GPIO_PUPDR_PUPD7_0             (0x1UL << GPIO_PUPDR_PUPD7_Pos)          /*!< 0x00004000 */
3551 #define GPIO_PUPDR_PUPD7_1             (0x2UL << GPIO_PUPDR_PUPD7_Pos)          /*!< 0x00008000 */
3552 #define GPIO_PUPDR_PUPD8_Pos           (16U)
3553 #define GPIO_PUPDR_PUPD8_Msk           (0x3UL << GPIO_PUPDR_PUPD8_Pos)          /*!< 0x00030000 */
3554 #define GPIO_PUPDR_PUPD8               GPIO_PUPDR_PUPD8_Msk
3555 #define GPIO_PUPDR_PUPD8_0             (0x1UL << GPIO_PUPDR_PUPD8_Pos)          /*!< 0x00010000 */
3556 #define GPIO_PUPDR_PUPD8_1             (0x2UL << GPIO_PUPDR_PUPD8_Pos)          /*!< 0x00020000 */
3557 #define GPIO_PUPDR_PUPD9_Pos           (18U)
3558 #define GPIO_PUPDR_PUPD9_Msk           (0x3UL << GPIO_PUPDR_PUPD9_Pos)          /*!< 0x000C0000 */
3559 #define GPIO_PUPDR_PUPD9               GPIO_PUPDR_PUPD9_Msk
3560 #define GPIO_PUPDR_PUPD9_0             (0x1UL << GPIO_PUPDR_PUPD9_Pos)          /*!< 0x00040000 */
3561 #define GPIO_PUPDR_PUPD9_1             (0x2UL << GPIO_PUPDR_PUPD9_Pos)          /*!< 0x00080000 */
3562 #define GPIO_PUPDR_PUPD10_Pos          (20U)
3563 #define GPIO_PUPDR_PUPD10_Msk          (0x3UL << GPIO_PUPDR_PUPD10_Pos)         /*!< 0x00300000 */
3564 #define GPIO_PUPDR_PUPD10              GPIO_PUPDR_PUPD10_Msk
3565 #define GPIO_PUPDR_PUPD10_0            (0x1UL << GPIO_PUPDR_PUPD10_Pos)         /*!< 0x00100000 */
3566 #define GPIO_PUPDR_PUPD10_1            (0x2UL << GPIO_PUPDR_PUPD10_Pos)         /*!< 0x00200000 */
3567 #define GPIO_PUPDR_PUPD11_Pos          (22U)
3568 #define GPIO_PUPDR_PUPD11_Msk          (0x3UL << GPIO_PUPDR_PUPD11_Pos)         /*!< 0x00C00000 */
3569 #define GPIO_PUPDR_PUPD11              GPIO_PUPDR_PUPD11_Msk
3570 #define GPIO_PUPDR_PUPD11_0            (0x1UL << GPIO_PUPDR_PUPD11_Pos)         /*!< 0x00400000 */
3571 #define GPIO_PUPDR_PUPD11_1            (0x2UL << GPIO_PUPDR_PUPD11_Pos)         /*!< 0x00800000 */
3572 #define GPIO_PUPDR_PUPD12_Pos          (24U)
3573 #define GPIO_PUPDR_PUPD12_Msk          (0x3UL << GPIO_PUPDR_PUPD12_Pos)         /*!< 0x03000000 */
3574 #define GPIO_PUPDR_PUPD12              GPIO_PUPDR_PUPD12_Msk
3575 #define GPIO_PUPDR_PUPD12_0            (0x1UL << GPIO_PUPDR_PUPD12_Pos)         /*!< 0x01000000 */
3576 #define GPIO_PUPDR_PUPD12_1            (0x2UL << GPIO_PUPDR_PUPD12_Pos)         /*!< 0x02000000 */
3577 #define GPIO_PUPDR_PUPD13_Pos          (26U)
3578 #define GPIO_PUPDR_PUPD13_Msk          (0x3UL << GPIO_PUPDR_PUPD13_Pos)         /*!< 0x0C000000 */
3579 #define GPIO_PUPDR_PUPD13              GPIO_PUPDR_PUPD13_Msk
3580 #define GPIO_PUPDR_PUPD13_0            (0x1UL << GPIO_PUPDR_PUPD13_Pos)         /*!< 0x04000000 */
3581 #define GPIO_PUPDR_PUPD13_1            (0x2UL << GPIO_PUPDR_PUPD13_Pos)         /*!< 0x08000000 */
3582 #define GPIO_PUPDR_PUPD14_Pos          (28U)
3583 #define GPIO_PUPDR_PUPD14_Msk          (0x3UL << GPIO_PUPDR_PUPD14_Pos)         /*!< 0x30000000 */
3584 #define GPIO_PUPDR_PUPD14              GPIO_PUPDR_PUPD14_Msk
3585 #define GPIO_PUPDR_PUPD14_0            (0x1UL << GPIO_PUPDR_PUPD14_Pos)         /*!< 0x10000000 */
3586 #define GPIO_PUPDR_PUPD14_1            (0x2UL << GPIO_PUPDR_PUPD14_Pos)         /*!< 0x20000000 */
3587 #define GPIO_PUPDR_PUPD15_Pos          (30U)
3588 #define GPIO_PUPDR_PUPD15_Msk          (0x3UL << GPIO_PUPDR_PUPD15_Pos)         /*!< 0xC0000000 */
3589 #define GPIO_PUPDR_PUPD15              GPIO_PUPDR_PUPD15_Msk
3590 #define GPIO_PUPDR_PUPD15_0            (0x1UL << GPIO_PUPDR_PUPD15_Pos)         /*!< 0x40000000 */
3591 #define GPIO_PUPDR_PUPD15_1            (0x2UL << GPIO_PUPDR_PUPD15_Pos)         /*!< 0x80000000 */
3592 
3593 /******************  Bits definition for GPIO_IDR register  *******************/
3594 #define GPIO_IDR_ID0_Pos               (0U)
3595 #define GPIO_IDR_ID0_Msk               (0x1UL << GPIO_IDR_ID0_Pos)              /*!< 0x00000001 */
3596 #define GPIO_IDR_ID0                   GPIO_IDR_ID0_Msk
3597 #define GPIO_IDR_ID1_Pos               (1U)
3598 #define GPIO_IDR_ID1_Msk               (0x1UL << GPIO_IDR_ID1_Pos)              /*!< 0x00000002 */
3599 #define GPIO_IDR_ID1                   GPIO_IDR_ID1_Msk
3600 #define GPIO_IDR_ID2_Pos               (2U)
3601 #define GPIO_IDR_ID2_Msk               (0x1UL << GPIO_IDR_ID2_Pos)              /*!< 0x00000004 */
3602 #define GPIO_IDR_ID2                   GPIO_IDR_ID2_Msk
3603 #define GPIO_IDR_ID3_Pos               (3U)
3604 #define GPIO_IDR_ID3_Msk               (0x1UL << GPIO_IDR_ID3_Pos)              /*!< 0x00000008 */
3605 #define GPIO_IDR_ID3                   GPIO_IDR_ID3_Msk
3606 #define GPIO_IDR_ID4_Pos               (4U)
3607 #define GPIO_IDR_ID4_Msk               (0x1UL << GPIO_IDR_ID4_Pos)              /*!< 0x00000010 */
3608 #define GPIO_IDR_ID4                   GPIO_IDR_ID4_Msk
3609 #define GPIO_IDR_ID5_Pos               (5U)
3610 #define GPIO_IDR_ID5_Msk               (0x1UL << GPIO_IDR_ID5_Pos)              /*!< 0x00000020 */
3611 #define GPIO_IDR_ID5                   GPIO_IDR_ID5_Msk
3612 #define GPIO_IDR_ID6_Pos               (6U)
3613 #define GPIO_IDR_ID6_Msk               (0x1UL << GPIO_IDR_ID6_Pos)              /*!< 0x00000040 */
3614 #define GPIO_IDR_ID6                   GPIO_IDR_ID6_Msk
3615 #define GPIO_IDR_ID7_Pos               (7U)
3616 #define GPIO_IDR_ID7_Msk               (0x1UL << GPIO_IDR_ID7_Pos)              /*!< 0x00000080 */
3617 #define GPIO_IDR_ID7                   GPIO_IDR_ID7_Msk
3618 #define GPIO_IDR_ID8_Pos               (8U)
3619 #define GPIO_IDR_ID8_Msk               (0x1UL << GPIO_IDR_ID8_Pos)              /*!< 0x00000100 */
3620 #define GPIO_IDR_ID8                   GPIO_IDR_ID8_Msk
3621 #define GPIO_IDR_ID9_Pos               (9U)
3622 #define GPIO_IDR_ID9_Msk               (0x1UL << GPIO_IDR_ID9_Pos)              /*!< 0x00000200 */
3623 #define GPIO_IDR_ID9                   GPIO_IDR_ID9_Msk
3624 #define GPIO_IDR_ID10_Pos              (10U)
3625 #define GPIO_IDR_ID10_Msk              (0x1UL << GPIO_IDR_ID10_Pos)             /*!< 0x00000400 */
3626 #define GPIO_IDR_ID10                  GPIO_IDR_ID10_Msk
3627 #define GPIO_IDR_ID11_Pos              (11U)
3628 #define GPIO_IDR_ID11_Msk              (0x1UL << GPIO_IDR_ID11_Pos)             /*!< 0x00000800 */
3629 #define GPIO_IDR_ID11                  GPIO_IDR_ID11_Msk
3630 #define GPIO_IDR_ID12_Pos              (12U)
3631 #define GPIO_IDR_ID12_Msk              (0x1UL << GPIO_IDR_ID12_Pos)             /*!< 0x00001000 */
3632 #define GPIO_IDR_ID12                  GPIO_IDR_ID12_Msk
3633 #define GPIO_IDR_ID13_Pos              (13U)
3634 #define GPIO_IDR_ID13_Msk              (0x1UL << GPIO_IDR_ID13_Pos)             /*!< 0x00002000 */
3635 #define GPIO_IDR_ID13                  GPIO_IDR_ID13_Msk
3636 #define GPIO_IDR_ID14_Pos              (14U)
3637 #define GPIO_IDR_ID14_Msk              (0x1UL << GPIO_IDR_ID14_Pos)             /*!< 0x00004000 */
3638 #define GPIO_IDR_ID14                  GPIO_IDR_ID14_Msk
3639 #define GPIO_IDR_ID15_Pos              (15U)
3640 #define GPIO_IDR_ID15_Msk              (0x1UL << GPIO_IDR_ID15_Pos)             /*!< 0x00008000 */
3641 #define GPIO_IDR_ID15                  GPIO_IDR_ID15_Msk
3642 
3643 /******************  Bits definition for GPIO_ODR register  *******************/
3644 #define GPIO_ODR_OD0_Pos               (0U)
3645 #define GPIO_ODR_OD0_Msk               (0x1UL << GPIO_ODR_OD0_Pos)              /*!< 0x00000001 */
3646 #define GPIO_ODR_OD0                   GPIO_ODR_OD0_Msk
3647 #define GPIO_ODR_OD1_Pos               (1U)
3648 #define GPIO_ODR_OD1_Msk               (0x1UL << GPIO_ODR_OD1_Pos)              /*!< 0x00000002 */
3649 #define GPIO_ODR_OD1                   GPIO_ODR_OD1_Msk
3650 #define GPIO_ODR_OD2_Pos               (2U)
3651 #define GPIO_ODR_OD2_Msk               (0x1UL << GPIO_ODR_OD2_Pos)              /*!< 0x00000004 */
3652 #define GPIO_ODR_OD2                   GPIO_ODR_OD2_Msk
3653 #define GPIO_ODR_OD3_Pos               (3U)
3654 #define GPIO_ODR_OD3_Msk               (0x1UL << GPIO_ODR_OD3_Pos)              /*!< 0x00000008 */
3655 #define GPIO_ODR_OD3                   GPIO_ODR_OD3_Msk
3656 #define GPIO_ODR_OD4_Pos               (4U)
3657 #define GPIO_ODR_OD4_Msk               (0x1UL << GPIO_ODR_OD4_Pos)              /*!< 0x00000010 */
3658 #define GPIO_ODR_OD4                   GPIO_ODR_OD4_Msk
3659 #define GPIO_ODR_OD5_Pos               (5U)
3660 #define GPIO_ODR_OD5_Msk               (0x1UL << GPIO_ODR_OD5_Pos)              /*!< 0x00000020 */
3661 #define GPIO_ODR_OD5                   GPIO_ODR_OD5_Msk
3662 #define GPIO_ODR_OD6_Pos               (6U)
3663 #define GPIO_ODR_OD6_Msk               (0x1UL << GPIO_ODR_OD6_Pos)              /*!< 0x00000040 */
3664 #define GPIO_ODR_OD6                   GPIO_ODR_OD6_Msk
3665 #define GPIO_ODR_OD7_Pos               (7U)
3666 #define GPIO_ODR_OD7_Msk               (0x1UL << GPIO_ODR_OD7_Pos)              /*!< 0x00000080 */
3667 #define GPIO_ODR_OD7                   GPIO_ODR_OD7_Msk
3668 #define GPIO_ODR_OD8_Pos               (8U)
3669 #define GPIO_ODR_OD8_Msk               (0x1UL << GPIO_ODR_OD8_Pos)              /*!< 0x00000100 */
3670 #define GPIO_ODR_OD8                   GPIO_ODR_OD8_Msk
3671 #define GPIO_ODR_OD9_Pos               (9U)
3672 #define GPIO_ODR_OD9_Msk               (0x1UL << GPIO_ODR_OD9_Pos)              /*!< 0x00000200 */
3673 #define GPIO_ODR_OD9                   GPIO_ODR_OD9_Msk
3674 #define GPIO_ODR_OD10_Pos              (10U)
3675 #define GPIO_ODR_OD10_Msk              (0x1UL << GPIO_ODR_OD10_Pos)             /*!< 0x00000400 */
3676 #define GPIO_ODR_OD10                  GPIO_ODR_OD10_Msk
3677 #define GPIO_ODR_OD11_Pos              (11U)
3678 #define GPIO_ODR_OD11_Msk              (0x1UL << GPIO_ODR_OD11_Pos)             /*!< 0x00000800 */
3679 #define GPIO_ODR_OD11                  GPIO_ODR_OD11_Msk
3680 #define GPIO_ODR_OD12_Pos              (12U)
3681 #define GPIO_ODR_OD12_Msk              (0x1UL << GPIO_ODR_OD12_Pos)             /*!< 0x00001000 */
3682 #define GPIO_ODR_OD12                  GPIO_ODR_OD12_Msk
3683 #define GPIO_ODR_OD13_Pos              (13U)
3684 #define GPIO_ODR_OD13_Msk              (0x1UL << GPIO_ODR_OD13_Pos)             /*!< 0x00002000 */
3685 #define GPIO_ODR_OD13                  GPIO_ODR_OD13_Msk
3686 #define GPIO_ODR_OD14_Pos              (14U)
3687 #define GPIO_ODR_OD14_Msk              (0x1UL << GPIO_ODR_OD14_Pos)             /*!< 0x00004000 */
3688 #define GPIO_ODR_OD14                  GPIO_ODR_OD14_Msk
3689 #define GPIO_ODR_OD15_Pos              (15U)
3690 #define GPIO_ODR_OD15_Msk              (0x1UL << GPIO_ODR_OD15_Pos)             /*!< 0x00008000 */
3691 #define GPIO_ODR_OD15                  GPIO_ODR_OD15_Msk
3692 
3693 /******************  Bits definition for GPIO_BSRR register  ******************/
3694 #define GPIO_BSRR_BS0_Pos              (0U)
3695 #define GPIO_BSRR_BS0_Msk              (0x1UL << GPIO_BSRR_BS0_Pos)             /*!< 0x00000001 */
3696 #define GPIO_BSRR_BS0                  GPIO_BSRR_BS0_Msk
3697 #define GPIO_BSRR_BS1_Pos              (1U)
3698 #define GPIO_BSRR_BS1_Msk              (0x1UL << GPIO_BSRR_BS1_Pos)             /*!< 0x00000002 */
3699 #define GPIO_BSRR_BS1                  GPIO_BSRR_BS1_Msk
3700 #define GPIO_BSRR_BS2_Pos              (2U)
3701 #define GPIO_BSRR_BS2_Msk              (0x1UL << GPIO_BSRR_BS2_Pos)             /*!< 0x00000004 */
3702 #define GPIO_BSRR_BS2                  GPIO_BSRR_BS2_Msk
3703 #define GPIO_BSRR_BS3_Pos              (3U)
3704 #define GPIO_BSRR_BS3_Msk              (0x1UL << GPIO_BSRR_BS3_Pos)             /*!< 0x00000008 */
3705 #define GPIO_BSRR_BS3                  GPIO_BSRR_BS3_Msk
3706 #define GPIO_BSRR_BS4_Pos              (4U)
3707 #define GPIO_BSRR_BS4_Msk              (0x1UL << GPIO_BSRR_BS4_Pos)             /*!< 0x00000010 */
3708 #define GPIO_BSRR_BS4                  GPIO_BSRR_BS4_Msk
3709 #define GPIO_BSRR_BS5_Pos              (5U)
3710 #define GPIO_BSRR_BS5_Msk              (0x1UL << GPIO_BSRR_BS5_Pos)             /*!< 0x00000020 */
3711 #define GPIO_BSRR_BS5                  GPIO_BSRR_BS5_Msk
3712 #define GPIO_BSRR_BS6_Pos              (6U)
3713 #define GPIO_BSRR_BS6_Msk              (0x1UL << GPIO_BSRR_BS6_Pos)             /*!< 0x00000040 */
3714 #define GPIO_BSRR_BS6                  GPIO_BSRR_BS6_Msk
3715 #define GPIO_BSRR_BS7_Pos              (7U)
3716 #define GPIO_BSRR_BS7_Msk              (0x1UL << GPIO_BSRR_BS7_Pos)             /*!< 0x00000080 */
3717 #define GPIO_BSRR_BS7                  GPIO_BSRR_BS7_Msk
3718 #define GPIO_BSRR_BS8_Pos              (8U)
3719 #define GPIO_BSRR_BS8_Msk              (0x1UL << GPIO_BSRR_BS8_Pos)             /*!< 0x00000100 */
3720 #define GPIO_BSRR_BS8                  GPIO_BSRR_BS8_Msk
3721 #define GPIO_BSRR_BS9_Pos              (9U)
3722 #define GPIO_BSRR_BS9_Msk              (0x1UL << GPIO_BSRR_BS9_Pos)             /*!< 0x00000200 */
3723 #define GPIO_BSRR_BS9                  GPIO_BSRR_BS9_Msk
3724 #define GPIO_BSRR_BS10_Pos             (10U)
3725 #define GPIO_BSRR_BS10_Msk             (0x1UL << GPIO_BSRR_BS10_Pos)            /*!< 0x00000400 */
3726 #define GPIO_BSRR_BS10                 GPIO_BSRR_BS10_Msk
3727 #define GPIO_BSRR_BS11_Pos             (11U)
3728 #define GPIO_BSRR_BS11_Msk             (0x1UL << GPIO_BSRR_BS11_Pos)            /*!< 0x00000800 */
3729 #define GPIO_BSRR_BS11                 GPIO_BSRR_BS11_Msk
3730 #define GPIO_BSRR_BS12_Pos             (12U)
3731 #define GPIO_BSRR_BS12_Msk             (0x1UL << GPIO_BSRR_BS12_Pos)            /*!< 0x00001000 */
3732 #define GPIO_BSRR_BS12                 GPIO_BSRR_BS12_Msk
3733 #define GPIO_BSRR_BS13_Pos             (13U)
3734 #define GPIO_BSRR_BS13_Msk             (0x1UL << GPIO_BSRR_BS13_Pos)            /*!< 0x00002000 */
3735 #define GPIO_BSRR_BS13                 GPIO_BSRR_BS13_Msk
3736 #define GPIO_BSRR_BS14_Pos             (14U)
3737 #define GPIO_BSRR_BS14_Msk             (0x1UL << GPIO_BSRR_BS14_Pos)            /*!< 0x00004000 */
3738 #define GPIO_BSRR_BS14                 GPIO_BSRR_BS14_Msk
3739 #define GPIO_BSRR_BS15_Pos             (15U)
3740 #define GPIO_BSRR_BS15_Msk             (0x1UL << GPIO_BSRR_BS15_Pos)            /*!< 0x00008000 */
3741 #define GPIO_BSRR_BS15                 GPIO_BSRR_BS15_Msk
3742 #define GPIO_BSRR_BR0_Pos              (16U)
3743 #define GPIO_BSRR_BR0_Msk              (0x1UL << GPIO_BSRR_BR0_Pos)             /*!< 0x00010000 */
3744 #define GPIO_BSRR_BR0                  GPIO_BSRR_BR0_Msk
3745 #define GPIO_BSRR_BR1_Pos              (17U)
3746 #define GPIO_BSRR_BR1_Msk              (0x1UL << GPIO_BSRR_BR1_Pos)             /*!< 0x00020000 */
3747 #define GPIO_BSRR_BR1                  GPIO_BSRR_BR1_Msk
3748 #define GPIO_BSRR_BR2_Pos              (18U)
3749 #define GPIO_BSRR_BR2_Msk              (0x1UL << GPIO_BSRR_BR2_Pos)             /*!< 0x00040000 */
3750 #define GPIO_BSRR_BR2                  GPIO_BSRR_BR2_Msk
3751 #define GPIO_BSRR_BR3_Pos              (19U)
3752 #define GPIO_BSRR_BR3_Msk              (0x1UL << GPIO_BSRR_BR3_Pos)             /*!< 0x00080000 */
3753 #define GPIO_BSRR_BR3                  GPIO_BSRR_BR3_Msk
3754 #define GPIO_BSRR_BR4_Pos              (20U)
3755 #define GPIO_BSRR_BR4_Msk              (0x1UL << GPIO_BSRR_BR4_Pos)             /*!< 0x00100000 */
3756 #define GPIO_BSRR_BR4                  GPIO_BSRR_BR4_Msk
3757 #define GPIO_BSRR_BR5_Pos              (21U)
3758 #define GPIO_BSRR_BR5_Msk              (0x1UL << GPIO_BSRR_BR5_Pos)             /*!< 0x00200000 */
3759 #define GPIO_BSRR_BR5                  GPIO_BSRR_BR5_Msk
3760 #define GPIO_BSRR_BR6_Pos              (22U)
3761 #define GPIO_BSRR_BR6_Msk              (0x1UL << GPIO_BSRR_BR6_Pos)             /*!< 0x00400000 */
3762 #define GPIO_BSRR_BR6                  GPIO_BSRR_BR6_Msk
3763 #define GPIO_BSRR_BR7_Pos              (23U)
3764 #define GPIO_BSRR_BR7_Msk              (0x1UL << GPIO_BSRR_BR7_Pos)             /*!< 0x00800000 */
3765 #define GPIO_BSRR_BR7                  GPIO_BSRR_BR7_Msk
3766 #define GPIO_BSRR_BR8_Pos              (24U)
3767 #define GPIO_BSRR_BR8_Msk              (0x1UL << GPIO_BSRR_BR8_Pos)             /*!< 0x01000000 */
3768 #define GPIO_BSRR_BR8                  GPIO_BSRR_BR8_Msk
3769 #define GPIO_BSRR_BR9_Pos              (25U)
3770 #define GPIO_BSRR_BR9_Msk              (0x1UL << GPIO_BSRR_BR9_Pos)             /*!< 0x02000000 */
3771 #define GPIO_BSRR_BR9                  GPIO_BSRR_BR9_Msk
3772 #define GPIO_BSRR_BR10_Pos             (26U)
3773 #define GPIO_BSRR_BR10_Msk             (0x1UL << GPIO_BSRR_BR10_Pos)            /*!< 0x04000000 */
3774 #define GPIO_BSRR_BR10                 GPIO_BSRR_BR10_Msk
3775 #define GPIO_BSRR_BR11_Pos             (27U)
3776 #define GPIO_BSRR_BR11_Msk             (0x1UL << GPIO_BSRR_BR11_Pos)            /*!< 0x08000000 */
3777 #define GPIO_BSRR_BR11                 GPIO_BSRR_BR11_Msk
3778 #define GPIO_BSRR_BR12_Pos             (28U)
3779 #define GPIO_BSRR_BR12_Msk             (0x1UL << GPIO_BSRR_BR12_Pos)            /*!< 0x10000000 */
3780 #define GPIO_BSRR_BR12                 GPIO_BSRR_BR12_Msk
3781 #define GPIO_BSRR_BR13_Pos             (29U)
3782 #define GPIO_BSRR_BR13_Msk             (0x1UL << GPIO_BSRR_BR13_Pos)            /*!< 0x20000000 */
3783 #define GPIO_BSRR_BR13                 GPIO_BSRR_BR13_Msk
3784 #define GPIO_BSRR_BR14_Pos             (30U)
3785 #define GPIO_BSRR_BR14_Msk             (0x1UL << GPIO_BSRR_BR14_Pos)            /*!< 0x40000000 */
3786 #define GPIO_BSRR_BR14                 GPIO_BSRR_BR14_Msk
3787 #define GPIO_BSRR_BR15_Pos             (31U)
3788 #define GPIO_BSRR_BR15_Msk             (0x1UL << GPIO_BSRR_BR15_Pos)            /*!< 0x80000000 */
3789 #define GPIO_BSRR_BR15                 GPIO_BSRR_BR15_Msk
3790 
3791 /****************** Bit definition for GPIO_LCKR register *********************/
3792 #define GPIO_LCKR_LCK0_Pos             (0U)
3793 #define GPIO_LCKR_LCK0_Msk             (0x1UL << GPIO_LCKR_LCK0_Pos)            /*!< 0x00000001 */
3794 #define GPIO_LCKR_LCK0                 GPIO_LCKR_LCK0_Msk
3795 #define GPIO_LCKR_LCK1_Pos             (1U)
3796 #define GPIO_LCKR_LCK1_Msk             (0x1UL << GPIO_LCKR_LCK1_Pos)            /*!< 0x00000002 */
3797 #define GPIO_LCKR_LCK1                 GPIO_LCKR_LCK1_Msk
3798 #define GPIO_LCKR_LCK2_Pos             (2U)
3799 #define GPIO_LCKR_LCK2_Msk             (0x1UL << GPIO_LCKR_LCK2_Pos)            /*!< 0x00000004 */
3800 #define GPIO_LCKR_LCK2                 GPIO_LCKR_LCK2_Msk
3801 #define GPIO_LCKR_LCK3_Pos             (3U)
3802 #define GPIO_LCKR_LCK3_Msk             (0x1UL << GPIO_LCKR_LCK3_Pos)            /*!< 0x00000008 */
3803 #define GPIO_LCKR_LCK3                 GPIO_LCKR_LCK3_Msk
3804 #define GPIO_LCKR_LCK4_Pos             (4U)
3805 #define GPIO_LCKR_LCK4_Msk             (0x1UL << GPIO_LCKR_LCK4_Pos)            /*!< 0x00000010 */
3806 #define GPIO_LCKR_LCK4                 GPIO_LCKR_LCK4_Msk
3807 #define GPIO_LCKR_LCK5_Pos             (5U)
3808 #define GPIO_LCKR_LCK5_Msk             (0x1UL << GPIO_LCKR_LCK5_Pos)            /*!< 0x00000020 */
3809 #define GPIO_LCKR_LCK5                 GPIO_LCKR_LCK5_Msk
3810 #define GPIO_LCKR_LCK6_Pos             (6U)
3811 #define GPIO_LCKR_LCK6_Msk             (0x1UL << GPIO_LCKR_LCK6_Pos)            /*!< 0x00000040 */
3812 #define GPIO_LCKR_LCK6                 GPIO_LCKR_LCK6_Msk
3813 #define GPIO_LCKR_LCK7_Pos             (7U)
3814 #define GPIO_LCKR_LCK7_Msk             (0x1UL << GPIO_LCKR_LCK7_Pos)            /*!< 0x00000080 */
3815 #define GPIO_LCKR_LCK7                 GPIO_LCKR_LCK7_Msk
3816 #define GPIO_LCKR_LCK8_Pos             (8U)
3817 #define GPIO_LCKR_LCK8_Msk             (0x1UL << GPIO_LCKR_LCK8_Pos)            /*!< 0x00000100 */
3818 #define GPIO_LCKR_LCK8                 GPIO_LCKR_LCK8_Msk
3819 #define GPIO_LCKR_LCK9_Pos             (9U)
3820 #define GPIO_LCKR_LCK9_Msk             (0x1UL << GPIO_LCKR_LCK9_Pos)            /*!< 0x00000200 */
3821 #define GPIO_LCKR_LCK9                 GPIO_LCKR_LCK9_Msk
3822 #define GPIO_LCKR_LCK10_Pos            (10U)
3823 #define GPIO_LCKR_LCK10_Msk            (0x1UL << GPIO_LCKR_LCK10_Pos)           /*!< 0x00000400 */
3824 #define GPIO_LCKR_LCK10                GPIO_LCKR_LCK10_Msk
3825 #define GPIO_LCKR_LCK11_Pos            (11U)
3826 #define GPIO_LCKR_LCK11_Msk            (0x1UL << GPIO_LCKR_LCK11_Pos)           /*!< 0x00000800 */
3827 #define GPIO_LCKR_LCK11                GPIO_LCKR_LCK11_Msk
3828 #define GPIO_LCKR_LCK12_Pos            (12U)
3829 #define GPIO_LCKR_LCK12_Msk            (0x1UL << GPIO_LCKR_LCK12_Pos)           /*!< 0x00001000 */
3830 #define GPIO_LCKR_LCK12                GPIO_LCKR_LCK12_Msk
3831 #define GPIO_LCKR_LCK13_Pos            (13U)
3832 #define GPIO_LCKR_LCK13_Msk            (0x1UL << GPIO_LCKR_LCK13_Pos)           /*!< 0x00002000 */
3833 #define GPIO_LCKR_LCK13                GPIO_LCKR_LCK13_Msk
3834 #define GPIO_LCKR_LCK14_Pos            (14U)
3835 #define GPIO_LCKR_LCK14_Msk            (0x1UL << GPIO_LCKR_LCK14_Pos)           /*!< 0x00004000 */
3836 #define GPIO_LCKR_LCK14                GPIO_LCKR_LCK14_Msk
3837 #define GPIO_LCKR_LCK15_Pos            (15U)
3838 #define GPIO_LCKR_LCK15_Msk            (0x1UL << GPIO_LCKR_LCK15_Pos)           /*!< 0x00008000 */
3839 #define GPIO_LCKR_LCK15                GPIO_LCKR_LCK15_Msk
3840 #define GPIO_LCKR_LCKK_Pos             (16U)
3841 #define GPIO_LCKR_LCKK_Msk             (0x1UL << GPIO_LCKR_LCKK_Pos)            /*!< 0x00010000 */
3842 #define GPIO_LCKR_LCKK                 GPIO_LCKR_LCKK_Msk
3843 
3844 /****************** Bit definition for GPIO_AFRL register *********************/
3845 #define GPIO_AFRL_AFSEL0_Pos           (0U)
3846 #define GPIO_AFRL_AFSEL0_Msk           (0xFUL << GPIO_AFRL_AFSEL0_Pos)          /*!< 0x0000000F */
3847 #define GPIO_AFRL_AFSEL0               GPIO_AFRL_AFSEL0_Msk
3848 #define GPIO_AFRL_AFSEL0_0             (0x1UL << GPIO_AFRL_AFSEL0_Pos)          /*!< 0x00000001 */
3849 #define GPIO_AFRL_AFSEL0_1             (0x2UL << GPIO_AFRL_AFSEL0_Pos)          /*!< 0x00000002 */
3850 #define GPIO_AFRL_AFSEL0_2             (0x4UL << GPIO_AFRL_AFSEL0_Pos)          /*!< 0x00000004 */
3851 #define GPIO_AFRL_AFSEL0_3             (0x8UL << GPIO_AFRL_AFSEL0_Pos)          /*!< 0x00000008 */
3852 #define GPIO_AFRL_AFSEL1_Pos           (4U)
3853 #define GPIO_AFRL_AFSEL1_Msk           (0xFUL << GPIO_AFRL_AFSEL1_Pos)          /*!< 0x000000F0 */
3854 #define GPIO_AFRL_AFSEL1               GPIO_AFRL_AFSEL1_Msk
3855 #define GPIO_AFRL_AFSEL1_0             (0x1UL << GPIO_AFRL_AFSEL1_Pos)          /*!< 0x00000010 */
3856 #define GPIO_AFRL_AFSEL1_1             (0x2UL << GPIO_AFRL_AFSEL1_Pos)          /*!< 0x00000020 */
3857 #define GPIO_AFRL_AFSEL1_2             (0x4UL << GPIO_AFRL_AFSEL1_Pos)          /*!< 0x00000040 */
3858 #define GPIO_AFRL_AFSEL1_3             (0x8UL << GPIO_AFRL_AFSEL1_Pos)          /*!< 0x00000080 */
3859 #define GPIO_AFRL_AFSEL2_Pos           (8U)
3860 #define GPIO_AFRL_AFSEL2_Msk           (0xFUL << GPIO_AFRL_AFSEL2_Pos)          /*!< 0x00000F00 */
3861 #define GPIO_AFRL_AFSEL2               GPIO_AFRL_AFSEL2_Msk
3862 #define GPIO_AFRL_AFSEL2_0             (0x1UL << GPIO_AFRL_AFSEL2_Pos)          /*!< 0x00000100 */
3863 #define GPIO_AFRL_AFSEL2_1             (0x2UL << GPIO_AFRL_AFSEL2_Pos)          /*!< 0x00000200 */
3864 #define GPIO_AFRL_AFSEL2_2             (0x4UL << GPIO_AFRL_AFSEL2_Pos)          /*!< 0x00000400 */
3865 #define GPIO_AFRL_AFSEL2_3             (0x8UL << GPIO_AFRL_AFSEL2_Pos)          /*!< 0x00000800 */
3866 #define GPIO_AFRL_AFSEL3_Pos           (12U)
3867 #define GPIO_AFRL_AFSEL3_Msk           (0xFUL << GPIO_AFRL_AFSEL3_Pos)          /*!< 0x0000F000 */
3868 #define GPIO_AFRL_AFSEL3               GPIO_AFRL_AFSEL3_Msk
3869 #define GPIO_AFRL_AFSEL3_0             (0x1UL << GPIO_AFRL_AFSEL3_Pos)          /*!< 0x00001000 */
3870 #define GPIO_AFRL_AFSEL3_1             (0x2UL << GPIO_AFRL_AFSEL3_Pos)          /*!< 0x00002000 */
3871 #define GPIO_AFRL_AFSEL3_2             (0x4UL << GPIO_AFRL_AFSEL3_Pos)          /*!< 0x00004000 */
3872 #define GPIO_AFRL_AFSEL3_3             (0x8UL << GPIO_AFRL_AFSEL3_Pos)          /*!< 0x00008000 */
3873 #define GPIO_AFRL_AFSEL4_Pos           (16U)
3874 #define GPIO_AFRL_AFSEL4_Msk           (0xFUL << GPIO_AFRL_AFSEL4_Pos)          /*!< 0x000F0000 */
3875 #define GPIO_AFRL_AFSEL4               GPIO_AFRL_AFSEL4_Msk
3876 #define GPIO_AFRL_AFSEL4_0             (0x1UL << GPIO_AFRL_AFSEL4_Pos)          /*!< 0x00010000 */
3877 #define GPIO_AFRL_AFSEL4_1             (0x2UL << GPIO_AFRL_AFSEL4_Pos)          /*!< 0x00020000 */
3878 #define GPIO_AFRL_AFSEL4_2             (0x4UL << GPIO_AFRL_AFSEL4_Pos)          /*!< 0x00040000 */
3879 #define GPIO_AFRL_AFSEL4_3             (0x8UL << GPIO_AFRL_AFSEL4_Pos)          /*!< 0x00080000 */
3880 #define GPIO_AFRL_AFSEL5_Pos           (20U)
3881 #define GPIO_AFRL_AFSEL5_Msk           (0xFUL << GPIO_AFRL_AFSEL5_Pos)          /*!< 0x00F00000 */
3882 #define GPIO_AFRL_AFSEL5               GPIO_AFRL_AFSEL5_Msk
3883 #define GPIO_AFRL_AFSEL5_0             (0x1UL << GPIO_AFRL_AFSEL5_Pos)          /*!< 0x00100000 */
3884 #define GPIO_AFRL_AFSEL5_1             (0x2UL << GPIO_AFRL_AFSEL5_Pos)          /*!< 0x00200000 */
3885 #define GPIO_AFRL_AFSEL5_2             (0x4UL << GPIO_AFRL_AFSEL5_Pos)          /*!< 0x00400000 */
3886 #define GPIO_AFRL_AFSEL5_3             (0x8UL << GPIO_AFRL_AFSEL5_Pos)          /*!< 0x00800000 */
3887 #define GPIO_AFRL_AFSEL6_Pos           (24U)
3888 #define GPIO_AFRL_AFSEL6_Msk           (0xFUL << GPIO_AFRL_AFSEL6_Pos)          /*!< 0x0F000000 */
3889 #define GPIO_AFRL_AFSEL6               GPIO_AFRL_AFSEL6_Msk
3890 #define GPIO_AFRL_AFSEL6_0             (0x1UL << GPIO_AFRL_AFSEL6_Pos)          /*!< 0x01000000 */
3891 #define GPIO_AFRL_AFSEL6_1             (0x2UL << GPIO_AFRL_AFSEL6_Pos)          /*!< 0x02000000 */
3892 #define GPIO_AFRL_AFSEL6_2             (0x4UL << GPIO_AFRL_AFSEL6_Pos)          /*!< 0x04000000 */
3893 #define GPIO_AFRL_AFSEL6_3             (0x8UL << GPIO_AFRL_AFSEL6_Pos)          /*!< 0x08000000 */
3894 #define GPIO_AFRL_AFSEL7_Pos           (28U)
3895 #define GPIO_AFRL_AFSEL7_Msk           (0xFUL << GPIO_AFRL_AFSEL7_Pos)          /*!< 0xF0000000 */
3896 #define GPIO_AFRL_AFSEL7               GPIO_AFRL_AFSEL7_Msk
3897 #define GPIO_AFRL_AFSEL7_0             (0x1UL << GPIO_AFRL_AFSEL7_Pos)          /*!< 0x10000000 */
3898 #define GPIO_AFRL_AFSEL7_1             (0x2UL << GPIO_AFRL_AFSEL7_Pos)          /*!< 0x20000000 */
3899 #define GPIO_AFRL_AFSEL7_2             (0x4UL << GPIO_AFRL_AFSEL7_Pos)          /*!< 0x40000000 */
3900 #define GPIO_AFRL_AFSEL7_3             (0x8UL << GPIO_AFRL_AFSEL7_Pos)          /*!< 0x80000000 */
3901 
3902 /****************** Bit definition for GPIO_AFRH register *********************/
3903 #define GPIO_AFRH_AFSEL8_Pos           (0U)
3904 #define GPIO_AFRH_AFSEL8_Msk           (0xFUL << GPIO_AFRH_AFSEL8_Pos)          /*!< 0x0000000F */
3905 #define GPIO_AFRH_AFSEL8               GPIO_AFRH_AFSEL8_Msk
3906 #define GPIO_AFRH_AFSEL8_0             (0x1UL << GPIO_AFRH_AFSEL8_Pos)          /*!< 0x00000001 */
3907 #define GPIO_AFRH_AFSEL8_1             (0x2UL << GPIO_AFRH_AFSEL8_Pos)          /*!< 0x00000002 */
3908 #define GPIO_AFRH_AFSEL8_2             (0x4UL << GPIO_AFRH_AFSEL8_Pos)          /*!< 0x00000004 */
3909 #define GPIO_AFRH_AFSEL8_3             (0x8UL << GPIO_AFRH_AFSEL8_Pos)          /*!< 0x00000008 */
3910 #define GPIO_AFRH_AFSEL9_Pos           (4U)
3911 #define GPIO_AFRH_AFSEL9_Msk           (0xFUL << GPIO_AFRH_AFSEL9_Pos)          /*!< 0x000000F0 */
3912 #define GPIO_AFRH_AFSEL9               GPIO_AFRH_AFSEL9_Msk
3913 #define GPIO_AFRH_AFSEL9_0             (0x1UL << GPIO_AFRH_AFSEL9_Pos)          /*!< 0x00000010 */
3914 #define GPIO_AFRH_AFSEL9_1             (0x2UL << GPIO_AFRH_AFSEL9_Pos)          /*!< 0x00000020 */
3915 #define GPIO_AFRH_AFSEL9_2             (0x4UL << GPIO_AFRH_AFSEL9_Pos)          /*!< 0x00000040 */
3916 #define GPIO_AFRH_AFSEL9_3             (0x8UL << GPIO_AFRH_AFSEL9_Pos)          /*!< 0x00000080 */
3917 #define GPIO_AFRH_AFSEL10_Pos          (8U)
3918 #define GPIO_AFRH_AFSEL10_Msk          (0xFUL << GPIO_AFRH_AFSEL10_Pos)         /*!< 0x00000F00 */
3919 #define GPIO_AFRH_AFSEL10              GPIO_AFRH_AFSEL10_Msk
3920 #define GPIO_AFRH_AFSEL10_0            (0x1UL << GPIO_AFRH_AFSEL10_Pos)         /*!< 0x00000100 */
3921 #define GPIO_AFRH_AFSEL10_1            (0x2UL << GPIO_AFRH_AFSEL10_Pos)         /*!< 0x00000200 */
3922 #define GPIO_AFRH_AFSEL10_2            (0x4UL << GPIO_AFRH_AFSEL10_Pos)         /*!< 0x00000400 */
3923 #define GPIO_AFRH_AFSEL10_3            (0x8UL << GPIO_AFRH_AFSEL10_Pos)         /*!< 0x00000800 */
3924 #define GPIO_AFRH_AFSEL11_Pos          (12U)
3925 #define GPIO_AFRH_AFSEL11_Msk          (0xFUL << GPIO_AFRH_AFSEL11_Pos)         /*!< 0x0000F000 */
3926 #define GPIO_AFRH_AFSEL11              GPIO_AFRH_AFSEL11_Msk
3927 #define GPIO_AFRH_AFSEL11_0            (0x1UL << GPIO_AFRH_AFSEL11_Pos)         /*!< 0x00001000 */
3928 #define GPIO_AFRH_AFSEL11_1            (0x2UL << GPIO_AFRH_AFSEL11_Pos)         /*!< 0x00002000 */
3929 #define GPIO_AFRH_AFSEL11_2            (0x4UL << GPIO_AFRH_AFSEL11_Pos)         /*!< 0x00004000 */
3930 #define GPIO_AFRH_AFSEL11_3            (0x8UL << GPIO_AFRH_AFSEL11_Pos)         /*!< 0x00008000 */
3931 #define GPIO_AFRH_AFSEL12_Pos          (16U)
3932 #define GPIO_AFRH_AFSEL12_Msk          (0xFUL << GPIO_AFRH_AFSEL12_Pos)         /*!< 0x000F0000 */
3933 #define GPIO_AFRH_AFSEL12              GPIO_AFRH_AFSEL12_Msk
3934 #define GPIO_AFRH_AFSEL12_0            (0x1UL << GPIO_AFRH_AFSEL12_Pos)         /*!< 0x00010000 */
3935 #define GPIO_AFRH_AFSEL12_1            (0x2UL << GPIO_AFRH_AFSEL12_Pos)         /*!< 0x00020000 */
3936 #define GPIO_AFRH_AFSEL12_2            (0x4UL << GPIO_AFRH_AFSEL12_Pos)         /*!< 0x00040000 */
3937 #define GPIO_AFRH_AFSEL12_3            (0x8UL << GPIO_AFRH_AFSEL12_Pos)         /*!< 0x00080000 */
3938 #define GPIO_AFRH_AFSEL13_Pos          (20U)
3939 #define GPIO_AFRH_AFSEL13_Msk          (0xFUL << GPIO_AFRH_AFSEL13_Pos)         /*!< 0x00F00000 */
3940 #define GPIO_AFRH_AFSEL13              GPIO_AFRH_AFSEL13_Msk
3941 #define GPIO_AFRH_AFSEL13_0            (0x1UL << GPIO_AFRH_AFSEL13_Pos)         /*!< 0x00100000 */
3942 #define GPIO_AFRH_AFSEL13_1            (0x2UL << GPIO_AFRH_AFSEL13_Pos)         /*!< 0x00200000 */
3943 #define GPIO_AFRH_AFSEL13_2            (0x4UL << GPIO_AFRH_AFSEL13_Pos)         /*!< 0x00400000 */
3944 #define GPIO_AFRH_AFSEL13_3            (0x8UL << GPIO_AFRH_AFSEL13_Pos)         /*!< 0x00800000 */
3945 #define GPIO_AFRH_AFSEL14_Pos          (24U)
3946 #define GPIO_AFRH_AFSEL14_Msk          (0xFUL << GPIO_AFRH_AFSEL14_Pos)         /*!< 0x0F000000 */
3947 #define GPIO_AFRH_AFSEL14              GPIO_AFRH_AFSEL14_Msk
3948 #define GPIO_AFRH_AFSEL14_0            (0x1UL << GPIO_AFRH_AFSEL14_Pos)         /*!< 0x01000000 */
3949 #define GPIO_AFRH_AFSEL14_1            (0x2UL << GPIO_AFRH_AFSEL14_Pos)         /*!< 0x02000000 */
3950 #define GPIO_AFRH_AFSEL14_2            (0x4UL << GPIO_AFRH_AFSEL14_Pos)         /*!< 0x04000000 */
3951 #define GPIO_AFRH_AFSEL14_3            (0x8UL << GPIO_AFRH_AFSEL14_Pos)         /*!< 0x08000000 */
3952 #define GPIO_AFRH_AFSEL15_Pos          (28U)
3953 #define GPIO_AFRH_AFSEL15_Msk          (0xFUL << GPIO_AFRH_AFSEL15_Pos)         /*!< 0xF0000000 */
3954 #define GPIO_AFRH_AFSEL15              GPIO_AFRH_AFSEL15_Msk
3955 #define GPIO_AFRH_AFSEL15_0            (0x1UL << GPIO_AFRH_AFSEL15_Pos)         /*!< 0x10000000 */
3956 #define GPIO_AFRH_AFSEL15_1            (0x2UL << GPIO_AFRH_AFSEL15_Pos)         /*!< 0x20000000 */
3957 #define GPIO_AFRH_AFSEL15_2            (0x4UL << GPIO_AFRH_AFSEL15_Pos)         /*!< 0x40000000 */
3958 #define GPIO_AFRH_AFSEL15_3            (0x8UL << GPIO_AFRH_AFSEL15_Pos)         /*!< 0x80000000 */
3959 
3960 /******************  Bits definition for GPIO_BRR register  ******************/
3961 #define GPIO_BRR_BR0_Pos               (0U)
3962 #define GPIO_BRR_BR0_Msk               (0x1UL << GPIO_BRR_BR0_Pos)              /*!< 0x00000001 */
3963 #define GPIO_BRR_BR0                   GPIO_BRR_BR0_Msk
3964 #define GPIO_BRR_BR1_Pos               (1U)
3965 #define GPIO_BRR_BR1_Msk               (0x1UL << GPIO_BRR_BR1_Pos)              /*!< 0x00000002 */
3966 #define GPIO_BRR_BR1                   GPIO_BRR_BR1_Msk
3967 #define GPIO_BRR_BR2_Pos               (2U)
3968 #define GPIO_BRR_BR2_Msk               (0x1UL << GPIO_BRR_BR2_Pos)              /*!< 0x00000004 */
3969 #define GPIO_BRR_BR2                   GPIO_BRR_BR2_Msk
3970 #define GPIO_BRR_BR3_Pos               (3U)
3971 #define GPIO_BRR_BR3_Msk               (0x1UL << GPIO_BRR_BR3_Pos)              /*!< 0x00000008 */
3972 #define GPIO_BRR_BR3                   GPIO_BRR_BR3_Msk
3973 #define GPIO_BRR_BR4_Pos               (4U)
3974 #define GPIO_BRR_BR4_Msk               (0x1UL << GPIO_BRR_BR4_Pos)              /*!< 0x00000010 */
3975 #define GPIO_BRR_BR4                   GPIO_BRR_BR4_Msk
3976 #define GPIO_BRR_BR5_Pos               (5U)
3977 #define GPIO_BRR_BR5_Msk               (0x1UL << GPIO_BRR_BR5_Pos)              /*!< 0x00000020 */
3978 #define GPIO_BRR_BR5                   GPIO_BRR_BR5_Msk
3979 #define GPIO_BRR_BR6_Pos               (6U)
3980 #define GPIO_BRR_BR6_Msk               (0x1UL << GPIO_BRR_BR6_Pos)              /*!< 0x00000040 */
3981 #define GPIO_BRR_BR6                   GPIO_BRR_BR6_Msk
3982 #define GPIO_BRR_BR7_Pos               (7U)
3983 #define GPIO_BRR_BR7_Msk               (0x1UL << GPIO_BRR_BR7_Pos)              /*!< 0x00000080 */
3984 #define GPIO_BRR_BR7                   GPIO_BRR_BR7_Msk
3985 #define GPIO_BRR_BR8_Pos               (8U)
3986 #define GPIO_BRR_BR8_Msk               (0x1UL << GPIO_BRR_BR8_Pos)              /*!< 0x00000100 */
3987 #define GPIO_BRR_BR8                   GPIO_BRR_BR8_Msk
3988 #define GPIO_BRR_BR9_Pos               (9U)
3989 #define GPIO_BRR_BR9_Msk               (0x1UL << GPIO_BRR_BR9_Pos)              /*!< 0x00000200 */
3990 #define GPIO_BRR_BR9                   GPIO_BRR_BR9_Msk
3991 #define GPIO_BRR_BR10_Pos              (10U)
3992 #define GPIO_BRR_BR10_Msk              (0x1UL << GPIO_BRR_BR10_Pos)             /*!< 0x00000400 */
3993 #define GPIO_BRR_BR10                  GPIO_BRR_BR10_Msk
3994 #define GPIO_BRR_BR11_Pos              (11U)
3995 #define GPIO_BRR_BR11_Msk              (0x1UL << GPIO_BRR_BR11_Pos)             /*!< 0x00000800 */
3996 #define GPIO_BRR_BR11                  GPIO_BRR_BR11_Msk
3997 #define GPIO_BRR_BR12_Pos              (12U)
3998 #define GPIO_BRR_BR12_Msk              (0x1UL << GPIO_BRR_BR12_Pos)             /*!< 0x00001000 */
3999 #define GPIO_BRR_BR12                  GPIO_BRR_BR12_Msk
4000 #define GPIO_BRR_BR13_Pos              (13U)
4001 #define GPIO_BRR_BR13_Msk              (0x1UL << GPIO_BRR_BR13_Pos)             /*!< 0x00002000 */
4002 #define GPIO_BRR_BR13                  GPIO_BRR_BR13_Msk
4003 #define GPIO_BRR_BR14_Pos              (14U)
4004 #define GPIO_BRR_BR14_Msk              (0x1UL << GPIO_BRR_BR14_Pos)             /*!< 0x00004000 */
4005 #define GPIO_BRR_BR14                  GPIO_BRR_BR14_Msk
4006 #define GPIO_BRR_BR15_Pos              (15U)
4007 #define GPIO_BRR_BR15_Msk              (0x1UL << GPIO_BRR_BR15_Pos)             /*!< 0x00008000 */
4008 #define GPIO_BRR_BR15                  GPIO_BRR_BR15_Msk
4009 
4010 
4011 /******************************************************************************/
4012 /*                                                                            */
4013 /*                      Inter-integrated Circuit Interface (I2C)              */
4014 /*                                                                            */
4015 /******************************************************************************/
4016 /*******************  Bit definition for I2C_CR1 register  *******************/
4017 #define I2C_CR1_PE_Pos               (0U)
4018 #define I2C_CR1_PE_Msk               (0x1UL << I2C_CR1_PE_Pos)                 /*!< 0x00000001 */
4019 #define I2C_CR1_PE                   I2C_CR1_PE_Msk                            /*!< Peripheral enable */
4020 #define I2C_CR1_TXIE_Pos             (1U)
4021 #define I2C_CR1_TXIE_Msk             (0x1UL << I2C_CR1_TXIE_Pos)               /*!< 0x00000002 */
4022 #define I2C_CR1_TXIE                 I2C_CR1_TXIE_Msk                          /*!< TX interrupt enable */
4023 #define I2C_CR1_RXIE_Pos             (2U)
4024 #define I2C_CR1_RXIE_Msk             (0x1UL << I2C_CR1_RXIE_Pos)               /*!< 0x00000004 */
4025 #define I2C_CR1_RXIE                 I2C_CR1_RXIE_Msk                          /*!< RX interrupt enable */
4026 #define I2C_CR1_ADDRIE_Pos           (3U)
4027 #define I2C_CR1_ADDRIE_Msk           (0x1UL << I2C_CR1_ADDRIE_Pos)             /*!< 0x00000008 */
4028 #define I2C_CR1_ADDRIE               I2C_CR1_ADDRIE_Msk                        /*!< Address match interrupt enable */
4029 #define I2C_CR1_NACKIE_Pos           (4U)
4030 #define I2C_CR1_NACKIE_Msk           (0x1UL << I2C_CR1_NACKIE_Pos)             /*!< 0x00000010 */
4031 #define I2C_CR1_NACKIE               I2C_CR1_NACKIE_Msk                        /*!< NACK received interrupt enable */
4032 #define I2C_CR1_STOPIE_Pos           (5U)
4033 #define I2C_CR1_STOPIE_Msk           (0x1UL << I2C_CR1_STOPIE_Pos)             /*!< 0x00000020 */
4034 #define I2C_CR1_STOPIE               I2C_CR1_STOPIE_Msk                        /*!< STOP detection interrupt enable */
4035 #define I2C_CR1_TCIE_Pos             (6U)
4036 #define I2C_CR1_TCIE_Msk             (0x1UL << I2C_CR1_TCIE_Pos)               /*!< 0x00000040 */
4037 #define I2C_CR1_TCIE                 I2C_CR1_TCIE_Msk                          /*!< Transfer complete interrupt enable */
4038 #define I2C_CR1_ERRIE_Pos            (7U)
4039 #define I2C_CR1_ERRIE_Msk            (0x1UL << I2C_CR1_ERRIE_Pos)              /*!< 0x00000080 */
4040 #define I2C_CR1_ERRIE                I2C_CR1_ERRIE_Msk                         /*!< Errors interrupt enable */
4041 #define I2C_CR1_DNF_Pos              (8U)
4042 #define I2C_CR1_DNF_Msk              (0xFUL << I2C_CR1_DNF_Pos)                /*!< 0x00000F00 */
4043 #define I2C_CR1_DNF                  I2C_CR1_DNF_Msk                           /*!< Digital noise filter */
4044 #define I2C_CR1_ANFOFF_Pos           (12U)
4045 #define I2C_CR1_ANFOFF_Msk           (0x1UL << I2C_CR1_ANFOFF_Pos)             /*!< 0x00001000 */
4046 #define I2C_CR1_ANFOFF               I2C_CR1_ANFOFF_Msk                        /*!< Analog noise filter OFF */
4047 #define I2C_CR1_SWRST_Pos            (13U)
4048 #define I2C_CR1_SWRST_Msk            (0x1UL << I2C_CR1_SWRST_Pos)              /*!< 0x00002000 */
4049 #define I2C_CR1_SWRST                I2C_CR1_SWRST_Msk                         /*!< Software reset */
4050 #define I2C_CR1_TXDMAEN_Pos          (14U)
4051 #define I2C_CR1_TXDMAEN_Msk          (0x1UL << I2C_CR1_TXDMAEN_Pos)            /*!< 0x00004000 */
4052 #define I2C_CR1_TXDMAEN              I2C_CR1_TXDMAEN_Msk                       /*!< DMA transmission requests enable */
4053 #define I2C_CR1_RXDMAEN_Pos          (15U)
4054 #define I2C_CR1_RXDMAEN_Msk          (0x1UL << I2C_CR1_RXDMAEN_Pos)            /*!< 0x00008000 */
4055 #define I2C_CR1_RXDMAEN              I2C_CR1_RXDMAEN_Msk                       /*!< DMA reception requests enable */
4056 #define I2C_CR1_SBC_Pos              (16U)
4057 #define I2C_CR1_SBC_Msk              (0x1UL << I2C_CR1_SBC_Pos)                /*!< 0x00010000 */
4058 #define I2C_CR1_SBC                  I2C_CR1_SBC_Msk                           /*!< Slave byte control */
4059 #define I2C_CR1_NOSTRETCH_Pos        (17U)
4060 #define I2C_CR1_NOSTRETCH_Msk        (0x1UL << I2C_CR1_NOSTRETCH_Pos)          /*!< 0x00020000 */
4061 #define I2C_CR1_NOSTRETCH            I2C_CR1_NOSTRETCH_Msk                     /*!< Clock stretching disable */
4062 #define I2C_CR1_WUPEN_Pos            (18U)
4063 #define I2C_CR1_WUPEN_Msk            (0x1UL << I2C_CR1_WUPEN_Pos)              /*!< 0x00040000 */
4064 #define I2C_CR1_WUPEN                I2C_CR1_WUPEN_Msk                         /*!< Wakeup from STOP enable */
4065 #define I2C_CR1_GCEN_Pos             (19U)
4066 #define I2C_CR1_GCEN_Msk             (0x1UL << I2C_CR1_GCEN_Pos)               /*!< 0x00080000 */
4067 #define I2C_CR1_GCEN                 I2C_CR1_GCEN_Msk                          /*!< General call enable */
4068 #define I2C_CR1_SMBHEN_Pos           (20U)
4069 #define I2C_CR1_SMBHEN_Msk           (0x1UL << I2C_CR1_SMBHEN_Pos)             /*!< 0x00100000 */
4070 #define I2C_CR1_SMBHEN               I2C_CR1_SMBHEN_Msk                        /*!< SMBus host address enable */
4071 #define I2C_CR1_SMBDEN_Pos           (21U)
4072 #define I2C_CR1_SMBDEN_Msk           (0x1UL << I2C_CR1_SMBDEN_Pos)             /*!< 0x00200000 */
4073 #define I2C_CR1_SMBDEN               I2C_CR1_SMBDEN_Msk                        /*!< SMBus device default address enable */
4074 #define I2C_CR1_ALERTEN_Pos          (22U)
4075 #define I2C_CR1_ALERTEN_Msk          (0x1UL << I2C_CR1_ALERTEN_Pos)            /*!< 0x00400000 */
4076 #define I2C_CR1_ALERTEN              I2C_CR1_ALERTEN_Msk                       /*!< SMBus alert enable */
4077 #define I2C_CR1_PECEN_Pos            (23U)
4078 #define I2C_CR1_PECEN_Msk            (0x1UL << I2C_CR1_PECEN_Pos)              /*!< 0x00800000 */
4079 #define I2C_CR1_PECEN                I2C_CR1_PECEN_Msk                         /*!< PEC enable */
4080 
4081 /******************  Bit definition for I2C_CR2 register  ********************/
4082 #define I2C_CR2_SADD_Pos             (0U)
4083 #define I2C_CR2_SADD_Msk             (0x3FFUL << I2C_CR2_SADD_Pos)             /*!< 0x000003FF */
4084 #define I2C_CR2_SADD                 I2C_CR2_SADD_Msk                          /*!< Slave address (master mode) */
4085 #define I2C_CR2_RD_WRN_Pos           (10U)
4086 #define I2C_CR2_RD_WRN_Msk           (0x1UL << I2C_CR2_RD_WRN_Pos)             /*!< 0x00000400 */
4087 #define I2C_CR2_RD_WRN               I2C_CR2_RD_WRN_Msk                        /*!< Transfer direction (master mode) */
4088 #define I2C_CR2_ADD10_Pos            (11U)
4089 #define I2C_CR2_ADD10_Msk            (0x1UL << I2C_CR2_ADD10_Pos)              /*!< 0x00000800 */
4090 #define I2C_CR2_ADD10                I2C_CR2_ADD10_Msk                         /*!< 10-bit addressing mode (master mode) */
4091 #define I2C_CR2_HEAD10R_Pos          (12U)
4092 #define I2C_CR2_HEAD10R_Msk          (0x1UL << I2C_CR2_HEAD10R_Pos)            /*!< 0x00001000 */
4093 #define I2C_CR2_HEAD10R              I2C_CR2_HEAD10R_Msk                       /*!< 10-bit address header only read direction (master mode) */
4094 #define I2C_CR2_START_Pos            (13U)
4095 #define I2C_CR2_START_Msk            (0x1UL << I2C_CR2_START_Pos)              /*!< 0x00002000 */
4096 #define I2C_CR2_START                I2C_CR2_START_Msk                         /*!< START generation */
4097 #define I2C_CR2_STOP_Pos             (14U)
4098 #define I2C_CR2_STOP_Msk             (0x1UL << I2C_CR2_STOP_Pos)               /*!< 0x00004000 */
4099 #define I2C_CR2_STOP                 I2C_CR2_STOP_Msk                          /*!< STOP generation (master mode) */
4100 #define I2C_CR2_NACK_Pos             (15U)
4101 #define I2C_CR2_NACK_Msk             (0x1UL << I2C_CR2_NACK_Pos)               /*!< 0x00008000 */
4102 #define I2C_CR2_NACK                 I2C_CR2_NACK_Msk                          /*!< NACK generation (slave mode) */
4103 #define I2C_CR2_NBYTES_Pos           (16U)
4104 #define I2C_CR2_NBYTES_Msk           (0xFFUL << I2C_CR2_NBYTES_Pos)            /*!< 0x00FF0000 */
4105 #define I2C_CR2_NBYTES               I2C_CR2_NBYTES_Msk                        /*!< Number of bytes */
4106 #define I2C_CR2_RELOAD_Pos           (24U)
4107 #define I2C_CR2_RELOAD_Msk           (0x1UL << I2C_CR2_RELOAD_Pos)             /*!< 0x01000000 */
4108 #define I2C_CR2_RELOAD               I2C_CR2_RELOAD_Msk                        /*!< NBYTES reload mode */
4109 #define I2C_CR2_AUTOEND_Pos          (25U)
4110 #define I2C_CR2_AUTOEND_Msk          (0x1UL << I2C_CR2_AUTOEND_Pos)            /*!< 0x02000000 */
4111 #define I2C_CR2_AUTOEND              I2C_CR2_AUTOEND_Msk                       /*!< Automatic end mode (master mode) */
4112 #define I2C_CR2_PECBYTE_Pos          (26U)
4113 #define I2C_CR2_PECBYTE_Msk          (0x1UL << I2C_CR2_PECBYTE_Pos)            /*!< 0x04000000 */
4114 #define I2C_CR2_PECBYTE              I2C_CR2_PECBYTE_Msk                       /*!< Packet error checking byte */
4115 
4116 /*******************  Bit definition for I2C_OAR1 register  ******************/
4117 #define I2C_OAR1_OA1_Pos             (0U)
4118 #define I2C_OAR1_OA1_Msk             (0x3FFUL << I2C_OAR1_OA1_Pos)             /*!< 0x000003FF */
4119 #define I2C_OAR1_OA1                 I2C_OAR1_OA1_Msk                          /*!< Interface own address 1 */
4120 #define I2C_OAR1_OA1MODE_Pos         (10U)
4121 #define I2C_OAR1_OA1MODE_Msk         (0x1UL << I2C_OAR1_OA1MODE_Pos)           /*!< 0x00000400 */
4122 #define I2C_OAR1_OA1MODE             I2C_OAR1_OA1MODE_Msk                      /*!< Own address 1 10-bit mode */
4123 #define I2C_OAR1_OA1EN_Pos           (15U)
4124 #define I2C_OAR1_OA1EN_Msk           (0x1UL << I2C_OAR1_OA1EN_Pos)             /*!< 0x00008000 */
4125 #define I2C_OAR1_OA1EN               I2C_OAR1_OA1EN_Msk                        /*!< Own address 1 enable */
4126 
4127 /*******************  Bit definition for I2C_OAR2 register  ******************/
4128 #define I2C_OAR2_OA2_Pos             (1U)
4129 #define I2C_OAR2_OA2_Msk             (0x7FUL << I2C_OAR2_OA2_Pos)              /*!< 0x000000FE */
4130 #define I2C_OAR2_OA2                 I2C_OAR2_OA2_Msk                          /*!< Interface own address 2 */
4131 #define I2C_OAR2_OA2MSK_Pos          (8U)
4132 #define I2C_OAR2_OA2MSK_Msk          (0x7UL << I2C_OAR2_OA2MSK_Pos)            /*!< 0x00000700 */
4133 #define I2C_OAR2_OA2MSK              I2C_OAR2_OA2MSK_Msk                       /*!< Own address 2 masks */
4134 #define I2C_OAR2_OA2NOMASK           (0U)                                      /*!< No mask                                        */
4135 #define I2C_OAR2_OA2MASK01_Pos       (8U)
4136 #define I2C_OAR2_OA2MASK01_Msk       (0x1UL << I2C_OAR2_OA2MASK01_Pos)         /*!< 0x00000100 */
4137 #define I2C_OAR2_OA2MASK01           I2C_OAR2_OA2MASK01_Msk                    /*!< OA2[1] is masked, Only OA2[7:2] are compared   */
4138 #define I2C_OAR2_OA2MASK02_Pos       (9U)
4139 #define I2C_OAR2_OA2MASK02_Msk       (0x1UL << I2C_OAR2_OA2MASK02_Pos)         /*!< 0x00000200 */
4140 #define I2C_OAR2_OA2MASK02           I2C_OAR2_OA2MASK02_Msk                    /*!< OA2[2:1] is masked, Only OA2[7:3] are compared */
4141 #define I2C_OAR2_OA2MASK03_Pos       (8U)
4142 #define I2C_OAR2_OA2MASK03_Msk       (0x3UL << I2C_OAR2_OA2MASK03_Pos)         /*!< 0x00000300 */
4143 #define I2C_OAR2_OA2MASK03           I2C_OAR2_OA2MASK03_Msk                    /*!< OA2[3:1] is masked, Only OA2[7:4] are compared */
4144 #define I2C_OAR2_OA2MASK04_Pos       (10U)
4145 #define I2C_OAR2_OA2MASK04_Msk       (0x1UL << I2C_OAR2_OA2MASK04_Pos)         /*!< 0x00000400 */
4146 #define I2C_OAR2_OA2MASK04           I2C_OAR2_OA2MASK04_Msk                    /*!< OA2[4:1] is masked, Only OA2[7:5] are compared */
4147 #define I2C_OAR2_OA2MASK05_Pos       (8U)
4148 #define I2C_OAR2_OA2MASK05_Msk       (0x5UL << I2C_OAR2_OA2MASK05_Pos)         /*!< 0x00000500 */
4149 #define I2C_OAR2_OA2MASK05           I2C_OAR2_OA2MASK05_Msk                    /*!< OA2[5:1] is masked, Only OA2[7:6] are compared */
4150 #define I2C_OAR2_OA2MASK06_Pos       (9U)
4151 #define I2C_OAR2_OA2MASK06_Msk       (0x3UL << I2C_OAR2_OA2MASK06_Pos)         /*!< 0x00000600 */
4152 #define I2C_OAR2_OA2MASK06           I2C_OAR2_OA2MASK06_Msk                    /*!< OA2[6:1] is masked, Only OA2[7] are compared   */
4153 #define I2C_OAR2_OA2MASK07_Pos       (8U)
4154 #define I2C_OAR2_OA2MASK07_Msk       (0x7UL << I2C_OAR2_OA2MASK07_Pos)         /*!< 0x00000700 */
4155 #define I2C_OAR2_OA2MASK07           I2C_OAR2_OA2MASK07_Msk                    /*!< OA2[7:1] is masked, No comparison is done      */
4156 #define I2C_OAR2_OA2EN_Pos           (15U)
4157 #define I2C_OAR2_OA2EN_Msk           (0x1UL << I2C_OAR2_OA2EN_Pos)             /*!< 0x00008000 */
4158 #define I2C_OAR2_OA2EN               I2C_OAR2_OA2EN_Msk                        /*!< Own address 2 enable */
4159 
4160 /*******************  Bit definition for I2C_TIMINGR register *******************/
4161 #define I2C_TIMINGR_SCLL_Pos         (0U)
4162 #define I2C_TIMINGR_SCLL_Msk         (0xFFUL << I2C_TIMINGR_SCLL_Pos)          /*!< 0x000000FF */
4163 #define I2C_TIMINGR_SCLL             I2C_TIMINGR_SCLL_Msk                      /*!< SCL low period (master mode) */
4164 #define I2C_TIMINGR_SCLH_Pos         (8U)
4165 #define I2C_TIMINGR_SCLH_Msk         (0xFFUL << I2C_TIMINGR_SCLH_Pos)          /*!< 0x0000FF00 */
4166 #define I2C_TIMINGR_SCLH             I2C_TIMINGR_SCLH_Msk                      /*!< SCL high period (master mode) */
4167 #define I2C_TIMINGR_SDADEL_Pos       (16U)
4168 #define I2C_TIMINGR_SDADEL_Msk       (0xFUL << I2C_TIMINGR_SDADEL_Pos)         /*!< 0x000F0000 */
4169 #define I2C_TIMINGR_SDADEL           I2C_TIMINGR_SDADEL_Msk                    /*!< Data hold time */
4170 #define I2C_TIMINGR_SCLDEL_Pos       (20U)
4171 #define I2C_TIMINGR_SCLDEL_Msk       (0xFUL << I2C_TIMINGR_SCLDEL_Pos)         /*!< 0x00F00000 */
4172 #define I2C_TIMINGR_SCLDEL           I2C_TIMINGR_SCLDEL_Msk                    /*!< Data setup time */
4173 #define I2C_TIMINGR_PRESC_Pos        (28U)
4174 #define I2C_TIMINGR_PRESC_Msk        (0xFUL << I2C_TIMINGR_PRESC_Pos)          /*!< 0xF0000000 */
4175 #define I2C_TIMINGR_PRESC            I2C_TIMINGR_PRESC_Msk                     /*!< Timings prescaler */
4176 
4177 /******************* Bit definition for I2C_TIMEOUTR register *******************/
4178 #define I2C_TIMEOUTR_TIMEOUTA_Pos    (0U)
4179 #define I2C_TIMEOUTR_TIMEOUTA_Msk    (0xFFFUL << I2C_TIMEOUTR_TIMEOUTA_Pos)    /*!< 0x00000FFF */
4180 #define I2C_TIMEOUTR_TIMEOUTA        I2C_TIMEOUTR_TIMEOUTA_Msk                 /*!< Bus timeout A */
4181 #define I2C_TIMEOUTR_TIDLE_Pos       (12U)
4182 #define I2C_TIMEOUTR_TIDLE_Msk       (0x1UL << I2C_TIMEOUTR_TIDLE_Pos)         /*!< 0x00001000 */
4183 #define I2C_TIMEOUTR_TIDLE           I2C_TIMEOUTR_TIDLE_Msk                    /*!< Idle clock timeout detection */
4184 #define I2C_TIMEOUTR_TIMOUTEN_Pos    (15U)
4185 #define I2C_TIMEOUTR_TIMOUTEN_Msk    (0x1UL << I2C_TIMEOUTR_TIMOUTEN_Pos)      /*!< 0x00008000 */
4186 #define I2C_TIMEOUTR_TIMOUTEN        I2C_TIMEOUTR_TIMOUTEN_Msk                 /*!< Clock timeout enable */
4187 #define I2C_TIMEOUTR_TIMEOUTB_Pos    (16U)
4188 #define I2C_TIMEOUTR_TIMEOUTB_Msk    (0xFFFUL << I2C_TIMEOUTR_TIMEOUTB_Pos)    /*!< 0x0FFF0000 */
4189 #define I2C_TIMEOUTR_TIMEOUTB        I2C_TIMEOUTR_TIMEOUTB_Msk                 /*!< Bus timeout B*/
4190 #define I2C_TIMEOUTR_TEXTEN_Pos      (31U)
4191 #define I2C_TIMEOUTR_TEXTEN_Msk      (0x1UL << I2C_TIMEOUTR_TEXTEN_Pos)        /*!< 0x80000000 */
4192 #define I2C_TIMEOUTR_TEXTEN          I2C_TIMEOUTR_TEXTEN_Msk                   /*!< Extended clock timeout enable */
4193 
4194 /******************  Bit definition for I2C_ISR register  *********************/
4195 #define I2C_ISR_TXE_Pos              (0U)
4196 #define I2C_ISR_TXE_Msk              (0x1UL << I2C_ISR_TXE_Pos)                /*!< 0x00000001 */
4197 #define I2C_ISR_TXE                  I2C_ISR_TXE_Msk                           /*!< Transmit data register empty */
4198 #define I2C_ISR_TXIS_Pos             (1U)
4199 #define I2C_ISR_TXIS_Msk             (0x1UL << I2C_ISR_TXIS_Pos)               /*!< 0x00000002 */
4200 #define I2C_ISR_TXIS                 I2C_ISR_TXIS_Msk                          /*!< Transmit interrupt status */
4201 #define I2C_ISR_RXNE_Pos             (2U)
4202 #define I2C_ISR_RXNE_Msk             (0x1UL << I2C_ISR_RXNE_Pos)               /*!< 0x00000004 */
4203 #define I2C_ISR_RXNE                 I2C_ISR_RXNE_Msk                          /*!< Receive data register not empty */
4204 #define I2C_ISR_ADDR_Pos             (3U)
4205 #define I2C_ISR_ADDR_Msk             (0x1UL << I2C_ISR_ADDR_Pos)               /*!< 0x00000008 */
4206 #define I2C_ISR_ADDR                 I2C_ISR_ADDR_Msk                          /*!< Address matched (slave mode)*/
4207 #define I2C_ISR_NACKF_Pos            (4U)
4208 #define I2C_ISR_NACKF_Msk            (0x1UL << I2C_ISR_NACKF_Pos)              /*!< 0x00000010 */
4209 #define I2C_ISR_NACKF                I2C_ISR_NACKF_Msk                         /*!< NACK received flag */
4210 #define I2C_ISR_STOPF_Pos            (5U)
4211 #define I2C_ISR_STOPF_Msk            (0x1UL << I2C_ISR_STOPF_Pos)              /*!< 0x00000020 */
4212 #define I2C_ISR_STOPF                I2C_ISR_STOPF_Msk                         /*!< STOP detection flag */
4213 #define I2C_ISR_TC_Pos               (6U)
4214 #define I2C_ISR_TC_Msk               (0x1UL << I2C_ISR_TC_Pos)                 /*!< 0x00000040 */
4215 #define I2C_ISR_TC                   I2C_ISR_TC_Msk                            /*!< Transfer complete (master mode) */
4216 #define I2C_ISR_TCR_Pos              (7U)
4217 #define I2C_ISR_TCR_Msk              (0x1UL << I2C_ISR_TCR_Pos)                /*!< 0x00000080 */
4218 #define I2C_ISR_TCR                  I2C_ISR_TCR_Msk                           /*!< Transfer complete reload */
4219 #define I2C_ISR_BERR_Pos             (8U)
4220 #define I2C_ISR_BERR_Msk             (0x1UL << I2C_ISR_BERR_Pos)               /*!< 0x00000100 */
4221 #define I2C_ISR_BERR                 I2C_ISR_BERR_Msk                          /*!< Bus error */
4222 #define I2C_ISR_ARLO_Pos             (9U)
4223 #define I2C_ISR_ARLO_Msk             (0x1UL << I2C_ISR_ARLO_Pos)               /*!< 0x00000200 */
4224 #define I2C_ISR_ARLO                 I2C_ISR_ARLO_Msk                          /*!< Arbitration lost */
4225 #define I2C_ISR_OVR_Pos              (10U)
4226 #define I2C_ISR_OVR_Msk              (0x1UL << I2C_ISR_OVR_Pos)                /*!< 0x00000400 */
4227 #define I2C_ISR_OVR                  I2C_ISR_OVR_Msk                           /*!< Overrun/Underrun */
4228 #define I2C_ISR_PECERR_Pos           (11U)
4229 #define I2C_ISR_PECERR_Msk           (0x1UL << I2C_ISR_PECERR_Pos)             /*!< 0x00000800 */
4230 #define I2C_ISR_PECERR               I2C_ISR_PECERR_Msk                        /*!< PEC error in reception */
4231 #define I2C_ISR_TIMEOUT_Pos          (12U)
4232 #define I2C_ISR_TIMEOUT_Msk          (0x1UL << I2C_ISR_TIMEOUT_Pos)            /*!< 0x00001000 */
4233 #define I2C_ISR_TIMEOUT              I2C_ISR_TIMEOUT_Msk                       /*!< Timeout or Tlow detection flag */
4234 #define I2C_ISR_ALERT_Pos            (13U)
4235 #define I2C_ISR_ALERT_Msk            (0x1UL << I2C_ISR_ALERT_Pos)              /*!< 0x00002000 */
4236 #define I2C_ISR_ALERT                I2C_ISR_ALERT_Msk                         /*!< SMBus alert */
4237 #define I2C_ISR_BUSY_Pos             (15U)
4238 #define I2C_ISR_BUSY_Msk             (0x1UL << I2C_ISR_BUSY_Pos)               /*!< 0x00008000 */
4239 #define I2C_ISR_BUSY                 I2C_ISR_BUSY_Msk                          /*!< Bus busy */
4240 #define I2C_ISR_DIR_Pos              (16U)
4241 #define I2C_ISR_DIR_Msk              (0x1UL << I2C_ISR_DIR_Pos)                /*!< 0x00010000 */
4242 #define I2C_ISR_DIR                  I2C_ISR_DIR_Msk                           /*!< Transfer direction (slave mode) */
4243 #define I2C_ISR_ADDCODE_Pos          (17U)
4244 #define I2C_ISR_ADDCODE_Msk          (0x7FUL << I2C_ISR_ADDCODE_Pos)           /*!< 0x00FE0000 */
4245 #define I2C_ISR_ADDCODE              I2C_ISR_ADDCODE_Msk                       /*!< Address match code (slave mode) */
4246 
4247 /******************  Bit definition for I2C_ICR register  *********************/
4248 #define I2C_ICR_ADDRCF_Pos           (3U)
4249 #define I2C_ICR_ADDRCF_Msk           (0x1UL << I2C_ICR_ADDRCF_Pos)             /*!< 0x00000008 */
4250 #define I2C_ICR_ADDRCF               I2C_ICR_ADDRCF_Msk                        /*!< Address matched clear flag */
4251 #define I2C_ICR_NACKCF_Pos           (4U)
4252 #define I2C_ICR_NACKCF_Msk           (0x1UL << I2C_ICR_NACKCF_Pos)             /*!< 0x00000010 */
4253 #define I2C_ICR_NACKCF               I2C_ICR_NACKCF_Msk                        /*!< NACK clear flag */
4254 #define I2C_ICR_STOPCF_Pos           (5U)
4255 #define I2C_ICR_STOPCF_Msk           (0x1UL << I2C_ICR_STOPCF_Pos)             /*!< 0x00000020 */
4256 #define I2C_ICR_STOPCF               I2C_ICR_STOPCF_Msk                        /*!< STOP detection clear flag */
4257 #define I2C_ICR_BERRCF_Pos           (8U)
4258 #define I2C_ICR_BERRCF_Msk           (0x1UL << I2C_ICR_BERRCF_Pos)             /*!< 0x00000100 */
4259 #define I2C_ICR_BERRCF               I2C_ICR_BERRCF_Msk                        /*!< Bus error clear flag */
4260 #define I2C_ICR_ARLOCF_Pos           (9U)
4261 #define I2C_ICR_ARLOCF_Msk           (0x1UL << I2C_ICR_ARLOCF_Pos)             /*!< 0x00000200 */
4262 #define I2C_ICR_ARLOCF               I2C_ICR_ARLOCF_Msk                        /*!< Arbitration lost clear flag */
4263 #define I2C_ICR_OVRCF_Pos            (10U)
4264 #define I2C_ICR_OVRCF_Msk            (0x1UL << I2C_ICR_OVRCF_Pos)              /*!< 0x00000400 */
4265 #define I2C_ICR_OVRCF                I2C_ICR_OVRCF_Msk                         /*!< Overrun/Underrun clear flag */
4266 #define I2C_ICR_PECCF_Pos            (11U)
4267 #define I2C_ICR_PECCF_Msk            (0x1UL << I2C_ICR_PECCF_Pos)              /*!< 0x00000800 */
4268 #define I2C_ICR_PECCF                I2C_ICR_PECCF_Msk                         /*!< PAC error clear flag */
4269 #define I2C_ICR_TIMOUTCF_Pos         (12U)
4270 #define I2C_ICR_TIMOUTCF_Msk         (0x1UL << I2C_ICR_TIMOUTCF_Pos)           /*!< 0x00001000 */
4271 #define I2C_ICR_TIMOUTCF             I2C_ICR_TIMOUTCF_Msk                      /*!< Timeout clear flag */
4272 #define I2C_ICR_ALERTCF_Pos          (13U)
4273 #define I2C_ICR_ALERTCF_Msk          (0x1UL << I2C_ICR_ALERTCF_Pos)            /*!< 0x00002000 */
4274 #define I2C_ICR_ALERTCF              I2C_ICR_ALERTCF_Msk                       /*!< Alert clear flag */
4275 
4276 /******************  Bit definition for I2C_PECR register  *********************/
4277 #define I2C_PECR_PEC_Pos             (0U)
4278 #define I2C_PECR_PEC_Msk             (0xFFUL << I2C_PECR_PEC_Pos)              /*!< 0x000000FF */
4279 #define I2C_PECR_PEC                 I2C_PECR_PEC_Msk                          /*!< PEC register */
4280 
4281 /******************  Bit definition for I2C_RXDR register  *********************/
4282 #define I2C_RXDR_RXDATA_Pos          (0U)
4283 #define I2C_RXDR_RXDATA_Msk          (0xFFUL << I2C_RXDR_RXDATA_Pos)           /*!< 0x000000FF */
4284 #define I2C_RXDR_RXDATA              I2C_RXDR_RXDATA_Msk                       /*!< 8-bit receive data */
4285 
4286 /******************  Bit definition for I2C_TXDR register  *********************/
4287 #define I2C_TXDR_TXDATA_Pos          (0U)
4288 #define I2C_TXDR_TXDATA_Msk          (0xFFUL << I2C_TXDR_TXDATA_Pos)           /*!< 0x000000FF */
4289 #define I2C_TXDR_TXDATA              I2C_TXDR_TXDATA_Msk                       /*!< 8-bit transmit data */
4290 
4291 
4292 /******************************************************************************/
4293 /*                                                                            */
4294 /*                        Independent WATCHDOG (IWDG)                         */
4295 /*                                                                            */
4296 /******************************************************************************/
4297 /*******************  Bit definition for IWDG_KR register  ********************/
4298 #define IWDG_KR_KEY_Pos      (0U)
4299 #define IWDG_KR_KEY_Msk      (0xFFFFUL << IWDG_KR_KEY_Pos)                     /*!< 0x0000FFFF */
4300 #define IWDG_KR_KEY          IWDG_KR_KEY_Msk                                   /*!<Key value (write only, read 0000h)  */
4301 
4302 /*******************  Bit definition for IWDG_PR register  ********************/
4303 #define IWDG_PR_PR_Pos       (0U)
4304 #define IWDG_PR_PR_Msk       (0x7UL << IWDG_PR_PR_Pos)                         /*!< 0x00000007 */
4305 #define IWDG_PR_PR           IWDG_PR_PR_Msk                                    /*!<PR[2:0] (Prescaler divider)         */
4306 #define IWDG_PR_PR_0         (0x1UL << IWDG_PR_PR_Pos)                         /*!< 0x00000001 */
4307 #define IWDG_PR_PR_1         (0x2UL << IWDG_PR_PR_Pos)                         /*!< 0x00000002 */
4308 #define IWDG_PR_PR_2         (0x4UL << IWDG_PR_PR_Pos)                         /*!< 0x00000004 */
4309 
4310 /*******************  Bit definition for IWDG_RLR register  *******************/
4311 #define IWDG_RLR_RL_Pos      (0U)
4312 #define IWDG_RLR_RL_Msk      (0xFFFUL << IWDG_RLR_RL_Pos)                      /*!< 0x00000FFF */
4313 #define IWDG_RLR_RL          IWDG_RLR_RL_Msk                                   /*!<Watchdog counter reload value        */
4314 
4315 /*******************  Bit definition for IWDG_SR register  ********************/
4316 #define IWDG_SR_PVU_Pos      (0U)
4317 #define IWDG_SR_PVU_Msk      (0x1UL << IWDG_SR_PVU_Pos)                        /*!< 0x00000001 */
4318 #define IWDG_SR_PVU          IWDG_SR_PVU_Msk                                   /*!< Watchdog prescaler value update */
4319 #define IWDG_SR_RVU_Pos      (1U)
4320 #define IWDG_SR_RVU_Msk      (0x1UL << IWDG_SR_RVU_Pos)                        /*!< 0x00000002 */
4321 #define IWDG_SR_RVU          IWDG_SR_RVU_Msk                                   /*!< Watchdog counter reload value update */
4322 #define IWDG_SR_WVU_Pos      (2U)
4323 #define IWDG_SR_WVU_Msk      (0x1UL << IWDG_SR_WVU_Pos)                        /*!< 0x00000004 */
4324 #define IWDG_SR_WVU          IWDG_SR_WVU_Msk                                   /*!< Watchdog counter window value update */
4325 
4326 /*******************  Bit definition for IWDG_KR register  ********************/
4327 #define IWDG_WINR_WIN_Pos    (0U)
4328 #define IWDG_WINR_WIN_Msk    (0xFFFUL << IWDG_WINR_WIN_Pos)                    /*!< 0x00000FFF */
4329 #define IWDG_WINR_WIN        IWDG_WINR_WIN_Msk                                 /*!< Watchdog counter window value */
4330 
4331 
4332 /******************************************************************************/
4333 /*                                                                            */
4334 /*                        Power Control                                       */
4335 /*                                                                            */
4336 /******************************************************************************/
4337 /* Note: No specific macro feature on this device */
4338 
4339 /********************  Bit definition for PWR_CR1 register  ********************/
4340 #define PWR_CR1_LPMS_Pos          (0U)
4341 #define PWR_CR1_LPMS_Msk          (0x7UL << PWR_CR1_LPMS_Pos)                  /*!< 0x00000007 */
4342 #define PWR_CR1_LPMS              PWR_CR1_LPMS_Msk                             /*!< Low Power Mode Selection */
4343 #define PWR_CR1_LPMS_0            (0x1UL << PWR_CR1_LPMS_Pos)                  /*!< 0x00000001 */
4344 #define PWR_CR1_LPMS_1            (0x2UL << PWR_CR1_LPMS_Pos)                  /*!< 0x00000002 */
4345 #define PWR_CR1_FPD_STOP_Pos      (3U)
4346 #define PWR_CR1_FPD_STOP_Msk      (0x1UL << PWR_CR1_FPD_STOP_Pos)              /*!< 0x00000008 */
4347 #define PWR_CR1_FPD_STOP          PWR_CR1_FPD_STOP_Msk                         /*!< Flash power down mode during stop */
4348 #define PWR_CR1_FPD_LPRUN_Pos     (4U)
4349 #define PWR_CR1_FPD_LPRUN_Msk     (0x1UL << PWR_CR1_FPD_LPRUN_Pos)             /*!< 0x00000010 */
4350 #define PWR_CR1_FPD_LPRUN         PWR_CR1_FPD_LPRUN_Msk                        /*!< Flash power down mode during run */
4351 #define PWR_CR1_FPD_LPSLP_Pos     (5U)
4352 #define PWR_CR1_FPD_LPSLP_Msk     (0x1UL << PWR_CR1_FPD_LPSLP_Pos)             /*!< 0x00000020 */
4353 #define PWR_CR1_FPD_LPSLP         PWR_CR1_FPD_LPSLP_Msk                        /*!< Flash power down mode during sleep */
4354 #define PWR_CR1_DBP_Pos           (8U)
4355 #define PWR_CR1_DBP_Msk           (0x1UL << PWR_CR1_DBP_Pos)                   /*!< 0x00000100 */
4356 #define PWR_CR1_DBP               PWR_CR1_DBP_Msk                              /*!< Disable Backup Domain write protection */
4357 #define PWR_CR1_VOS_Pos           (9U)
4358 #define PWR_CR1_VOS_Msk           (0x3UL << PWR_CR1_VOS_Pos)                   /*!< 0x00000600 */
4359 #define PWR_CR1_VOS               PWR_CR1_VOS_Msk                              /*!< Voltage scaling */
4360 #define PWR_CR1_VOS_0             (0x1UL << PWR_CR1_VOS_Pos)                   /*!< Voltage scaling bit 0 */
4361 #define PWR_CR1_VOS_1             (0x2UL << PWR_CR1_VOS_Pos)                   /*!< Voltage scaling bit 1 */
4362 #define PWR_CR1_LPR_Pos           (14U)
4363 #define PWR_CR1_LPR_Msk           (0x1UL << PWR_CR1_LPR_Pos)                   /*!< 0x00004000 */
4364 #define PWR_CR1_LPR               PWR_CR1_LPR_Msk                              /*!< Regulator Low-Power Run mode */
4365 
4366 
4367 /********************  Bit definition for PWR_CR3 register  ********************/
4368 #define PWR_CR3_EWUP_Pos          (0U)
4369 #define PWR_CR3_EWUP_Msk          (0x3FUL << PWR_CR3_EWUP_Pos)                 /*!< 0x0000003F */
4370 #define PWR_CR3_EWUP              PWR_CR3_EWUP_Msk                             /*!< Enable all Wake-Up Pins  */
4371 #define PWR_CR3_EWUP1_Pos         (0U)
4372 #define PWR_CR3_EWUP1_Msk         (0x1UL << PWR_CR3_EWUP1_Pos)                 /*!< 0x00000001 */
4373 #define PWR_CR3_EWUP1             PWR_CR3_EWUP1_Msk                            /*!< Enable WKUP pin 1 */
4374 #define PWR_CR3_EWUP2_Pos         (1U)
4375 #define PWR_CR3_EWUP2_Msk         (0x1UL << PWR_CR3_EWUP2_Pos)                 /*!< 0x00000002 */
4376 #define PWR_CR3_EWUP2             PWR_CR3_EWUP2_Msk                            /*!< Enable WKUP pin 2 */
4377 #define PWR_CR3_EWUP3_Pos         (2U)
4378 #define PWR_CR3_EWUP3_Msk         (0x1UL << PWR_CR3_EWUP3_Pos)                 /*!< 0x00000004 */
4379 #define PWR_CR3_EWUP3             PWR_CR3_EWUP3_Msk                            /*!< Enable WKUP pin 3 */
4380 #define PWR_CR3_EWUP4_Pos         (3U)
4381 #define PWR_CR3_EWUP4_Msk         (0x1UL << PWR_CR3_EWUP4_Pos)                 /*!< 0x00000008 */
4382 #define PWR_CR3_EWUP4             PWR_CR3_EWUP4_Msk                            /*!< Enable WKUP pin 4 */
4383 #define PWR_CR3_EWUP5_Pos         (4U)
4384 #define PWR_CR3_EWUP5_Msk         (0x1UL << PWR_CR3_EWUP5_Pos)                 /*!< 0x00000010 */
4385 #define PWR_CR3_EWUP5             PWR_CR3_EWUP5_Msk                            /*!< Enable WKUP pin 5 */
4386 #define PWR_CR3_EWUP6_Pos         (5U)
4387 #define PWR_CR3_EWUP6_Msk         (0x1UL << PWR_CR3_EWUP6_Pos)                 /*!< 0x00000020 */
4388 #define PWR_CR3_EWUP6             PWR_CR3_EWUP6_Msk                            /*!< Enable WKUP pin 6 */
4389 #define PWR_CR3_APC_Pos           (10U)
4390 #define PWR_CR3_APC_Msk           (0x1UL << PWR_CR3_APC_Pos)                   /*!< 0x00000400 */
4391 #define PWR_CR3_APC               PWR_CR3_APC_Msk                              /*!< Apply pull-up and pull-down configuration */
4392 #define PWR_CR3_EIWUL_Pos         (15U)
4393 #define PWR_CR3_EIWUL_Msk         (0x1UL << PWR_CR3_EIWUL_Pos)                 /*!< 0x00008000 */
4394 #define PWR_CR3_EIWUL             PWR_CR3_EIWUL_Msk                            /*!< Enable Internal Wake-up line */
4395 
4396 /********************  Bit definition for PWR_CR4 register  ********************/
4397 #define PWR_CR4_WP_Pos            (0U)
4398 #define PWR_CR4_WP_Msk            (0x3FUL << PWR_CR4_WP_Pos)                   /*!< 0x0000003F */
4399 #define PWR_CR4_WP                PWR_CR4_WP_Msk                               /*!< all Wake-Up Pin polarity */
4400 #define PWR_CR4_WP1_Pos           (0U)
4401 #define PWR_CR4_WP1_Msk           (0x1UL << PWR_CR4_WP1_Pos)                   /*!< 0x00000001 */
4402 #define PWR_CR4_WP1               PWR_CR4_WP1_Msk                              /*!< Wake-Up Pin 1 polarity */
4403 #define PWR_CR4_WP2_Pos           (1U)
4404 #define PWR_CR4_WP2_Msk           (0x1UL << PWR_CR4_WP2_Pos)                   /*!< 0x00000002 */
4405 #define PWR_CR4_WP2               PWR_CR4_WP2_Msk                              /*!< Wake-Up Pin 2 polarity */
4406 #define PWR_CR4_WP3_Pos           (2U)
4407 #define PWR_CR4_WP3_Msk           (0x1UL << PWR_CR4_WP3_Pos)                   /*!< 0x00000004 */
4408 #define PWR_CR4_WP3               PWR_CR4_WP3_Msk                              /*!< Wake-Up Pin 3 polarity */
4409 #define PWR_CR4_WP4_Pos           (3U)
4410 #define PWR_CR4_WP4_Msk           (0x1UL << PWR_CR4_WP4_Pos)                   /*!< 0x00000008 */
4411 #define PWR_CR4_WP4               PWR_CR4_WP4_Msk                              /*!< Wake-Up Pin 4 polarity */
4412 #define PWR_CR4_WP5_Pos           (4U)
4413 #define PWR_CR4_WP5_Msk           (0x1UL << PWR_CR4_WP5_Pos)                   /*!< 0x00000010 */
4414 #define PWR_CR4_WP5               PWR_CR4_WP5_Msk                              /*!< Wake-Up Pin 5 polarity */
4415 #define PWR_CR4_WP6_Pos           (5U)
4416 #define PWR_CR4_WP6_Msk           (0x1UL << PWR_CR4_WP6_Pos)                   /*!< 0x00000020 */
4417 #define PWR_CR4_WP6               PWR_CR4_WP6_Msk                              /*!< Wake-Up Pin 6 polarity */
4418 #define PWR_CR4_VBE_Pos           (8U)
4419 #define PWR_CR4_VBE_Msk           (0x1UL << PWR_CR4_VBE_Pos)                   /*!< 0x00000100 */
4420 #define PWR_CR4_VBE               PWR_CR4_VBE_Msk                              /*!< VBAT Battery charging Enable  */
4421 #define PWR_CR4_VBRS_Pos          (9U)
4422 #define PWR_CR4_VBRS_Msk          (0x1UL << PWR_CR4_VBRS_Pos)                  /*!< 0x00000200 */
4423 #define PWR_CR4_VBRS              PWR_CR4_VBRS_Msk                             /*!< VBAT Battery charging Resistor Selection */
4424 
4425 /********************  Bit definition for PWR_SR1 register  ********************/
4426 #define PWR_SR1_WUF_Pos           (0U)
4427 #define PWR_SR1_WUF_Msk           (0x3FUL << PWR_SR1_WUF_Pos)                  /*!< 0x0000003F */
4428 #define PWR_SR1_WUF               PWR_SR1_WUF_Msk                              /*!< Wakeup Flags  */
4429 #define PWR_SR1_WUF1_Pos          (0U)
4430 #define PWR_SR1_WUF1_Msk          (0x1UL << PWR_SR1_WUF1_Pos)                  /*!< 0x00000001 */
4431 #define PWR_SR1_WUF1              PWR_SR1_WUF1_Msk                             /*!< Wakeup Flag 1 */
4432 #define PWR_SR1_WUF2_Pos          (1U)
4433 #define PWR_SR1_WUF2_Msk          (0x1UL << PWR_SR1_WUF2_Pos)                  /*!< 0x00000002 */
4434 #define PWR_SR1_WUF2              PWR_SR1_WUF2_Msk                             /*!< Wakeup Flag 2 */
4435 #define PWR_SR1_WUF3_Pos          (2U)
4436 #define PWR_SR1_WUF3_Msk          (0x1UL << PWR_SR1_WUF3_Pos)                  /*!< 0x00000004 */
4437 #define PWR_SR1_WUF3              PWR_SR1_WUF3_Msk                             /*!< Wakeup Flag 3 */
4438 #define PWR_SR1_WUF4_Pos          (3U)
4439 #define PWR_SR1_WUF4_Msk          (0x1UL << PWR_SR1_WUF4_Pos)                  /*!< 0x00000008 */
4440 #define PWR_SR1_WUF4              PWR_SR1_WUF4_Msk                             /*!< Wakeup Flag 4 */
4441 #define PWR_SR1_WUF5_Pos          (4U)
4442 #define PWR_SR1_WUF5_Msk          (0x1UL << PWR_SR1_WUF5_Pos)                  /*!< 0x00000010 */
4443 #define PWR_SR1_WUF5              PWR_SR1_WUF5_Msk                             /*!< Wakeup Flag 5 */
4444 #define PWR_SR1_WUF6_Pos          (5U)
4445 #define PWR_SR1_WUF6_Msk          (0x1UL << PWR_SR1_WUF6_Pos)                  /*!< 0x00000020 */
4446 #define PWR_SR1_WUF6              PWR_SR1_WUF6_Msk                             /*!< Wakeup Flag 6 */
4447 #define PWR_SR1_SBF_Pos           (8U)
4448 #define PWR_SR1_SBF_Msk           (0x1UL << PWR_SR1_SBF_Pos)                   /*!< 0x00000100 */
4449 #define PWR_SR1_SBF               PWR_SR1_SBF_Msk                              /*!< Standby Flag  */
4450 #define PWR_SR1_WUFI_Pos          (15U)
4451 #define PWR_SR1_WUFI_Msk          (0x1UL << PWR_SR1_WUFI_Pos)                  /*!< 0x00008000 */
4452 #define PWR_SR1_WUFI              PWR_SR1_WUFI_Msk                             /*!< Wakeup Flag Internal */
4453 
4454 /********************  Bit definition for PWR_SR2 register  ********************/
4455 #define PWR_SR2_FLASH_RDY_Pos     (7U)
4456 #define PWR_SR2_FLASH_RDY_Msk     (0x1UL << PWR_SR2_FLASH_RDY_Pos)             /*!< 0x00000080 */
4457 #define PWR_SR2_FLASH_RDY         PWR_SR2_FLASH_RDY_Msk                        /*!< Flash Ready */
4458 #define PWR_SR2_REGLPS_Pos        (8U)
4459 #define PWR_SR2_REGLPS_Msk        (0x1UL << PWR_SR2_REGLPS_Pos)                /*!< 0x00000100 */
4460 #define PWR_SR2_REGLPS            PWR_SR2_REGLPS_Msk                           /*!< Regulator Low Power started */
4461 #define PWR_SR2_REGLPF_Pos        (9U)
4462 #define PWR_SR2_REGLPF_Msk        (0x1UL << PWR_SR2_REGLPF_Pos)                /*!< 0x00000200 */
4463 #define PWR_SR2_REGLPF            PWR_SR2_REGLPF_Msk                           /*!< Regulator Low Power flag    */
4464 #define PWR_SR2_VOSF_Pos          (10U)
4465 #define PWR_SR2_VOSF_Msk          (0x1UL << PWR_SR2_VOSF_Pos)                  /*!< 0x00000400 */
4466 #define PWR_SR2_VOSF              PWR_SR2_VOSF_Msk                             /*!< Voltage Scaling Flag */
4467 
4468 /********************  Bit definition for PWR_SCR register  ********************/
4469 #define PWR_SCR_CWUF_Pos          (0U)
4470 #define PWR_SCR_CWUF_Msk          (0x3FUL << PWR_SCR_CWUF_Pos)                 /*!< 0x0000003F */
4471 #define PWR_SCR_CWUF              PWR_SCR_CWUF_Msk                             /*!< Clear Wake-up Flags  */
4472 #define PWR_SCR_CWUF1_Pos         (0U)
4473 #define PWR_SCR_CWUF1_Msk         (0x1UL << PWR_SCR_CWUF1_Pos)                 /*!< 0x00000001 */
4474 #define PWR_SCR_CWUF1             PWR_SCR_CWUF1_Msk                            /*!< Clear Wake-up Flag 1 */
4475 #define PWR_SCR_CWUF2_Pos         (1U)
4476 #define PWR_SCR_CWUF2_Msk         (0x1UL << PWR_SCR_CWUF2_Pos)                 /*!< 0x00000002 */
4477 #define PWR_SCR_CWUF2             PWR_SCR_CWUF2_Msk                            /*!< Clear Wake-up Flag 2 */
4478 #define PWR_SCR_CWUF3_Pos         (2U)
4479 #define PWR_SCR_CWUF3_Msk         (0x1UL << PWR_SCR_CWUF3_Pos)                 /*!< 0x00000004 */
4480 #define PWR_SCR_CWUF3             PWR_SCR_CWUF3_Msk                            /*!< Clear Wake-up Flag 3 */
4481 #define PWR_SCR_CWUF4_Pos         (3U)
4482 #define PWR_SCR_CWUF4_Msk         (0x1UL << PWR_SCR_CWUF4_Pos)                 /*!< 0x00000008 */
4483 #define PWR_SCR_CWUF4             PWR_SCR_CWUF4_Msk                            /*!< Clear Wake-up Flag 4 */
4484 #define PWR_SCR_CWUF5_Pos         (4U)
4485 #define PWR_SCR_CWUF5_Msk         (0x1UL << PWR_SCR_CWUF5_Pos)                 /*!< 0x00000010 */
4486 #define PWR_SCR_CWUF5             PWR_SCR_CWUF5_Msk                            /*!< Clear Wake-up Flag 5 */
4487 #define PWR_SCR_CWUF6_Pos         (5U)
4488 #define PWR_SCR_CWUF6_Msk         (0x1UL << PWR_SCR_CWUF6_Pos)                 /*!< 0x00000020 */
4489 #define PWR_SCR_CWUF6             PWR_SCR_CWUF6_Msk                            /*!< Clear Wake-up Flag 6 */
4490 #define PWR_SCR_CSBF_Pos          (8U)
4491 #define PWR_SCR_CSBF_Msk          (0x1UL << PWR_SCR_CSBF_Pos)                  /*!< 0x00000100 */
4492 #define PWR_SCR_CSBF              PWR_SCR_CSBF_Msk                             /*!< Clear Standby Flag  */
4493 
4494 /********************  Bit definition for PWR_PUCRA register  *****************/
4495 #define PWR_PUCRA_PU0_Pos         (0U)
4496 #define PWR_PUCRA_PU0_Msk         (0x1UL << PWR_PUCRA_PU0_Pos)                 /*!< 0x00000001 */
4497 #define PWR_PUCRA_PU0             PWR_PUCRA_PU0_Msk                            /*!< Pin PA0 Pull-Up set */
4498 #define PWR_PUCRA_PU1_Pos         (1U)
4499 #define PWR_PUCRA_PU1_Msk         (0x1UL << PWR_PUCRA_PU1_Pos)                 /*!< 0x00000002 */
4500 #define PWR_PUCRA_PU1             PWR_PUCRA_PU1_Msk                            /*!< Pin PA1 Pull-Up set */
4501 #define PWR_PUCRA_PU2_Pos         (2U)
4502 #define PWR_PUCRA_PU2_Msk         (0x1UL << PWR_PUCRA_PU2_Pos)                 /*!< 0x00000004 */
4503 #define PWR_PUCRA_PU2             PWR_PUCRA_PU2_Msk                            /*!< Pin PA2 Pull-Up set */
4504 #define PWR_PUCRA_PU3_Pos         (3U)
4505 #define PWR_PUCRA_PU3_Msk         (0x1UL << PWR_PUCRA_PU3_Pos)                 /*!< 0x00000008 */
4506 #define PWR_PUCRA_PU3             PWR_PUCRA_PU3_Msk                            /*!< Pin PA3 Pull-Up set */
4507 #define PWR_PUCRA_PU4_Pos         (4U)
4508 #define PWR_PUCRA_PU4_Msk         (0x1UL << PWR_PUCRA_PU4_Pos)                 /*!< 0x00000010 */
4509 #define PWR_PUCRA_PU4             PWR_PUCRA_PU4_Msk                            /*!< Pin PA4 Pull-Up set */
4510 #define PWR_PUCRA_PU5_Pos         (5U)
4511 #define PWR_PUCRA_PU5_Msk         (0x1UL << PWR_PUCRA_PU5_Pos)                 /*!< 0x00000020 */
4512 #define PWR_PUCRA_PU5             PWR_PUCRA_PU5_Msk                            /*!< Pin PA5 Pull-Up set */
4513 #define PWR_PUCRA_PU6_Pos         (6U)
4514 #define PWR_PUCRA_PU6_Msk         (0x1UL << PWR_PUCRA_PU6_Pos)                 /*!< 0x00000040 */
4515 #define PWR_PUCRA_PU6             PWR_PUCRA_PU6_Msk                            /*!< Pin PA6 Pull-Up set */
4516 #define PWR_PUCRA_PU7_Pos         (7U)
4517 #define PWR_PUCRA_PU7_Msk         (0x1UL << PWR_PUCRA_PU7_Pos)                 /*!< 0x00000080 */
4518 #define PWR_PUCRA_PU7             PWR_PUCRA_PU7_Msk                            /*!< Pin PA7 Pull-Up set */
4519 #define PWR_PUCRA_PU8_Pos         (8U)
4520 #define PWR_PUCRA_PU8_Msk         (0x1UL << PWR_PUCRA_PU8_Pos)                 /*!< 0x00000100 */
4521 #define PWR_PUCRA_PU8             PWR_PUCRA_PU8_Msk                            /*!< Pin PA8 Pull-Up set */
4522 #define PWR_PUCRA_PU9_Pos         (9U)
4523 #define PWR_PUCRA_PU9_Msk         (0x1UL << PWR_PUCRA_PU9_Pos)                 /*!< 0x00000200 */
4524 #define PWR_PUCRA_PU9             PWR_PUCRA_PU9_Msk                            /*!< Pin PA9 Pull-Up set */
4525 #define PWR_PUCRA_PU10_Pos        (10U)
4526 #define PWR_PUCRA_PU10_Msk        (0x1UL << PWR_PUCRA_PU10_Pos)                /*!< 0x00000400 */
4527 #define PWR_PUCRA_PU10            PWR_PUCRA_PU10_Msk                           /*!< Pin PA10 Pull-Up set */
4528 #define PWR_PUCRA_PU11_Pos        (11U)
4529 #define PWR_PUCRA_PU11_Msk        (0x1UL << PWR_PUCRA_PU11_Pos)                /*!< 0x00000800 */
4530 #define PWR_PUCRA_PU11            PWR_PUCRA_PU11_Msk                           /*!< Pin PA11 Pull-Up set */
4531 #define PWR_PUCRA_PU12_Pos        (12U)
4532 #define PWR_PUCRA_PU12_Msk        (0x1UL << PWR_PUCRA_PU12_Pos)                /*!< 0x00001000 */
4533 #define PWR_PUCRA_PU12            PWR_PUCRA_PU12_Msk                           /*!< Pin PA12 Pull-Up set */
4534 #define PWR_PUCRA_PU13_Pos        (13U)
4535 #define PWR_PUCRA_PU13_Msk        (0x1UL << PWR_PUCRA_PU13_Pos)                /*!< 0x00002000 */
4536 #define PWR_PUCRA_PU13            PWR_PUCRA_PU13_Msk                           /*!< Pin PA13 Pull-Up set */
4537 #define PWR_PUCRA_PU14_Pos        (14U)
4538 #define PWR_PUCRA_PU14_Msk        (0x1UL << PWR_PUCRA_PU14_Pos)                /*!< 0x00004000 */
4539 #define PWR_PUCRA_PU14            PWR_PUCRA_PU14_Msk                           /*!< Pin PA14 Pull-Up set */
4540 #define PWR_PUCRA_PU15_Pos        (15U)
4541 #define PWR_PUCRA_PU15_Msk        (0x1UL << PWR_PUCRA_PU15_Pos)                /*!< 0x00008000 */
4542 #define PWR_PUCRA_PU15            PWR_PUCRA_PU15_Msk                           /*!< Pin PA15 Pull-Up set */
4543 
4544 /********************  Bit definition for PWR_PDCRA register  *****************/
4545 #define PWR_PDCRA_PD0_Pos         (0U)
4546 #define PWR_PDCRA_PD0_Msk         (0x1UL << PWR_PDCRA_PD0_Pos)                 /*!< 0x00000001 */
4547 #define PWR_PDCRA_PD0             PWR_PDCRA_PD0_Msk                            /*!< Pin PA0 Pull-Down set */
4548 #define PWR_PDCRA_PD1_Pos         (1U)
4549 #define PWR_PDCRA_PD1_Msk         (0x1UL << PWR_PDCRA_PD1_Pos)                 /*!< 0x00000002 */
4550 #define PWR_PDCRA_PD1             PWR_PDCRA_PD1_Msk                            /*!< Pin PA1 Pull-Down set */
4551 #define PWR_PDCRA_PD2_Pos         (2U)
4552 #define PWR_PDCRA_PD2_Msk         (0x1UL << PWR_PDCRA_PD2_Pos)                 /*!< 0x00000004 */
4553 #define PWR_PDCRA_PD2             PWR_PDCRA_PD2_Msk                            /*!< Pin PA2 Pull-Down set */
4554 #define PWR_PDCRA_PD3_Pos         (3U)
4555 #define PWR_PDCRA_PD3_Msk         (0x1UL << PWR_PDCRA_PD3_Pos)                 /*!< 0x00000008 */
4556 #define PWR_PDCRA_PD3             PWR_PDCRA_PD3_Msk                            /*!< Pin PA3 Pull-Down set */
4557 #define PWR_PDCRA_PD4_Pos         (4U)
4558 #define PWR_PDCRA_PD4_Msk         (0x1UL << PWR_PDCRA_PD4_Pos)                 /*!< 0x00000010 */
4559 #define PWR_PDCRA_PD4             PWR_PDCRA_PD4_Msk                            /*!< Pin PA4 Pull-Down set */
4560 #define PWR_PDCRA_PD5_Pos         (5U)
4561 #define PWR_PDCRA_PD5_Msk         (0x1UL << PWR_PDCRA_PD5_Pos)                 /*!< 0x00000020 */
4562 #define PWR_PDCRA_PD5             PWR_PDCRA_PD5_Msk                            /*!< Pin PA5 Pull-Down set */
4563 #define PWR_PDCRA_PD6_Pos         (6U)
4564 #define PWR_PDCRA_PD6_Msk         (0x1UL << PWR_PDCRA_PD6_Pos)                 /*!< 0x00000040 */
4565 #define PWR_PDCRA_PD6             PWR_PDCRA_PD6_Msk                            /*!< Pin PA6 Pull-Down set */
4566 #define PWR_PDCRA_PD7_Pos         (7U)
4567 #define PWR_PDCRA_PD7_Msk         (0x1UL << PWR_PDCRA_PD7_Pos)                 /*!< 0x00000080 */
4568 #define PWR_PDCRA_PD7             PWR_PDCRA_PD7_Msk                            /*!< Pin PA7 Pull-Down set */
4569 #define PWR_PDCRA_PD8_Pos         (8U)
4570 #define PWR_PDCRA_PD8_Msk         (0x1UL << PWR_PDCRA_PD8_Pos)                 /*!< 0x00000100 */
4571 #define PWR_PDCRA_PD8             PWR_PDCRA_PD8_Msk                            /*!< Pin PA8 Pull-Down set */
4572 #define PWR_PDCRA_PD9_Pos         (9U)
4573 #define PWR_PDCRA_PD9_Msk         (0x1UL << PWR_PDCRA_PD9_Pos)                 /*!< 0x00000200 */
4574 #define PWR_PDCRA_PD9             PWR_PDCRA_PD9_Msk                            /*!< Pin PA9 Pull-Down set */
4575 #define PWR_PDCRA_PD10_Pos        (10U)
4576 #define PWR_PDCRA_PD10_Msk        (0x1UL << PWR_PDCRA_PD10_Pos)                /*!< 0x00000400 */
4577 #define PWR_PDCRA_PD10            PWR_PDCRA_PD10_Msk                           /*!< Pin PA10 Pull-Down set */
4578 #define PWR_PDCRA_PD11_Pos        (11U)
4579 #define PWR_PDCRA_PD11_Msk        (0x1UL << PWR_PDCRA_PD11_Pos)                /*!< 0x00000800 */
4580 #define PWR_PDCRA_PD11            PWR_PDCRA_PD11_Msk                           /*!< Pin PA11 Pull-Down set */
4581 #define PWR_PDCRA_PD12_Pos        (12U)
4582 #define PWR_PDCRA_PD12_Msk        (0x1UL << PWR_PDCRA_PD12_Pos)                /*!< 0x00001000 */
4583 #define PWR_PDCRA_PD12            PWR_PDCRA_PD12_Msk                           /*!< Pin PA12 Pull-Down set */
4584 #define PWR_PDCRA_PD13_Pos        (13U)
4585 #define PWR_PDCRA_PD13_Msk        (0x1UL << PWR_PDCRA_PD13_Pos)                /*!< 0x00002000 */
4586 #define PWR_PDCRA_PD13            PWR_PDCRA_PD13_Msk                           /*!< Pin PA13 Pull-Down set */
4587 #define PWR_PDCRA_PD14_Pos        (14U)
4588 #define PWR_PDCRA_PD14_Msk        (0x1UL << PWR_PDCRA_PD14_Pos)                /*!< 0x00004000 */
4589 #define PWR_PDCRA_PD14            PWR_PDCRA_PD14_Msk                           /*!< Pin PA14 Pull-Down set */
4590 #define PWR_PDCRA_PD15_Pos        (15U)
4591 #define PWR_PDCRA_PD15_Msk        (0x1UL << PWR_PDCRA_PD15_Pos)                /*!< 0x00008000 */
4592 #define PWR_PDCRA_PD15            PWR_PDCRA_PD15_Msk                           /*!< Pin PA15 Pull-Down set */
4593 
4594 /********************  Bit definition for PWR_PUCRB register  *****************/
4595 #define PWR_PUCRB_PU0_Pos         (0U)
4596 #define PWR_PUCRB_PU0_Msk         (0x1UL << PWR_PUCRB_PU0_Pos)                 /*!< 0x00000001 */
4597 #define PWR_PUCRB_PU0             PWR_PUCRB_PU0_Msk                            /*!< Pin PB0 Pull-Up set */
4598 #define PWR_PUCRB_PU1_Pos         (1U)
4599 #define PWR_PUCRB_PU1_Msk         (0x1UL << PWR_PUCRB_PU1_Pos)                 /*!< 0x00000002 */
4600 #define PWR_PUCRB_PU1             PWR_PUCRB_PU1_Msk                            /*!< Pin PB1 Pull-Up set */
4601 #define PWR_PUCRB_PU2_Pos         (2U)
4602 #define PWR_PUCRB_PU2_Msk         (0x1UL << PWR_PUCRB_PU2_Pos)                 /*!< 0x00000004 */
4603 #define PWR_PUCRB_PU2             PWR_PUCRB_PU2_Msk                            /*!< Pin PB2 Pull-Up set */
4604 #define PWR_PUCRB_PU3_Pos         (3U)
4605 #define PWR_PUCRB_PU3_Msk         (0x1UL << PWR_PUCRB_PU3_Pos)                 /*!< 0x00000008 */
4606 #define PWR_PUCRB_PU3             PWR_PUCRB_PU3_Msk                            /*!< Pin PB3 Pull-Up set */
4607 #define PWR_PUCRB_PU4_Pos         (4U)
4608 #define PWR_PUCRB_PU4_Msk         (0x1UL << PWR_PUCRB_PU4_Pos)                 /*!< 0x00000010 */
4609 #define PWR_PUCRB_PU4             PWR_PUCRB_PU4_Msk                            /*!< Pin PB4 Pull-Up set */
4610 #define PWR_PUCRB_PU5_Pos         (5U)
4611 #define PWR_PUCRB_PU5_Msk         (0x1UL << PWR_PUCRB_PU5_Pos)                 /*!< 0x00000020 */
4612 #define PWR_PUCRB_PU5             PWR_PUCRB_PU5_Msk                            /*!< Pin PB5 Pull-Up set */
4613 #define PWR_PUCRB_PU6_Pos         (6U)
4614 #define PWR_PUCRB_PU6_Msk         (0x1UL << PWR_PUCRB_PU6_Pos)                 /*!< 0x00000040 */
4615 #define PWR_PUCRB_PU6             PWR_PUCRB_PU6_Msk                            /*!< Pin PB6 Pull-Up set */
4616 #define PWR_PUCRB_PU7_Pos         (7U)
4617 #define PWR_PUCRB_PU7_Msk         (0x1UL << PWR_PUCRB_PU7_Pos)                 /*!< 0x00000080 */
4618 #define PWR_PUCRB_PU7             PWR_PUCRB_PU7_Msk                            /*!< Pin PB7 Pull-Up set */
4619 #define PWR_PUCRB_PU8_Pos         (8U)
4620 #define PWR_PUCRB_PU8_Msk         (0x1UL << PWR_PUCRB_PU8_Pos)                 /*!< 0x00000100 */
4621 #define PWR_PUCRB_PU8             PWR_PUCRB_PU8_Msk                            /*!< Pin PB8 Pull-Up set */
4622 #define PWR_PUCRB_PU9_Pos         (9U)
4623 #define PWR_PUCRB_PU9_Msk         (0x1UL << PWR_PUCRB_PU9_Pos)                 /*!< 0x00000200 */
4624 #define PWR_PUCRB_PU9             PWR_PUCRB_PU9_Msk                            /*!< Pin PB9 Pull-Up set */
4625 #define PWR_PUCRB_PU10_Pos        (10U)
4626 #define PWR_PUCRB_PU10_Msk        (0x1UL << PWR_PUCRB_PU10_Pos)                /*!< 0x00000400 */
4627 #define PWR_PUCRB_PU10            PWR_PUCRB_PU10_Msk                           /*!< Pin PB10 Pull-Up set */
4628 #define PWR_PUCRB_PU11_Pos        (11U)
4629 #define PWR_PUCRB_PU11_Msk        (0x1UL << PWR_PUCRB_PU11_Pos)                /*!< 0x00000800 */
4630 #define PWR_PUCRB_PU11            PWR_PUCRB_PU11_Msk                           /*!< Pin PB11 Pull-Up set */
4631 #define PWR_PUCRB_PU12_Pos        (12U)
4632 #define PWR_PUCRB_PU12_Msk        (0x1UL << PWR_PUCRB_PU12_Pos)                /*!< 0x00001000 */
4633 #define PWR_PUCRB_PU12            PWR_PUCRB_PU12_Msk                           /*!< Pin PB12 Pull-Up set */
4634 #define PWR_PUCRB_PU13_Pos        (13U)
4635 #define PWR_PUCRB_PU13_Msk        (0x1UL << PWR_PUCRB_PU13_Pos)                /*!< 0x00002000 */
4636 #define PWR_PUCRB_PU13            PWR_PUCRB_PU13_Msk                           /*!< Pin PB13 Pull-Up set */
4637 #define PWR_PUCRB_PU14_Pos        (14U)
4638 #define PWR_PUCRB_PU14_Msk        (0x1UL << PWR_PUCRB_PU14_Pos)                /*!< 0x00004000 */
4639 #define PWR_PUCRB_PU14            PWR_PUCRB_PU14_Msk                           /*!< Pin PB14 Pull-Up set */
4640 #define PWR_PUCRB_PU15_Pos        (15U)
4641 #define PWR_PUCRB_PU15_Msk        (0x1UL << PWR_PUCRB_PU15_Pos)                /*!< 0x00008000 */
4642 #define PWR_PUCRB_PU15            PWR_PUCRB_PU15_Msk                           /*!< Pin PB15 Pull-Up set */
4643 
4644 /********************  Bit definition for PWR_PDCRB register  *****************/
4645 #define PWR_PDCRB_PD0_Pos         (0U)
4646 #define PWR_PDCRB_PD0_Msk         (0x1UL << PWR_PDCRB_PD0_Pos)                 /*!< 0x00000001 */
4647 #define PWR_PDCRB_PD0             PWR_PDCRB_PD0_Msk                            /*!< Pin PB0 Pull-Down set */
4648 #define PWR_PDCRB_PD1_Pos         (1U)
4649 #define PWR_PDCRB_PD1_Msk         (0x1UL << PWR_PDCRB_PD1_Pos)                 /*!< 0x00000002 */
4650 #define PWR_PDCRB_PD1             PWR_PDCRB_PD1_Msk                            /*!< Pin PB1 Pull-Down set */
4651 #define PWR_PDCRB_PD2_Pos         (2U)
4652 #define PWR_PDCRB_PD2_Msk         (0x1UL << PWR_PDCRB_PD2_Pos)                 /*!< 0x00000004 */
4653 #define PWR_PDCRB_PD2             PWR_PDCRB_PD2_Msk                            /*!< Pin PB2 Pull-Down set */
4654 #define PWR_PDCRB_PD3_Pos         (3U)
4655 #define PWR_PDCRB_PD3_Msk         (0x1UL << PWR_PDCRB_PD3_Pos)                 /*!< 0x00000008 */
4656 #define PWR_PDCRB_PD3             PWR_PDCRB_PD3_Msk                            /*!< Pin PB3 Pull-Down set */
4657 #define PWR_PDCRB_PD4_Pos         (4U)
4658 #define PWR_PDCRB_PD4_Msk         (0x1UL << PWR_PDCRB_PD4_Pos)                 /*!< 0x00000010 */
4659 #define PWR_PDCRB_PD4             PWR_PDCRB_PD4_Msk                            /*!< Pin PB4 Pull-Down set */
4660 #define PWR_PDCRB_PD5_Pos         (5U)
4661 #define PWR_PDCRB_PD5_Msk         (0x1UL << PWR_PDCRB_PD5_Pos)                 /*!< 0x00000020 */
4662 #define PWR_PDCRB_PD5             PWR_PDCRB_PD5_Msk                            /*!< Pin PB5 Pull-Down set */
4663 #define PWR_PDCRB_PD6_Pos         (6U)
4664 #define PWR_PDCRB_PD6_Msk         (0x1UL << PWR_PDCRB_PD6_Pos)                 /*!< 0x00000040 */
4665 #define PWR_PDCRB_PD6             PWR_PDCRB_PD6_Msk                            /*!< Pin PB6 Pull-Down set */
4666 #define PWR_PDCRB_PD7_Pos         (7U)
4667 #define PWR_PDCRB_PD7_Msk         (0x1UL << PWR_PDCRB_PD7_Pos)                 /*!< 0x00000080 */
4668 #define PWR_PDCRB_PD7             PWR_PDCRB_PD7_Msk                            /*!< Pin PB7 Pull-Down set */
4669 #define PWR_PDCRB_PD8_Pos         (8U)
4670 #define PWR_PDCRB_PD8_Msk         (0x1UL << PWR_PDCRB_PD8_Pos)                 /*!< 0x00000100 */
4671 #define PWR_PDCRB_PD8             PWR_PDCRB_PD8_Msk                            /*!< Pin PB8 Pull-Down set */
4672 #define PWR_PDCRB_PD9_Pos         (9U)
4673 #define PWR_PDCRB_PD9_Msk         (0x1UL << PWR_PDCRB_PD9_Pos)                 /*!< 0x00000200 */
4674 #define PWR_PDCRB_PD9             PWR_PDCRB_PD9_Msk                            /*!< Pin PB9 Pull-Down set */
4675 #define PWR_PDCRB_PD10_Pos        (10U)
4676 #define PWR_PDCRB_PD10_Msk        (0x1UL << PWR_PDCRB_PD10_Pos)                /*!< 0x00000400 */
4677 #define PWR_PDCRB_PD10            PWR_PDCRB_PD10_Msk                           /*!< Pin PB10 Pull-Down set */
4678 #define PWR_PDCRB_PD11_Pos        (11U)
4679 #define PWR_PDCRB_PD11_Msk        (0x1UL << PWR_PDCRB_PD11_Pos)                /*!< 0x00000800 */
4680 #define PWR_PDCRB_PD11            PWR_PDCRB_PD11_Msk                           /*!< Pin PB11 Pull-Down set */
4681 #define PWR_PDCRB_PD12_Pos        (12U)
4682 #define PWR_PDCRB_PD12_Msk        (0x1UL << PWR_PDCRB_PD12_Pos)                /*!< 0x00001000 */
4683 #define PWR_PDCRB_PD12            PWR_PDCRB_PD12_Msk                           /*!< Pin PB12 Pull-Down set */
4684 #define PWR_PDCRB_PD13_Pos        (13U)
4685 #define PWR_PDCRB_PD13_Msk        (0x1UL << PWR_PDCRB_PD13_Pos)                /*!< 0x00002000 */
4686 #define PWR_PDCRB_PD13            PWR_PDCRB_PD13_Msk                           /*!< Pin PB13 Pull-Down set */
4687 #define PWR_PDCRB_PD14_Pos        (14U)
4688 #define PWR_PDCRB_PD14_Msk        (0x1UL << PWR_PDCRB_PD14_Pos)                /*!< 0x00004000 */
4689 #define PWR_PDCRB_PD14            PWR_PDCRB_PD14_Msk                           /*!< Pin PB14 Pull-Down set */
4690 #define PWR_PDCRB_PD15_Pos        (15U)
4691 #define PWR_PDCRB_PD15_Msk        (0x1UL << PWR_PDCRB_PD15_Pos)                /*!< 0x00008000 */
4692 #define PWR_PDCRB_PD15            PWR_PDCRB_PD15_Msk                           /*!< Pin PB15 Pull-Down set */
4693 
4694 /********************  Bit definition for PWR_PUCRC register  *****************/
4695 #define PWR_PUCRC_PU0_Pos         (0U)
4696 #define PWR_PUCRC_PU0_Msk         (0x1UL << PWR_PUCRC_PU0_Pos)                 /*!< 0x00000001 */
4697 #define PWR_PUCRC_PU0             PWR_PUCRC_PU0_Msk                            /*!< Pin PC0 Pull-Up set */
4698 #define PWR_PUCRC_PU1_Pos         (1U)
4699 #define PWR_PUCRC_PU1_Msk         (0x1UL << PWR_PUCRC_PU1_Pos)                 /*!< 0x00000002 */
4700 #define PWR_PUCRC_PU1             PWR_PUCRC_PU1_Msk                            /*!< Pin PC1 Pull-Up set */
4701 #define PWR_PUCRC_PU2_Pos         (2U)
4702 #define PWR_PUCRC_PU2_Msk         (0x1UL << PWR_PUCRC_PU2_Pos)                 /*!< 0x00000004 */
4703 #define PWR_PUCRC_PU2             PWR_PUCRC_PU2_Msk                            /*!< Pin PC2 Pull-Up set */
4704 #define PWR_PUCRC_PU3_Pos         (3U)
4705 #define PWR_PUCRC_PU3_Msk         (0x1UL << PWR_PUCRC_PU3_Pos)                 /*!< 0x00000008 */
4706 #define PWR_PUCRC_PU3             PWR_PUCRC_PU3_Msk                            /*!< Pin PC3 Pull-Up set */
4707 #define PWR_PUCRC_PU4_Pos         (4U)
4708 #define PWR_PUCRC_PU4_Msk         (0x1UL << PWR_PUCRC_PU4_Pos)                 /*!< 0x00000010 */
4709 #define PWR_PUCRC_PU4             PWR_PUCRC_PU4_Msk                            /*!< Pin PC4 Pull-Up set */
4710 #define PWR_PUCRC_PU5_Pos         (5U)
4711 #define PWR_PUCRC_PU5_Msk         (0x1UL << PWR_PUCRC_PU5_Pos)                 /*!< 0x00000020 */
4712 #define PWR_PUCRC_PU5             PWR_PUCRC_PU5_Msk                            /*!< Pin PC5 Pull-Up set */
4713 #define PWR_PUCRC_PU6_Pos         (6U)
4714 #define PWR_PUCRC_PU6_Msk         (0x1UL << PWR_PUCRC_PU6_Pos)                 /*!< 0x00000040 */
4715 #define PWR_PUCRC_PU6             PWR_PUCRC_PU6_Msk                            /*!< Pin PC6 Pull-Up set */
4716 #define PWR_PUCRC_PU7_Pos         (7U)
4717 #define PWR_PUCRC_PU7_Msk         (0x1UL << PWR_PUCRC_PU7_Pos)                 /*!< 0x00000080 */
4718 #define PWR_PUCRC_PU7             PWR_PUCRC_PU7_Msk                            /*!< Pin PC7 Pull-Up set */
4719 #define PWR_PUCRC_PU8_Pos         (8U)
4720 #define PWR_PUCRC_PU8_Msk         (0x1UL << PWR_PUCRC_PU8_Pos)                 /*!< 0x00000100 */
4721 #define PWR_PUCRC_PU8             PWR_PUCRC_PU8_Msk                            /*!< Pin PC8 Pull-Up set */
4722 #define PWR_PUCRC_PU9_Pos         (9U)
4723 #define PWR_PUCRC_PU9_Msk         (0x1UL << PWR_PUCRC_PU9_Pos)                 /*!< 0x00000200 */
4724 #define PWR_PUCRC_PU9             PWR_PUCRC_PU9_Msk                            /*!< Pin PC9 Pull-Up set */
4725 #define PWR_PUCRC_PU10_Pos        (10U)
4726 #define PWR_PUCRC_PU10_Msk        (0x1UL << PWR_PUCRC_PU10_Pos)                /*!< 0x00000400 */
4727 #define PWR_PUCRC_PU10            PWR_PUCRC_PU10_Msk                           /*!< Pin PC10 Pull-Up set */
4728 #define PWR_PUCRC_PU11_Pos        (11U)
4729 #define PWR_PUCRC_PU11_Msk        (0x1UL << PWR_PUCRC_PU11_Pos)                /*!< 0x00000800 */
4730 #define PWR_PUCRC_PU11            PWR_PUCRC_PU11_Msk                           /*!< Pin PC11 Pull-Up set */
4731 #define PWR_PUCRC_PU12_Pos        (12U)
4732 #define PWR_PUCRC_PU12_Msk        (0x1UL << PWR_PUCRC_PU12_Pos)                /*!< 0x00001000 */
4733 #define PWR_PUCRC_PU12            PWR_PUCRC_PU12_Msk                           /*!< Pin PC12 Pull-Up set */
4734 #define PWR_PUCRC_PU13_Pos        (13U)
4735 #define PWR_PUCRC_PU13_Msk        (0x1UL << PWR_PUCRC_PU13_Pos)                /*!< 0x00002000 */
4736 #define PWR_PUCRC_PU13            PWR_PUCRC_PU13_Msk                           /*!< Pin PC13 Pull-Up set */
4737 #define PWR_PUCRC_PU14_Pos        (14U)
4738 #define PWR_PUCRC_PU14_Msk        (0x1UL << PWR_PUCRC_PU14_Pos)                /*!< 0x00004000 */
4739 #define PWR_PUCRC_PU14            PWR_PUCRC_PU14_Msk                           /*!< Pin PC14 Pull-Up set */
4740 #define PWR_PUCRC_PU15_Pos        (15U)
4741 #define PWR_PUCRC_PU15_Msk        (0x1UL << PWR_PUCRC_PU15_Pos)                /*!< 0x00008000 */
4742 #define PWR_PUCRC_PU15            PWR_PUCRC_PU15_Msk                           /*!< Pin PC15 Pull-Up set */
4743 
4744 /********************  Bit definition for PWR_PDCRC register  *****************/
4745 #define PWR_PDCRC_PD0_Pos         (0U)
4746 #define PWR_PDCRC_PD0_Msk         (0x1UL << PWR_PDCRC_PD0_Pos)                 /*!< 0x00000001 */
4747 #define PWR_PDCRC_PD0             PWR_PDCRC_PD0_Msk                            /*!< Pin PC0 Pull-Down set */
4748 #define PWR_PDCRC_PD1_Pos         (1U)
4749 #define PWR_PDCRC_PD1_Msk         (0x1UL << PWR_PDCRC_PD1_Pos)                 /*!< 0x00000002 */
4750 #define PWR_PDCRC_PD1             PWR_PDCRC_PD1_Msk                            /*!< Pin PC1 Pull-Down set */
4751 #define PWR_PDCRC_PD2_Pos         (2U)
4752 #define PWR_PDCRC_PD2_Msk         (0x1UL << PWR_PDCRC_PD2_Pos)                 /*!< 0x00000004 */
4753 #define PWR_PDCRC_PD2             PWR_PDCRC_PD2_Msk                            /*!< Pin PC2 Pull-Down set */
4754 #define PWR_PDCRC_PD3_Pos         (3U)
4755 #define PWR_PDCRC_PD3_Msk         (0x1UL << PWR_PDCRC_PD3_Pos)                 /*!< 0x00000008 */
4756 #define PWR_PDCRC_PD3             PWR_PDCRC_PD3_Msk                            /*!< Pin PC3 Pull-Down set */
4757 #define PWR_PDCRC_PD4_Pos         (4U)
4758 #define PWR_PDCRC_PD4_Msk         (0x1UL << PWR_PDCRC_PD4_Pos)                 /*!< 0x00000010 */
4759 #define PWR_PDCRC_PD4             PWR_PDCRC_PD4_Msk                            /*!< Pin PC4 Pull-Down set */
4760 #define PWR_PDCRC_PD5_Pos         (5U)
4761 #define PWR_PDCRC_PD5_Msk         (0x1UL << PWR_PDCRC_PD5_Pos)                 /*!< 0x00000020 */
4762 #define PWR_PDCRC_PD5             PWR_PDCRC_PD5_Msk                            /*!< Pin PC5 Pull-Down set */
4763 #define PWR_PDCRC_PD6_Pos         (6U)
4764 #define PWR_PDCRC_PD6_Msk         (0x1UL << PWR_PDCRC_PD6_Pos)                 /*!< 0x00000040 */
4765 #define PWR_PDCRC_PD6             PWR_PDCRC_PD6_Msk                            /*!< Pin PC6 Pull-Down set */
4766 #define PWR_PDCRC_PD7_Pos         (7U)
4767 #define PWR_PDCRC_PD7_Msk         (0x1UL << PWR_PDCRC_PD7_Pos)                 /*!< 0x00000080 */
4768 #define PWR_PDCRC_PD7             PWR_PDCRC_PD7_Msk                            /*!< Pin PC7 Pull-Down set */
4769 #define PWR_PDCRC_PD8_Pos         (8U)
4770 #define PWR_PDCRC_PD8_Msk         (0x1UL << PWR_PDCRC_PD8_Pos)                 /*!< 0x00000100 */
4771 #define PWR_PDCRC_PD8             PWR_PDCRC_PD8_Msk                            /*!< Pin PC8 Pull-Down set */
4772 #define PWR_PDCRC_PD9_Pos         (9U)
4773 #define PWR_PDCRC_PD9_Msk         (0x1UL << PWR_PDCRC_PD9_Pos)                 /*!< 0x00000200 */
4774 #define PWR_PDCRC_PD9             PWR_PDCRC_PD9_Msk                            /*!< Pin PC9 Pull-Down set */
4775 #define PWR_PDCRC_PD10_Pos        (10U)
4776 #define PWR_PDCRC_PD10_Msk        (0x1UL << PWR_PDCRC_PD10_Pos)                /*!< 0x00000400 */
4777 #define PWR_PDCRC_PD10            PWR_PDCRC_PD10_Msk                           /*!< Pin PC10 Pull-Down set */
4778 #define PWR_PDCRC_PD11_Pos        (11U)
4779 #define PWR_PDCRC_PD11_Msk        (0x1UL << PWR_PDCRC_PD11_Pos)                /*!< 0x00000800 */
4780 #define PWR_PDCRC_PD11            PWR_PDCRC_PD11_Msk                           /*!< Pin PC11 Pull-Down set */
4781 #define PWR_PDCRC_PD12_Pos        (12U)
4782 #define PWR_PDCRC_PD12_Msk        (0x1UL << PWR_PDCRC_PD12_Pos)                /*!< 0x00001000 */
4783 #define PWR_PDCRC_PD12            PWR_PDCRC_PD12_Msk                           /*!< Pin PC12 Pull-Down set */
4784 #define PWR_PDCRC_PD13_Pos        (13U)
4785 #define PWR_PDCRC_PD13_Msk        (0x1UL << PWR_PDCRC_PD13_Pos)                /*!< 0x00002000 */
4786 #define PWR_PDCRC_PD13            PWR_PDCRC_PD13_Msk                           /*!< Pin PC13 Pull-Down set */
4787 #define PWR_PDCRC_PD14_Pos        (14U)
4788 #define PWR_PDCRC_PD14_Msk        (0x1UL << PWR_PDCRC_PD14_Pos)                /*!< 0x00004000 */
4789 #define PWR_PDCRC_PD14            PWR_PDCRC_PD14_Msk                           /*!< Pin PC14 Pull-Down set */
4790 #define PWR_PDCRC_PD15_Pos        (15U)
4791 #define PWR_PDCRC_PD15_Msk        (0x1UL << PWR_PDCRC_PD15_Pos)                /*!< 0x00008000 */
4792 #define PWR_PDCRC_PD15            PWR_PDCRC_PD15_Msk                           /*!< Pin PC15 Pull-Down set */
4793 
4794 /********************  Bit definition for PWR_PUCRD register  *****************/
4795 #define PWR_PUCRD_PU0_Pos         (0U)
4796 #define PWR_PUCRD_PU0_Msk         (0x1UL << PWR_PUCRD_PU0_Pos)                 /*!< 0x00000001 */
4797 #define PWR_PUCRD_PU0             PWR_PUCRD_PU0_Msk                            /*!< Pin PD0 Pull-Up set */
4798 #define PWR_PUCRD_PU1_Pos         (1U)
4799 #define PWR_PUCRD_PU1_Msk         (0x1UL << PWR_PUCRD_PU1_Pos)                 /*!< 0x00000002 */
4800 #define PWR_PUCRD_PU1             PWR_PUCRD_PU1_Msk                            /*!< Pin PD1 Pull-Up set */
4801 #define PWR_PUCRD_PU2_Pos         (2U)
4802 #define PWR_PUCRD_PU2_Msk         (0x1UL << PWR_PUCRD_PU2_Pos)                 /*!< 0x00000004 */
4803 #define PWR_PUCRD_PU2             PWR_PUCRD_PU2_Msk                            /*!< Pin PD2 Pull-Up set */
4804 #define PWR_PUCRD_PU3_Pos         (3U)
4805 #define PWR_PUCRD_PU3_Msk         (0x1UL << PWR_PUCRD_PU3_Pos)                 /*!< 0x00000008 */
4806 #define PWR_PUCRD_PU3             PWR_PUCRD_PU3_Msk                            /*!< Pin PD3 Pull-Up set */
4807 #define PWR_PUCRD_PU4_Pos         (4U)
4808 #define PWR_PUCRD_PU4_Msk         (0x1UL << PWR_PUCRD_PU4_Pos)                 /*!< 0x00000010 */
4809 #define PWR_PUCRD_PU4             PWR_PUCRD_PU4_Msk                            /*!< Pin PD4 Pull-Up set */
4810 #define PWR_PUCRD_PU5_Pos         (5U)
4811 #define PWR_PUCRD_PU5_Msk         (0x1UL << PWR_PUCRD_PU5_Pos)                 /*!< 0x00000020 */
4812 #define PWR_PUCRD_PU5             PWR_PUCRD_PU5_Msk                            /*!< Pin PD5 Pull-Up set */
4813 #define PWR_PUCRD_PU6_Pos         (6U)
4814 #define PWR_PUCRD_PU6_Msk         (0x1UL << PWR_PUCRD_PU6_Pos)                 /*!< 0x00000040 */
4815 #define PWR_PUCRD_PU6             PWR_PUCRD_PU6_Msk                            /*!< Pin PD6 Pull-Up set */
4816 #define PWR_PUCRD_PU8_Pos         (8U)
4817 #define PWR_PUCRD_PU8_Msk         (0x1UL << PWR_PUCRD_PU8_Pos)                 /*!< 0x00000100 */
4818 #define PWR_PUCRD_PU8             PWR_PUCRD_PU8_Msk                            /*!< Pin PD8 Pull-Up set */
4819 #define PWR_PUCRD_PU9_Pos         (9U)
4820 #define PWR_PUCRD_PU9_Msk         (0x1UL << PWR_PUCRD_PU9_Pos)                 /*!< 0x00000200 */
4821 #define PWR_PUCRD_PU9             PWR_PUCRD_PU9_Msk                            /*!< Pin PD9 Pull-Up set */
4822 #define PWR_PUCRD_PD10_Pos        (10U)
4823 #define PWR_PUCRD_PD10_Msk        (0x1UL << PWR_PUCRD_PD10_Pos)                /*!< 0x00000400 */
4824 #define PWR_PUCRD_PD10            PWR_PUCRD_PD10_Msk                           /*!< Pin PD10 Pull-Up set */
4825 #define PWR_PUCRD_PD11_Pos        (11U)
4826 #define PWR_PUCRD_PD11_Msk        (0x1UL << PWR_PUCRD_PD11_Pos)                /*!< 0x00000800 */
4827 #define PWR_PUCRD_PD11            PWR_PUCRD_PD11_Msk                           /*!< Pin PD11 Pull-Up set */
4828 #define PWR_PUCRD_PD12_Pos        (12U)
4829 #define PWR_PUCRD_PD12_Msk        (0x1UL << PWR_PUCRD_PD12_Pos)                /*!< 0x00001000 */
4830 #define PWR_PUCRD_PD12            PWR_PUCRD_PD12_Msk                           /*!< Pin PD12 Pull-Up set */
4831 #define PWR_PUCRD_PD13_Pos        (13U)
4832 #define PWR_PUCRD_PD13_Msk        (0x1UL << PWR_PUCRD_PD13_Pos)                /*!< 0x00002000 */
4833 #define PWR_PUCRD_PD13            PWR_PUCRD_PD13_Msk                           /*!< Pin PD13 Pull-Up set */
4834 #define PWR_PUCRD_PD14_Pos        (14U)
4835 #define PWR_PUCRD_PD14_Msk        (0x1UL << PWR_PUCRD_PD14_Pos)                /*!< 0x00004000 */
4836 #define PWR_PUCRD_PD14            PWR_PUCRD_PD14_Msk                           /*!< Pin PD14 Pull-Up set */
4837 #define PWR_PUCRD_PD15_Pos        (15U)
4838 #define PWR_PUCRD_PD15_Msk        (0x1UL << PWR_PUCRD_PD15_Pos)                /*!< 0x00008000 */
4839 #define PWR_PUCRD_PD15            PWR_PUCRD_PD15_Msk                           /*!< Pin PD15 Pull-Up set */
4840 
4841 /********************  Bit definition for PWR_PDCRD register  *****************/
4842 #define PWR_PDCRD_PD0_Pos         (0U)
4843 #define PWR_PDCRD_PD0_Msk         (0x1UL << PWR_PDCRD_PD0_Pos)                 /*!< 0x00000001 */
4844 #define PWR_PDCRD_PD0             PWR_PDCRD_PD0_Msk                            /*!< Pin PD0 Pull-Down set */
4845 #define PWR_PDCRD_PD1_Pos         (1U)
4846 #define PWR_PDCRD_PD1_Msk         (0x1UL << PWR_PDCRD_PD1_Pos)                 /*!< 0x00000002 */
4847 #define PWR_PDCRD_PD1             PWR_PDCRD_PD1_Msk                            /*!< Pin PD1 Pull-Down set */
4848 #define PWR_PDCRD_PD2_Pos         (2U)
4849 #define PWR_PDCRD_PD2_Msk         (0x1UL << PWR_PDCRD_PD2_Pos)                 /*!< 0x00000004 */
4850 #define PWR_PDCRD_PD2             PWR_PDCRD_PD2_Msk                            /*!< Pin PD2 Pull-Down set */
4851 #define PWR_PDCRD_PD3_Pos         (3U)
4852 #define PWR_PDCRD_PD3_Msk         (0x1UL << PWR_PDCRD_PD3_Pos)                 /*!< 0x00000008 */
4853 #define PWR_PDCRD_PD3             PWR_PDCRD_PD3_Msk                            /*!< Pin PD3 Pull-Down set */
4854 #define PWR_PDCRD_PD4_Pos         (4U)
4855 #define PWR_PDCRD_PD4_Msk         (0x1UL << PWR_PDCRD_PD4_Pos)                 /*!< 0x00000010 */
4856 #define PWR_PDCRD_PD4             PWR_PDCRD_PD4_Msk                            /*!< Pin PD4 Pull-Down set */
4857 #define PWR_PDCRD_PD5_Pos         (5U)
4858 #define PWR_PDCRD_PD5_Msk         (0x1UL << PWR_PDCRD_PD5_Pos)                 /*!< 0x00000020 */
4859 #define PWR_PDCRD_PD5             PWR_PDCRD_PD5_Msk                            /*!< Pin PD5 Pull-Down set */
4860 #define PWR_PDCRD_PD6_Pos         (6U)
4861 #define PWR_PDCRD_PD6_Msk         (0x1UL << PWR_PDCRD_PD6_Pos)                 /*!< 0x00000040 */
4862 #define PWR_PDCRD_PD6             PWR_PDCRD_PD6_Msk                            /*!< Pin PD6 Pull-Down set */
4863 #define PWR_PDCRD_PD8_Pos         (8U)
4864 #define PWR_PDCRD_PD8_Msk         (0x1UL << PWR_PDCRD_PD8_Pos)                 /*!< 0x00000100 */
4865 #define PWR_PDCRD_PD8             PWR_PDCRD_PD8_Msk                            /*!< Pin PD8 Pull-Down set */
4866 #define PWR_PDCRD_PD9_Pos         (9U)
4867 #define PWR_PDCRD_PD9_Msk         (0x1UL << PWR_PDCRD_PD9_Pos)                 /*!< 0x00000200 */
4868 #define PWR_PDCRD_PD9             PWR_PDCRD_PD9_Msk                            /*!< Pin PD9 Pull-Down set */
4869 #define PWR_PDCRD_PD10_Pos        (10U)
4870 #define PWR_PDCRD_PD10_Msk        (0x1UL << PWR_PDCRD_PD10_Pos)                /*!< 0x00000400 */
4871 #define PWR_PDCRD_PD10            PWR_PDCRD_PD10_Msk                           /*!< Pin PD10 Pull-Down set */
4872 #define PWR_PDCRD_PD11_Pos        (11U)
4873 #define PWR_PDCRD_PD11_Msk        (0x1UL << PWR_PDCRD_PD11_Pos)                /*!< 0x00000800 */
4874 #define PWR_PDCRD_PD11            PWR_PDCRD_PD11_Msk                           /*!< Pin PD11 Pull-Down set */
4875 #define PWR_PDCRD_PD12_Pos        (12U)
4876 #define PWR_PDCRD_PD12_Msk        (0x1UL << PWR_PDCRD_PD12_Pos)                /*!< 0x00001000 */
4877 #define PWR_PDCRD_PD12            PWR_PDCRD_PD12_Msk                           /*!< Pin PD12 Pull-Down set */
4878 #define PWR_PDCRD_PD13_Pos        (13U)
4879 #define PWR_PDCRD_PD13_Msk        (0x1UL << PWR_PDCRD_PD13_Pos)                /*!< 0x00002000 */
4880 #define PWR_PDCRD_PD13            PWR_PDCRD_PD13_Msk                           /*!< Pin PD13 Pull-Down set */
4881 #define PWR_PDCRD_PD14_Pos        (14U)
4882 #define PWR_PDCRD_PD14_Msk        (0x1UL << PWR_PDCRD_PD14_Pos)                /*!< 0x00004000 */
4883 #define PWR_PDCRD_PD14            PWR_PDCRD_PD14_Msk                           /*!< Pin PD14 Pull-Down set */
4884 #define PWR_PDCRD_PD15_Pos        (15U)
4885 #define PWR_PDCRD_PD15_Msk        (0x1UL << PWR_PDCRD_PD15_Pos)                /*!< 0x00008000 */
4886 #define PWR_PDCRD_PD15            PWR_PDCRD_PD15_Msk                           /*!< Pin PD15 Pull-Down set */
4887 /********************  Bit definition for PWR_PUCRE register  *****************/
4888 #define PWR_PUCRE_PU0_Pos         (0U)
4889 #define PWR_PUCRE_PU0_Msk         (0x1UL << PWR_PUCRE_PU0_Pos)                 /*!< 0x00000001 */
4890 #define PWR_PUCRE_PU0             PWR_PUCRE_PU0_Msk                            /*!< Pin PE0 Pull-Up set */
4891 #define PWR_PUCRE_PU1_Pos         (1U)
4892 #define PWR_PUCRE_PU1_Msk         (0x1UL << PWR_PUCRE_PU1_Pos)                 /*!< 0x00000002 */
4893 #define PWR_PUCRE_PU1             PWR_PUCRE_PU1_Msk                            /*!< Pin PE1 Pull-Up set */
4894 #define PWR_PUCRE_PU2_Pos         (2U)
4895 #define PWR_PUCRE_PU2_Msk         (0x1UL << PWR_PUCRE_PU2_Pos)                 /*!< 0x00000004 */
4896 #define PWR_PUCRE_PU2             PWR_PUCRE_PU2_Msk                            /*!< Pin PE2 Pull-Up set */
4897 #define PWR_PUCRE_PU3_Pos         (3U)
4898 #define PWR_PUCRE_PU3_Msk         (0x1UL << PWR_PUCRE_PU3_Pos)                 /*!< 0x00000008 */
4899 #define PWR_PUCRE_PU3             PWR_PUCRE_PU3_Msk                            /*!< Pin PE3 Pull-Up set */
4900 #define PWR_PUCRE_PU4_Pos         (4U)
4901 #define PWR_PUCRE_PU4_Msk         (0x1UL << PWR_PUCRE_PU4_Pos)                 /*!< 0x00000010 */
4902 #define PWR_PUCRE_PU4             PWR_PUCRE_PU4_Msk                            /*!< Pin PE4 Pull-Up set */
4903 #define PWR_PUCRE_PD5_Pos         (5U)
4904 #define PWR_PUCRE_PD5_Msk         (0x1UL << PWR_PUCRE_PD5_Pos)                 /*!< 0x00000020 */
4905 #define PWR_PUCRE_PD5             PWR_PUCRE_PD5_Msk                            /*!< Pin PE5 Pull-Up set */
4906 #define PWR_PUCRE_PD6_Pos         (6U)
4907 #define PWR_PUCRE_PD6_Msk         (0x1UL << PWR_PUCRE_PD6_Pos)                 /*!< 0x00000040 */
4908 #define PWR_PUCRE_PD6             PWR_PUCRE_PD6_Msk                            /*!< Pin PE6 Pull-Up set */
4909 #define PWR_PUCRE_PD7_Pos         (7U)
4910 #define PWR_PUCRE_PD7_Msk         (0x1UL << PWR_PUCRE_PD7_Pos)                 /*!< 0x00000080 */
4911 #define PWR_PUCRE_PD7             PWR_PUCRE_PD7_Msk                            /*!< Pin PE7 Pull-Up set */
4912 #define PWR_PUCRE_PD8_Pos         (8U)
4913 #define PWR_PUCRE_PD8_Msk         (0x1UL << PWR_PUCRE_PD8_Pos)                 /*!< 0x00000100 */
4914 #define PWR_PUCRE_PD8             PWR_PUCRE_PD8_Msk                            /*!< Pin PE8 Pull-Up set */
4915 #define PWR_PUCRE_PD9_Pos         (9U)
4916 #define PWR_PUCRE_PD9_Msk         (0x1UL << PWR_PUCRE_PD9_Pos)                 /*!< 0x00000200 */
4917 #define PWR_PUCRE_PD9             PWR_PUCRE_PD9_Msk                            /*!< Pin PE9 Pull-Up set */
4918 #define PWR_PUCRE_PD10_Pos        (10U)
4919 #define PWR_PUCRE_PD10_Msk        (0x1UL << PWR_PUCRE_PD10_Pos)                /*!< 0x00000400 */
4920 #define PWR_PUCRE_PD10            PWR_PUCRE_PD10_Msk                           /*!< Pin PE10 Pull-Up set */
4921 #define PWR_PUCRE_PD11_Pos        (11U)
4922 #define PWR_PUCRE_PD11_Msk        (0x1UL << PWR_PUCRE_PD11_Pos)                /*!< 0x00000800 */
4923 #define PWR_PUCRE_PD11            PWR_PUCRE_PD11_Msk                           /*!< Pin PE11 Pull-Up set */
4924 #define PWR_PUCRE_PD12_Pos        (12U)
4925 #define PWR_PUCRE_PD12_Msk        (0x1UL << PWR_PUCRE_PD12_Pos)                /*!< 0x00001000 */
4926 #define PWR_PUCRE_PD12            PWR_PUCRE_PD12_Msk                           /*!< Pin PE12 Pull-Up set */
4927 #define PWR_PUCRE_PD13_Pos        (13U)
4928 #define PWR_PUCRE_PD13_Msk        (0x1UL << PWR_PUCRE_PD13_Pos)                /*!< 0x00002000 */
4929 #define PWR_PUCRE_PD13            PWR_PUCRE_PD13_Msk                           /*!< Pin PE13 Pull-Up set */
4930 #define PWR_PUCRE_PD14_Pos        (14U)
4931 #define PWR_PUCRE_PD14_Msk        (0x1UL << PWR_PUCRE_PD14_Pos)                /*!< 0x00004000 */
4932 #define PWR_PUCRE_PD14            PWR_PUCRE_PD14_Msk                           /*!< Pin PE14 Pull-Up set */
4933 #define PWR_PUCRE_PD15_Pos        (15U)
4934 #define PWR_PUCRE_PD15_Msk        (0x1UL << PWR_PUCRE_PD15_Pos)                /*!< 0x00008000 */
4935 #define PWR_PUCRE_PD15            PWR_PUCRE_PD15_Msk                           /*!< Pin PE15 Pull-Up set */
4936 
4937 /********************  Bit definition for PWR_PDCRE register  *****************/
4938 #define PWR_PDCRE_PD0_Pos         (0U)
4939 #define PWR_PDCRE_PD0_Msk         (0x1UL << PWR_PDCRE_PD0_Pos)                 /*!< 0x00000001 */
4940 #define PWR_PDCRE_PD0             PWR_PDCRE_PD0_Msk                            /*!< Pin PE0 Pull-Down set */
4941 #define PWR_PDCRE_PD1_Pos         (1U)
4942 #define PWR_PDCRE_PD1_Msk         (0x1UL << PWR_PDCRE_PD1_Pos)                 /*!< 0x00000002 */
4943 #define PWR_PDCRE_PD1             PWR_PDCRE_PD1_Msk                            /*!< Pin PE1 Pull-Down set */
4944 #define PWR_PDCRE_PD2_Pos         (2U)
4945 #define PWR_PDCRE_PD2_Msk         (0x1UL << PWR_PDCRE_PD2_Pos)                 /*!< 0x00000004 */
4946 #define PWR_PDCRE_PD2             PWR_PDCRE_PD2_Msk                            /*!< Pin PE2 Pull-Down set */
4947 #define PWR_PDCRE_PD3_Pos         (3U)
4948 #define PWR_PDCRE_PD3_Msk         (0x1UL << PWR_PDCRE_PD3_Pos)                 /*!< 0x00000008 */
4949 #define PWR_PDCRE_PD3             PWR_PDCRE_PD3_Msk                            /*!< Pin PE3 Pull-Down set */
4950 #define PWR_PDCRE_PD4_Pos         (4U)
4951 #define PWR_PDCRE_PD4_Msk         (0x1UL << PWR_PDCRE_PD4_Pos)                 /*!< 0x00000010 */
4952 #define PWR_PDCRE_PD4             PWR_PDCRE_PD4_Msk                            /*!< Pin PE4 Pull-Down set */
4953 #define PWR_PDCRE_PD5_Pos         (5U)
4954 #define PWR_PDCRE_PD5_Msk         (0x1UL << PWR_PDCRE_PD5_Pos)                 /*!< 0x00000020 */
4955 #define PWR_PDCRE_PD5             PWR_PDCRE_PD5_Msk                            /*!< Pin PE5 Pull-Down set */
4956 #define PWR_PDCRE_PD6_Pos         (6U)
4957 #define PWR_PDCRE_PD6_Msk         (0x1UL << PWR_PDCRE_PD6_Pos)                 /*!< 0x00000040 */
4958 #define PWR_PDCRE_PD6             PWR_PDCRE_PD6_Msk                            /*!< Pin PE6 Pull-Down set */
4959 #define PWR_PDCRE_PD7_Pos         (7U)
4960 #define PWR_PDCRE_PD7_Msk         (0x1UL << PWR_PDCRE_PD7_Pos)                 /*!< 0x00000080 */
4961 #define PWR_PDCRE_PD7             PWR_PDCRE_PD7_Msk                            /*!< Pin PE7 Pull-Down set */
4962 #define PWR_PDCRE_PD8_Pos         (8U)
4963 #define PWR_PDCRE_PD8_Msk         (0x1UL << PWR_PDCRE_PD8_Pos)                 /*!< 0x00000100 */
4964 #define PWR_PDCRE_PD8             PWR_PDCRE_PD8_Msk                            /*!< Pin PE8 Pull-Down set */
4965 #define PWR_PDCRE_PD9_Pos         (9U)
4966 #define PWR_PDCRE_PD9_Msk         (0x1UL << PWR_PDCRE_PD9_Pos)                 /*!< 0x00000200 */
4967 #define PWR_PDCRE_PD9             PWR_PDCRE_PD9_Msk                            /*!< Pin PE9 Pull-Down set */
4968 #define PWR_PDCRE_PD10_Pos        (10U)
4969 #define PWR_PDCRE_PD10_Msk        (0x1UL << PWR_PDCRE_PD10_Pos)                /*!< 0x00000400 */
4970 #define PWR_PDCRE_PD10            PWR_PDCRE_PD10_Msk                           /*!< Pin PE10 Pull-Down set */
4971 #define PWR_PDCRE_PD11_Pos        (11U)
4972 #define PWR_PDCRE_PD11_Msk        (0x1UL << PWR_PDCRE_PD11_Pos)                /*!< 0x00000800 */
4973 #define PWR_PDCRE_PD11            PWR_PDCRE_PD11_Msk                           /*!< Pin PE11 Pull-Down set */
4974 #define PWR_PDCRE_PD12_Pos        (12U)
4975 #define PWR_PDCRE_PD12_Msk        (0x1UL << PWR_PDCRE_PD12_Pos)                /*!< 0x00001000 */
4976 #define PWR_PDCRE_PD12            PWR_PDCRE_PD12_Msk                           /*!< Pin PE12 Pull-Down set */
4977 #define PWR_PDCRE_PD13_Pos        (13U)
4978 #define PWR_PDCRE_PD13_Msk        (0x1UL << PWR_PDCRE_PD13_Pos)                /*!< 0x00002000 */
4979 #define PWR_PDCRE_PD13            PWR_PDCRE_PD13_Msk                           /*!< Pin PE13 Pull-Down set */
4980 #define PWR_PDCRE_PD14_Pos        (14U)
4981 #define PWR_PDCRE_PD14_Msk        (0x1UL << PWR_PDCRE_PD14_Pos)                /*!< 0x00004000 */
4982 #define PWR_PDCRE_PD14            PWR_PDCRE_PD14_Msk                           /*!< Pin PE14 Pull-Down set */
4983 #define PWR_PDCRE_PD15_Pos        (15U)
4984 #define PWR_PDCRE_PD15_Msk        (0x1UL << PWR_PDCRE_PD15_Pos)                /*!< 0x00008000 */
4985 #define PWR_PDCRE_PD15            PWR_PDCRE_PD15_Msk                           /*!< Pin PE15 Pull-Down set */
4986 
4987 /********************  Bit definition for PWR_PUCRF register  *****************/
4988 #define PWR_PUCRF_PU0_Pos         (0U)
4989 #define PWR_PUCRF_PU0_Msk         (0x1UL << PWR_PUCRF_PU0_Pos)                 /*!< 0x00000001 */
4990 #define PWR_PUCRF_PU0             PWR_PUCRF_PU0_Msk                            /*!< Pin PF0 Pull-Up set */
4991 #define PWR_PUCRF_PU1_Pos         (1U)
4992 #define PWR_PUCRF_PU1_Msk         (0x1UL << PWR_PUCRF_PU1_Pos)                 /*!< 0x00000002 */
4993 #define PWR_PUCRF_PU1             PWR_PUCRF_PU1_Msk                            /*!< Pin PF1 Pull-Up set */
4994 #define PWR_PUCRF_PU2_Pos         (2U)
4995 #define PWR_PUCRF_PU2_Msk         (0x1UL << PWR_PUCRF_PU2_Pos)                 /*!< 0x00000004 */
4996 #define PWR_PUCRF_PU2             PWR_PUCRF_PU2_Msk                            /*!< Pin PF2 Pull-Up set */
4997 #define PWR_PUCRF_PU3_Pos         (3U)
4998 #define PWR_PUCRF_PU3_Msk         (0x1UL << PWR_PUCRF_PU3_Pos)                 /*!< 0x00000008 */
4999 #define PWR_PUCRF_PU3             PWR_PUCRF_PU3_Msk                            /*!< Pin PF3 Pull-Up set */
5000 #define PWR_PUCRF_PU4_Pos         (4U)
5001 #define PWR_PUCRF_PU4_Msk         (0x1UL << PWR_PUCRF_PU4_Pos)                 /*!< 0x00000010 */
5002 #define PWR_PUCRF_PU4             PWR_PUCRF_PU4_Msk                            /*!< Pin PF4 Pull-Up set */
5003 #define PWR_PUCRF_PD5_Pos         (5U)
5004 #define PWR_PUCRF_PD5_Msk         (0x1UL << PWR_PUCRF_PD5_Pos)                 /*!< 0x00000020 */
5005 #define PWR_PUCRF_PD5             PWR_PUCRF_PD5_Msk                            /*!< Pin PF5 Pull-Up set */
5006 #define PWR_PUCRF_PD6_Pos         (6U)
5007 #define PWR_PUCRF_PD6_Msk         (0x1UL << PWR_PUCRF_PD6_Pos)                 /*!< 0x00000040 */
5008 #define PWR_PUCRF_PD6             PWR_PUCRF_PD6_Msk                            /*!< Pin PF6 Pull-Up set */
5009 #define PWR_PUCRF_PD7_Pos         (7U)
5010 #define PWR_PUCRF_PD7_Msk         (0x1UL << PWR_PUCRF_PD7_Pos)                 /*!< 0x00000080 */
5011 #define PWR_PUCRF_PD7             PWR_PUCRF_PD7_Msk                            /*!< Pin PF7 Pull-Up set */
5012 #define PWR_PUCRF_PD8_Pos         (8U)
5013 #define PWR_PUCRF_PD8_Msk         (0x1UL << PWR_PUCRF_PD8_Pos)                 /*!< 0x00000100 */
5014 #define PWR_PUCRF_PD8             PWR_PUCRF_PD8_Msk                            /*!< Pin PF8 Pull-Up set */
5015 #define PWR_PUCRF_PD9_Pos         (9U)
5016 #define PWR_PUCRF_PD9_Msk         (0x1UL << PWR_PUCRF_PD9_Pos)                 /*!< 0x00000200 */
5017 #define PWR_PUCRF_PD9             PWR_PUCRF_PD9_Msk                            /*!< Pin PF9 Pull-Up set */
5018 #define PWR_PUCRF_PD10_Pos        (10U)
5019 #define PWR_PUCRF_PD10_Msk        (0x1UL << PWR_PUCRF_PD10_Pos)                /*!< 0x00000400 */
5020 #define PWR_PUCRF_PD10            PWR_PUCRF_PD10_Msk                           /*!< Pin PF10 Pull-Up set */
5021 #define PWR_PUCRF_PD11_Pos        (11U)
5022 #define PWR_PUCRF_PD11_Msk        (0x1UL << PWR_PUCRF_PD11_Pos)                /*!< 0x00000800 */
5023 #define PWR_PUCRF_PD11            PWR_PUCRF_PD11_Msk                           /*!< Pin PF11 Pull-Up set */
5024 #define PWR_PUCRF_PD12_Pos        (12U)
5025 #define PWR_PUCRF_PD12_Msk        (0x1UL << PWR_PUCRF_PD12_Pos)                /*!< 0x00001000 */
5026 #define PWR_PUCRF_PD12            PWR_PUCRF_PD12_Msk                           /*!< Pin PF12 Pull-Up set */
5027 #define PWR_PUCRF_PD13_Pos        (13U)
5028 #define PWR_PUCRF_PD13_Msk        (0x1UL << PWR_PUCRF_PD13_Pos)                /*!< 0x00002000 */
5029 #define PWR_PUCRF_PD13            PWR_PUCRF_PD13_Msk                           /*!< Pin PF13 Pull-Up set */
5030 
5031 /********************  Bit definition for PWR_PDCRF register  *****************/
5032 #define PWR_PDCRF_PD0_Pos         (0U)
5033 #define PWR_PDCRF_PD0_Msk         (0x1UL << PWR_PDCRF_PD0_Pos)                 /*!< 0x00000001 */
5034 #define PWR_PDCRF_PD0             PWR_PDCRF_PD0_Msk                            /*!< Pin PF0 Pull-Down set */
5035 #define PWR_PDCRF_PD1_Pos         (1U)
5036 #define PWR_PDCRF_PD1_Msk         (0x1UL << PWR_PDCRF_PD1_Pos)                 /*!< 0x00000002 */
5037 #define PWR_PDCRF_PD1             PWR_PDCRF_PD1_Msk                            /*!< Pin PF1 Pull-Down set */
5038 #define PWR_PDCRF_PD2_Pos         (2U)
5039 #define PWR_PDCRF_PD2_Msk         (0x1UL << PWR_PDCRF_PD2_Pos)                 /*!< 0x00000004 */
5040 #define PWR_PDCRF_PD2             PWR_PDCRF_PD2_Msk                            /*!< Pin PF2 Pull-Down set */
5041 #define PWR_PDCRF_PD3_Pos         (3U)
5042 #define PWR_PDCRF_PD3_Msk         (0x1UL << PWR_PDCRF_PD3_Pos)                 /*!< 0x00000008 */
5043 #define PWR_PDCRF_PD3             PWR_PDCRF_PD3_Msk                            /*!< Pin PF3 Pull-Down set */
5044 #define PWR_PDCRF_PD4_Pos         (4U)
5045 #define PWR_PDCRF_PD4_Msk         (0x1UL << PWR_PDCRF_PD4_Pos)                 /*!< 0x00000010 */
5046 #define PWR_PDCRF_PD4             PWR_PDCRF_PD4_Msk                            /*!< Pin PF4 Pull-Down set */
5047 #define PWR_PDCRF_PD5_Pos         (5U)
5048 #define PWR_PDCRF_PD5_Msk         (0x1UL << PWR_PDCRF_PD5_Pos)                 /*!< 0x00000020 */
5049 #define PWR_PDCRF_PD5             PWR_PDCRF_PD5_Msk                            /*!< Pin PF5 Pull-Down set */
5050 #define PWR_PDCRF_PD6_Pos         (6U)
5051 #define PWR_PDCRF_PD6_Msk         (0x1UL << PWR_PDCRF_PD6_Pos)                 /*!< 0x00000040 */
5052 #define PWR_PDCRF_PD6             PWR_PDCRF_PD6_Msk                            /*!< Pin PF6 Pull-Down set */
5053 #define PWR_PDCRF_PD7_Pos         (7U)
5054 #define PWR_PDCRF_PD7_Msk         (0x1UL << PWR_PDCRF_PD7_Pos)                 /*!< 0x00000080 */
5055 #define PWR_PDCRF_PD7             PWR_PDCRF_PD7_Msk                            /*!< Pin PF7 Pull-Down set */
5056 #define PWR_PDCRF_PD8_Pos         (8U)
5057 #define PWR_PDCRF_PD8_Msk         (0x1UL << PWR_PDCRF_PD8_Pos)                 /*!< 0x00000100 */
5058 #define PWR_PDCRF_PD8             PWR_PDCRF_PD8_Msk                            /*!< Pin PF8 Pull-Down set */
5059 #define PWR_PDCRF_PD9_Pos         (9U)
5060 #define PWR_PDCRF_PD9_Msk         (0x1UL << PWR_PDCRF_PD9_Pos)                 /*!< 0x00000200 */
5061 #define PWR_PDCRF_PD9             PWR_PDCRF_PD9_Msk                            /*!< Pin PF9 Pull-Down set */
5062 #define PWR_PDCRF_PD10_Pos        (10U)
5063 #define PWR_PDCRF_PD10_Msk        (0x1UL << PWR_PDCRF_PD10_Pos)                /*!< 0x00000400 */
5064 #define PWR_PDCRF_PD10            PWR_PDCRF_PD10_Msk                           /*!< Pin PF10 Pull-Down set */
5065 #define PWR_PDCRF_PD11_Pos        (11U)
5066 #define PWR_PDCRF_PD11_Msk        (0x1UL << PWR_PDCRF_PD11_Pos)                /*!< 0x00000800 */
5067 #define PWR_PDCRF_PD11            PWR_PDCRF_PD11_Msk                           /*!< Pin PF11 Pull-Down set */
5068 #define PWR_PDCRF_PD12_Pos        (12U)
5069 #define PWR_PDCRF_PD12_Msk        (0x1UL << PWR_PDCRF_PD12_Pos)                /*!< 0x00001000 */
5070 #define PWR_PDCRF_PD12            PWR_PDCRF_PD12_Msk                           /*!< Pin PF12 Pull-Down set */
5071 #define PWR_PDCRF_PD13_Pos        (13U)
5072 #define PWR_PDCRF_PD13_Msk        (0x1UL << PWR_PDCRF_PD13_Pos)                /*!< 0x00002000 */
5073 #define PWR_PDCRF_PD13            PWR_PDCRF_PD13_Msk                           /*!< Pin PF13 Pull-Down set */
5074 
5075 /******************************************************************************/
5076 /*                                                                            */
5077 /*                           Reset and Clock Control                          */
5078 /*                                                                            */
5079 /******************************************************************************/
5080 /*
5081 * @brief Specific device feature definitions  (not present on all devices in the STM32G0 series)
5082 */
5083 #define RCC_MCO2_SUPPORT
5084 #define RCC_PLLQ_SUPPORT
5085 
5086 /********************  Bit definition for RCC_CR register  *****************/
5087 #define RCC_CR_HSION_Pos                 (8U)
5088 #define RCC_CR_HSION_Msk                 (0x1UL << RCC_CR_HSION_Pos)           /*!< 0x00000100 */
5089 #define RCC_CR_HSION                     RCC_CR_HSION_Msk                      /*!< Internal High Speed clock enable */
5090 #define RCC_CR_HSIKERON_Pos              (9U)
5091 #define RCC_CR_HSIKERON_Msk              (0x1UL << RCC_CR_HSIKERON_Pos)        /*!< 0x00000200 */
5092 #define RCC_CR_HSIKERON                  RCC_CR_HSIKERON_Msk                   /*!< Internal High Speed clock enable for some IPs Kernel */
5093 #define RCC_CR_HSIRDY_Pos                (10U)
5094 #define RCC_CR_HSIRDY_Msk                (0x1UL << RCC_CR_HSIRDY_Pos)          /*!< 0x00000400 */
5095 #define RCC_CR_HSIRDY                    RCC_CR_HSIRDY_Msk                     /*!< Internal High Speed clock ready flag */
5096 #define RCC_CR_HSIDIV_Pos                (11U)
5097 #define RCC_CR_HSIDIV_Msk                (0x7UL << RCC_CR_HSIDIV_Pos)          /*!< 0x00003800 */
5098 #define RCC_CR_HSIDIV                    RCC_CR_HSIDIV_Msk                     /*!< HSIDIV[13:11] Internal High Speed clock division factor */
5099 #define RCC_CR_HSIDIV_0                  (0x1UL << RCC_CR_HSIDIV_Pos)          /*!< 0x00000800 */
5100 #define RCC_CR_HSIDIV_1                  (0x2UL << RCC_CR_HSIDIV_Pos)          /*!< 0x00001000 */
5101 #define RCC_CR_HSIDIV_2                  (0x4UL << RCC_CR_HSIDIV_Pos)          /*!< 0x00002000 */
5102 #define RCC_CR_HSEON_Pos                 (16U)
5103 #define RCC_CR_HSEON_Msk                 (0x1UL << RCC_CR_HSEON_Pos)           /*!< 0x00010000 */
5104 #define RCC_CR_HSEON                     RCC_CR_HSEON_Msk                      /*!< External High Speed clock enable */
5105 #define RCC_CR_HSERDY_Pos                (17U)
5106 #define RCC_CR_HSERDY_Msk                (0x1UL << RCC_CR_HSERDY_Pos)          /*!< 0x00020000 */
5107 #define RCC_CR_HSERDY                    RCC_CR_HSERDY_Msk                     /*!< External High Speed clock ready */
5108 #define RCC_CR_HSEBYP_Pos                (18U)
5109 #define RCC_CR_HSEBYP_Msk                (0x1UL << RCC_CR_HSEBYP_Pos)          /*!< 0x00040000 */
5110 #define RCC_CR_HSEBYP                    RCC_CR_HSEBYP_Msk                     /*!< External High Speed clock Bypass */
5111 #define RCC_CR_CSSON_Pos                 (19U)
5112 #define RCC_CR_CSSON_Msk                 (0x1UL << RCC_CR_CSSON_Pos)           /*!< 0x00080000 */
5113 #define RCC_CR_CSSON                     RCC_CR_CSSON_Msk                      /*!< HSE Clock Security System enable */
5114 
5115 #define RCC_CR_PLLON_Pos                 (24U)
5116 #define RCC_CR_PLLON_Msk                 (0x1UL << RCC_CR_PLLON_Pos)           /*!< 0x01000000 */
5117 #define RCC_CR_PLLON                     RCC_CR_PLLON_Msk                      /*!< System PLL clock enable */
5118 #define RCC_CR_PLLRDY_Pos                (25U)
5119 #define RCC_CR_PLLRDY_Msk                (0x1UL << RCC_CR_PLLRDY_Pos)          /*!< 0x02000000 */
5120 #define RCC_CR_PLLRDY                    RCC_CR_PLLRDY_Msk                     /*!< System PLL clock ready */
5121 
5122 /********************  Bit definition for RCC_ICSCR register  ***************/
5123 /*!< HSICAL configuration */
5124 #define RCC_ICSCR_HSICAL_Pos             (0U)
5125 #define RCC_ICSCR_HSICAL_Msk             (0xFFUL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x000000FF */
5126 #define RCC_ICSCR_HSICAL                 RCC_ICSCR_HSICAL_Msk                  /*!< HSICAL[7:0] bits */
5127 #define RCC_ICSCR_HSICAL_0               (0x01UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000001 */
5128 #define RCC_ICSCR_HSICAL_1               (0x02UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000002 */
5129 #define RCC_ICSCR_HSICAL_2               (0x04UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000004 */
5130 #define RCC_ICSCR_HSICAL_3               (0x08UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000008 */
5131 #define RCC_ICSCR_HSICAL_4               (0x10UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000010 */
5132 #define RCC_ICSCR_HSICAL_5               (0x20UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000020 */
5133 #define RCC_ICSCR_HSICAL_6               (0x40UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000040 */
5134 #define RCC_ICSCR_HSICAL_7               (0x80UL << RCC_ICSCR_HSICAL_Pos)      /*!< 0x00000080 */
5135 
5136 /*!< HSITRIM configuration */
5137 #define RCC_ICSCR_HSITRIM_Pos            (8U)
5138 #define RCC_ICSCR_HSITRIM_Msk            (0x7FUL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00007F00 */
5139 #define RCC_ICSCR_HSITRIM                RCC_ICSCR_HSITRIM_Msk                 /*!< HSITRIM[14:8] bits */
5140 #define RCC_ICSCR_HSITRIM_0              (0x01UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00000100 */
5141 #define RCC_ICSCR_HSITRIM_1              (0x02UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00000200 */
5142 #define RCC_ICSCR_HSITRIM_2              (0x04UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00000400 */
5143 #define RCC_ICSCR_HSITRIM_3              (0x08UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00000800 */
5144 #define RCC_ICSCR_HSITRIM_4              (0x10UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00001000 */
5145 #define RCC_ICSCR_HSITRIM_5              (0x20UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00002000 */
5146 #define RCC_ICSCR_HSITRIM_6              (0x40UL << RCC_ICSCR_HSITRIM_Pos)     /*!< 0x00004000 */
5147 
5148 /********************  Bit definition for RCC_CFGR register  ***************/
5149 /*!< SW configuration */
5150 #define RCC_CFGR_SW_Pos                (0U)
5151 #define RCC_CFGR_SW_Msk                (0x7UL << RCC_CFGR_SW_Pos)              /*!< 0x00000007 */
5152 #define RCC_CFGR_SW                    RCC_CFGR_SW_Msk                         /*!< SW[2:0] bits (System clock Switch) */
5153 #define RCC_CFGR_SW_0                  (0x1UL << RCC_CFGR_SW_Pos)              /*!< 0x00000001 */
5154 #define RCC_CFGR_SW_1                  (0x2UL << RCC_CFGR_SW_Pos)              /*!< 0x00000002 */
5155 #define RCC_CFGR_SW_2                  (0x4UL << RCC_CFGR_SW_Pos)              /*!< 0x00000004 */
5156 
5157 /*!< SWS configuration */
5158 #define RCC_CFGR_SWS_Pos               (3U)
5159 #define RCC_CFGR_SWS_Msk               (0x7UL << RCC_CFGR_SWS_Pos)             /*!< 0x00000038 */
5160 #define RCC_CFGR_SWS                   RCC_CFGR_SWS_Msk                        /*!< SWS[2:0] bits (System Clock Switch Status) */
5161 #define RCC_CFGR_SWS_0                 (0x1UL << RCC_CFGR_SWS_Pos)             /*!< 0x00000008 */
5162 #define RCC_CFGR_SWS_1                 (0x2UL << RCC_CFGR_SWS_Pos)             /*!< 0x00000010 */
5163 #define RCC_CFGR_SWS_2                 (0x4UL << RCC_CFGR_SWS_Pos)             /*!< 0x00000020 */
5164 
5165 /*!< HPRE configuration */
5166 #define RCC_CFGR_HPRE_Pos              (8U)
5167 #define RCC_CFGR_HPRE_Msk              (0xFUL << RCC_CFGR_HPRE_Pos)            /*!< 0x00000F00 */
5168 #define RCC_CFGR_HPRE                  RCC_CFGR_HPRE_Msk                       /*!< HPRE[3:0] bits (AHB prescaler) */
5169 #define RCC_CFGR_HPRE_0                (0x1UL << RCC_CFGR_HPRE_Pos)            /*!< 0x00000100 */
5170 #define RCC_CFGR_HPRE_1                (0x2UL << RCC_CFGR_HPRE_Pos)            /*!< 0x00000200 */
5171 #define RCC_CFGR_HPRE_2                (0x4UL << RCC_CFGR_HPRE_Pos)            /*!< 0x00000400 */
5172 #define RCC_CFGR_HPRE_3                (0x8UL << RCC_CFGR_HPRE_Pos)            /*!< 0x00000800 */
5173 
5174 /*!< PPRE configuration */
5175 #define RCC_CFGR_PPRE_Pos              (12U)
5176 #define RCC_CFGR_PPRE_Msk              (0x7UL << RCC_CFGR_PPRE_Pos)            /*!< 0x00007000 */
5177 #define RCC_CFGR_PPRE                  RCC_CFGR_PPRE_Msk                       /*!< PRE1[2:0] bits (APB prescaler) */
5178 #define RCC_CFGR_PPRE_0                (0x1UL << RCC_CFGR_PPRE_Pos)            /*!< 0x00001000 */
5179 #define RCC_CFGR_PPRE_1                (0x2UL << RCC_CFGR_PPRE_Pos)            /*!< 0x00002000 */
5180 #define RCC_CFGR_PPRE_2                (0x4UL << RCC_CFGR_PPRE_Pos)            /*!< 0x00004000 */
5181 
5182 /*!< MCO2SEL configuration */
5183 #define RCC_CFGR_MCO2SEL_Pos            (16U)
5184 #define RCC_CFGR_MCO2SEL_Msk            (0xFUL << RCC_CFGR_MCO2SEL_Pos)          /*!< 0x000F0000 */
5185 #define RCC_CFGR_MCO2SEL                RCC_CFGR_MCO2SEL_Msk                     /*!< MCO2SEL [3:0] bits (Clock output selection) */
5186 #define RCC_CFGR_MCO2SEL_0              (0x1UL << RCC_CFGR_MCO2SEL_Pos)          /*!< 0x00010000 */
5187 #define RCC_CFGR_MCO2SEL_1              (0x2UL << RCC_CFGR_MCO2SEL_Pos)          /*!< 0x00020000 */
5188 #define RCC_CFGR_MCO2SEL_2              (0x4UL << RCC_CFGR_MCO2SEL_Pos)          /*!< 0x00040000 */
5189 #define RCC_CFGR_MCO2SEL_3              (0x8UL << RCC_CFGR_MCO2SEL_Pos)          /*!< 0x00080000 */
5190 
5191 /*!< MCO2 Prescaler configuration */
5192 #define RCC_CFGR_MCO2PRE_Pos            (20U)
5193 #define RCC_CFGR_MCO2PRE_Msk            (0xFUL << RCC_CFGR_MCO2PRE_Pos)          /*!< 0x00F00000 */
5194 #define RCC_CFGR_MCO2PRE                RCC_CFGR_MCO2PRE_Msk                     /*!< MCO2 prescaler [3:0] */
5195 #define RCC_CFGR_MCO2PRE_0              (0x1UL << RCC_CFGR_MCO2PRE_Pos)          /*!< 0x00100000 */
5196 #define RCC_CFGR_MCO2PRE_1              (0x2UL << RCC_CFGR_MCO2PRE_Pos)          /*!< 0x00200000 */
5197 #define RCC_CFGR_MCO2PRE_2              (0x4UL << RCC_CFGR_MCO2PRE_Pos)          /*!< 0x00400000 */
5198 #define RCC_CFGR_MCO2PRE_3              (0x8UL << RCC_CFGR_MCO2PRE_Pos)          /*!< 0x00800000 */
5199 
5200 /*!< MCOSEL configuration */
5201 #define RCC_CFGR_MCOSEL_Pos            (24U)
5202 #define RCC_CFGR_MCOSEL_Msk            (0xFUL << RCC_CFGR_MCOSEL_Pos)          /*!< 0x0F000000 */
5203 #define RCC_CFGR_MCOSEL                RCC_CFGR_MCOSEL_Msk                     /*!< MCOSEL [2:0] bits (Clock output selection) */
5204 #define RCC_CFGR_MCOSEL_0              (0x1UL << RCC_CFGR_MCOSEL_Pos)          /*!< 0x01000000 */
5205 #define RCC_CFGR_MCOSEL_1              (0x2UL << RCC_CFGR_MCOSEL_Pos)          /*!< 0x02000000 */
5206 #define RCC_CFGR_MCOSEL_2              (0x4UL << RCC_CFGR_MCOSEL_Pos)          /*!< 0x04000000 */
5207 #define RCC_CFGR_MCOSEL_3              (0x8UL << RCC_CFGR_MCOSEL_Pos)          /*!< 0x08000000 */
5208 
5209 /*!< MCO Prescaler configuration */
5210 #define RCC_CFGR_MCOPRE_Pos            (28U)
5211 #define RCC_CFGR_MCOPRE_Msk            (0xFUL << RCC_CFGR_MCOPRE_Pos)          /*!< 0xF0000000 */
5212 #define RCC_CFGR_MCOPRE                RCC_CFGR_MCOPRE_Msk                     /*!< MCO prescaler [2:0] */
5213 #define RCC_CFGR_MCOPRE_0              (0x1UL << RCC_CFGR_MCOPRE_Pos)          /*!< 0x10000000 */
5214 #define RCC_CFGR_MCOPRE_1              (0x2UL << RCC_CFGR_MCOPRE_Pos)          /*!< 0x20000000 */
5215 #define RCC_CFGR_MCOPRE_2              (0x4UL << RCC_CFGR_MCOPRE_Pos)          /*!< 0x40000000 */
5216 #define RCC_CFGR_MCOPRE_3              (0x8UL << RCC_CFGR_MCOPRE_Pos)          /*!< 0x80000000 */
5217 
5218 /********************  Bit definition for RCC_PLLCFGR register  ***************/
5219 #define RCC_PLLCFGR_PLLSRC_Pos           (0U)
5220 #define RCC_PLLCFGR_PLLSRC_Msk           (0x3UL << RCC_PLLCFGR_PLLSRC_Pos)     /*!< 0x00000003 */
5221 #define RCC_PLLCFGR_PLLSRC               RCC_PLLCFGR_PLLSRC_Msk
5222 #define RCC_PLLCFGR_PLLSRC_0             (0x1UL << RCC_PLLCFGR_PLLSRC_Pos)     /*!< 0x00000001 */
5223 #define RCC_PLLCFGR_PLLSRC_1             (0x2UL << RCC_PLLCFGR_PLLSRC_Pos)     /*!< 0x00000002 */
5224 
5225 #define RCC_PLLCFGR_PLLSRC_NONE          (0x00000000UL)                        /*!< No clock sent to PLL      */
5226 #define RCC_PLLCFGR_PLLSRC_HSI_Pos       (1U)
5227 #define RCC_PLLCFGR_PLLSRC_HSI_Msk       (0x1UL << RCC_PLLCFGR_PLLSRC_HSI_Pos) /*!< 0x00000002 */
5228 #define RCC_PLLCFGR_PLLSRC_HSI           RCC_PLLCFGR_PLLSRC_HSI_Msk            /*!< HSI source clock selected */
5229 #define RCC_PLLCFGR_PLLSRC_HSE_Pos       (0U)
5230 #define RCC_PLLCFGR_PLLSRC_HSE_Msk       (0x3UL << RCC_PLLCFGR_PLLSRC_HSE_Pos) /*!< 0x00000003 */
5231 #define RCC_PLLCFGR_PLLSRC_HSE           RCC_PLLCFGR_PLLSRC_HSE_Msk            /*!< HSE source clock selected */
5232 
5233 #define RCC_PLLCFGR_PLLM_Pos             (4U)
5234 #define RCC_PLLCFGR_PLLM_Msk             (0x7UL << RCC_PLLCFGR_PLLM_Pos)       /*!< 0x00000070 */
5235 #define RCC_PLLCFGR_PLLM                 RCC_PLLCFGR_PLLM_Msk
5236 #define RCC_PLLCFGR_PLLM_0               (0x1UL << RCC_PLLCFGR_PLLM_Pos)       /*!< 0x00000010 */
5237 #define RCC_PLLCFGR_PLLM_1               (0x2UL << RCC_PLLCFGR_PLLM_Pos)       /*!< 0x00000020 */
5238 #define RCC_PLLCFGR_PLLM_2               (0x4UL << RCC_PLLCFGR_PLLM_Pos)       /*!< 0x00000040 */
5239 
5240 #define RCC_PLLCFGR_PLLN_Pos             (8U)
5241 #define RCC_PLLCFGR_PLLN_Msk             (0x7FUL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00007F00 */
5242 #define RCC_PLLCFGR_PLLN                 RCC_PLLCFGR_PLLN_Msk
5243 #define RCC_PLLCFGR_PLLN_0               (0x01UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00000100 */
5244 #define RCC_PLLCFGR_PLLN_1               (0x02UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00000200 */
5245 #define RCC_PLLCFGR_PLLN_2               (0x04UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00000400 */
5246 #define RCC_PLLCFGR_PLLN_3               (0x08UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00000800 */
5247 #define RCC_PLLCFGR_PLLN_4               (0x10UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00001000 */
5248 #define RCC_PLLCFGR_PLLN_5               (0x20UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00002000 */
5249 #define RCC_PLLCFGR_PLLN_6               (0x40UL << RCC_PLLCFGR_PLLN_Pos)      /*!< 0x00004000 */
5250 
5251 #define RCC_PLLCFGR_PLLPEN_Pos           (16U)
5252 #define RCC_PLLCFGR_PLLPEN_Msk           (0x1UL << RCC_PLLCFGR_PLLPEN_Pos)     /*!< 0x00010000 */
5253 #define RCC_PLLCFGR_PLLPEN               RCC_PLLCFGR_PLLPEN_Msk
5254 
5255 #define RCC_PLLCFGR_PLLP_Pos              (17U)
5256 #define RCC_PLLCFGR_PLLP_Msk              (0x1FUL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x003E0000 */
5257 #define RCC_PLLCFGR_PLLP                  RCC_PLLCFGR_PLLP_Msk
5258 #define RCC_PLLCFGR_PLLP_0                (0x01UL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x00020000 */
5259 #define RCC_PLLCFGR_PLLP_1                (0x02UL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x00040000 */
5260 #define RCC_PLLCFGR_PLLP_2                (0x04UL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x00080000 */
5261 #define RCC_PLLCFGR_PLLP_3                (0x08UL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x00100000 */
5262 #define RCC_PLLCFGR_PLLP_4                (0x10UL << RCC_PLLCFGR_PLLP_Pos)     /*!< 0x00200000 */
5263 
5264 #define RCC_PLLCFGR_PLLQEN_Pos           (24U)
5265 #define RCC_PLLCFGR_PLLQEN_Msk           (0x1UL << RCC_PLLCFGR_PLLQEN_Pos)     /*!< 0x01000000 */
5266 #define RCC_PLLCFGR_PLLQEN               RCC_PLLCFGR_PLLQEN_Msk
5267 
5268 #define RCC_PLLCFGR_PLLQ_Pos             (25U)
5269 #define RCC_PLLCFGR_PLLQ_Msk             (0x7UL << RCC_PLLCFGR_PLLQ_Pos)       /*!< 0x0E000000 */
5270 #define RCC_PLLCFGR_PLLQ                 RCC_PLLCFGR_PLLQ_Msk
5271 #define RCC_PLLCFGR_PLLQ_0               (0x1UL << RCC_PLLCFGR_PLLQ_Pos)       /*!< 0x02000000 */
5272 #define RCC_PLLCFGR_PLLQ_1               (0x2UL << RCC_PLLCFGR_PLLQ_Pos)       /*!< 0x04000000 */
5273 #define RCC_PLLCFGR_PLLQ_2               (0x4UL << RCC_PLLCFGR_PLLQ_Pos)       /*!< 0x08000000 */
5274 
5275 #define RCC_PLLCFGR_PLLREN_Pos           (28U)
5276 #define RCC_PLLCFGR_PLLREN_Msk           (0x1UL << RCC_PLLCFGR_PLLREN_Pos)     /*!< 0x10000000 */
5277 #define RCC_PLLCFGR_PLLREN               RCC_PLLCFGR_PLLREN_Msk
5278 
5279 #define RCC_PLLCFGR_PLLR_Pos             (29U)
5280 #define RCC_PLLCFGR_PLLR_Msk             (0x7UL << RCC_PLLCFGR_PLLR_Pos)       /*!< 0xE0000000 */
5281 #define RCC_PLLCFGR_PLLR                 RCC_PLLCFGR_PLLR_Msk
5282 #define RCC_PLLCFGR_PLLR_0               (0x1UL << RCC_PLLCFGR_PLLR_Pos)       /*!< 0x20000000 */
5283 #define RCC_PLLCFGR_PLLR_1               (0x2UL << RCC_PLLCFGR_PLLR_Pos)       /*!< 0x40000000 */
5284 #define RCC_PLLCFGR_PLLR_2               (0x4UL << RCC_PLLCFGR_PLLR_Pos)       /*!< 0x80000000 */
5285 
5286 /********************  Bit definition for RCC_CIER register  ******************/
5287 #define RCC_CIER_LSIRDYIE_Pos            (0U)
5288 #define RCC_CIER_LSIRDYIE_Msk            (0x1UL << RCC_CIER_LSIRDYIE_Pos)      /*!< 0x00000001 */
5289 #define RCC_CIER_LSIRDYIE                RCC_CIER_LSIRDYIE_Msk
5290 #define RCC_CIER_LSERDYIE_Pos            (1U)
5291 #define RCC_CIER_LSERDYIE_Msk            (0x1UL << RCC_CIER_LSERDYIE_Pos)      /*!< 0x00000002 */
5292 #define RCC_CIER_LSERDYIE                RCC_CIER_LSERDYIE_Msk
5293 #define RCC_CIER_HSIRDYIE_Pos            (3U)
5294 #define RCC_CIER_HSIRDYIE_Msk            (0x1UL << RCC_CIER_HSIRDYIE_Pos)      /*!< 0x00000008 */
5295 #define RCC_CIER_HSIRDYIE                RCC_CIER_HSIRDYIE_Msk
5296 #define RCC_CIER_HSERDYIE_Pos            (4U)
5297 #define RCC_CIER_HSERDYIE_Msk            (0x1UL << RCC_CIER_HSERDYIE_Pos)      /*!< 0x00000010 */
5298 #define RCC_CIER_HSERDYIE                RCC_CIER_HSERDYIE_Msk
5299 #define RCC_CIER_PLLRDYIE_Pos            (5U)
5300 #define RCC_CIER_PLLRDYIE_Msk            (0x1UL << RCC_CIER_PLLRDYIE_Pos)      /*!< 0x00000020 */
5301 #define RCC_CIER_PLLRDYIE                RCC_CIER_PLLRDYIE_Msk
5302 
5303 /********************  Bit definition for RCC_CIFR register  ******************/
5304 #define RCC_CIFR_LSIRDYF_Pos             (0U)
5305 #define RCC_CIFR_LSIRDYF_Msk             (0x1UL << RCC_CIFR_LSIRDYF_Pos)       /*!< 0x00000001 */
5306 #define RCC_CIFR_LSIRDYF                 RCC_CIFR_LSIRDYF_Msk
5307 #define RCC_CIFR_LSERDYF_Pos             (1U)
5308 #define RCC_CIFR_LSERDYF_Msk             (0x1UL << RCC_CIFR_LSERDYF_Pos)       /*!< 0x00000002 */
5309 #define RCC_CIFR_LSERDYF                 RCC_CIFR_LSERDYF_Msk
5310 #define RCC_CIFR_HSIRDYF_Pos             (3U)
5311 #define RCC_CIFR_HSIRDYF_Msk             (0x1UL << RCC_CIFR_HSIRDYF_Pos)       /*!< 0x00000008 */
5312 #define RCC_CIFR_HSIRDYF                 RCC_CIFR_HSIRDYF_Msk
5313 #define RCC_CIFR_HSERDYF_Pos             (4U)
5314 #define RCC_CIFR_HSERDYF_Msk             (0x1UL << RCC_CIFR_HSERDYF_Pos)       /*!< 0x00000010 */
5315 #define RCC_CIFR_HSERDYF                 RCC_CIFR_HSERDYF_Msk
5316 #define RCC_CIFR_PLLRDYF_Pos             (5U)
5317 #define RCC_CIFR_PLLRDYF_Msk             (0x1UL << RCC_CIFR_PLLRDYF_Pos)       /*!< 0x00000020 */
5318 #define RCC_CIFR_PLLRDYF                 RCC_CIFR_PLLRDYF_Msk
5319 #define RCC_CIFR_CSSF_Pos                (8U)
5320 #define RCC_CIFR_CSSF_Msk                (0x1UL << RCC_CIFR_CSSF_Pos)          /*!< 0x00000100 */
5321 #define RCC_CIFR_CSSF                    RCC_CIFR_CSSF_Msk
5322 #define RCC_CIFR_LSECSSF_Pos             (9U)
5323 #define RCC_CIFR_LSECSSF_Msk             (0x1UL << RCC_CIFR_LSECSSF_Pos)       /*!< 0x00000200 */
5324 #define RCC_CIFR_LSECSSF                 RCC_CIFR_LSECSSF_Msk
5325 
5326 /********************  Bit definition for RCC_CICR register  ******************/
5327 #define RCC_CICR_LSIRDYC_Pos             (0U)
5328 #define RCC_CICR_LSIRDYC_Msk             (0x1UL << RCC_CICR_LSIRDYC_Pos)       /*!< 0x00000001 */
5329 #define RCC_CICR_LSIRDYC                 RCC_CICR_LSIRDYC_Msk
5330 #define RCC_CICR_LSERDYC_Pos             (1U)
5331 #define RCC_CICR_LSERDYC_Msk             (0x1UL << RCC_CICR_LSERDYC_Pos)       /*!< 0x00000002 */
5332 #define RCC_CICR_LSERDYC                 RCC_CICR_LSERDYC_Msk
5333 #define RCC_CICR_HSIRDYC_Pos             (3U)
5334 #define RCC_CICR_HSIRDYC_Msk             (0x1UL << RCC_CICR_HSIRDYC_Pos)       /*!< 0x00000008 */
5335 #define RCC_CICR_HSIRDYC                 RCC_CICR_HSIRDYC_Msk
5336 #define RCC_CICR_HSERDYC_Pos             (4U)
5337 #define RCC_CICR_HSERDYC_Msk             (0x1UL << RCC_CICR_HSERDYC_Pos)       /*!< 0x00000010 */
5338 #define RCC_CICR_HSERDYC                 RCC_CICR_HSERDYC_Msk
5339 #define RCC_CICR_PLLRDYC_Pos             (5U)
5340 #define RCC_CICR_PLLRDYC_Msk             (0x1UL << RCC_CICR_PLLRDYC_Pos)       /*!< 0x00000020 */
5341 #define RCC_CICR_PLLRDYC                 RCC_CICR_PLLRDYC_Msk
5342 #define RCC_CICR_CSSC_Pos                (8U)
5343 #define RCC_CICR_CSSC_Msk                (0x1UL << RCC_CICR_CSSC_Pos)          /*!< 0x00000100 */
5344 #define RCC_CICR_CSSC                    RCC_CICR_CSSC_Msk
5345 #define RCC_CICR_LSECSSC_Pos             (9U)
5346 #define RCC_CICR_LSECSSC_Msk             (0x1UL << RCC_CICR_LSECSSC_Pos)       /*!< 0x00000200 */
5347 #define RCC_CICR_LSECSSC                 RCC_CICR_LSECSSC_Msk
5348 
5349 /********************  Bit definition for RCC_IOPRSTR register  ****************/
5350 #define RCC_IOPRSTR_GPIOARST_Pos         (0U)
5351 #define RCC_IOPRSTR_GPIOARST_Msk         (0x1UL << RCC_IOPRSTR_GPIOARST_Pos)   /*!< 0x00000001 */
5352 #define RCC_IOPRSTR_GPIOARST             RCC_IOPRSTR_GPIOARST_Msk
5353 #define RCC_IOPRSTR_GPIOBRST_Pos         (1U)
5354 #define RCC_IOPRSTR_GPIOBRST_Msk         (0x1UL << RCC_IOPRSTR_GPIOBRST_Pos)   /*!< 0x00000002 */
5355 #define RCC_IOPRSTR_GPIOBRST             RCC_IOPRSTR_GPIOBRST_Msk
5356 #define RCC_IOPRSTR_GPIOCRST_Pos         (2U)
5357 #define RCC_IOPRSTR_GPIOCRST_Msk         (0x1UL << RCC_IOPRSTR_GPIOCRST_Pos)   /*!< 0x00000004 */
5358 #define RCC_IOPRSTR_GPIOCRST             RCC_IOPRSTR_GPIOCRST_Msk
5359 #define RCC_IOPRSTR_GPIODRST_Pos         (3U)
5360 #define RCC_IOPRSTR_GPIODRST_Msk         (0x1UL << RCC_IOPRSTR_GPIODRST_Pos)   /*!< 0x00000008 */
5361 #define RCC_IOPRSTR_GPIODRST             RCC_IOPRSTR_GPIODRST_Msk
5362 #define RCC_IOPRSTR_GPIOERST_Pos         (4U)
5363 #define RCC_IOPRSTR_GPIOERST_Msk         (0x1UL << RCC_IOPRSTR_GPIOERST_Pos)   /*!< 0x00000010 */
5364 #define RCC_IOPRSTR_GPIOERST             RCC_IOPRSTR_GPIOERST_Msk
5365 #define RCC_IOPRSTR_GPIOFRST_Pos         (5U)
5366 #define RCC_IOPRSTR_GPIOFRST_Msk         (0x1UL << RCC_IOPRSTR_GPIOFRST_Pos)   /*!< 0x00000020 */
5367 #define RCC_IOPRSTR_GPIOFRST             RCC_IOPRSTR_GPIOFRST_Msk
5368 
5369 /********************  Bit definition for RCC_AHBRSTR register  ***************/
5370 #define RCC_AHBRSTR_DMA1RST_Pos          (0U)
5371 #define RCC_AHBRSTR_DMA1RST_Msk          (0x1UL << RCC_AHBRSTR_DMA1RST_Pos)    /*!< 0x00000001 */
5372 #define RCC_AHBRSTR_DMA1RST              RCC_AHBRSTR_DMA1RST_Msk
5373 #define RCC_AHBRSTR_DMA2RST_Pos          (1U)
5374 #define RCC_AHBRSTR_DMA2RST_Msk          (0x1UL << RCC_AHBRSTR_DMA2RST_Pos)    /*!< 0x00000002 */
5375 #define RCC_AHBRSTR_DMA2RST              RCC_AHBRSTR_DMA2RST_Msk
5376 #define RCC_AHBRSTR_FLASHRST_Pos         (8U)
5377 #define RCC_AHBRSTR_FLASHRST_Msk         (0x1UL << RCC_AHBRSTR_FLASHRST_Pos)   /*!< 0x00000100 */
5378 #define RCC_AHBRSTR_FLASHRST             RCC_AHBRSTR_FLASHRST_Msk
5379 #define RCC_AHBRSTR_CRCRST_Pos           (12U)
5380 #define RCC_AHBRSTR_CRCRST_Msk           (0x1UL << RCC_AHBRSTR_CRCRST_Pos)     /*!< 0x00001000 */
5381 #define RCC_AHBRSTR_CRCRST               RCC_AHBRSTR_CRCRST_Msk
5382 
5383 /********************  Bit definition for RCC_APBRSTR1 register  **************/
5384 #define RCC_APBRSTR1_TIM3RST_Pos         (1U)
5385 #define RCC_APBRSTR1_TIM3RST_Msk         (0x1UL << RCC_APBRSTR1_TIM3RST_Pos)   /*!< 0x00000002 */
5386 #define RCC_APBRSTR1_TIM3RST             RCC_APBRSTR1_TIM3RST_Msk
5387 #define RCC_APBRSTR1_TIM4RST_Pos         (2U)
5388 #define RCC_APBRSTR1_TIM4RST_Msk         (0x1UL << RCC_APBRSTR1_TIM4RST_Pos)   /*!< 0x00000004 */
5389 #define RCC_APBRSTR1_TIM4RST             RCC_APBRSTR1_TIM4RST_Msk
5390 #define RCC_APBRSTR1_TIM6RST_Pos         (4U)
5391 #define RCC_APBRSTR1_TIM6RST_Msk         (0x1UL << RCC_APBRSTR1_TIM6RST_Pos)   /*!< 0x00000010 */
5392 #define RCC_APBRSTR1_TIM6RST             RCC_APBRSTR1_TIM6RST_Msk
5393 #define RCC_APBRSTR1_TIM7RST_Pos         (5U)
5394 #define RCC_APBRSTR1_TIM7RST_Msk         (0x1UL << RCC_APBRSTR1_TIM7RST_Pos)   /*!< 0x00000020 */
5395 #define RCC_APBRSTR1_TIM7RST             RCC_APBRSTR1_TIM7RST_Msk
5396 #define RCC_APBRSTR1_USART5RST_Pos       (8U)
5397 #define RCC_APBRSTR1_USART5RST_Msk       (0x1UL << RCC_APBRSTR1_USART5RST_Pos) /*!< 0x00000100 */
5398 #define RCC_APBRSTR1_USART5RST           RCC_APBRSTR1_USART5RST_Msk
5399 #define RCC_APBRSTR1_USART6RST_Pos       (9U)
5400 #define RCC_APBRSTR1_USART6RST_Msk       (0x1UL << RCC_APBRSTR1_USART6RST_Pos) /*!< 0x00000200 */
5401 #define RCC_APBRSTR1_USART6RST           RCC_APBRSTR1_USART6RST_Msk
5402 #define RCC_APBRSTR1_USBRST_Pos          (13U)
5403 #define RCC_APBRSTR1_USBRST_Msk          (0x1UL << RCC_APBRSTR1_USBRST_Pos)    /*!< 0x00002000 */
5404 #define RCC_APBRSTR1_USBRST              RCC_APBRSTR1_USBRST_Msk
5405 #define RCC_APBRSTR1_SPI2RST_Pos         (14U)
5406 #define RCC_APBRSTR1_SPI2RST_Msk         (0x1UL << RCC_APBRSTR1_SPI2RST_Pos)   /*!< 0x00004000 */
5407 #define RCC_APBRSTR1_SPI2RST             RCC_APBRSTR1_SPI2RST_Msk
5408 #define RCC_APBRSTR1_SPI3RST_Pos         (15U)
5409 #define RCC_APBRSTR1_SPI3RST_Msk         (0x1UL << RCC_APBRSTR1_SPI3RST_Pos)   /*!< 0x00008000 */
5410 #define RCC_APBRSTR1_SPI3RST             RCC_APBRSTR1_SPI3RST_Msk
5411 #define RCC_APBRSTR1_USART2RST_Pos       (17U)
5412 #define RCC_APBRSTR1_USART2RST_Msk       (0x1UL << RCC_APBRSTR1_USART2RST_Pos) /*!< 0x00020000 */
5413 #define RCC_APBRSTR1_USART2RST           RCC_APBRSTR1_USART2RST_Msk
5414 #define RCC_APBRSTR1_USART3RST_Pos       (18U)
5415 #define RCC_APBRSTR1_USART3RST_Msk       (0x1UL << RCC_APBRSTR1_USART3RST_Pos) /*!< 0x00040000 */
5416 #define RCC_APBRSTR1_USART3RST           RCC_APBRSTR1_USART3RST_Msk
5417 #define RCC_APBRSTR1_USART4RST_Pos       (19U)
5418 #define RCC_APBRSTR1_USART4RST_Msk       (0x1UL << RCC_APBRSTR1_USART4RST_Pos) /*!< 0x00080000 */
5419 #define RCC_APBRSTR1_USART4RST           RCC_APBRSTR1_USART4RST_Msk
5420 #define RCC_APBRSTR1_I2C1RST_Pos         (21U)
5421 #define RCC_APBRSTR1_I2C1RST_Msk         (0x1UL << RCC_APBRSTR1_I2C1RST_Pos)    /*!< 0x00200000 */
5422 #define RCC_APBRSTR1_I2C1RST             RCC_APBRSTR1_I2C1RST_Msk
5423 #define RCC_APBRSTR1_I2C2RST_Pos         (22U)
5424 #define RCC_APBRSTR1_I2C2RST_Msk         (0x1UL << RCC_APBRSTR1_I2C2RST_Pos)    /*!< 0x00400000 */
5425 #define RCC_APBRSTR1_I2C2RST             RCC_APBRSTR1_I2C2RST_Msk
5426 #define RCC_APBRSTR1_I2C3RST_Pos         (23U)
5427 #define RCC_APBRSTR1_I2C3RST_Msk         (0x1UL << RCC_APBRSTR1_I2C3RST_Pos)    /*!< 0x00800000 */
5428 #define RCC_APBRSTR1_I2C3RST             RCC_APBRSTR1_I2C3RST_Msk
5429 #define RCC_APBRSTR1_DBGRST_Pos          (27U)
5430 #define RCC_APBRSTR1_DBGRST_Msk          (0x1UL << RCC_APBRSTR1_DBGRST_Pos)     /*!< 0x08000000 */
5431 #define RCC_APBRSTR1_DBGRST              RCC_APBRSTR1_DBGRST_Msk
5432 #define RCC_APBRSTR1_PWRRST_Pos          (28U)
5433 #define RCC_APBRSTR1_PWRRST_Msk          (0x1UL << RCC_APBRSTR1_PWRRST_Pos)     /*!< 0x10000000 */
5434 #define RCC_APBRSTR1_PWRRST              RCC_APBRSTR1_PWRRST_Msk
5435 
5436 /********************  Bit definition for RCC_APBRSTR2 register  **************/
5437 #define RCC_APBRSTR2_SYSCFGRST_Pos       (0U)
5438 #define RCC_APBRSTR2_SYSCFGRST_Msk       (0x1UL << RCC_APBRSTR2_SYSCFGRST_Pos)  /*!< 0x00000001 */
5439 #define RCC_APBRSTR2_SYSCFGRST           RCC_APBRSTR2_SYSCFGRST_Msk
5440 #define RCC_APBRSTR2_TIM1RST_Pos         (11U)
5441 #define RCC_APBRSTR2_TIM1RST_Msk         (0x1UL << RCC_APBRSTR2_TIM1RST_Pos)    /*!< 0x00000800 */
5442 #define RCC_APBRSTR2_TIM1RST             RCC_APBRSTR2_TIM1RST_Msk
5443 #define RCC_APBRSTR2_SPI1RST_Pos         (12U)
5444 #define RCC_APBRSTR2_SPI1RST_Msk         (0x1UL << RCC_APBRSTR2_SPI1RST_Pos)    /*!< 0x00001000 */
5445 #define RCC_APBRSTR2_SPI1RST             RCC_APBRSTR2_SPI1RST_Msk
5446 #define RCC_APBRSTR2_USART1RST_Pos       (14U)
5447 #define RCC_APBRSTR2_USART1RST_Msk       (0x1UL << RCC_APBRSTR2_USART1RST_Pos)  /*!< 0x00004000 */
5448 #define RCC_APBRSTR2_USART1RST           RCC_APBRSTR2_USART1RST_Msk
5449 #define RCC_APBRSTR2_TIM14RST_Pos        (15U)
5450 #define RCC_APBRSTR2_TIM14RST_Msk        (0x1UL << RCC_APBRSTR2_TIM14RST_Pos)   /*!< 0x00008000 */
5451 #define RCC_APBRSTR2_TIM14RST            RCC_APBRSTR2_TIM14RST_Msk
5452 #define RCC_APBRSTR2_TIM15RST_Pos        (16U)
5453 #define RCC_APBRSTR2_TIM15RST_Msk        (0x1UL << RCC_APBRSTR2_TIM15RST_Pos)   /*!< 0x00010000 */
5454 #define RCC_APBRSTR2_TIM15RST            RCC_APBRSTR2_TIM15RST_Msk
5455 #define RCC_APBRSTR2_TIM16RST_Pos        (17U)
5456 #define RCC_APBRSTR2_TIM16RST_Msk        (0x1UL << RCC_APBRSTR2_TIM16RST_Pos)   /*!< 0x00020000 */
5457 #define RCC_APBRSTR2_TIM16RST            RCC_APBRSTR2_TIM16RST_Msk
5458 #define RCC_APBRSTR2_TIM17RST_Pos        (18U)
5459 #define RCC_APBRSTR2_TIM17RST_Msk        (0x1UL << RCC_APBRSTR2_TIM17RST_Pos)   /*!< 0x00040000 */
5460 #define RCC_APBRSTR2_TIM17RST            RCC_APBRSTR2_TIM17RST_Msk
5461 #define RCC_APBRSTR2_ADCRST_Pos          (20U)
5462 #define RCC_APBRSTR2_ADCRST_Msk          (0x1UL << RCC_APBRSTR2_ADCRST_Pos)     /*!< 0x00100000 */
5463 #define RCC_APBRSTR2_ADCRST              RCC_APBRSTR2_ADCRST_Msk
5464 
5465 /********************  Bit definition for RCC_IOPENR register  ****************/
5466 #define RCC_IOPENR_GPIOAEN_Pos           (0U)
5467 #define RCC_IOPENR_GPIOAEN_Msk           (0x1UL << RCC_IOPENR_GPIOAEN_Pos)      /*!< 0x00000001 */
5468 #define RCC_IOPENR_GPIOAEN               RCC_IOPENR_GPIOAEN_Msk
5469 #define RCC_IOPENR_GPIOBEN_Pos           (1U)
5470 #define RCC_IOPENR_GPIOBEN_Msk           (0x1UL << RCC_IOPENR_GPIOBEN_Pos)      /*!< 0x00000002 */
5471 #define RCC_IOPENR_GPIOBEN               RCC_IOPENR_GPIOBEN_Msk
5472 #define RCC_IOPENR_GPIOCEN_Pos           (2U)
5473 #define RCC_IOPENR_GPIOCEN_Msk           (0x1UL << RCC_IOPENR_GPIOCEN_Pos)      /*!< 0x00000004 */
5474 #define RCC_IOPENR_GPIOCEN               RCC_IOPENR_GPIOCEN_Msk
5475 #define RCC_IOPENR_GPIODEN_Pos           (3U)
5476 #define RCC_IOPENR_GPIODEN_Msk           (0x1UL << RCC_IOPENR_GPIODEN_Pos)      /*!< 0x00000008 */
5477 #define RCC_IOPENR_GPIODEN               RCC_IOPENR_GPIODEN_Msk
5478 #define RCC_IOPENR_GPIOEEN_Pos           (4U)
5479 #define RCC_IOPENR_GPIOEEN_Msk           (0x1UL << RCC_IOPENR_GPIOEEN_Pos)      /*!< 0x00000010 */
5480 #define RCC_IOPENR_GPIOEEN               RCC_IOPENR_GPIOEEN_Msk
5481 #define RCC_IOPENR_GPIOFEN_Pos           (5U)
5482 #define RCC_IOPENR_GPIOFEN_Msk           (0x1UL << RCC_IOPENR_GPIOFEN_Pos)      /*!< 0x00000020 */
5483 #define RCC_IOPENR_GPIOFEN               RCC_IOPENR_GPIOFEN_Msk
5484 
5485 /********************  Bit definition for RCC_AHBENR register  ****************/
5486 #define RCC_AHBENR_DMA1EN_Pos            (0U)
5487 #define RCC_AHBENR_DMA1EN_Msk            (0x1UL << RCC_AHBENR_DMA1EN_Pos)       /*!< 0x00000001 */
5488 #define RCC_AHBENR_DMA1EN                RCC_AHBENR_DMA1EN_Msk
5489 #define RCC_AHBENR_DMA2EN_Pos            (1U)
5490 #define RCC_AHBENR_DMA2EN_Msk            (0x1UL << RCC_AHBENR_DMA2EN_Pos)       /*!< 0x00000002 */
5491 #define RCC_AHBENR_DMA2EN                RCC_AHBENR_DMA2EN_Msk
5492 #define RCC_AHBENR_FLASHEN_Pos           (8U)
5493 #define RCC_AHBENR_FLASHEN_Msk           (0x1UL << RCC_AHBENR_FLASHEN_Pos)      /*!< 0x00000100 */
5494 #define RCC_AHBENR_FLASHEN               RCC_AHBENR_FLASHEN_Msk
5495 #define RCC_AHBENR_CRCEN_Pos             (12U)
5496 #define RCC_AHBENR_CRCEN_Msk             (0x1UL << RCC_AHBENR_CRCEN_Pos)        /*!< 0x00001000 */
5497 #define RCC_AHBENR_CRCEN                 RCC_AHBENR_CRCEN_Msk
5498 
5499 /********************  Bit definition for RCC_APBENR1 register  ***************/
5500 #define RCC_APBENR1_TIM3EN_Pos           (1U)
5501 #define RCC_APBENR1_TIM3EN_Msk           (0x1UL << RCC_APBENR1_TIM3EN_Pos)      /*!< 0x00000002 */
5502 #define RCC_APBENR1_TIM3EN               RCC_APBENR1_TIM3EN_Msk
5503 #define RCC_APBENR1_TIM4EN_Pos           (2U)
5504 #define RCC_APBENR1_TIM4EN_Msk           (0x1UL << RCC_APBENR1_TIM4EN_Pos)      /*!< 0x00000004 */
5505 #define RCC_APBENR1_TIM4EN               RCC_APBENR1_TIM4EN_Msk
5506 #define RCC_APBENR1_TIM6EN_Pos           (4U)
5507 #define RCC_APBENR1_TIM6EN_Msk           (0x1UL << RCC_APBENR1_TIM6EN_Pos)      /*!< 0x00000010 */
5508 #define RCC_APBENR1_TIM6EN               RCC_APBENR1_TIM6EN_Msk
5509 #define RCC_APBENR1_TIM7EN_Pos           (5U)
5510 #define RCC_APBENR1_TIM7EN_Msk           (0x1UL << RCC_APBENR1_TIM7EN_Pos)      /*!< 0x00000020 */
5511 #define RCC_APBENR1_TIM7EN               RCC_APBENR1_TIM7EN_Msk
5512 #define RCC_APBENR1_USART5EN_Pos         (8U)
5513 #define RCC_APBENR1_USART5EN_Msk         (0x1UL << RCC_APBENR1_USART5EN_Pos)    /*!< 0x00000100 */
5514 #define RCC_APBENR1_USART5EN             RCC_APBENR1_USART5EN_Msk
5515 #define RCC_APBENR1_USART6EN_Pos         (9U)
5516 #define RCC_APBENR1_USART6EN_Msk         (0x1UL << RCC_APBENR1_USART6EN_Pos)    /*!< 0x00000200 */
5517 #define RCC_APBENR1_USART6EN             RCC_APBENR1_USART6EN_Msk
5518 #define RCC_APBENR1_RTCAPBEN_Pos         (10U)
5519 #define RCC_APBENR1_RTCAPBEN_Msk         (0x1UL << RCC_APBENR1_RTCAPBEN_Pos)    /*!< 0x00000400 */
5520 #define RCC_APBENR1_RTCAPBEN             RCC_APBENR1_RTCAPBEN_Msk
5521 #define RCC_APBENR1_WWDGEN_Pos           (11U)
5522 #define RCC_APBENR1_WWDGEN_Msk           (0x1UL << RCC_APBENR1_WWDGEN_Pos)      /*!< 0x00000800 */
5523 #define RCC_APBENR1_WWDGEN               RCC_APBENR1_WWDGEN_Msk
5524 #define RCC_APBENR1_USBEN_Pos            (13U)
5525 #define RCC_APBENR1_USBEN_Msk            (0x1UL << RCC_APBENR1_USBEN_Pos)       /*!< 0x00002000 */
5526 #define RCC_APBENR1_USBEN                RCC_APBENR1_USBEN_Msk
5527 #define RCC_APBENR1_SPI2EN_Pos           (14U)
5528 #define RCC_APBENR1_SPI2EN_Msk           (0x1UL << RCC_APBENR1_SPI2EN_Pos)      /*!< 0x00004000 */
5529 #define RCC_APBENR1_SPI2EN               RCC_APBENR1_SPI2EN_Msk
5530 #define RCC_APBENR1_SPI3EN_Pos           (15U)
5531 #define RCC_APBENR1_SPI3EN_Msk           (0x1UL << RCC_APBENR1_SPI3EN_Pos)      /*!< 0x00008000 */
5532 #define RCC_APBENR1_SPI3EN               RCC_APBENR1_SPI3EN_Msk
5533 #define RCC_APBENR1_USART2EN_Pos         (17U)
5534 #define RCC_APBENR1_USART2EN_Msk         (0x1UL << RCC_APBENR1_USART2EN_Pos)    /*!< 0x00020000 */
5535 #define RCC_APBENR1_USART2EN             RCC_APBENR1_USART2EN_Msk
5536 #define RCC_APBENR1_USART3EN_Pos         (18U)
5537 #define RCC_APBENR1_USART3EN_Msk         (0x1UL << RCC_APBENR1_USART3EN_Pos)    /*!< 0x00040000 */
5538 #define RCC_APBENR1_USART3EN             RCC_APBENR1_USART3EN_Msk
5539 #define RCC_APBENR1_USART4EN_Pos         (19U)
5540 #define RCC_APBENR1_USART4EN_Msk         (0x1UL << RCC_APBENR1_USART4EN_Pos)    /*!< 0x00080000 */
5541 #define RCC_APBENR1_USART4EN             RCC_APBENR1_USART4EN_Msk
5542 #define RCC_APBENR1_I2C1EN_Pos           (21U)
5543 #define RCC_APBENR1_I2C1EN_Msk           (0x1UL << RCC_APBENR1_I2C1EN_Pos)      /*!< 0x00200000 */
5544 #define RCC_APBENR1_I2C1EN               RCC_APBENR1_I2C1EN_Msk
5545 #define RCC_APBENR1_I2C2EN_Pos           (22U)
5546 #define RCC_APBENR1_I2C2EN_Msk           (0x1UL << RCC_APBENR1_I2C2EN_Pos)      /*!< 0x00400000 */
5547 #define RCC_APBENR1_I2C2EN               RCC_APBENR1_I2C2EN_Msk
5548 #define RCC_APBENR1_I2C3EN_Pos           (23U)
5549 #define RCC_APBENR1_I2C3EN_Msk           (0x1UL << RCC_APBENR1_I2C3EN_Pos)      /*!< 0x00800000 */
5550 #define RCC_APBENR1_I2C3EN               RCC_APBENR1_I2C3EN_Msk
5551 #define RCC_APBENR1_DBGEN_Pos            (27U)
5552 #define RCC_APBENR1_DBGEN_Msk            (0x1UL << RCC_APBENR1_DBGEN_Pos)       /*!< 0x08000000 */
5553 #define RCC_APBENR1_DBGEN                RCC_APBENR1_DBGEN_Msk
5554 #define RCC_APBENR1_PWREN_Pos            (28U)
5555 #define RCC_APBENR1_PWREN_Msk            (0x1UL << RCC_APBENR1_PWREN_Pos)       /*!< 0x10000000 */
5556 #define RCC_APBENR1_PWREN                RCC_APBENR1_PWREN_Msk
5557 
5558 /********************  Bit definition for RCC_APBENR2 register  **************/
5559 #define RCC_APBENR2_SYSCFGEN_Pos         (0U)
5560 #define RCC_APBENR2_SYSCFGEN_Msk         (0x1UL << RCC_APBENR2_SYSCFGEN_Pos)    /*!< 0x00000001 */
5561 #define RCC_APBENR2_SYSCFGEN             RCC_APBENR2_SYSCFGEN_Msk
5562 #define RCC_APBENR2_TIM1EN_Pos           (11U)
5563 #define RCC_APBENR2_TIM1EN_Msk           (0x1UL << RCC_APBENR2_TIM1EN_Pos)      /*!< 0x00000800 */
5564 #define RCC_APBENR2_TIM1EN               RCC_APBENR2_TIM1EN_Msk
5565 #define RCC_APBENR2_SPI1EN_Pos           (12U)
5566 #define RCC_APBENR2_SPI1EN_Msk           (0x1UL << RCC_APBENR2_SPI1EN_Pos)      /*!< 0x00001000 */
5567 #define RCC_APBENR2_SPI1EN               RCC_APBENR2_SPI1EN_Msk
5568 #define RCC_APBENR2_USART1EN_Pos         (14U)
5569 #define RCC_APBENR2_USART1EN_Msk         (0x1UL << RCC_APBENR2_USART1EN_Pos)    /*!< 0x00004000 */
5570 #define RCC_APBENR2_USART1EN             RCC_APBENR2_USART1EN_Msk
5571 #define RCC_APBENR2_TIM14EN_Pos          (15U)
5572 #define RCC_APBENR2_TIM14EN_Msk          (0x1UL << RCC_APBENR2_TIM14EN_Pos)     /*!< 0x00008000 */
5573 #define RCC_APBENR2_TIM14EN              RCC_APBENR2_TIM14EN_Msk
5574 #define RCC_APBENR2_TIM15EN_Pos          (16U)
5575 #define RCC_APBENR2_TIM15EN_Msk          (0x1UL << RCC_APBENR2_TIM15EN_Pos)     /*!< 0x00010000 */
5576 #define RCC_APBENR2_TIM15EN              RCC_APBENR2_TIM15EN_Msk
5577 #define RCC_APBENR2_TIM16EN_Pos          (17U)
5578 #define RCC_APBENR2_TIM16EN_Msk          (0x1UL << RCC_APBENR2_TIM16EN_Pos)     /*!< 0x00020000 */
5579 #define RCC_APBENR2_TIM16EN              RCC_APBENR2_TIM16EN_Msk
5580 #define RCC_APBENR2_TIM17EN_Pos          (18U)
5581 #define RCC_APBENR2_TIM17EN_Msk          (0x1UL << RCC_APBENR2_TIM17EN_Pos)     /*!< 0x00040000 */
5582 #define RCC_APBENR2_TIM17EN              RCC_APBENR2_TIM17EN_Msk
5583 #define RCC_APBENR2_ADCEN_Pos            (20U)
5584 #define RCC_APBENR2_ADCEN_Msk            (0x1UL << RCC_APBENR2_ADCEN_Pos)       /*!< 0x00100000 */
5585 #define RCC_APBENR2_ADCEN                RCC_APBENR2_ADCEN_Msk
5586 
5587 /********************  Bit definition for RCC_IOPSMENR register  *************/
5588 #define RCC_IOPSMENR_GPIOASMEN_Pos       (0U)
5589 #define RCC_IOPSMENR_GPIOASMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIOASMEN_Pos)  /*!< 0x00000001 */
5590 #define RCC_IOPSMENR_GPIOASMEN           RCC_IOPSMENR_GPIOASMEN_Msk
5591 #define RCC_IOPSMENR_GPIOBSMEN_Pos       (1U)
5592 #define RCC_IOPSMENR_GPIOBSMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIOBSMEN_Pos)  /*!< 0x00000002 */
5593 #define RCC_IOPSMENR_GPIOBSMEN           RCC_IOPSMENR_GPIOBSMEN_Msk
5594 #define RCC_IOPSMENR_GPIOCSMEN_Pos       (2U)
5595 #define RCC_IOPSMENR_GPIOCSMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIOCSMEN_Pos)  /*!< 0x00000004 */
5596 #define RCC_IOPSMENR_GPIOCSMEN           RCC_IOPSMENR_GPIOCSMEN_Msk
5597 #define RCC_IOPSMENR_GPIODSMEN_Pos       (3U)
5598 #define RCC_IOPSMENR_GPIODSMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIODSMEN_Pos)  /*!< 0x00000008 */
5599 #define RCC_IOPSMENR_GPIODSMEN           RCC_IOPSMENR_GPIODSMEN_Msk
5600 #define RCC_IOPSMENR_GPIOESMEN_Pos       (4U)
5601 #define RCC_IOPSMENR_GPIOESMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIOESMEN_Pos)  /*!< 0x00000010 */
5602 #define RCC_IOPSMENR_GPIOESMEN           RCC_IOPSMENR_GPIOESMEN_Msk
5603 #define RCC_IOPSMENR_GPIOFSMEN_Pos       (5U)
5604 #define RCC_IOPSMENR_GPIOFSMEN_Msk       (0x1UL << RCC_IOPSMENR_GPIOFSMEN_Pos)  /*!< 0x00000020 */
5605 #define RCC_IOPSMENR_GPIOFSMEN           RCC_IOPSMENR_GPIOFSMEN_Msk
5606 
5607 /********************  Bit definition for RCC_AHBSMENR register  *************/
5608 #define RCC_AHBSMENR_DMA1SMEN_Pos        (0U)
5609 #define RCC_AHBSMENR_DMA1SMEN_Msk        (0x1UL << RCC_AHBSMENR_DMA1SMEN_Pos)   /*!< 0x00000001 */
5610 #define RCC_AHBSMENR_DMA1SMEN            RCC_AHBSMENR_DMA1SMEN_Msk
5611 #define RCC_AHBSMENR_DMA2SMEN_Pos        (1U)
5612 #define RCC_AHBSMENR_DMA2SMEN_Msk        (0x1UL << RCC_AHBSMENR_DMA2SMEN_Pos)   /*!< 0x00000002 */
5613 #define RCC_AHBSMENR_DMA2SMEN            RCC_AHBSMENR_DMA2SMEN_Msk
5614 #define RCC_AHBSMENR_FLASHSMEN_Pos       (8U)
5615 #define RCC_AHBSMENR_FLASHSMEN_Msk       (0x1UL << RCC_AHBSMENR_FLASHSMEN_Pos)  /*!< 0x00000100 */
5616 #define RCC_AHBSMENR_FLASHSMEN           RCC_AHBSMENR_FLASHSMEN_Msk
5617 #define RCC_AHBSMENR_SRAMSMEN_Pos        (9U)
5618 #define RCC_AHBSMENR_SRAMSMEN_Msk        (0x1UL << RCC_AHBSMENR_SRAMSMEN_Pos)   /*!< 0x00000200 */
5619 #define RCC_AHBSMENR_SRAMSMEN            RCC_AHBSMENR_SRAMSMEN_Msk
5620 #define RCC_AHBSMENR_CRCSMEN_Pos         (12U)
5621 #define RCC_AHBSMENR_CRCSMEN_Msk         (0x1UL << RCC_AHBSMENR_CRCSMEN_Pos)    /*!< 0x00001000 */
5622 #define RCC_AHBSMENR_CRCSMEN             RCC_AHBSMENR_CRCSMEN_Msk
5623 
5624 /********************  Bit definition for RCC_APBSMENR1 register  *************/
5625 #define RCC_APBSMENR1_TIM3SMEN_Pos       (1U)
5626 #define RCC_APBSMENR1_TIM3SMEN_Msk       (0x1UL << RCC_APBSMENR1_TIM3SMEN_Pos)  /*!< 0x00000002 */
5627 #define RCC_APBSMENR1_TIM3SMEN           RCC_APBSMENR1_TIM3SMEN_Msk
5628 #define RCC_APBSMENR1_TIM4SMEN_Pos       (2U)
5629 #define RCC_APBSMENR1_TIM4SMEN_Msk       (0x1UL << RCC_APBSMENR1_TIM4SMEN_Pos)  /*!< 0x00000004 */
5630 #define RCC_APBSMENR1_TIM4SMEN           RCC_APBSMENR1_TIM4SMEN_Msk
5631 #define RCC_APBSMENR1_TIM6SMEN_Pos       (4U)
5632 #define RCC_APBSMENR1_TIM6SMEN_Msk       (0x1UL << RCC_APBSMENR1_TIM6SMEN_Pos)  /*!< 0x00000010 */
5633 #define RCC_APBSMENR1_TIM6SMEN           RCC_APBSMENR1_TIM6SMEN_Msk
5634 #define RCC_APBSMENR1_TIM7SMEN_Pos       (5U)
5635 #define RCC_APBSMENR1_TIM7SMEN_Msk       (0x1UL << RCC_APBSMENR1_TIM7SMEN_Pos)  /*!< 0x00000020 */
5636 #define RCC_APBSMENR1_TIM7SMEN           RCC_APBSMENR1_TIM7SMEN_Msk
5637 #define RCC_APBSMENR1_USART5SMEN_Pos     (8U)
5638 #define RCC_APBSMENR1_USART5SMEN_Msk     (0x1UL << RCC_APBSMENR1_USART5SMEN_Pos) /*!< 0x00000100 */
5639 #define RCC_APBSMENR1_USART5SMEN         RCC_APBSMENR1_USART5SMEN_Msk
5640 #define RCC_APBSMENR1_USART6SMEN_Pos     (9U)
5641 #define RCC_APBSMENR1_USART6SMEN_Msk     (0x1UL << RCC_APBSMENR1_USART6SMEN_Pos) /*!< 0x00000200 */
5642 #define RCC_APBSMENR1_USART6SMEN         RCC_APBSMENR1_USART6SMEN_Msk
5643 #define RCC_APBSMENR1_RTCAPBSMEN_Pos     (10U)
5644 #define RCC_APBSMENR1_RTCAPBSMEN_Msk     (0x1UL << RCC_APBSMENR1_RTCAPBSMEN_Pos) /*!< 0x00000400 */
5645 #define RCC_APBSMENR1_RTCAPBSMEN         RCC_APBSMENR1_RTCAPBSMEN_Msk
5646 #define RCC_APBSMENR1_WWDGSMEN_Pos       (11U)
5647 #define RCC_APBSMENR1_WWDGSMEN_Msk       (0x1UL << RCC_APBSMENR1_WWDGSMEN_Pos)   /*!< 0x00000800 */
5648 #define RCC_APBSMENR1_WWDGSMEN           RCC_APBSMENR1_WWDGSMEN_Msk
5649 #define RCC_APBSMENR1_USBSMEN_Pos        (13U)
5650 #define RCC_APBSMENR1_USBSMEN_Msk        (0x1UL << RCC_APBSMENR1_USBSMEN_Pos)    /*!< 0x00002000 */
5651 #define RCC_APBSMENR1_USBSMEN            RCC_APBSMENR1_USBSMEN_Msk
5652 #define RCC_APBSMENR1_SPI2SMEN_Pos       (14U)
5653 #define RCC_APBSMENR1_SPI2SMEN_Msk       (0x1UL << RCC_APBSMENR1_SPI2SMEN_Pos)   /*!< 0x00004000 */
5654 #define RCC_APBSMENR1_SPI2SMEN           RCC_APBSMENR1_SPI2SMEN_Msk
5655 #define RCC_APBSMENR1_SPI3SMEN_Pos       (15U)
5656 #define RCC_APBSMENR1_SPI3SMEN_Msk       (0x1UL << RCC_APBSMENR1_SPI3SMEN_Pos)   /*!< 0x00008000 */
5657 #define RCC_APBSMENR1_SPI3SMEN           RCC_APBSMENR1_SPI3SMEN_Msk
5658 #define RCC_APBSMENR1_USART2SMEN_Pos     (17U)
5659 #define RCC_APBSMENR1_USART2SMEN_Msk     (0x1UL << RCC_APBSMENR1_USART2SMEN_Pos) /*!< 0x00020000 */
5660 #define RCC_APBSMENR1_USART2SMEN         RCC_APBSMENR1_USART2SMEN_Msk
5661 #define RCC_APBSMENR1_USART3SMEN_Pos     (18U)
5662 #define RCC_APBSMENR1_USART3SMEN_Msk     (0x1UL << RCC_APBSMENR1_USART3SMEN_Pos) /*!< 0x00040000 */
5663 #define RCC_APBSMENR1_USART3SMEN         RCC_APBSMENR1_USART3SMEN_Msk
5664 #define RCC_APBSMENR1_USART4SMEN_Pos     (19U)
5665 #define RCC_APBSMENR1_USART4SMEN_Msk     (0x1UL << RCC_APBSMENR1_USART4SMEN_Pos) /*!< 0x00080000 */
5666 #define RCC_APBSMENR1_USART4SMEN         RCC_APBSMENR1_USART4SMEN_Msk
5667 #define RCC_APBSMENR1_I2C1SMEN_Pos       (21U)
5668 #define RCC_APBSMENR1_I2C1SMEN_Msk       (0x1UL << RCC_APBSMENR1_I2C1SMEN_Pos)   /*!< 0x00200000 */
5669 #define RCC_APBSMENR1_I2C1SMEN           RCC_APBSMENR1_I2C1SMEN_Msk
5670 #define RCC_APBSMENR1_I2C2SMEN_Pos       (22U)
5671 #define RCC_APBSMENR1_I2C2SMEN_Msk       (0x1UL << RCC_APBSMENR1_I2C2SMEN_Pos)   /*!< 0x00400000 */
5672 #define RCC_APBSMENR1_I2C2SMEN           RCC_APBSMENR1_I2C2SMEN_Msk
5673 #define RCC_APBSMENR1_I2C3SMEN_Pos       (23U)
5674 #define RCC_APBSMENR1_I2C3SMEN_Msk       (0x1UL << RCC_APBSMENR1_I2C3SMEN_Pos)   /*!< 0x00800000 */
5675 #define RCC_APBSMENR1_I2C3SMEN           RCC_APBSMENR1_I2C3SMEN_Msk
5676 #define RCC_APBSMENR1_DBGSMEN_Pos        (27U)
5677 #define RCC_APBSMENR1_DBGSMEN_Msk        (0x1UL << RCC_APBSMENR1_DBGSMEN_Pos)    /*!< 0x08000000 */
5678 #define RCC_APBSMENR1_DBGSMEN            RCC_APBSMENR1_DBGSMEN_Msk
5679 #define RCC_APBSMENR1_PWRSMEN_Pos        (28U)
5680 #define RCC_APBSMENR1_PWRSMEN_Msk        (0x1UL << RCC_APBSMENR1_PWRSMEN_Pos)    /*!< 0x10000000 */
5681 #define RCC_APBSMENR1_PWRSMEN            RCC_APBSMENR1_PWRSMEN_Msk
5682 
5683 /********************  Bit definition for RCC_APBSMENR2 register  *************/
5684 #define RCC_APBSMENR2_SYSCFGSMEN_Pos     (0U)
5685 #define RCC_APBSMENR2_SYSCFGSMEN_Msk     (0x1UL << RCC_APBSMENR2_SYSCFGSMEN_Pos) /*!< 0x00000001 */
5686 #define RCC_APBSMENR2_SYSCFGSMEN         RCC_APBSMENR2_SYSCFGSMEN_Msk
5687 #define RCC_APBSMENR2_TIM1SMEN_Pos       (11U)
5688 #define RCC_APBSMENR2_TIM1SMEN_Msk       (0x1UL << RCC_APBSMENR2_TIM1SMEN_Pos)  /*!< 0x00000800 */
5689 #define RCC_APBSMENR2_TIM1SMEN           RCC_APBSMENR2_TIM1SMEN_Msk
5690 #define RCC_APBSMENR2_SPI1SMEN_Pos       (12U)
5691 #define RCC_APBSMENR2_SPI1SMEN_Msk       (0x1UL << RCC_APBSMENR2_SPI1SMEN_Pos)  /*!< 0x00001000 */
5692 #define RCC_APBSMENR2_SPI1SMEN           RCC_APBSMENR2_SPI1SMEN_Msk
5693 #define RCC_APBSMENR2_USART1SMEN_Pos     (14U)
5694 #define RCC_APBSMENR2_USART1SMEN_Msk     (0x1UL << RCC_APBSMENR2_USART1SMEN_Pos) /*!< 0x00004000 */
5695 #define RCC_APBSMENR2_USART1SMEN         RCC_APBSMENR2_USART1SMEN_Msk
5696 #define RCC_APBSMENR2_TIM14SMEN_Pos      (15U)
5697 #define RCC_APBSMENR2_TIM14SMEN_Msk      (0x1UL << RCC_APBSMENR2_TIM14SMEN_Pos) /*!< 0x00008000 */
5698 #define RCC_APBSMENR2_TIM14SMEN          RCC_APBSMENR2_TIM14SMEN_Msk
5699 #define RCC_APBSMENR2_TIM15SMEN_Pos      (16U)
5700 #define RCC_APBSMENR2_TIM15SMEN_Msk      (0x1UL << RCC_APBSMENR2_TIM15SMEN_Pos) /*!< 0x00010000 */
5701 #define RCC_APBSMENR2_TIM15SMEN          RCC_APBSMENR2_TIM15SMEN_Msk
5702 #define RCC_APBSMENR2_TIM16SMEN_Pos      (17U)
5703 #define RCC_APBSMENR2_TIM16SMEN_Msk      (0x1UL << RCC_APBSMENR2_TIM16SMEN_Pos) /*!< 0x00020000 */
5704 #define RCC_APBSMENR2_TIM16SMEN          RCC_APBSMENR2_TIM16SMEN_Msk
5705 #define RCC_APBSMENR2_TIM17SMEN_Pos      (18U)
5706 #define RCC_APBSMENR2_TIM17SMEN_Msk      (0x1UL << RCC_APBSMENR2_TIM17SMEN_Pos) /*!< 0x00040000 */
5707 #define RCC_APBSMENR2_TIM17SMEN          RCC_APBSMENR2_TIM17SMEN_Msk
5708 #define RCC_APBSMENR2_ADCSMEN_Pos        (20U)
5709 #define RCC_APBSMENR2_ADCSMEN_Msk        (0x1UL << RCC_APBSMENR2_ADCSMEN_Pos)   /*!< 0x00100000 */
5710 #define RCC_APBSMENR2_ADCSMEN            RCC_APBSMENR2_ADCSMEN_Msk
5711 
5712 /********************  Bit definition for RCC_CCIPR register  ******************/
5713 #define RCC_CCIPR_USART1SEL_Pos          (0U)
5714 #define RCC_CCIPR_USART1SEL_Msk          (0x3UL << RCC_CCIPR_USART1SEL_Pos)     /*!< 0x00000003 */
5715 #define RCC_CCIPR_USART1SEL              RCC_CCIPR_USART1SEL_Msk
5716 #define RCC_CCIPR_USART1SEL_0            (0x1UL << RCC_CCIPR_USART1SEL_Pos)     /*!< 0x00000001 */
5717 #define RCC_CCIPR_USART1SEL_1            (0x2UL << RCC_CCIPR_USART1SEL_Pos)     /*!< 0x00000002 */
5718 
5719 #define RCC_CCIPR_USART2SEL_Pos          (2U)
5720 #define RCC_CCIPR_USART2SEL_Msk          (0x3UL << RCC_CCIPR_USART2SEL_Pos)     /*!< 0x0000000C */
5721 #define RCC_CCIPR_USART2SEL              RCC_CCIPR_USART2SEL_Msk
5722 #define RCC_CCIPR_USART2SEL_0            (0x1UL << RCC_CCIPR_USART2SEL_Pos)     /*!< 0x00000004 */
5723 #define RCC_CCIPR_USART2SEL_1            (0x2UL << RCC_CCIPR_USART2SEL_Pos)     /*!< 0x00000008 */
5724 
5725 #define RCC_CCIPR_USART3SEL_Pos          (4U)
5726 #define RCC_CCIPR_USART3SEL_Msk          (0x3UL << RCC_CCIPR_USART3SEL_Pos)     /*!< 0x00000030 */
5727 #define RCC_CCIPR_USART3SEL              RCC_CCIPR_USART3SEL_Msk
5728 #define RCC_CCIPR_USART3SEL_0            (0x1UL << RCC_CCIPR_USART3SEL_Pos)     /*!< 0x00000010 */
5729 #define RCC_CCIPR_USART3SEL_1            (0x2UL << RCC_CCIPR_USART3SEL_Pos)     /*!< 0x00000020 */
5730 
5731 
5732 #define RCC_CCIPR_I2C1SEL_Pos            (12U)
5733 #define RCC_CCIPR_I2C1SEL_Msk            (0x3UL << RCC_CCIPR_I2C1SEL_Pos)       /*!< 0x00003000 */
5734 #define RCC_CCIPR_I2C1SEL                RCC_CCIPR_I2C1SEL_Msk
5735 #define RCC_CCIPR_I2C1SEL_0              (0x1UL << RCC_CCIPR_I2C1SEL_Pos)       /*!< 0x00001000 */
5736 #define RCC_CCIPR_I2C1SEL_1              (0x2UL << RCC_CCIPR_I2C1SEL_Pos)       /*!< 0x00002000 */
5737 
5738 #define RCC_CCIPR_I2C2SEL_Pos           (14U)
5739 #define RCC_CCIPR_I2C2SEL_Msk           (0x3UL << RCC_CCIPR_I2C2SEL_Pos)        /*!< 0x0000C000 */
5740 #define RCC_CCIPR_I2C2SEL               RCC_CCIPR_I2C2SEL_Msk
5741 #define RCC_CCIPR_I2C2SEL_0             (0x1UL << RCC_CCIPR_I2C2SEL_Pos)        /*!< 0x00004000 */
5742 #define RCC_CCIPR_I2C2SEL_1             (0x2UL << RCC_CCIPR_I2C2SEL_Pos)        /*!< 0x00008000 */
5743 
5744 
5745 
5746 
5747 #define RCC_CCIPR_ADCSEL_Pos             (30U)
5748 #define RCC_CCIPR_ADCSEL_Msk             (0x3UL << RCC_CCIPR_ADCSEL_Pos)        /*!< 0xC0000000 */
5749 #define RCC_CCIPR_ADCSEL                 RCC_CCIPR_ADCSEL_Msk
5750 #define RCC_CCIPR_ADCSEL_0               (0x1UL << RCC_CCIPR_ADCSEL_Pos)        /*!< 0x40000000 */
5751 #define RCC_CCIPR_ADCSEL_1               (0x2UL << RCC_CCIPR_ADCSEL_Pos)        /*!< 0x80000000 */
5752 
5753 /********************  Bit definition for RCC_CCIPR2 register  ****************/
5754 #define RCC_CCIPR2_I2S1SEL_Pos            (0U)
5755 #define RCC_CCIPR2_I2S1SEL_Msk            (0x3UL << RCC_CCIPR2_I2S1SEL_Pos)     /*!< 0x00000003 */
5756 #define RCC_CCIPR2_I2S1SEL                RCC_CCIPR2_I2S1SEL_Msk
5757 #define RCC_CCIPR2_I2S1SEL_0              (0x1UL << RCC_CCIPR2_I2S1SEL_Pos)     /*!< 0x00000001 */
5758 #define RCC_CCIPR2_I2S1SEL_1              (0x2UL << RCC_CCIPR2_I2S1SEL_Pos)     /*!< 0x00000002 */
5759 #define RCC_CCIPR2_I2S2SEL_Pos            (2U)
5760 #define RCC_CCIPR2_I2S2SEL_Msk            (0x3UL << RCC_CCIPR2_I2S2SEL_Pos)     /*!< 0x0000000C */
5761 #define RCC_CCIPR2_I2S2SEL                RCC_CCIPR2_I2S2SEL_Msk
5762 #define RCC_CCIPR2_I2S2SEL_0              (0x1UL << RCC_CCIPR2_I2S2SEL_Pos)     /*!< 0x00000004 */
5763 #define RCC_CCIPR2_I2S2SEL_1              (0x2UL << RCC_CCIPR2_I2S2SEL_Pos)     /*!< 0x00000008 */
5764 #define RCC_CCIPR2_USBSEL_Pos             (12U)
5765 #define RCC_CCIPR2_USBSEL_Msk             (0x3UL << RCC_CCIPR2_USBSEL_Pos)     /*!< 0x00003000 */
5766 #define RCC_CCIPR2_USBSEL                 RCC_CCIPR2_USBSEL_Msk
5767 #define RCC_CCIPR2_USBSEL_0               (0x1UL << RCC_CCIPR2_USBSEL_Pos)      /*!< 0x00001000 */
5768 #define RCC_CCIPR2_USBSEL_1               (0x2UL << RCC_CCIPR2_USBSEL_Pos)      /*!< 0x00002000 */
5769 /********************  Bit definition for RCC_BDCR register  ******************/
5770 #define RCC_BDCR_LSEON_Pos               (0U)
5771 #define RCC_BDCR_LSEON_Msk               (0x1UL << RCC_BDCR_LSEON_Pos)          /*!< 0x00000001 */
5772 #define RCC_BDCR_LSEON                   RCC_BDCR_LSEON_Msk
5773 #define RCC_BDCR_LSERDY_Pos              (1U)
5774 #define RCC_BDCR_LSERDY_Msk              (0x1UL << RCC_BDCR_LSERDY_Pos)         /*!< 0x00000002 */
5775 #define RCC_BDCR_LSERDY                  RCC_BDCR_LSERDY_Msk
5776 #define RCC_BDCR_LSEBYP_Pos              (2U)
5777 #define RCC_BDCR_LSEBYP_Msk              (0x1UL << RCC_BDCR_LSEBYP_Pos)         /*!< 0x00000004 */
5778 #define RCC_BDCR_LSEBYP                  RCC_BDCR_LSEBYP_Msk
5779 
5780 #define RCC_BDCR_LSEDRV_Pos              (3U)
5781 #define RCC_BDCR_LSEDRV_Msk              (0x3UL << RCC_BDCR_LSEDRV_Pos)         /*!< 0x00000018 */
5782 #define RCC_BDCR_LSEDRV                  RCC_BDCR_LSEDRV_Msk
5783 #define RCC_BDCR_LSEDRV_0                (0x1UL << RCC_BDCR_LSEDRV_Pos)         /*!< 0x00000008 */
5784 #define RCC_BDCR_LSEDRV_1                (0x2UL << RCC_BDCR_LSEDRV_Pos)         /*!< 0x00000010 */
5785 
5786 #define RCC_BDCR_LSECSSON_Pos            (5U)
5787 #define RCC_BDCR_LSECSSON_Msk            (0x1UL << RCC_BDCR_LSECSSON_Pos)       /*!< 0x00000020 */
5788 #define RCC_BDCR_LSECSSON                RCC_BDCR_LSECSSON_Msk
5789 #define RCC_BDCR_LSECSSD_Pos             (6U)
5790 #define RCC_BDCR_LSECSSD_Msk             (0x1UL << RCC_BDCR_LSECSSD_Pos)        /*!< 0x00000040 */
5791 #define RCC_BDCR_LSECSSD                 RCC_BDCR_LSECSSD_Msk
5792 
5793 #define RCC_BDCR_RTCSEL_Pos              (8U)
5794 #define RCC_BDCR_RTCSEL_Msk              (0x3UL << RCC_BDCR_RTCSEL_Pos)         /*!< 0x00000300 */
5795 #define RCC_BDCR_RTCSEL                  RCC_BDCR_RTCSEL_Msk
5796 #define RCC_BDCR_RTCSEL_0                (0x1UL << RCC_BDCR_RTCSEL_Pos)         /*!< 0x00000100 */
5797 #define RCC_BDCR_RTCSEL_1                (0x2UL << RCC_BDCR_RTCSEL_Pos)         /*!< 0x00000200 */
5798 
5799 #define RCC_BDCR_RTCEN_Pos               (15U)
5800 #define RCC_BDCR_RTCEN_Msk               (0x1UL << RCC_BDCR_RTCEN_Pos)          /*!< 0x00008000 */
5801 #define RCC_BDCR_RTCEN                   RCC_BDCR_RTCEN_Msk
5802 #define RCC_BDCR_BDRST_Pos               (16U)
5803 #define RCC_BDCR_BDRST_Msk               (0x1UL << RCC_BDCR_BDRST_Pos)          /*!< 0x00010000 */
5804 #define RCC_BDCR_BDRST                   RCC_BDCR_BDRST_Msk
5805 
5806 #define RCC_BDCR_LSCOEN_Pos              (24U)
5807 #define RCC_BDCR_LSCOEN_Msk              (0x1UL << RCC_BDCR_LSCOEN_Pos)         /*!< 0x01000000 */
5808 #define RCC_BDCR_LSCOEN                  RCC_BDCR_LSCOEN_Msk
5809 #define RCC_BDCR_LSCOSEL_Pos             (25U)
5810 #define RCC_BDCR_LSCOSEL_Msk             (0x1UL << RCC_BDCR_LSCOSEL_Pos)        /*!< 0x02000000 */
5811 #define RCC_BDCR_LSCOSEL                 RCC_BDCR_LSCOSEL_Msk
5812 
5813 /********************  Bit definition for RCC_CSR register  *******************/
5814 #define RCC_CSR_LSION_Pos                (0U)
5815 #define RCC_CSR_LSION_Msk                (0x1UL << RCC_CSR_LSION_Pos)           /*!< 0x00000001 */
5816 #define RCC_CSR_LSION                    RCC_CSR_LSION_Msk
5817 #define RCC_CSR_LSIRDY_Pos               (1U)
5818 #define RCC_CSR_LSIRDY_Msk               (0x1UL << RCC_CSR_LSIRDY_Pos)          /*!< 0x00000002 */
5819 #define RCC_CSR_LSIRDY                   RCC_CSR_LSIRDY_Msk
5820 
5821 #define RCC_CSR_RMVF_Pos                 (23U)
5822 #define RCC_CSR_RMVF_Msk                 (0x1UL << RCC_CSR_RMVF_Pos)            /*!< 0x00800000 */
5823 #define RCC_CSR_RMVF                     RCC_CSR_RMVF_Msk
5824 #define RCC_CSR_OBLRSTF_Pos              (25U)
5825 #define RCC_CSR_OBLRSTF_Msk              (0x1UL << RCC_CSR_OBLRSTF_Pos)         /*!< 0x02000000 */
5826 #define RCC_CSR_OBLRSTF                  RCC_CSR_OBLRSTF_Msk
5827 #define RCC_CSR_PINRSTF_Pos              (26U)
5828 #define RCC_CSR_PINRSTF_Msk              (0x1UL << RCC_CSR_PINRSTF_Pos)         /*!< 0x04000000 */
5829 #define RCC_CSR_PINRSTF                  RCC_CSR_PINRSTF_Msk
5830 #define RCC_CSR_PWRRSTF_Pos              (27U)
5831 #define RCC_CSR_PWRRSTF_Msk              (0x1UL << RCC_CSR_PWRRSTF_Pos)         /*!< 0x08000000 */
5832 #define RCC_CSR_PWRRSTF                  RCC_CSR_PWRRSTF_Msk
5833 #define RCC_CSR_SFTRSTF_Pos              (28U)
5834 #define RCC_CSR_SFTRSTF_Msk              (0x1UL << RCC_CSR_SFTRSTF_Pos)         /*!< 0x10000000 */
5835 #define RCC_CSR_SFTRSTF                  RCC_CSR_SFTRSTF_Msk
5836 #define RCC_CSR_IWDGRSTF_Pos             (29U)
5837 #define RCC_CSR_IWDGRSTF_Msk             (0x1UL << RCC_CSR_IWDGRSTF_Pos)        /*!< 0x20000000 */
5838 #define RCC_CSR_IWDGRSTF                 RCC_CSR_IWDGRSTF_Msk
5839 #define RCC_CSR_WWDGRSTF_Pos             (30U)
5840 #define RCC_CSR_WWDGRSTF_Msk             (0x1UL << RCC_CSR_WWDGRSTF_Pos)        /*!< 0x40000000 */
5841 #define RCC_CSR_WWDGRSTF                 RCC_CSR_WWDGRSTF_Msk
5842 #define RCC_CSR_LPWRRSTF_Pos             (31U)
5843 #define RCC_CSR_LPWRRSTF_Msk             (0x1UL << RCC_CSR_LPWRRSTF_Pos)        /*!< 0x80000000 */
5844 #define RCC_CSR_LPWRRSTF                 RCC_CSR_LPWRRSTF_Msk
5845 
5846 /******************************************************************************/
5847 /*                                                                            */
5848 /*                           Real-Time Clock (RTC)                            */
5849 /*                                                                            */
5850 /******************************************************************************/
5851 /*
5852 * @brief Specific device feature definitions
5853 */
5854 #define RTC_WAKEUP_SUPPORT
5855 #define RTC_BACKUP_SUPPORT
5856 #define RTC_TAMPER3_SUPPORT          /*!< TAMPER3 only available on some devices */
5857 
5858 /********************  Bits definition for RTC_TR register  *******************/
5859 #define RTC_TR_PM_Pos                (22U)
5860 #define RTC_TR_PM_Msk                (0x1UL << RTC_TR_PM_Pos)                   /*!< 0x00400000 */
5861 #define RTC_TR_PM                    RTC_TR_PM_Msk
5862 #define RTC_TR_HT_Pos                (20U)
5863 #define RTC_TR_HT_Msk                (0x3UL << RTC_TR_HT_Pos)                   /*!< 0x00300000 */
5864 #define RTC_TR_HT                    RTC_TR_HT_Msk
5865 #define RTC_TR_HT_0                  (0x1UL << RTC_TR_HT_Pos)                   /*!< 0x00100000 */
5866 #define RTC_TR_HT_1                  (0x2UL << RTC_TR_HT_Pos)                   /*!< 0x00200000 */
5867 #define RTC_TR_HU_Pos                (16U)
5868 #define RTC_TR_HU_Msk                (0xFUL << RTC_TR_HU_Pos)                   /*!< 0x000F0000 */
5869 #define RTC_TR_HU                    RTC_TR_HU_Msk
5870 #define RTC_TR_HU_0                  (0x1UL << RTC_TR_HU_Pos)                   /*!< 0x00010000 */
5871 #define RTC_TR_HU_1                  (0x2UL << RTC_TR_HU_Pos)                   /*!< 0x00020000 */
5872 #define RTC_TR_HU_2                  (0x4UL << RTC_TR_HU_Pos)                   /*!< 0x00040000 */
5873 #define RTC_TR_HU_3                  (0x8UL << RTC_TR_HU_Pos)                   /*!< 0x00080000 */
5874 #define RTC_TR_MNT_Pos               (12U)
5875 #define RTC_TR_MNT_Msk               (0x7UL << RTC_TR_MNT_Pos)                  /*!< 0x00007000 */
5876 #define RTC_TR_MNT                   RTC_TR_MNT_Msk
5877 #define RTC_TR_MNT_0                 (0x1UL << RTC_TR_MNT_Pos)                  /*!< 0x00001000 */
5878 #define RTC_TR_MNT_1                 (0x2UL << RTC_TR_MNT_Pos)                  /*!< 0x00002000 */
5879 #define RTC_TR_MNT_2                 (0x4UL << RTC_TR_MNT_Pos)                  /*!< 0x00004000 */
5880 #define RTC_TR_MNU_Pos               (8U)
5881 #define RTC_TR_MNU_Msk               (0xFUL << RTC_TR_MNU_Pos)                  /*!< 0x00000F00 */
5882 #define RTC_TR_MNU                   RTC_TR_MNU_Msk
5883 #define RTC_TR_MNU_0                 (0x1UL << RTC_TR_MNU_Pos)                  /*!< 0x00000100 */
5884 #define RTC_TR_MNU_1                 (0x2UL << RTC_TR_MNU_Pos)                  /*!< 0x00000200 */
5885 #define RTC_TR_MNU_2                 (0x4UL << RTC_TR_MNU_Pos)                  /*!< 0x00000400 */
5886 #define RTC_TR_MNU_3                 (0x8UL << RTC_TR_MNU_Pos)                  /*!< 0x00000800 */
5887 #define RTC_TR_ST_Pos                (4U)
5888 #define RTC_TR_ST_Msk                (0x7UL << RTC_TR_ST_Pos)                   /*!< 0x00000070 */
5889 #define RTC_TR_ST                    RTC_TR_ST_Msk
5890 #define RTC_TR_ST_0                  (0x1UL << RTC_TR_ST_Pos)                   /*!< 0x00000010 */
5891 #define RTC_TR_ST_1                  (0x2UL << RTC_TR_ST_Pos)                   /*!< 0x00000020 */
5892 #define RTC_TR_ST_2                  (0x4UL << RTC_TR_ST_Pos)                   /*!< 0x00000040 */
5893 #define RTC_TR_SU_Pos                (0U)
5894 #define RTC_TR_SU_Msk                (0xFUL << RTC_TR_SU_Pos)                   /*!< 0x0000000F */
5895 #define RTC_TR_SU                    RTC_TR_SU_Msk
5896 #define RTC_TR_SU_0                  (0x1UL << RTC_TR_SU_Pos)                   /*!< 0x00000001 */
5897 #define RTC_TR_SU_1                  (0x2UL << RTC_TR_SU_Pos)                   /*!< 0x00000002 */
5898 #define RTC_TR_SU_2                  (0x4UL << RTC_TR_SU_Pos)                   /*!< 0x00000004 */
5899 #define RTC_TR_SU_3                  (0x8UL << RTC_TR_SU_Pos)                   /*!< 0x00000008 */
5900 
5901 /********************  Bits definition for RTC_DR register  *******************/
5902 #define RTC_DR_YT_Pos                (20U)
5903 #define RTC_DR_YT_Msk                (0xFUL << RTC_DR_YT_Pos)                   /*!< 0x00F00000 */
5904 #define RTC_DR_YT                    RTC_DR_YT_Msk
5905 #define RTC_DR_YT_0                  (0x1UL << RTC_DR_YT_Pos)                   /*!< 0x00100000 */
5906 #define RTC_DR_YT_1                  (0x2UL << RTC_DR_YT_Pos)                   /*!< 0x00200000 */
5907 #define RTC_DR_YT_2                  (0x4UL << RTC_DR_YT_Pos)                   /*!< 0x00400000 */
5908 #define RTC_DR_YT_3                  (0x8UL << RTC_DR_YT_Pos)                   /*!< 0x00800000 */
5909 #define RTC_DR_YU_Pos                (16U)
5910 #define RTC_DR_YU_Msk                (0xFUL << RTC_DR_YU_Pos)                   /*!< 0x000F0000 */
5911 #define RTC_DR_YU                    RTC_DR_YU_Msk
5912 #define RTC_DR_YU_0                  (0x1UL << RTC_DR_YU_Pos)                   /*!< 0x00010000 */
5913 #define RTC_DR_YU_1                  (0x2UL << RTC_DR_YU_Pos)                   /*!< 0x00020000 */
5914 #define RTC_DR_YU_2                  (0x4UL << RTC_DR_YU_Pos)                   /*!< 0x00040000 */
5915 #define RTC_DR_YU_3                  (0x8UL << RTC_DR_YU_Pos)                   /*!< 0x00080000 */
5916 #define RTC_DR_WDU_Pos               (13U)
5917 #define RTC_DR_WDU_Msk               (0x7UL << RTC_DR_WDU_Pos)                  /*!< 0x0000E000 */
5918 #define RTC_DR_WDU                   RTC_DR_WDU_Msk
5919 #define RTC_DR_WDU_0                 (0x1UL << RTC_DR_WDU_Pos)                  /*!< 0x00002000 */
5920 #define RTC_DR_WDU_1                 (0x2UL << RTC_DR_WDU_Pos)                  /*!< 0x00004000 */
5921 #define RTC_DR_WDU_2                 (0x4UL << RTC_DR_WDU_Pos)                  /*!< 0x00008000 */
5922 #define RTC_DR_MT_Pos                (12U)
5923 #define RTC_DR_MT_Msk                (0x1UL << RTC_DR_MT_Pos)                   /*!< 0x00001000 */
5924 #define RTC_DR_MT                    RTC_DR_MT_Msk
5925 #define RTC_DR_MU_Pos                (8U)
5926 #define RTC_DR_MU_Msk                (0xFUL << RTC_DR_MU_Pos)                   /*!< 0x00000F00 */
5927 #define RTC_DR_MU                    RTC_DR_MU_Msk
5928 #define RTC_DR_MU_0                  (0x1UL << RTC_DR_MU_Pos)                   /*!< 0x00000100 */
5929 #define RTC_DR_MU_1                  (0x2UL << RTC_DR_MU_Pos)                   /*!< 0x00000200 */
5930 #define RTC_DR_MU_2                  (0x4UL << RTC_DR_MU_Pos)                   /*!< 0x00000400 */
5931 #define RTC_DR_MU_3                  (0x8UL << RTC_DR_MU_Pos)                   /*!< 0x00000800 */
5932 #define RTC_DR_DT_Pos                (4U)
5933 #define RTC_DR_DT_Msk                (0x3UL << RTC_DR_DT_Pos)                   /*!< 0x00000030 */
5934 #define RTC_DR_DT                    RTC_DR_DT_Msk
5935 #define RTC_DR_DT_0                  (0x1UL << RTC_DR_DT_Pos)                   /*!< 0x00000010 */
5936 #define RTC_DR_DT_1                  (0x2UL << RTC_DR_DT_Pos)                   /*!< 0x00000020 */
5937 #define RTC_DR_DU_Pos                (0U)
5938 #define RTC_DR_DU_Msk                (0xFUL << RTC_DR_DU_Pos)                   /*!< 0x0000000F */
5939 #define RTC_DR_DU                    RTC_DR_DU_Msk
5940 #define RTC_DR_DU_0                  (0x1UL << RTC_DR_DU_Pos)                   /*!< 0x00000001 */
5941 #define RTC_DR_DU_1                  (0x2UL << RTC_DR_DU_Pos)                   /*!< 0x00000002 */
5942 #define RTC_DR_DU_2                  (0x4UL << RTC_DR_DU_Pos)                   /*!< 0x00000004 */
5943 #define RTC_DR_DU_3                  (0x8UL << RTC_DR_DU_Pos)                   /*!< 0x00000008 */
5944 
5945 /********************  Bits definition for RTC_SSR register  ******************/
5946 #define RTC_SSR_SS_Pos               (0U)
5947 #define RTC_SSR_SS_Msk               (0xFFFFUL << RTC_SSR_SS_Pos)               /*!< 0x0000FFFF */
5948 #define RTC_SSR_SS                   RTC_SSR_SS_Msk
5949 
5950 /********************  Bits definition for RTC_ICSR register  ******************/
5951 #define RTC_ICSR_RECALPF_Pos         (16U)
5952 #define RTC_ICSR_RECALPF_Msk         (0x1UL << RTC_ICSR_RECALPF_Pos)            /*!< 0x00010000 */
5953 #define RTC_ICSR_RECALPF             RTC_ICSR_RECALPF_Msk
5954 #define RTC_ICSR_INIT_Pos            (7U)
5955 #define RTC_ICSR_INIT_Msk            (0x1UL << RTC_ICSR_INIT_Pos)               /*!< 0x00000080 */
5956 #define RTC_ICSR_INIT                RTC_ICSR_INIT_Msk
5957 #define RTC_ICSR_INITF_Pos           (6U)
5958 #define RTC_ICSR_INITF_Msk           (0x1UL << RTC_ICSR_INITF_Pos)              /*!< 0x00000040 */
5959 #define RTC_ICSR_INITF               RTC_ICSR_INITF_Msk
5960 #define RTC_ICSR_RSF_Pos             (5U)
5961 #define RTC_ICSR_RSF_Msk             (0x1UL << RTC_ICSR_RSF_Pos)                /*!< 0x00000020 */
5962 #define RTC_ICSR_RSF                 RTC_ICSR_RSF_Msk
5963 #define RTC_ICSR_INITS_Pos           (4U)
5964 #define RTC_ICSR_INITS_Msk           (0x1UL << RTC_ICSR_INITS_Pos)              /*!< 0x00000010 */
5965 #define RTC_ICSR_INITS               RTC_ICSR_INITS_Msk
5966 #define RTC_ICSR_SHPF_Pos            (3U)
5967 #define RTC_ICSR_SHPF_Msk            (0x1UL << RTC_ICSR_SHPF_Pos)               /*!< 0x00000008 */
5968 #define RTC_ICSR_SHPF                RTC_ICSR_SHPF_Msk
5969 #define RTC_ICSR_WUTWF_Pos           (2U)
5970 #define RTC_ICSR_WUTWF_Msk           (0x1UL << RTC_ICSR_WUTWF_Pos)              /*!< 0x00000004 */
5971 #define RTC_ICSR_WUTWF               RTC_ICSR_WUTWF_Msk                         /*!< Wakeup timer write flag > */
5972 #define RTC_ICSR_ALRBWF_Pos          (1U)
5973 #define RTC_ICSR_ALRBWF_Msk          (0x1UL << RTC_ICSR_ALRBWF_Pos)             /*!< 0x00000002 */
5974 #define RTC_ICSR_ALRBWF              RTC_ICSR_ALRBWF_Msk
5975 #define RTC_ICSR_ALRAWF_Pos          (0U)
5976 #define RTC_ICSR_ALRAWF_Msk          (0x1UL << RTC_ICSR_ALRAWF_Pos)             /*!< 0x00000001 */
5977 #define RTC_ICSR_ALRAWF              RTC_ICSR_ALRAWF_Msk
5978 
5979 /********************  Bits definition for RTC_PRER register  *****************/
5980 #define RTC_PRER_PREDIV_A_Pos        (16U)
5981 #define RTC_PRER_PREDIV_A_Msk        (0x7FUL << RTC_PRER_PREDIV_A_Pos)          /*!< 0x007F0000 */
5982 #define RTC_PRER_PREDIV_A            RTC_PRER_PREDIV_A_Msk
5983 #define RTC_PRER_PREDIV_S_Pos        (0U)
5984 #define RTC_PRER_PREDIV_S_Msk        (0x7FFFUL << RTC_PRER_PREDIV_S_Pos)        /*!< 0x00007FFF */
5985 #define RTC_PRER_PREDIV_S            RTC_PRER_PREDIV_S_Msk
5986 
5987 /********************  Bits definition for RTC_WUTR register  *****************/
5988 #define RTC_WUTR_WUT_Pos             (0U)
5989 #define RTC_WUTR_WUT_Msk             (0xFFFFUL << RTC_WUTR_WUT_Pos)            /*!< 0x0000FFFF */
5990 #define RTC_WUTR_WUT                 RTC_WUTR_WUT_Msk                          /*!< Wakeup auto-reload value bits > */
5991 
5992 /********************  Bits definition for RTC_CR register  *******************/
5993 #define RTC_CR_OUT2EN_Pos            (31U)
5994 #define RTC_CR_OUT2EN_Msk            (0x1UL << RTC_CR_OUT2EN_Pos)              /*!< 0x80000000 */
5995 #define RTC_CR_OUT2EN                RTC_CR_OUT2EN_Msk                         /*!< RTC_OUT2 output enable */
5996 #define RTC_CR_TAMPALRM_TYPE_Pos     (30U)
5997 #define RTC_CR_TAMPALRM_TYPE_Msk     (0x1UL << RTC_CR_TAMPALRM_TYPE_Pos)       /*!< 0x40000000 */
5998 #define RTC_CR_TAMPALRM_TYPE         RTC_CR_TAMPALRM_TYPE_Msk                  /*!< TAMPALARM output type  */
5999 #define RTC_CR_TAMPALRM_PU_Pos       (29U)
6000 #define RTC_CR_TAMPALRM_PU_Msk       (0x1UL << RTC_CR_TAMPALRM_PU_Pos)         /*!< 0x20000000 */
6001 #define RTC_CR_TAMPALRM_PU           RTC_CR_TAMPALRM_PU_Msk                    /*!< TAMPALARM output pull-up config */
6002 #define RTC_CR_TAMPOE_Pos            (26U)
6003 #define RTC_CR_TAMPOE_Msk            (0x1UL << RTC_CR_TAMPOE_Pos)              /*!< 0x04000000 */
6004 #define RTC_CR_TAMPOE                RTC_CR_TAMPOE_Msk                         /*!< Tamper detection output enable on TAMPALARM  */
6005 #define RTC_CR_TAMPTS_Pos            (25U)
6006 #define RTC_CR_TAMPTS_Msk            (0x1UL << RTC_CR_TAMPTS_Pos)              /*!< 0x02000000 */
6007 #define RTC_CR_TAMPTS                RTC_CR_TAMPTS_Msk                         /*!< Activate timestamp on tamper detection event  */
6008 #define RTC_CR_ITSE_Pos              (24U)
6009 #define RTC_CR_ITSE_Msk              (0x1UL << RTC_CR_ITSE_Pos)                /*!< 0x01000000 */
6010 #define RTC_CR_ITSE                  RTC_CR_ITSE_Msk                           /*!< Timestamp on internal event enable  */
6011 #define RTC_CR_COE_Pos               (23U)
6012 #define RTC_CR_COE_Msk               (0x1UL << RTC_CR_COE_Pos)                 /*!< 0x00800000 */
6013 #define RTC_CR_COE                   RTC_CR_COE_Msk
6014 #define RTC_CR_OSEL_Pos              (21U)
6015 #define RTC_CR_OSEL_Msk              (0x3UL << RTC_CR_OSEL_Pos)                 /*!< 0x00600000 */
6016 #define RTC_CR_OSEL                  RTC_CR_OSEL_Msk
6017 #define RTC_CR_OSEL_0                (0x1UL << RTC_CR_OSEL_Pos)                 /*!< 0x00200000 */
6018 #define RTC_CR_OSEL_1                (0x2UL << RTC_CR_OSEL_Pos)                 /*!< 0x00400000 */
6019 #define RTC_CR_POL_Pos               (20U)
6020 #define RTC_CR_POL_Msk               (0x1UL << RTC_CR_POL_Pos)                  /*!< 0x00100000 */
6021 #define RTC_CR_POL                   RTC_CR_POL_Msk
6022 #define RTC_CR_COSEL_Pos             (19U)
6023 #define RTC_CR_COSEL_Msk             (0x1UL << RTC_CR_COSEL_Pos)                /*!< 0x00080000 */
6024 #define RTC_CR_COSEL                 RTC_CR_COSEL_Msk
6025 #define RTC_CR_BKP_Pos               (18U)
6026 #define RTC_CR_BKP_Msk               (0x1UL << RTC_CR_BKP_Pos)                  /*!< 0x00040000 */
6027 #define RTC_CR_BKP                   RTC_CR_BKP_Msk
6028 #define RTC_CR_SUB1H_Pos             (17U)
6029 #define RTC_CR_SUB1H_Msk             (0x1UL << RTC_CR_SUB1H_Pos)                /*!< 0x00020000 */
6030 #define RTC_CR_SUB1H                 RTC_CR_SUB1H_Msk
6031 #define RTC_CR_ADD1H_Pos             (16U)
6032 #define RTC_CR_ADD1H_Msk             (0x1UL << RTC_CR_ADD1H_Pos)                /*!< 0x00010000 */
6033 #define RTC_CR_ADD1H                 RTC_CR_ADD1H_Msk
6034 #define RTC_CR_TSIE_Pos              (15U)
6035 #define RTC_CR_TSIE_Msk              (0x1UL << RTC_CR_TSIE_Pos)                /*!< 0x00008000 */
6036 #define RTC_CR_TSIE                  RTC_CR_TSIE_Msk                           /*!< Timestamp interrupt enable > */
6037 #define RTC_CR_WUTIE_Pos             (14U)
6038 #define RTC_CR_WUTIE_Msk             (0x1UL << RTC_CR_WUTIE_Pos)               /*!< 0x00004000 */
6039 #define RTC_CR_WUTIE                 RTC_CR_WUTIE_Msk                          /*!< Wakeup timer interrupt enable > */
6040 #define RTC_CR_ALRBIE_Pos            (13U)
6041 #define RTC_CR_ALRBIE_Msk            (0x1UL << RTC_CR_ALRBIE_Pos)              /*!< 0x00002000 */
6042 #define RTC_CR_ALRBIE                RTC_CR_ALRBIE_Msk
6043 #define RTC_CR_ALRAIE_Pos            (12U)
6044 #define RTC_CR_ALRAIE_Msk            (0x1UL << RTC_CR_ALRAIE_Pos)              /*!< 0x00001000 */
6045 #define RTC_CR_ALRAIE                RTC_CR_ALRAIE_Msk
6046 #define RTC_CR_TSE_Pos               (11U)
6047 #define RTC_CR_TSE_Msk               (0x1UL << RTC_CR_TSE_Pos)                 /*!< 0x00000800 */
6048 #define RTC_CR_TSE                   RTC_CR_TSE_Msk                            /*!< timestamp enable > */
6049 #define RTC_CR_WUTE_Pos              (10U)
6050 #define RTC_CR_WUTE_Msk              (0x1UL << RTC_CR_WUTE_Pos)                /*!< 0x00000400 */
6051 #define RTC_CR_WUTE                  RTC_CR_WUTE_Msk                           /*!< Wakeup timer enable > */
6052 #define RTC_CR_ALRBE_Pos             (9U)
6053 #define RTC_CR_ALRBE_Msk             (0x1UL << RTC_CR_ALRBE_Pos)               /*!< 0x00000200 */
6054 #define RTC_CR_ALRBE                 RTC_CR_ALRBE_Msk
6055 #define RTC_CR_ALRAE_Pos             (8U)
6056 #define RTC_CR_ALRAE_Msk             (0x1UL << RTC_CR_ALRAE_Pos)                /*!< 0x00000100 */
6057 #define RTC_CR_ALRAE                 RTC_CR_ALRAE_Msk
6058 #define RTC_CR_FMT_Pos               (6U)
6059 #define RTC_CR_FMT_Msk               (0x1UL << RTC_CR_FMT_Pos)                  /*!< 0x00000040 */
6060 #define RTC_CR_FMT                   RTC_CR_FMT_Msk
6061 #define RTC_CR_BYPSHAD_Pos           (5U)
6062 #define RTC_CR_BYPSHAD_Msk           (0x1UL << RTC_CR_BYPSHAD_Pos)              /*!< 0x00000020 */
6063 #define RTC_CR_BYPSHAD               RTC_CR_BYPSHAD_Msk
6064 #define RTC_CR_REFCKON_Pos           (4U)
6065 #define RTC_CR_REFCKON_Msk           (0x1UL << RTC_CR_REFCKON_Pos)              /*!< 0x00000010 */
6066 #define RTC_CR_REFCKON               RTC_CR_REFCKON_Msk
6067 #define RTC_CR_TSEDGE_Pos            (3U)
6068 #define RTC_CR_TSEDGE_Msk            (0x1UL << RTC_CR_TSEDGE_Pos)              /*!< 0x00000008 */
6069 #define RTC_CR_TSEDGE                RTC_CR_TSEDGE_Msk                         /*!< Timestamp event active edge > */
6070 #define RTC_CR_WUCKSEL_Pos           (0U)
6071 #define RTC_CR_WUCKSEL_Msk           (0x7UL << RTC_CR_WUCKSEL_Pos)             /*!< 0x00000007 */
6072 #define RTC_CR_WUCKSEL               RTC_CR_WUCKSEL_Msk                        /*!< Wakeup clock selection > */
6073 #define RTC_CR_WUCKSEL_0             (0x1UL << RTC_CR_WUCKSEL_Pos)             /*!< 0x00000001 */
6074 #define RTC_CR_WUCKSEL_1             (0x2UL << RTC_CR_WUCKSEL_Pos)             /*!< 0x00000002 */
6075 #define RTC_CR_WUCKSEL_2             (0x4UL << RTC_CR_WUCKSEL_Pos)             /*!< 0x00000004 */
6076 
6077 /********************  Bits definition for RTC_WPR register  ******************/
6078 #define RTC_WPR_KEY_Pos              (0U)
6079 #define RTC_WPR_KEY_Msk              (0xFFUL << RTC_WPR_KEY_Pos)                /*!< 0x000000FF */
6080 #define RTC_WPR_KEY                  RTC_WPR_KEY_Msk
6081 
6082 /********************  Bits definition for RTC_CALR register  *****************/
6083 #define RTC_CALR_CALP_Pos            (15U)
6084 #define RTC_CALR_CALP_Msk            (0x1UL << RTC_CALR_CALP_Pos)               /*!< 0x00008000 */
6085 #define RTC_CALR_CALP                RTC_CALR_CALP_Msk
6086 #define RTC_CALR_CALW8_Pos           (14U)
6087 #define RTC_CALR_CALW8_Msk           (0x1UL << RTC_CALR_CALW8_Pos)              /*!< 0x00004000 */
6088 #define RTC_CALR_CALW8               RTC_CALR_CALW8_Msk
6089 #define RTC_CALR_CALW16_Pos          (13U)
6090 #define RTC_CALR_CALW16_Msk          (0x1UL << RTC_CALR_CALW16_Pos)             /*!< 0x00002000 */
6091 #define RTC_CALR_CALW16              RTC_CALR_CALW16_Msk
6092 #define RTC_CALR_CALM_Pos            (0U)
6093 #define RTC_CALR_CALM_Msk            (0x1FFUL << RTC_CALR_CALM_Pos)             /*!< 0x000001FF */
6094 #define RTC_CALR_CALM                RTC_CALR_CALM_Msk
6095 #define RTC_CALR_CALM_0              (0x001UL << RTC_CALR_CALM_Pos)             /*!< 0x00000001 */
6096 #define RTC_CALR_CALM_1              (0x002UL << RTC_CALR_CALM_Pos)             /*!< 0x00000002 */
6097 #define RTC_CALR_CALM_2              (0x004UL << RTC_CALR_CALM_Pos)             /*!< 0x00000004 */
6098 #define RTC_CALR_CALM_3              (0x008UL << RTC_CALR_CALM_Pos)             /*!< 0x00000008 */
6099 #define RTC_CALR_CALM_4              (0x010UL << RTC_CALR_CALM_Pos)             /*!< 0x00000010 */
6100 #define RTC_CALR_CALM_5              (0x020UL << RTC_CALR_CALM_Pos)             /*!< 0x00000020 */
6101 #define RTC_CALR_CALM_6              (0x040UL << RTC_CALR_CALM_Pos)             /*!< 0x00000040 */
6102 #define RTC_CALR_CALM_7              (0x080UL << RTC_CALR_CALM_Pos)             /*!< 0x00000080 */
6103 #define RTC_CALR_CALM_8              (0x100UL << RTC_CALR_CALM_Pos)             /*!< 0x00000100 */
6104 
6105 /********************  Bits definition for RTC_SHIFTR register  ***************/
6106 #define RTC_SHIFTR_SUBFS_Pos         (0U)
6107 #define RTC_SHIFTR_SUBFS_Msk         (0x7FFFUL << RTC_SHIFTR_SUBFS_Pos)         /*!< 0x00007FFF */
6108 #define RTC_SHIFTR_SUBFS             RTC_SHIFTR_SUBFS_Msk
6109 #define RTC_SHIFTR_ADD1S_Pos         (31U)
6110 #define RTC_SHIFTR_ADD1S_Msk         (0x1UL << RTC_SHIFTR_ADD1S_Pos)            /*!< 0x80000000 */
6111 #define RTC_SHIFTR_ADD1S             RTC_SHIFTR_ADD1S_Msk
6112 
6113 /********************  Bits definition for RTC_TSTR register  *****************/
6114 #define RTC_TSTR_PM_Pos              (22U)
6115 #define RTC_TSTR_PM_Msk              (0x1UL << RTC_TSTR_PM_Pos)                /*!< 0x00400000 */
6116 #define RTC_TSTR_PM                  RTC_TSTR_PM_Msk                           /*!< AM-PM notation > */
6117 #define RTC_TSTR_HT_Pos              (20U)
6118 #define RTC_TSTR_HT_Msk              (0x3UL << RTC_TSTR_HT_Pos)                /*!< 0x00300000 */
6119 #define RTC_TSTR_HT                  RTC_TSTR_HT_Msk
6120 #define RTC_TSTR_HT_0                (0x1UL << RTC_TSTR_HT_Pos)                /*!< 0x00100000 */
6121 #define RTC_TSTR_HT_1                (0x2UL << RTC_TSTR_HT_Pos)                /*!< 0x00200000 */
6122 #define RTC_TSTR_HU_Pos              (16U)
6123 #define RTC_TSTR_HU_Msk              (0xFUL << RTC_TSTR_HU_Pos)                /*!< 0x000F0000 */
6124 #define RTC_TSTR_HU                  RTC_TSTR_HU_Msk
6125 #define RTC_TSTR_HU_0                (0x1UL << RTC_TSTR_HU_Pos)                /*!< 0x00010000 */
6126 #define RTC_TSTR_HU_1                (0x2UL << RTC_TSTR_HU_Pos)                /*!< 0x00020000 */
6127 #define RTC_TSTR_HU_2                (0x4UL << RTC_TSTR_HU_Pos)                /*!< 0x00040000 */
6128 #define RTC_TSTR_HU_3                (0x8UL << RTC_TSTR_HU_Pos)                /*!< 0x00080000 */
6129 #define RTC_TSTR_MNT_Pos             (12U)
6130 #define RTC_TSTR_MNT_Msk             (0x7UL << RTC_TSTR_MNT_Pos)               /*!< 0x00007000 */
6131 #define RTC_TSTR_MNT                 RTC_TSTR_MNT_Msk
6132 #define RTC_TSTR_MNT_0               (0x1UL << RTC_TSTR_MNT_Pos)               /*!< 0x00001000 */
6133 #define RTC_TSTR_MNT_1               (0x2UL << RTC_TSTR_MNT_Pos)               /*!< 0x00002000 */
6134 #define RTC_TSTR_MNT_2               (0x4UL << RTC_TSTR_MNT_Pos)                /*!< 0x00004000 */
6135 #define RTC_TSTR_MNU_Pos             (8U)
6136 #define RTC_TSTR_MNU_Msk             (0xFUL << RTC_TSTR_MNU_Pos)                /*!< 0x00000F00 */
6137 #define RTC_TSTR_MNU                 RTC_TSTR_MNU_Msk
6138 #define RTC_TSTR_MNU_0               (0x1UL << RTC_TSTR_MNU_Pos)                /*!< 0x00000100 */
6139 #define RTC_TSTR_MNU_1               (0x2UL << RTC_TSTR_MNU_Pos)                /*!< 0x00000200 */
6140 #define RTC_TSTR_MNU_2               (0x4UL << RTC_TSTR_MNU_Pos)                /*!< 0x00000400 */
6141 #define RTC_TSTR_MNU_3               (0x8UL << RTC_TSTR_MNU_Pos)                /*!< 0x00000800 */
6142 #define RTC_TSTR_ST_Pos              (4U)
6143 #define RTC_TSTR_ST_Msk              (0x7UL << RTC_TSTR_ST_Pos)                 /*!< 0x00000070 */
6144 #define RTC_TSTR_ST                  RTC_TSTR_ST_Msk
6145 #define RTC_TSTR_ST_0                (0x1UL << RTC_TSTR_ST_Pos)                 /*!< 0x00000010 */
6146 #define RTC_TSTR_ST_1                (0x2UL << RTC_TSTR_ST_Pos)                 /*!< 0x00000020 */
6147 #define RTC_TSTR_ST_2                (0x4UL << RTC_TSTR_ST_Pos)                 /*!< 0x00000040 */
6148 #define RTC_TSTR_SU_Pos              (0U)
6149 #define RTC_TSTR_SU_Msk              (0xFUL << RTC_TSTR_SU_Pos)                 /*!< 0x0000000F */
6150 #define RTC_TSTR_SU                  RTC_TSTR_SU_Msk
6151 #define RTC_TSTR_SU_0                (0x1UL << RTC_TSTR_SU_Pos)                 /*!< 0x00000001 */
6152 #define RTC_TSTR_SU_1                (0x2UL << RTC_TSTR_SU_Pos)                 /*!< 0x00000002 */
6153 #define RTC_TSTR_SU_2                (0x4UL << RTC_TSTR_SU_Pos)                 /*!< 0x00000004 */
6154 #define RTC_TSTR_SU_3                (0x8UL << RTC_TSTR_SU_Pos)                 /*!< 0x00000008 */
6155 
6156 /********************  Bits definition for RTC_TSDR register  *****************/
6157 #define RTC_TSDR_WDU_Pos             (13U)
6158 #define RTC_TSDR_WDU_Msk             (0x7UL << RTC_TSDR_WDU_Pos)               /*!< 0x0000E000 */
6159 #define RTC_TSDR_WDU                 RTC_TSDR_WDU_Msk                          /*!< Week day units > */
6160 #define RTC_TSDR_WDU_0               (0x1UL << RTC_TSDR_WDU_Pos)               /*!< 0x00002000 */
6161 #define RTC_TSDR_WDU_1               (0x2UL << RTC_TSDR_WDU_Pos)               /*!< 0x00004000 */
6162 #define RTC_TSDR_WDU_2               (0x4UL << RTC_TSDR_WDU_Pos)               /*!< 0x00008000 */
6163 #define RTC_TSDR_MT_Pos              (12U)
6164 #define RTC_TSDR_MT_Msk              (0x1UL << RTC_TSDR_MT_Pos)                /*!< 0x00001000 */
6165 #define RTC_TSDR_MT                  RTC_TSDR_MT_Msk
6166 #define RTC_TSDR_MU_Pos              (8U)
6167 #define RTC_TSDR_MU_Msk              (0xFUL << RTC_TSDR_MU_Pos)                /*!< 0x00000F00 */
6168 #define RTC_TSDR_MU                  RTC_TSDR_MU_Msk
6169 #define RTC_TSDR_MU_0                (0x1UL << RTC_TSDR_MU_Pos)                /*!< 0x00000100 */
6170 #define RTC_TSDR_MU_1                (0x2UL << RTC_TSDR_MU_Pos)                /*!< 0x00000200 */
6171 #define RTC_TSDR_MU_2                (0x4UL << RTC_TSDR_MU_Pos)                /*!< 0x00000400 */
6172 #define RTC_TSDR_MU_3                (0x8UL << RTC_TSDR_MU_Pos)                /*!< 0x00000800 */
6173 #define RTC_TSDR_DT_Pos              (4U)
6174 #define RTC_TSDR_DT_Msk              (0x3UL << RTC_TSDR_DT_Pos)                /*!< 0x00000030 */
6175 #define RTC_TSDR_DT                  RTC_TSDR_DT_Msk
6176 #define RTC_TSDR_DT_0                (0x1UL << RTC_TSDR_DT_Pos)                /*!< 0x00000010 */
6177 #define RTC_TSDR_DT_1                (0x2UL << RTC_TSDR_DT_Pos)                /*!< 0x00000020 */
6178 #define RTC_TSDR_DU_Pos              (0U)
6179 #define RTC_TSDR_DU_Msk              (0xFUL << RTC_TSDR_DU_Pos)                /*!< 0x0000000F */
6180 #define RTC_TSDR_DU                  RTC_TSDR_DU_Msk
6181 #define RTC_TSDR_DU_0                (0x1UL << RTC_TSDR_DU_Pos)                /*!< 0x00000001 */
6182 #define RTC_TSDR_DU_1                (0x2UL << RTC_TSDR_DU_Pos)                /*!< 0x00000002 */
6183 #define RTC_TSDR_DU_2                (0x4UL << RTC_TSDR_DU_Pos)                /*!< 0x00000004 */
6184 #define RTC_TSDR_DU_3                (0x8UL << RTC_TSDR_DU_Pos)                /*!< 0x00000008 */
6185 
6186 /********************  Bits definition for RTC_TSSSR register  ****************/
6187 #define RTC_TSSSR_SS_Pos             (0U)
6188 #define RTC_TSSSR_SS_Msk             (0xFFFFUL << RTC_TSSSR_SS_Pos)            /*!< 0x0000FFFF */
6189 #define RTC_TSSSR_SS                 RTC_TSSSR_SS_Msk                          /*!< Sub second value > */
6190 
6191 /********************  Bits definition for RTC_ALRMAR register  ***************/
6192 #define RTC_ALRMAR_MSK4_Pos          (31U)
6193 #define RTC_ALRMAR_MSK4_Msk          (0x1UL << RTC_ALRMAR_MSK4_Pos)            /*!< 0x80000000 */
6194 #define RTC_ALRMAR_MSK4              RTC_ALRMAR_MSK4_Msk
6195 #define RTC_ALRMAR_WDSEL_Pos         (30U)
6196 #define RTC_ALRMAR_WDSEL_Msk         (0x1UL << RTC_ALRMAR_WDSEL_Pos)           /*!< 0x40000000 */
6197 #define RTC_ALRMAR_WDSEL             RTC_ALRMAR_WDSEL_Msk
6198 #define RTC_ALRMAR_DT_Pos            (28U)
6199 #define RTC_ALRMAR_DT_Msk            (0x3UL << RTC_ALRMAR_DT_Pos)              /*!< 0x30000000 */
6200 #define RTC_ALRMAR_DT                RTC_ALRMAR_DT_Msk
6201 #define RTC_ALRMAR_DT_0              (0x1UL << RTC_ALRMAR_DT_Pos)              /*!< 0x10000000 */
6202 #define RTC_ALRMAR_DT_1              (0x2UL << RTC_ALRMAR_DT_Pos)              /*!< 0x20000000 */
6203 #define RTC_ALRMAR_DU_Pos            (24U)
6204 #define RTC_ALRMAR_DU_Msk            (0xFUL << RTC_ALRMAR_DU_Pos)              /*!< 0x0F000000 */
6205 #define RTC_ALRMAR_DU                RTC_ALRMAR_DU_Msk
6206 #define RTC_ALRMAR_DU_0              (0x1UL << RTC_ALRMAR_DU_Pos)              /*!< 0x01000000 */
6207 #define RTC_ALRMAR_DU_1              (0x2UL << RTC_ALRMAR_DU_Pos)              /*!< 0x02000000 */
6208 #define RTC_ALRMAR_DU_2              (0x4UL << RTC_ALRMAR_DU_Pos)              /*!< 0x04000000 */
6209 #define RTC_ALRMAR_DU_3              (0x8UL << RTC_ALRMAR_DU_Pos)              /*!< 0x08000000 */
6210 #define RTC_ALRMAR_MSK3_Pos          (23U)
6211 #define RTC_ALRMAR_MSK3_Msk          (0x1UL << RTC_ALRMAR_MSK3_Pos)            /*!< 0x00800000 */
6212 #define RTC_ALRMAR_MSK3              RTC_ALRMAR_MSK3_Msk
6213 #define RTC_ALRMAR_PM_Pos            (22U)
6214 #define RTC_ALRMAR_PM_Msk            (0x1UL << RTC_ALRMAR_PM_Pos)              /*!< 0x00400000 */
6215 #define RTC_ALRMAR_PM                RTC_ALRMAR_PM_Msk
6216 #define RTC_ALRMAR_HT_Pos            (20U)
6217 #define RTC_ALRMAR_HT_Msk            (0x3UL << RTC_ALRMAR_HT_Pos)              /*!< 0x00300000 */
6218 #define RTC_ALRMAR_HT                RTC_ALRMAR_HT_Msk
6219 #define RTC_ALRMAR_HT_0              (0x1UL << RTC_ALRMAR_HT_Pos)              /*!< 0x00100000 */
6220 #define RTC_ALRMAR_HT_1              (0x2UL << RTC_ALRMAR_HT_Pos)              /*!< 0x00200000 */
6221 #define RTC_ALRMAR_HU_Pos            (16U)
6222 #define RTC_ALRMAR_HU_Msk            (0xFUL << RTC_ALRMAR_HU_Pos)              /*!< 0x000F0000 */
6223 #define RTC_ALRMAR_HU                RTC_ALRMAR_HU_Msk
6224 #define RTC_ALRMAR_HU_0              (0x1UL << RTC_ALRMAR_HU_Pos)              /*!< 0x00010000 */
6225 #define RTC_ALRMAR_HU_1              (0x2UL << RTC_ALRMAR_HU_Pos)              /*!< 0x00020000 */
6226 #define RTC_ALRMAR_HU_2              (0x4UL << RTC_ALRMAR_HU_Pos)              /*!< 0x00040000 */
6227 #define RTC_ALRMAR_HU_3              (0x8UL << RTC_ALRMAR_HU_Pos)              /*!< 0x00080000 */
6228 #define RTC_ALRMAR_MSK2_Pos          (15U)
6229 #define RTC_ALRMAR_MSK2_Msk          (0x1UL << RTC_ALRMAR_MSK2_Pos)            /*!< 0x00008000 */
6230 #define RTC_ALRMAR_MSK2              RTC_ALRMAR_MSK2_Msk
6231 #define RTC_ALRMAR_MNT_Pos           (12U)
6232 #define RTC_ALRMAR_MNT_Msk           (0x7UL << RTC_ALRMAR_MNT_Pos)             /*!< 0x00007000 */
6233 #define RTC_ALRMAR_MNT               RTC_ALRMAR_MNT_Msk
6234 #define RTC_ALRMAR_MNT_0             (0x1UL << RTC_ALRMAR_MNT_Pos)             /*!< 0x00001000 */
6235 #define RTC_ALRMAR_MNT_1             (0x2UL << RTC_ALRMAR_MNT_Pos)             /*!< 0x00002000 */
6236 #define RTC_ALRMAR_MNT_2             (0x4UL << RTC_ALRMAR_MNT_Pos)             /*!< 0x00004000 */
6237 #define RTC_ALRMAR_MNU_Pos           (8U)
6238 #define RTC_ALRMAR_MNU_Msk           (0xFUL << RTC_ALRMAR_MNU_Pos)             /*!< 0x00000F00 */
6239 #define RTC_ALRMAR_MNU               RTC_ALRMAR_MNU_Msk
6240 #define RTC_ALRMAR_MNU_0             (0x1UL << RTC_ALRMAR_MNU_Pos)             /*!< 0x00000100 */
6241 #define RTC_ALRMAR_MNU_1             (0x2UL << RTC_ALRMAR_MNU_Pos)             /*!< 0x00000200 */
6242 #define RTC_ALRMAR_MNU_2             (0x4UL << RTC_ALRMAR_MNU_Pos)             /*!< 0x00000400 */
6243 #define RTC_ALRMAR_MNU_3             (0x8UL << RTC_ALRMAR_MNU_Pos)             /*!< 0x00000800 */
6244 #define RTC_ALRMAR_MSK1_Pos          (7U)
6245 #define RTC_ALRMAR_MSK1_Msk          (0x1UL << RTC_ALRMAR_MSK1_Pos)            /*!< 0x00000080 */
6246 #define RTC_ALRMAR_MSK1              RTC_ALRMAR_MSK1_Msk
6247 #define RTC_ALRMAR_ST_Pos            (4U)
6248 #define RTC_ALRMAR_ST_Msk            (0x7UL << RTC_ALRMAR_ST_Pos)              /*!< 0x00000070 */
6249 #define RTC_ALRMAR_ST                RTC_ALRMAR_ST_Msk
6250 #define RTC_ALRMAR_ST_0              (0x1UL << RTC_ALRMAR_ST_Pos)              /*!< 0x00000010 */
6251 #define RTC_ALRMAR_ST_1              (0x2UL << RTC_ALRMAR_ST_Pos)              /*!< 0x00000020 */
6252 #define RTC_ALRMAR_ST_2              (0x4UL << RTC_ALRMAR_ST_Pos)              /*!< 0x00000040 */
6253 #define RTC_ALRMAR_SU_Pos            (0U)
6254 #define RTC_ALRMAR_SU_Msk            (0xFUL << RTC_ALRMAR_SU_Pos)              /*!< 0x0000000F */
6255 #define RTC_ALRMAR_SU                RTC_ALRMAR_SU_Msk
6256 #define RTC_ALRMAR_SU_0              (0x1UL << RTC_ALRMAR_SU_Pos)              /*!< 0x00000001 */
6257 #define RTC_ALRMAR_SU_1              (0x2UL << RTC_ALRMAR_SU_Pos)              /*!< 0x00000002 */
6258 #define RTC_ALRMAR_SU_2              (0x4UL << RTC_ALRMAR_SU_Pos)              /*!< 0x00000004 */
6259 #define RTC_ALRMAR_SU_3              (0x8UL << RTC_ALRMAR_SU_Pos)              /*!< 0x00000008 */
6260 
6261 /********************  Bits definition for RTC_ALRMASSR register  *************/
6262 #define RTC_ALRMASSR_MASKSS_Pos      (24U)
6263 #define RTC_ALRMASSR_MASKSS_Msk      (0xFUL << RTC_ALRMASSR_MASKSS_Pos)        /*!< 0x0F000000 */
6264 #define RTC_ALRMASSR_MASKSS          RTC_ALRMASSR_MASKSS_Msk
6265 #define RTC_ALRMASSR_MASKSS_0        (0x1UL << RTC_ALRMASSR_MASKSS_Pos)        /*!< 0x01000000 */
6266 #define RTC_ALRMASSR_MASKSS_1        (0x2UL << RTC_ALRMASSR_MASKSS_Pos)        /*!< 0x02000000 */
6267 #define RTC_ALRMASSR_MASKSS_2        (0x4UL << RTC_ALRMASSR_MASKSS_Pos)        /*!< 0x04000000 */
6268 #define RTC_ALRMASSR_MASKSS_3        (0x8UL << RTC_ALRMASSR_MASKSS_Pos)        /*!< 0x08000000 */
6269 #define RTC_ALRMASSR_SS_Pos          (0U)
6270 #define RTC_ALRMASSR_SS_Msk          (0x7FFFUL << RTC_ALRMASSR_SS_Pos)         /*!< 0x00007FFF */
6271 #define RTC_ALRMASSR_SS              RTC_ALRMASSR_SS_Msk
6272 
6273 /********************  Bits definition for RTC_ALRMBR register  ***************/
6274 #define RTC_ALRMBR_MSK4_Pos          (31U)
6275 #define RTC_ALRMBR_MSK4_Msk          (0x1UL << RTC_ALRMBR_MSK4_Pos)            /*!< 0x80000000 */
6276 #define RTC_ALRMBR_MSK4              RTC_ALRMBR_MSK4_Msk
6277 #define RTC_ALRMBR_WDSEL_Pos         (30U)
6278 #define RTC_ALRMBR_WDSEL_Msk         (0x1UL << RTC_ALRMBR_WDSEL_Pos)           /*!< 0x40000000 */
6279 #define RTC_ALRMBR_WDSEL             RTC_ALRMBR_WDSEL_Msk
6280 #define RTC_ALRMBR_DT_Pos            (28U)
6281 #define RTC_ALRMBR_DT_Msk            (0x3UL << RTC_ALRMBR_DT_Pos)              /*!< 0x30000000 */
6282 #define RTC_ALRMBR_DT                RTC_ALRMBR_DT_Msk
6283 #define RTC_ALRMBR_DT_0              (0x1UL << RTC_ALRMBR_DT_Pos)              /*!< 0x10000000 */
6284 #define RTC_ALRMBR_DT_1              (0x2UL << RTC_ALRMBR_DT_Pos)              /*!< 0x20000000 */
6285 #define RTC_ALRMBR_DU_Pos            (24U)
6286 #define RTC_ALRMBR_DU_Msk            (0xFUL << RTC_ALRMBR_DU_Pos)              /*!< 0x0F000000 */
6287 #define RTC_ALRMBR_DU                RTC_ALRMBR_DU_Msk
6288 #define RTC_ALRMBR_DU_0              (0x1UL << RTC_ALRMBR_DU_Pos)              /*!< 0x01000000 */
6289 #define RTC_ALRMBR_DU_1              (0x2UL << RTC_ALRMBR_DU_Pos)              /*!< 0x02000000 */
6290 #define RTC_ALRMBR_DU_2              (0x4UL << RTC_ALRMBR_DU_Pos)              /*!< 0x04000000 */
6291 #define RTC_ALRMBR_DU_3              (0x8UL << RTC_ALRMBR_DU_Pos)              /*!< 0x08000000 */
6292 #define RTC_ALRMBR_MSK3_Pos          (23U)
6293 #define RTC_ALRMBR_MSK3_Msk          (0x1UL << RTC_ALRMBR_MSK3_Pos)            /*!< 0x00800000 */
6294 #define RTC_ALRMBR_MSK3              RTC_ALRMBR_MSK3_Msk
6295 #define RTC_ALRMBR_PM_Pos            (22U)
6296 #define RTC_ALRMBR_PM_Msk            (0x1UL << RTC_ALRMBR_PM_Pos)              /*!< 0x00400000 */
6297 #define RTC_ALRMBR_PM                RTC_ALRMBR_PM_Msk
6298 #define RTC_ALRMBR_HT_Pos            (20U)
6299 #define RTC_ALRMBR_HT_Msk            (0x3UL << RTC_ALRMBR_HT_Pos)              /*!< 0x00300000 */
6300 #define RTC_ALRMBR_HT                RTC_ALRMBR_HT_Msk
6301 #define RTC_ALRMBR_HT_0              (0x1UL << RTC_ALRMBR_HT_Pos)              /*!< 0x00100000 */
6302 #define RTC_ALRMBR_HT_1              (0x2UL << RTC_ALRMBR_HT_Pos)              /*!< 0x00200000 */
6303 #define RTC_ALRMBR_HU_Pos            (16U)
6304 #define RTC_ALRMBR_HU_Msk            (0xFUL << RTC_ALRMBR_HU_Pos)              /*!< 0x000F0000 */
6305 #define RTC_ALRMBR_HU                RTC_ALRMBR_HU_Msk
6306 #define RTC_ALRMBR_HU_0              (0x1UL << RTC_ALRMBR_HU_Pos)              /*!< 0x00010000 */
6307 #define RTC_ALRMBR_HU_1              (0x2UL << RTC_ALRMBR_HU_Pos)              /*!< 0x00020000 */
6308 #define RTC_ALRMBR_HU_2              (0x4UL << RTC_ALRMBR_HU_Pos)              /*!< 0x00040000 */
6309 #define RTC_ALRMBR_HU_3              (0x8UL << RTC_ALRMBR_HU_Pos)              /*!< 0x00080000 */
6310 #define RTC_ALRMBR_MSK2_Pos          (15U)
6311 #define RTC_ALRMBR_MSK2_Msk          (0x1UL << RTC_ALRMBR_MSK2_Pos)            /*!< 0x00008000 */
6312 #define RTC_ALRMBR_MSK2              RTC_ALRMBR_MSK2_Msk
6313 #define RTC_ALRMBR_MNT_Pos           (12U)
6314 #define RTC_ALRMBR_MNT_Msk           (0x7UL << RTC_ALRMBR_MNT_Pos)             /*!< 0x00007000 */
6315 #define RTC_ALRMBR_MNT               RTC_ALRMBR_MNT_Msk
6316 #define RTC_ALRMBR_MNT_0             (0x1UL << RTC_ALRMBR_MNT_Pos)             /*!< 0x00001000 */
6317 #define RTC_ALRMBR_MNT_1             (0x2UL << RTC_ALRMBR_MNT_Pos)             /*!< 0x00002000 */
6318 #define RTC_ALRMBR_MNT_2             (0x4UL << RTC_ALRMBR_MNT_Pos)             /*!< 0x00004000 */
6319 #define RTC_ALRMBR_MNU_Pos           (8U)
6320 #define RTC_ALRMBR_MNU_Msk           (0xFUL << RTC_ALRMBR_MNU_Pos)             /*!< 0x00000F00 */
6321 #define RTC_ALRMBR_MNU               RTC_ALRMBR_MNU_Msk
6322 #define RTC_ALRMBR_MNU_0             (0x1UL << RTC_ALRMBR_MNU_Pos)             /*!< 0x00000100 */
6323 #define RTC_ALRMBR_MNU_1             (0x2UL << RTC_ALRMBR_MNU_Pos)             /*!< 0x00000200 */
6324 #define RTC_ALRMBR_MNU_2             (0x4UL << RTC_ALRMBR_MNU_Pos)             /*!< 0x00000400 */
6325 #define RTC_ALRMBR_MNU_3             (0x8UL << RTC_ALRMBR_MNU_Pos)             /*!< 0x00000800 */
6326 #define RTC_ALRMBR_MSK1_Pos          (7U)
6327 #define RTC_ALRMBR_MSK1_Msk          (0x1UL << RTC_ALRMBR_MSK1_Pos)            /*!< 0x00000080 */
6328 #define RTC_ALRMBR_MSK1              RTC_ALRMBR_MSK1_Msk
6329 #define RTC_ALRMBR_ST_Pos            (4U)
6330 #define RTC_ALRMBR_ST_Msk            (0x7UL << RTC_ALRMBR_ST_Pos)              /*!< 0x00000070 */
6331 #define RTC_ALRMBR_ST                RTC_ALRMBR_ST_Msk
6332 #define RTC_ALRMBR_ST_0              (0x1UL << RTC_ALRMBR_ST_Pos)              /*!< 0x00000010 */
6333 #define RTC_ALRMBR_ST_1              (0x2UL << RTC_ALRMBR_ST_Pos)              /*!< 0x00000020 */
6334 #define RTC_ALRMBR_ST_2              (0x4UL << RTC_ALRMBR_ST_Pos)              /*!< 0x00000040 */
6335 #define RTC_ALRMBR_SU_Pos            (0U)
6336 #define RTC_ALRMBR_SU_Msk            (0xFUL << RTC_ALRMBR_SU_Pos)              /*!< 0x0000000F */
6337 #define RTC_ALRMBR_SU                RTC_ALRMBR_SU_Msk
6338 #define RTC_ALRMBR_SU_0              (0x1UL << RTC_ALRMBR_SU_Pos)              /*!< 0x00000001 */
6339 #define RTC_ALRMBR_SU_1              (0x2UL << RTC_ALRMBR_SU_Pos)              /*!< 0x00000002 */
6340 #define RTC_ALRMBR_SU_2              (0x4UL << RTC_ALRMBR_SU_Pos)              /*!< 0x00000004 */
6341 #define RTC_ALRMBR_SU_3              (0x8UL << RTC_ALRMBR_SU_Pos)              /*!< 0x00000008 */
6342 
6343 /********************  Bits definition for RTC_ALRMASSR register  *************/
6344 #define RTC_ALRMBSSR_MASKSS_Pos      (24U)
6345 #define RTC_ALRMBSSR_MASKSS_Msk      (0xFUL << RTC_ALRMBSSR_MASKSS_Pos)        /*!< 0x0F000000 */
6346 #define RTC_ALRMBSSR_MASKSS          RTC_ALRMBSSR_MASKSS_Msk
6347 #define RTC_ALRMBSSR_MASKSS_0        (0x1UL << RTC_ALRMBSSR_MASKSS_Pos)        /*!< 0x01000000 */
6348 #define RTC_ALRMBSSR_MASKSS_1        (0x2UL << RTC_ALRMBSSR_MASKSS_Pos)        /*!< 0x02000000 */
6349 #define RTC_ALRMBSSR_MASKSS_2        (0x4UL << RTC_ALRMBSSR_MASKSS_Pos)        /*!< 0x04000000 */
6350 #define RTC_ALRMBSSR_MASKSS_3        (0x8UL << RTC_ALRMBSSR_MASKSS_Pos)        /*!< 0x08000000 */
6351 #define RTC_ALRMBSSR_SS_Pos          (0U)
6352 #define RTC_ALRMBSSR_SS_Msk          (0x7FFFUL << RTC_ALRMBSSR_SS_Pos)         /*!< 0x00007FFF */
6353 #define RTC_ALRMBSSR_SS              RTC_ALRMBSSR_SS_Msk
6354 
6355 /********************  Bits definition for RTC_SR register  *******************/
6356 #define RTC_SR_ITSF_Pos              (5U)
6357 #define RTC_SR_ITSF_Msk              (0x1UL << RTC_SR_ITSF_Pos)                /*!< 0x00000020 */
6358 #define RTC_SR_ITSF                  RTC_SR_ITSF_Msk
6359 #define RTC_SR_TSOVF_Pos             (4U)
6360 #define RTC_SR_TSOVF_Msk             (0x1UL << RTC_SR_TSOVF_Pos)               /*!< 0x00000010 */
6361 #define RTC_SR_TSOVF                 RTC_SR_TSOVF_Msk                          /*!< Timestamp overflow flag > */
6362 #define RTC_SR_TSF_Pos               (3U)
6363 #define RTC_SR_TSF_Msk               (0x1UL << RTC_SR_TSF_Pos)                 /*!< 0x00000008 */
6364 #define RTC_SR_TSF                   RTC_SR_TSF_Msk                            /*!< Timestamp flag > */
6365 #define RTC_SR_WUTF_Pos              (2U)
6366 #define RTC_SR_WUTF_Msk              (0x1UL << RTC_SR_WUTF_Pos)                /*!< 0x00000004 */
6367 #define RTC_SR_WUTF                  RTC_SR_WUTF_Msk                           /*!< Wakeup timer flag > */
6368 #define RTC_SR_ALRBF_Pos             (1U)
6369 #define RTC_SR_ALRBF_Msk             (0x1UL << RTC_SR_ALRBF_Pos)               /*!< 0x00000002 */
6370 #define RTC_SR_ALRBF                 RTC_SR_ALRBF_Msk
6371 #define RTC_SR_ALRAF_Pos             (0U)
6372 #define RTC_SR_ALRAF_Msk             (0x1UL << RTC_SR_ALRAF_Pos)               /*!< 0x00000001 */
6373 #define RTC_SR_ALRAF                 RTC_SR_ALRAF_Msk
6374 
6375 /********************  Bits definition for RTC_MISR register  *****************/
6376 #define RTC_MISR_ITSMF_Pos           (5U)
6377 #define RTC_MISR_ITSMF_Msk           (0x1UL << RTC_MISR_ITSMF_Pos)             /*!< 0x00000020 */
6378 #define RTC_MISR_ITSMF               RTC_MISR_ITSMF_Msk
6379 #define RTC_MISR_TSOVMF_Pos          (4U)
6380 #define RTC_MISR_TSOVMF_Msk          (0x1UL << RTC_MISR_TSOVMF_Pos)            /*!< 0x00000010 */
6381 #define RTC_MISR_TSOVMF              RTC_MISR_TSOVMF_Msk                       /*!< Timestamp overflow masked flag > */
6382 #define RTC_MISR_TSMF_Pos            (3U)
6383 #define RTC_MISR_TSMF_Msk            (0x1UL << RTC_MISR_TSMF_Pos)              /*!< 0x00000008 */
6384 #define RTC_MISR_TSMF                RTC_MISR_TSMF_Msk                         /*!< Timestamp masked flag > */
6385 #define RTC_MISR_WUTMF_Pos           (2U)
6386 #define RTC_MISR_WUTMF_Msk           (0x1UL << RTC_MISR_WUTMF_Pos)             /*!< 0x00000004 */
6387 #define RTC_MISR_WUTMF               RTC_MISR_WUTMF_Msk                        /*!< Wakeup timer masked flag > */
6388 #define RTC_MISR_ALRBMF_Pos          (1U)
6389 #define RTC_MISR_ALRBMF_Msk          (0x1UL << RTC_MISR_ALRBMF_Pos)            /*!< 0x00000002 */
6390 #define RTC_MISR_ALRBMF              RTC_MISR_ALRBMF_Msk
6391 #define RTC_MISR_ALRAMF_Pos          (0U)
6392 #define RTC_MISR_ALRAMF_Msk          (0x1UL << RTC_MISR_ALRAMF_Pos)            /*!< 0x00000001 */
6393 #define RTC_MISR_ALRAMF              RTC_MISR_ALRAMF_Msk
6394 
6395 /********************  Bits definition for RTC_SCR register  ******************/
6396 #define RTC_SCR_CITSF_Pos            (5U)
6397 #define RTC_SCR_CITSF_Msk            (0x1UL << RTC_SCR_CITSF_Pos)              /*!< 0x00000020 */
6398 #define RTC_SCR_CITSF                RTC_SCR_CITSF_Msk
6399 #define RTC_SCR_CTSOVF_Pos           (4U)
6400 #define RTC_SCR_CTSOVF_Msk           (0x1UL << RTC_SCR_CTSOVF_Pos)             /*!< 0x00000010 */
6401 #define RTC_SCR_CTSOVF               RTC_SCR_CTSOVF_Msk                        /*!< Clear timestamp overflow flag > */
6402 #define RTC_SCR_CTSF_Pos             (3U)
6403 #define RTC_SCR_CTSF_Msk             (0x1UL << RTC_SCR_CTSF_Pos)               /*!< 0x00000008 */
6404 #define RTC_SCR_CTSF                 RTC_SCR_CTSF_Msk                          /*!< Clear timestamp flag > */
6405 #define RTC_SCR_CWUTF_Pos            (2U)
6406 #define RTC_SCR_CWUTF_Msk            (0x1UL << RTC_SCR_CWUTF_Pos)              /*!< 0x00000004 */
6407 #define RTC_SCR_CWUTF                RTC_SCR_CWUTF_Msk                         /*!< Clear wakeup timer flag > */
6408 #define RTC_SCR_CALRBF_Pos           (1U)
6409 #define RTC_SCR_CALRBF_Msk           (0x1UL << RTC_SCR_CALRBF_Pos)             /*!< 0x00000002 */
6410 #define RTC_SCR_CALRBF               RTC_SCR_CALRBF_Msk
6411 #define RTC_SCR_CALRAF_Pos           (0U)
6412 #define RTC_SCR_CALRAF_Msk           (0x1UL << RTC_SCR_CALRAF_Pos)             /*!< 0x00000001 */
6413 #define RTC_SCR_CALRAF               RTC_SCR_CALRAF_Msk
6414 
6415 /******************************************************************************/
6416 /*                                                                            */
6417 /*                     Tamper and backup register (TAMP)                      */
6418 /*                                                                            */
6419 /******************************************************************************/
6420 /********************  Bits definition for TAMP_CR1 register  *****************/
6421 #define TAMP_CR1_TAMP1E_Pos          (0U)
6422 #define TAMP_CR1_TAMP1E_Msk          (0x1UL << TAMP_CR1_TAMP1E_Pos)             /*!< 0x00000001 */
6423 #define TAMP_CR1_TAMP1E              TAMP_CR1_TAMP1E_Msk
6424 #define TAMP_CR1_TAMP2E_Pos          (1U)
6425 #define TAMP_CR1_TAMP2E_Msk          (0x1UL << TAMP_CR1_TAMP2E_Pos)             /*!< 0x00000002 */
6426 #define TAMP_CR1_TAMP2E              TAMP_CR1_TAMP2E_Msk
6427 #define TAMP_CR1_TAMP3E_Pos          (2U)
6428 #define TAMP_CR1_TAMP3E_Msk          (0x1UL << TAMP_CR1_TAMP3E_Pos)             /*!< 0x00000004 */
6429 #define TAMP_CR1_TAMP3E              TAMP_CR1_TAMP3E_Msk
6430 #define TAMP_CR1_ITAMP3E_Pos         (18U)
6431 #define TAMP_CR1_ITAMP3E_Msk         (0x1UL << TAMP_CR1_ITAMP3E_Pos)            /*!< 0x00040000 */
6432 #define TAMP_CR1_ITAMP3E             TAMP_CR1_ITAMP3E_Msk
6433 #define TAMP_CR1_ITAMP4E_Pos         (19U)
6434 #define TAMP_CR1_ITAMP4E_Msk         (0x1UL << TAMP_CR1_ITAMP4E_Pos)            /*!< 0x00080000 */
6435 #define TAMP_CR1_ITAMP4E             TAMP_CR1_ITAMP4E_Msk
6436 #define TAMP_CR1_ITAMP5E_Pos         (20U)
6437 #define TAMP_CR1_ITAMP5E_Msk         (0x1UL << TAMP_CR1_ITAMP5E_Pos)            /*!< 0x00100000 */
6438 #define TAMP_CR1_ITAMP5E             TAMP_CR1_ITAMP5E_Msk
6439 #define TAMP_CR1_ITAMP6E_Pos         (21U)
6440 #define TAMP_CR1_ITAMP6E_Msk         (0x1UL << TAMP_CR1_ITAMP6E_Pos)            /*!< 0x00200000 */
6441 #define TAMP_CR1_ITAMP6E             TAMP_CR1_ITAMP6E_Msk
6442 
6443 /********************  Bits definition for TAMP_CR2 register  *****************/
6444 #define TAMP_CR2_TAMP1NOERASE_Pos    (0U)
6445 #define TAMP_CR2_TAMP1NOERASE_Msk    (0x1UL << TAMP_CR2_TAMP1NOERASE_Pos)       /*!< 0x00000001 */
6446 #define TAMP_CR2_TAMP1NOERASE        TAMP_CR2_TAMP1NOERASE_Msk
6447 #define TAMP_CR2_TAMP2NOERASE_Pos    (1U)
6448 #define TAMP_CR2_TAMP2NOERASE_Msk    (0x1UL << TAMP_CR2_TAMP2NOERASE_Pos)       /*!< 0x00000002 */
6449 #define TAMP_CR2_TAMP2NOERASE        TAMP_CR2_TAMP2NOERASE_Msk
6450 #define TAMP_CR2_TAMP3NOERASE_Pos    (2U)
6451 #define TAMP_CR2_TAMP3NOERASE_Msk    (0x1UL << TAMP_CR2_TAMP3NOERASE_Pos)       /*!< 0x00000004 */
6452 #define TAMP_CR2_TAMP3NOERASE        TAMP_CR2_TAMP3NOERASE_Msk
6453 #define TAMP_CR2_TAMP1MSK_Pos        (16U)
6454 #define TAMP_CR2_TAMP1MSK_Msk        (0x1UL << TAMP_CR2_TAMP1MSK_Pos)           /*!< 0x00010000 */
6455 #define TAMP_CR2_TAMP1MSK            TAMP_CR2_TAMP1MSK_Msk
6456 #define TAMP_CR2_TAMP2MSK_Pos        (17U)
6457 #define TAMP_CR2_TAMP2MSK_Msk        (0x1UL << TAMP_CR2_TAMP2MSK_Pos)           /*!< 0x00020000 */
6458 #define TAMP_CR2_TAMP2MSK            TAMP_CR2_TAMP2MSK_Msk
6459 #define TAMP_CR2_TAMP3MSK_Pos        (18U)
6460 #define TAMP_CR2_TAMP3MSK_Msk        (0x1UL << TAMP_CR2_TAMP3MSK_Pos)           /*!< 0x00040000 */
6461 #define TAMP_CR2_TAMP3MSK            TAMP_CR2_TAMP3MSK_Msk
6462 #define TAMP_CR2_TAMP1TRG_Pos        (24U)
6463 #define TAMP_CR2_TAMP1TRG_Msk        (0x1UL << TAMP_CR2_TAMP1TRG_Pos)           /*!< 0x01000000 */
6464 #define TAMP_CR2_TAMP1TRG            TAMP_CR2_TAMP1TRG_Msk
6465 #define TAMP_CR2_TAMP2TRG_Pos        (25U)
6466 #define TAMP_CR2_TAMP2TRG_Msk        (0x1UL << TAMP_CR2_TAMP2TRG_Pos)           /*!< 0x02000000 */
6467 #define TAMP_CR2_TAMP2TRG            TAMP_CR2_TAMP2TRG_Msk
6468 #define TAMP_CR2_TAMP3TRG_Pos        (26U)
6469 #define TAMP_CR2_TAMP3TRG_Msk        (0x1UL << TAMP_CR2_TAMP3TRG_Pos)           /*!< 0x04000000 */
6470 #define TAMP_CR2_TAMP3TRG            TAMP_CR2_TAMP3TRG_Msk
6471 
6472 /********************  Bits definition for TAMP_FLTCR register  ***************/
6473 #define TAMP_FLTCR_TAMPFREQ_0        0x00000001U
6474 #define TAMP_FLTCR_TAMPFREQ_1        0x00000002U
6475 #define TAMP_FLTCR_TAMPFREQ_2        0x00000004U
6476 #define TAMP_FLTCR_TAMPFREQ_Pos      (0U)
6477 #define TAMP_FLTCR_TAMPFREQ_Msk      (0x7UL << TAMP_FLTCR_TAMPFREQ_Pos)         /*!< 0x00000007 */
6478 #define TAMP_FLTCR_TAMPFREQ          TAMP_FLTCR_TAMPFREQ_Msk
6479 #define TAMP_FLTCR_TAMPFLT_0         0x00000008U
6480 #define TAMP_FLTCR_TAMPFLT_1         0x00000010U
6481 #define TAMP_FLTCR_TAMPFLT_Pos       (3U)
6482 #define TAMP_FLTCR_TAMPFLT_Msk       (0x3UL << TAMP_FLTCR_TAMPFLT_Pos)          /*!< 0x00000018 */
6483 #define TAMP_FLTCR_TAMPFLT           TAMP_FLTCR_TAMPFLT_Msk
6484 #define TAMP_FLTCR_TAMPPRCH_0        0x00000020U
6485 #define TAMP_FLTCR_TAMPPRCH_1        0x00000040U
6486 #define TAMP_FLTCR_TAMPPRCH_Pos      (5U)
6487 #define TAMP_FLTCR_TAMPPRCH_Msk      (0x3UL << TAMP_FLTCR_TAMPPRCH_Pos)         /*!< 0x00000060 */
6488 #define TAMP_FLTCR_TAMPPRCH          TAMP_FLTCR_TAMPPRCH_Msk
6489 #define TAMP_FLTCR_TAMPPUDIS_Pos     (7U)
6490 #define TAMP_FLTCR_TAMPPUDIS_Msk     (0x1UL << TAMP_FLTCR_TAMPPUDIS_Pos)        /*!< 0x00000080 */
6491 #define TAMP_FLTCR_TAMPPUDIS         TAMP_FLTCR_TAMPPUDIS_Msk
6492 
6493 /********************  Bits definition for TAMP_IER register  *****************/
6494 #define TAMP_IER_TAMP1IE_Pos         (0U)
6495 #define TAMP_IER_TAMP1IE_Msk         (0x1UL << TAMP_IER_TAMP1IE_Pos)            /*!< 0x00000001 */
6496 #define TAMP_IER_TAMP1IE             TAMP_IER_TAMP1IE_Msk
6497 #define TAMP_IER_TAMP2IE_Pos         (1U)
6498 #define TAMP_IER_TAMP2IE_Msk         (0x1UL << TAMP_IER_TAMP2IE_Pos)            /*!< 0x00000002 */
6499 #define TAMP_IER_TAMP2IE             TAMP_IER_TAMP2IE_Msk
6500 #define TAMP_IER_TAMP3IE_Pos         (2U)
6501 #define TAMP_IER_TAMP3IE_Msk         (0x1UL << TAMP_IER_TAMP3IE_Pos)            /*!< 0x00000004 */
6502 #define TAMP_IER_TAMP3IE             TAMP_IER_TAMP3IE_Msk
6503 #define TAMP_IER_ITAMP3IE_Pos        (18U)
6504 #define TAMP_IER_ITAMP3IE_Msk        (0x1UL << TAMP_IER_ITAMP3IE_Pos)           /*!< 0x00040000 */
6505 #define TAMP_IER_ITAMP3IE            TAMP_IER_ITAMP3IE_Msk
6506 #define TAMP_IER_ITAMP4IE_Pos        (19U)
6507 #define TAMP_IER_ITAMP4IE_Msk        (0x1UL << TAMP_IER_ITAMP4IE_Pos)           /*!< 0x00080000 */
6508 #define TAMP_IER_ITAMP4IE            TAMP_IER_ITAMP4IE_Msk
6509 #define TAMP_IER_ITAMP5IE_Pos        (20U)
6510 #define TAMP_IER_ITAMP5IE_Msk        (0x1UL << TAMP_IER_ITAMP5IE_Pos)           /*!< 0x00100000 */
6511 #define TAMP_IER_ITAMP5IE            TAMP_IER_ITAMP5IE_Msk
6512 #define TAMP_IER_ITAMP6IE_Pos        (21U)
6513 #define TAMP_IER_ITAMP6IE_Msk        (0x1UL << TAMP_IER_ITAMP6IE_Pos)           /*!< 0x00200000 */
6514 #define TAMP_IER_ITAMP6IE            TAMP_IER_ITAMP6IE_Msk
6515 
6516 /********************  Bits definition for TAMP_SR register  ******************/
6517 #define TAMP_SR_TAMP1F_Pos           (0U)
6518 #define TAMP_SR_TAMP1F_Msk           (0x1UL << TAMP_SR_TAMP1F_Pos)              /*!< 0x00000001 */
6519 #define TAMP_SR_TAMP1F               TAMP_SR_TAMP1F_Msk
6520 #define TAMP_SR_TAMP2F_Pos           (1U)
6521 #define TAMP_SR_TAMP2F_Msk           (0x1UL << TAMP_SR_TAMP2F_Pos)              /*!< 0x00000002 */
6522 #define TAMP_SR_TAMP2F               TAMP_SR_TAMP2F_Msk
6523 #define TAMP_SR_TAMP3F_Pos           (2U)
6524 #define TAMP_SR_TAMP3F_Msk           (0x1UL << TAMP_SR_TAMP3F_Pos)              /*!< 0x00000004 */
6525 #define TAMP_SR_TAMP3F               TAMP_SR_TAMP3F_Msk
6526 #define TAMP_SR_ITAMP3F_Pos          (18U)
6527 #define TAMP_SR_ITAMP3F_Msk          (0x1UL << TAMP_SR_ITAMP3F_Pos)             /*!< 0x00040000 */
6528 #define TAMP_SR_ITAMP3F              TAMP_SR_ITAMP3F_Msk
6529 #define TAMP_SR_ITAMP4F_Pos          (19U)
6530 #define TAMP_SR_ITAMP4F_Msk          (0x1UL << TAMP_SR_ITAMP4F_Pos)             /*!< 0x00080000 */
6531 #define TAMP_SR_ITAMP4F              TAMP_SR_ITAMP4F_Msk
6532 #define TAMP_SR_ITAMP5F_Pos          (20U)
6533 #define TAMP_SR_ITAMP5F_Msk          (0x1UL << TAMP_SR_ITAMP5F_Pos)             /*!< 0x00100000 */
6534 #define TAMP_SR_ITAMP5F              TAMP_SR_ITAMP5F_Msk
6535 #define TAMP_SR_ITAMP6F_Pos          (21U)
6536 #define TAMP_SR_ITAMP6F_Msk          (0x1UL << TAMP_SR_ITAMP6F_Pos)             /*!< 0x00200000 */
6537 #define TAMP_SR_ITAMP6F              TAMP_SR_ITAMP6F_Msk
6538 
6539 /********************  Bits definition for TAMP_MISR register  ****************/
6540 #define TAMP_MISR_TAMP1MF_Pos        (0U)
6541 #define TAMP_MISR_TAMP1MF_Msk        (0x1UL << TAMP_MISR_TAMP1MF_Pos)           /*!< 0x00000001 */
6542 #define TAMP_MISR_TAMP1MF            TAMP_MISR_TAMP1MF_Msk
6543 #define TAMP_MISR_TAMP2MF_Pos        (1U)
6544 #define TAMP_MISR_TAMP2MF_Msk        (0x1UL << TAMP_MISR_TAMP2MF_Pos)           /*!< 0x00000002 */
6545 #define TAMP_MISR_TAMP2MF            TAMP_MISR_TAMP2MF_Msk
6546 #define TAMP_MISR_TAMP3MF_Pos        (2U)
6547 #define TAMP_MISR_TAMP3MF_Msk        (0x1UL << TAMP_MISR_TAMP3MF_Pos)           /*!< 0x00000004 */
6548 #define TAMP_MISR_TAMP3MF            TAMP_MISR_TAMP3MF_Msk
6549 #define TAMP_MISR_ITAMP3MF_Pos       (18U)
6550 #define TAMP_MISR_ITAMP3MF_Msk       (0x1UL << TAMP_MISR_ITAMP3MF_Pos)          /*!< 0x00040000 */
6551 #define TAMP_MISR_ITAMP3MF           TAMP_MISR_ITAMP3MF_Msk
6552 #define TAMP_MISR_ITAMP4MF_Pos       (19U)
6553 #define TAMP_MISR_ITAMP4MF_Msk       (0x1UL << TAMP_MISR_ITAMP4MF_Pos)          /*!< 0x00080000 */
6554 #define TAMP_MISR_ITAMP4MF           TAMP_MISR_ITAMP4MF_Msk
6555 #define TAMP_MISR_ITAMP5MF_Pos       (20U)
6556 #define TAMP_MISR_ITAMP5MF_Msk       (0x1UL << TAMP_MISR_ITAMP5MF_Pos)          /*!< 0x00100000 */
6557 #define TAMP_MISR_ITAMP5MF           TAMP_MISR_ITAMP5MF_Msk
6558 #define TAMP_MISR_ITAMP6MF_Pos       (21U)
6559 #define TAMP_MISR_ITAMP6MF_Msk       (0x1UL << TAMP_MISR_ITAMP6MF_Pos)          /*!< 0x00200000 */
6560 #define TAMP_MISR_ITAMP6MF           TAMP_MISR_ITAMP6MF_Msk
6561 
6562 /********************  Bits definition for TAMP_SCR register  *****************/
6563 #define TAMP_SCR_CTAMP1F_Pos         (0U)
6564 #define TAMP_SCR_CTAMP1F_Msk         (0x1UL << TAMP_SCR_CTAMP1F_Pos)            /*!< 0x00000001 */
6565 #define TAMP_SCR_CTAMP1F             TAMP_SCR_CTAMP1F_Msk
6566 #define TAMP_SCR_CTAMP2F_Pos         (1U)
6567 #define TAMP_SCR_CTAMP2F_Msk         (0x1UL << TAMP_SCR_CTAMP2F_Pos)            /*!< 0x00000002 */
6568 #define TAMP_SCR_CTAMP2F             TAMP_SCR_CTAMP2F_Msk
6569 #define TAMP_SCR_CTAMP3F_Pos         (2U)
6570 #define TAMP_SCR_CTAMP3F_Msk         (0x1UL << TAMP_SCR_CTAMP3F_Pos)            /*!< 0x00000004 */
6571 #define TAMP_SCR_CTAMP3F             TAMP_SCR_CTAMP3F_Msk
6572 #define TAMP_SCR_CITAMP3F_Pos        (18U)
6573 #define TAMP_SCR_CITAMP3F_Msk        (0x1UL << TAMP_SCR_CITAMP3F_Pos)           /*!< 0x00040000 */
6574 #define TAMP_SCR_CITAMP3F            TAMP_SCR_CITAMP3F_Msk
6575 #define TAMP_SCR_CITAMP4F_Pos        (19U)
6576 #define TAMP_SCR_CITAMP4F_Msk        (0x1UL << TAMP_SCR_CITAMP4F_Pos)           /*!< 0x00080000 */
6577 #define TAMP_SCR_CITAMP4F            TAMP_SCR_CITAMP4F_Msk
6578 #define TAMP_SCR_CITAMP5F_Pos        (20U)
6579 #define TAMP_SCR_CITAMP5F_Msk        (0x1UL << TAMP_SCR_CITAMP5F_Pos)           /*!< 0x00100000 */
6580 #define TAMP_SCR_CITAMP5F            TAMP_SCR_CITAMP5F_Msk
6581 #define TAMP_SCR_CITAMP6F_Pos        (21U)
6582 #define TAMP_SCR_CITAMP6F_Msk        (0x1UL << TAMP_SCR_CITAMP6F_Pos)           /*!< 0x00200000 */
6583 #define TAMP_SCR_CITAMP6F            TAMP_SCR_CITAMP6F_Msk
6584 
6585 /********************  Bits definition for TAMP_BKP0R register  ***************/
6586 #define TAMP_BKP0R_Pos               (0U)
6587 #define TAMP_BKP0R_Msk               (0xFFFFFFFFUL << TAMP_BKP0R_Pos)           /*!< 0xFFFFFFFF */
6588 #define TAMP_BKP0R                   TAMP_BKP0R_Msk
6589 
6590 /********************  Bits definition for TAMP_BKP1R register  ***************/
6591 #define TAMP_BKP1R_Pos               (0U)
6592 #define TAMP_BKP1R_Msk               (0xFFFFFFFFUL << TAMP_BKP1R_Pos)           /*!< 0xFFFFFFFF */
6593 #define TAMP_BKP1R                   TAMP_BKP1R_Msk
6594 
6595 /********************  Bits definition for TAMP_BKP2R register  ***************/
6596 #define TAMP_BKP2R_Pos               (0U)
6597 #define TAMP_BKP2R_Msk               (0xFFFFFFFFUL << TAMP_BKP2R_Pos)           /*!< 0xFFFFFFFF */
6598 #define TAMP_BKP2R                   TAMP_BKP2R_Msk
6599 
6600 /********************  Bits definition for TAMP_BKP3R register  ***************/
6601 #define TAMP_BKP3R_Pos               (0U)
6602 #define TAMP_BKP3R_Msk               (0xFFFFFFFFUL << TAMP_BKP3R_Pos)           /*!< 0xFFFFFFFF */
6603 #define TAMP_BKP3R                   TAMP_BKP3R_Msk
6604 
6605 /********************  Bits definition for TAMP_BKP4R register  ***************/
6606 #define TAMP_BKP4R_Pos               (0U)
6607 #define TAMP_BKP4R_Msk               (0xFFFFFFFFUL << TAMP_BKP4R_Pos)           /*!< 0xFFFFFFFF */
6608 #define TAMP_BKP4R                   TAMP_BKP4R_Msk
6609 
6610 /******************************************************************************/
6611 /*                                                                            */
6612 /*                        Serial Peripheral Interface (SPI)                   */
6613 /*                                                                            */
6614 /******************************************************************************/
6615 /*
6616  * @brief Specific device feature definitions (not present on all devices in the STM32G0 series)
6617  */
6618 #define SPI_I2S_SUPPORT                       /*!< I2S support */
6619 
6620 /*******************  Bit definition for SPI_CR1 register  ********************/
6621 #define SPI_CR1_CPHA_Pos            (0U)
6622 #define SPI_CR1_CPHA_Msk            (0x1UL << SPI_CR1_CPHA_Pos)                /*!< 0x00000001 */
6623 #define SPI_CR1_CPHA                SPI_CR1_CPHA_Msk                           /*!<Clock Phase      */
6624 #define SPI_CR1_CPOL_Pos            (1U)
6625 #define SPI_CR1_CPOL_Msk            (0x1UL << SPI_CR1_CPOL_Pos)                /*!< 0x00000002 */
6626 #define SPI_CR1_CPOL                SPI_CR1_CPOL_Msk                           /*!<Clock Polarity   */
6627 #define SPI_CR1_MSTR_Pos            (2U)
6628 #define SPI_CR1_MSTR_Msk            (0x1UL << SPI_CR1_MSTR_Pos)                /*!< 0x00000004 */
6629 #define SPI_CR1_MSTR                SPI_CR1_MSTR_Msk                           /*!<Master Selection */
6630 
6631 #define SPI_CR1_BR_Pos              (3U)
6632 #define SPI_CR1_BR_Msk              (0x7UL << SPI_CR1_BR_Pos)                  /*!< 0x00000038 */
6633 #define SPI_CR1_BR                  SPI_CR1_BR_Msk                             /*!<BR[2:0] bits (Baud Rate Control) */
6634 #define SPI_CR1_BR_0                (0x1UL << SPI_CR1_BR_Pos)                  /*!< 0x00000008 */
6635 #define SPI_CR1_BR_1                (0x2UL << SPI_CR1_BR_Pos)                  /*!< 0x00000010 */
6636 #define SPI_CR1_BR_2                (0x4UL << SPI_CR1_BR_Pos)                  /*!< 0x00000020 */
6637 
6638 #define SPI_CR1_SPE_Pos             (6U)
6639 #define SPI_CR1_SPE_Msk             (0x1UL << SPI_CR1_SPE_Pos)                 /*!< 0x00000040 */
6640 #define SPI_CR1_SPE                 SPI_CR1_SPE_Msk                            /*!<SPI Enable                          */
6641 #define SPI_CR1_LSBFIRST_Pos        (7U)
6642 #define SPI_CR1_LSBFIRST_Msk        (0x1UL << SPI_CR1_LSBFIRST_Pos)            /*!< 0x00000080 */
6643 #define SPI_CR1_LSBFIRST            SPI_CR1_LSBFIRST_Msk                       /*!<Frame Format                        */
6644 #define SPI_CR1_SSI_Pos             (8U)
6645 #define SPI_CR1_SSI_Msk             (0x1UL << SPI_CR1_SSI_Pos)                 /*!< 0x00000100 */
6646 #define SPI_CR1_SSI                 SPI_CR1_SSI_Msk                            /*!<Internal slave select               */
6647 #define SPI_CR1_SSM_Pos             (9U)
6648 #define SPI_CR1_SSM_Msk             (0x1UL << SPI_CR1_SSM_Pos)                 /*!< 0x00000200 */
6649 #define SPI_CR1_SSM                 SPI_CR1_SSM_Msk                            /*!<Software slave management           */
6650 #define SPI_CR1_RXONLY_Pos          (10U)
6651 #define SPI_CR1_RXONLY_Msk          (0x1UL << SPI_CR1_RXONLY_Pos)              /*!< 0x00000400 */
6652 #define SPI_CR1_RXONLY              SPI_CR1_RXONLY_Msk                         /*!<Receive only                        */
6653 #define SPI_CR1_CRCL_Pos            (11U)
6654 #define SPI_CR1_CRCL_Msk            (0x1UL << SPI_CR1_CRCL_Pos)                /*!< 0x00000800 */
6655 #define SPI_CR1_CRCL                SPI_CR1_CRCL_Msk                           /*!< CRC Length */
6656 #define SPI_CR1_CRCNEXT_Pos         (12U)
6657 #define SPI_CR1_CRCNEXT_Msk         (0x1UL << SPI_CR1_CRCNEXT_Pos)             /*!< 0x00001000 */
6658 #define SPI_CR1_CRCNEXT             SPI_CR1_CRCNEXT_Msk                        /*!<Transmit CRC next                   */
6659 #define SPI_CR1_CRCEN_Pos           (13U)
6660 #define SPI_CR1_CRCEN_Msk           (0x1UL << SPI_CR1_CRCEN_Pos)               /*!< 0x00002000 */
6661 #define SPI_CR1_CRCEN               SPI_CR1_CRCEN_Msk                          /*!<Hardware CRC calculation enable     */
6662 #define SPI_CR1_BIDIOE_Pos          (14U)
6663 #define SPI_CR1_BIDIOE_Msk          (0x1UL << SPI_CR1_BIDIOE_Pos)              /*!< 0x00004000 */
6664 #define SPI_CR1_BIDIOE              SPI_CR1_BIDIOE_Msk                         /*!<Output enable in bidirectional mode */
6665 #define SPI_CR1_BIDIMODE_Pos        (15U)
6666 #define SPI_CR1_BIDIMODE_Msk        (0x1UL << SPI_CR1_BIDIMODE_Pos)            /*!< 0x00008000 */
6667 #define SPI_CR1_BIDIMODE            SPI_CR1_BIDIMODE_Msk                       /*!<Bidirectional data mode enable      */
6668 
6669 /*******************  Bit definition for SPI_CR2 register  ********************/
6670 #define SPI_CR2_RXDMAEN_Pos         (0U)
6671 #define SPI_CR2_RXDMAEN_Msk         (0x1UL << SPI_CR2_RXDMAEN_Pos)             /*!< 0x00000001 */
6672 #define SPI_CR2_RXDMAEN             SPI_CR2_RXDMAEN_Msk                        /*!< Rx Buffer DMA Enable */
6673 #define SPI_CR2_TXDMAEN_Pos         (1U)
6674 #define SPI_CR2_TXDMAEN_Msk         (0x1UL << SPI_CR2_TXDMAEN_Pos)             /*!< 0x00000002 */
6675 #define SPI_CR2_TXDMAEN             SPI_CR2_TXDMAEN_Msk                        /*!< Tx Buffer DMA Enable */
6676 #define SPI_CR2_SSOE_Pos            (2U)
6677 #define SPI_CR2_SSOE_Msk            (0x1UL << SPI_CR2_SSOE_Pos)                /*!< 0x00000004 */
6678 #define SPI_CR2_SSOE                SPI_CR2_SSOE_Msk                           /*!< SS Output Enable */
6679 #define SPI_CR2_NSSP_Pos            (3U)
6680 #define SPI_CR2_NSSP_Msk            (0x1UL << SPI_CR2_NSSP_Pos)                /*!< 0x00000008 */
6681 #define SPI_CR2_NSSP                SPI_CR2_NSSP_Msk                           /*!< NSS pulse management Enable */
6682 #define SPI_CR2_FRF_Pos             (4U)
6683 #define SPI_CR2_FRF_Msk             (0x1UL << SPI_CR2_FRF_Pos)                 /*!< 0x00000010 */
6684 #define SPI_CR2_FRF                 SPI_CR2_FRF_Msk                            /*!< Frame Format Enable */
6685 #define SPI_CR2_ERRIE_Pos           (5U)
6686 #define SPI_CR2_ERRIE_Msk           (0x1UL << SPI_CR2_ERRIE_Pos)               /*!< 0x00000020 */
6687 #define SPI_CR2_ERRIE               SPI_CR2_ERRIE_Msk                          /*!< Error Interrupt Enable */
6688 #define SPI_CR2_RXNEIE_Pos          (6U)
6689 #define SPI_CR2_RXNEIE_Msk          (0x1UL << SPI_CR2_RXNEIE_Pos)              /*!< 0x00000040 */
6690 #define SPI_CR2_RXNEIE              SPI_CR2_RXNEIE_Msk                         /*!< RX buffer Not Empty Interrupt Enable */
6691 #define SPI_CR2_TXEIE_Pos           (7U)
6692 #define SPI_CR2_TXEIE_Msk           (0x1UL << SPI_CR2_TXEIE_Pos)               /*!< 0x00000080 */
6693 #define SPI_CR2_TXEIE               SPI_CR2_TXEIE_Msk                          /*!< Tx buffer Empty Interrupt Enable */
6694 #define SPI_CR2_DS_Pos              (8U)
6695 #define SPI_CR2_DS_Msk              (0xFUL << SPI_CR2_DS_Pos)                  /*!< 0x00000F00 */
6696 #define SPI_CR2_DS                  SPI_CR2_DS_Msk                             /*!< DS[3:0] Data Size */
6697 #define SPI_CR2_DS_0                (0x1UL << SPI_CR2_DS_Pos)                  /*!< 0x00000100 */
6698 #define SPI_CR2_DS_1                (0x2UL << SPI_CR2_DS_Pos)                  /*!< 0x00000200 */
6699 #define SPI_CR2_DS_2                (0x4UL << SPI_CR2_DS_Pos)                  /*!< 0x00000400 */
6700 #define SPI_CR2_DS_3                (0x8UL << SPI_CR2_DS_Pos)                  /*!< 0x00000800 */
6701 #define SPI_CR2_FRXTH_Pos           (12U)
6702 #define SPI_CR2_FRXTH_Msk           (0x1UL << SPI_CR2_FRXTH_Pos)               /*!< 0x00001000 */
6703 #define SPI_CR2_FRXTH               SPI_CR2_FRXTH_Msk                          /*!< FIFO reception Threshold */
6704 #define SPI_CR2_LDMARX_Pos          (13U)
6705 #define SPI_CR2_LDMARX_Msk          (0x1UL << SPI_CR2_LDMARX_Pos)              /*!< 0x00002000 */
6706 #define SPI_CR2_LDMARX              SPI_CR2_LDMARX_Msk                         /*!< Last DMA transfer for reception */
6707 #define SPI_CR2_LDMATX_Pos          (14U)
6708 #define SPI_CR2_LDMATX_Msk          (0x1UL << SPI_CR2_LDMATX_Pos)              /*!< 0x00004000 */
6709 #define SPI_CR2_LDMATX              SPI_CR2_LDMATX_Msk                         /*!< Last DMA transfer for transmission */
6710 
6711 /********************  Bit definition for SPI_SR register  ********************/
6712 #define SPI_SR_RXNE_Pos             (0U)
6713 #define SPI_SR_RXNE_Msk             (0x1UL << SPI_SR_RXNE_Pos)                 /*!< 0x00000001 */
6714 #define SPI_SR_RXNE                 SPI_SR_RXNE_Msk                            /*!< Receive buffer Not Empty */
6715 #define SPI_SR_TXE_Pos              (1U)
6716 #define SPI_SR_TXE_Msk              (0x1UL << SPI_SR_TXE_Pos)                  /*!< 0x00000002 */
6717 #define SPI_SR_TXE                  SPI_SR_TXE_Msk                             /*!< Transmit buffer Empty */
6718 #define SPI_SR_CHSIDE_Pos           (2U)
6719 #define SPI_SR_CHSIDE_Msk           (0x1UL << SPI_SR_CHSIDE_Pos)               /*!< 0x00000004 */
6720 #define SPI_SR_CHSIDE               SPI_SR_CHSIDE_Msk                          /*!< Channel side */
6721 #define SPI_SR_UDR_Pos              (3U)
6722 #define SPI_SR_UDR_Msk              (0x1UL << SPI_SR_UDR_Pos)                  /*!< 0x00000008 */
6723 #define SPI_SR_UDR                  SPI_SR_UDR_Msk                             /*!< Underrun flag */
6724 #define SPI_SR_CRCERR_Pos           (4U)
6725 #define SPI_SR_CRCERR_Msk           (0x1UL << SPI_SR_CRCERR_Pos)               /*!< 0x00000010 */
6726 #define SPI_SR_CRCERR               SPI_SR_CRCERR_Msk                          /*!< CRC Error flag */
6727 #define SPI_SR_MODF_Pos             (5U)
6728 #define SPI_SR_MODF_Msk             (0x1UL << SPI_SR_MODF_Pos)                 /*!< 0x00000020 */
6729 #define SPI_SR_MODF                 SPI_SR_MODF_Msk                            /*!< Mode fault */
6730 #define SPI_SR_OVR_Pos              (6U)
6731 #define SPI_SR_OVR_Msk              (0x1UL << SPI_SR_OVR_Pos)                  /*!< 0x00000040 */
6732 #define SPI_SR_OVR                  SPI_SR_OVR_Msk                             /*!< Overrun flag */
6733 #define SPI_SR_BSY_Pos              (7U)
6734 #define SPI_SR_BSY_Msk              (0x1UL << SPI_SR_BSY_Pos)                  /*!< 0x00000080 */
6735 #define SPI_SR_BSY                  SPI_SR_BSY_Msk                             /*!< Busy flag */
6736 #define SPI_SR_FRE_Pos              (8U)
6737 #define SPI_SR_FRE_Msk              (0x1UL << SPI_SR_FRE_Pos)                  /*!< 0x00000100 */
6738 #define SPI_SR_FRE                  SPI_SR_FRE_Msk                             /*!< TI frame format error */
6739 #define SPI_SR_FRLVL_Pos            (9U)
6740 #define SPI_SR_FRLVL_Msk            (0x3UL << SPI_SR_FRLVL_Pos)                /*!< 0x00000600 */
6741 #define SPI_SR_FRLVL                SPI_SR_FRLVL_Msk                           /*!< FIFO Reception Level */
6742 #define SPI_SR_FRLVL_0              (0x1UL << SPI_SR_FRLVL_Pos)                /*!< 0x00000200 */
6743 #define SPI_SR_FRLVL_1              (0x2UL << SPI_SR_FRLVL_Pos)                /*!< 0x00000400 */
6744 #define SPI_SR_FTLVL_Pos            (11U)
6745 #define SPI_SR_FTLVL_Msk            (0x3UL << SPI_SR_FTLVL_Pos)                /*!< 0x00001800 */
6746 #define SPI_SR_FTLVL                SPI_SR_FTLVL_Msk                           /*!< FIFO Transmission Level */
6747 #define SPI_SR_FTLVL_0              (0x1UL << SPI_SR_FTLVL_Pos)                /*!< 0x00000800 */
6748 #define SPI_SR_FTLVL_1              (0x2UL << SPI_SR_FTLVL_Pos)                /*!< 0x00001000 */
6749 
6750 /********************  Bit definition for SPI_DR register  ********************/
6751 #define SPI_DR_DR_Pos               (0U)
6752 #define SPI_DR_DR_Msk               (0xFFFFUL << SPI_DR_DR_Pos)                /*!< 0x0000FFFF */
6753 #define SPI_DR_DR                   SPI_DR_DR_Msk                              /*!<Data Register           */
6754 
6755 /*******************  Bit definition for SPI_CRCPR register  ******************/
6756 #define SPI_CRCPR_CRCPOLY_Pos       (0U)
6757 #define SPI_CRCPR_CRCPOLY_Msk       (0xFFFFUL << SPI_CRCPR_CRCPOLY_Pos)        /*!< 0x0000FFFF */
6758 #define SPI_CRCPR_CRCPOLY           SPI_CRCPR_CRCPOLY_Msk                      /*!<CRC polynomial register */
6759 
6760 /******************  Bit definition for SPI_RXCRCR register  ******************/
6761 #define SPI_RXCRCR_RXCRC_Pos        (0U)
6762 #define SPI_RXCRCR_RXCRC_Msk        (0xFFFFUL << SPI_RXCRCR_RXCRC_Pos)         /*!< 0x0000FFFF */
6763 #define SPI_RXCRCR_RXCRC            SPI_RXCRCR_RXCRC_Msk                       /*!<Rx CRC Register         */
6764 
6765 /******************  Bit definition for SPI_TXCRCR register  ******************/
6766 #define SPI_TXCRCR_TXCRC_Pos        (0U)
6767 #define SPI_TXCRCR_TXCRC_Msk        (0xFFFFUL << SPI_TXCRCR_TXCRC_Pos)         /*!< 0x0000FFFF */
6768 #define SPI_TXCRCR_TXCRC            SPI_TXCRCR_TXCRC_Msk                       /*!<Tx CRC Register         */
6769 
6770 /******************  Bit definition for SPI_I2SCFGR register  *****************/
6771 #define SPI_I2SCFGR_CHLEN_Pos       (0U)
6772 #define SPI_I2SCFGR_CHLEN_Msk       (0x1UL << SPI_I2SCFGR_CHLEN_Pos)           /*!< 0x00000001 */
6773 #define SPI_I2SCFGR_CHLEN           SPI_I2SCFGR_CHLEN_Msk                      /*!<Channel length (number of bits per audio channel) */
6774 #define SPI_I2SCFGR_DATLEN_Pos      (1U)
6775 #define SPI_I2SCFGR_DATLEN_Msk      (0x3UL << SPI_I2SCFGR_DATLEN_Pos)          /*!< 0x00000006 */
6776 #define SPI_I2SCFGR_DATLEN          SPI_I2SCFGR_DATLEN_Msk                     /*!<DATLEN[1:0] bits (Data length to be transferred) */
6777 #define SPI_I2SCFGR_DATLEN_0        (0x1UL << SPI_I2SCFGR_DATLEN_Pos)          /*!< 0x00000002 */
6778 #define SPI_I2SCFGR_DATLEN_1        (0x2UL << SPI_I2SCFGR_DATLEN_Pos)          /*!< 0x00000004 */
6779 #define SPI_I2SCFGR_CKPOL_Pos       (3U)
6780 #define SPI_I2SCFGR_CKPOL_Msk       (0x1UL << SPI_I2SCFGR_CKPOL_Pos)           /*!< 0x00000008 */
6781 #define SPI_I2SCFGR_CKPOL           SPI_I2SCFGR_CKPOL_Msk                      /*!<steady state clock polarity */
6782 #define SPI_I2SCFGR_I2SSTD_Pos      (4U)
6783 #define SPI_I2SCFGR_I2SSTD_Msk      (0x3UL << SPI_I2SCFGR_I2SSTD_Pos)          /*!< 0x00000030 */
6784 #define SPI_I2SCFGR_I2SSTD          SPI_I2SCFGR_I2SSTD_Msk                     /*!<I2SSTD[1:0] bits (I2S standard selection) */
6785 #define SPI_I2SCFGR_I2SSTD_0        (0x1UL << SPI_I2SCFGR_I2SSTD_Pos)          /*!< 0x00000010 */
6786 #define SPI_I2SCFGR_I2SSTD_1        (0x2UL << SPI_I2SCFGR_I2SSTD_Pos)          /*!< 0x00000020 */
6787 #define SPI_I2SCFGR_PCMSYNC_Pos     (7U)
6788 #define SPI_I2SCFGR_PCMSYNC_Msk     (0x1UL << SPI_I2SCFGR_PCMSYNC_Pos)         /*!< 0x00000080 */
6789 #define SPI_I2SCFGR_PCMSYNC         SPI_I2SCFGR_PCMSYNC_Msk                    /*!<PCM frame synchronization */
6790 #define SPI_I2SCFGR_I2SCFG_Pos      (8U)
6791 #define SPI_I2SCFGR_I2SCFG_Msk      (0x3UL << SPI_I2SCFGR_I2SCFG_Pos)          /*!< 0x00000300 */
6792 #define SPI_I2SCFGR_I2SCFG          SPI_I2SCFGR_I2SCFG_Msk                     /*!<I2SCFG[1:0] bits (I2S configuration mode) */
6793 #define SPI_I2SCFGR_I2SCFG_0        (0x1UL << SPI_I2SCFGR_I2SCFG_Pos)          /*!< 0x00000100 */
6794 #define SPI_I2SCFGR_I2SCFG_1        (0x2UL << SPI_I2SCFGR_I2SCFG_Pos)          /*!< 0x00000200 */
6795 #define SPI_I2SCFGR_I2SE_Pos        (10U)
6796 #define SPI_I2SCFGR_I2SE_Msk        (0x1UL << SPI_I2SCFGR_I2SE_Pos)            /*!< 0x00000400 */
6797 #define SPI_I2SCFGR_I2SE            SPI_I2SCFGR_I2SE_Msk                       /*!<I2S Enable */
6798 #define SPI_I2SCFGR_I2SMOD_Pos      (11U)
6799 #define SPI_I2SCFGR_I2SMOD_Msk      (0x1UL << SPI_I2SCFGR_I2SMOD_Pos)          /*!< 0x00000800 */
6800 #define SPI_I2SCFGR_I2SMOD          SPI_I2SCFGR_I2SMOD_Msk                     /*!<I2S mode selection */
6801 #define SPI_I2SCFGR_ASTRTEN_Pos     (12U)
6802 #define SPI_I2SCFGR_ASTRTEN_Msk     (0x1UL << SPI_I2SCFGR_ASTRTEN_Pos)         /*!< 0x00001000 */
6803 #define SPI_I2SCFGR_ASTRTEN         SPI_I2SCFGR_ASTRTEN_Msk                    /*!<Asynchronous start enable */
6804 
6805 /******************  Bit definition for SPI_I2SPR register  *******************/
6806 #define SPI_I2SPR_I2SDIV_Pos        (0U)
6807 #define SPI_I2SPR_I2SDIV_Msk        (0xFFUL << SPI_I2SPR_I2SDIV_Pos)           /*!< 0x000000FF */
6808 #define SPI_I2SPR_I2SDIV            SPI_I2SPR_I2SDIV_Msk                       /*!<I2S Linear prescaler */
6809 #define SPI_I2SPR_ODD_Pos           (8U)
6810 #define SPI_I2SPR_ODD_Msk           (0x1UL << SPI_I2SPR_ODD_Pos)               /*!< 0x00000100 */
6811 #define SPI_I2SPR_ODD               SPI_I2SPR_ODD_Msk                          /*!<Odd factor for the prescaler */
6812 #define SPI_I2SPR_MCKOE_Pos         (9U)
6813 #define SPI_I2SPR_MCKOE_Msk         (0x1UL << SPI_I2SPR_MCKOE_Pos)             /*!< 0x00000200 */
6814 #define SPI_I2SPR_MCKOE             SPI_I2SPR_MCKOE_Msk                        /*!<Master Clock Output Enable */
6815 
6816 /******************************************************************************/
6817 /*                                                                            */
6818 /*                                 SYSCFG                                     */
6819 /*                                                                            */
6820 /******************************************************************************/
6821 #define SYSCFG_CDEN_SUPPORT
6822 /*****************  Bit definition for SYSCFG_CFGR1 register  ****************/
6823 #define SYSCFG_CFGR1_MEM_MODE_Pos             (0U)
6824 #define SYSCFG_CFGR1_MEM_MODE_Msk             (0x3UL << SYSCFG_CFGR1_MEM_MODE_Pos) /*!< 0x00000003 */
6825 #define SYSCFG_CFGR1_MEM_MODE                 SYSCFG_CFGR1_MEM_MODE_Msk            /*!< SYSCFG_Memory Remap Config */
6826 #define SYSCFG_CFGR1_MEM_MODE_0               (0x1UL << SYSCFG_CFGR1_MEM_MODE_Pos) /*!< 0x00000001 */
6827 #define SYSCFG_CFGR1_MEM_MODE_1               (0x2UL << SYSCFG_CFGR1_MEM_MODE_Pos) /*!< 0x00000002 */
6828 #define SYSCFG_CFGR1_PA11_RMP_Pos             (3U)
6829 #define SYSCFG_CFGR1_PA11_RMP_Msk             (0x1UL << SYSCFG_CFGR1_PA11_RMP_Pos) /*!< 0x00000008 */
6830 #define SYSCFG_CFGR1_PA11_RMP                 SYSCFG_CFGR1_PA11_RMP_Msk            /*!< PA11 Remap */
6831 #define SYSCFG_CFGR1_PA12_RMP_Pos             (4U)
6832 #define SYSCFG_CFGR1_PA12_RMP_Msk             (0x1UL << SYSCFG_CFGR1_PA12_RMP_Pos) /*!< 0x00000010 */
6833 #define SYSCFG_CFGR1_PA12_RMP                 SYSCFG_CFGR1_PA12_RMP_Msk            /*!< PA12 Remap */
6834 #define SYSCFG_CFGR1_IR_POL_Pos               (5U)
6835 #define SYSCFG_CFGR1_IR_POL_Msk               (0x1UL << SYSCFG_CFGR1_IR_POL_Pos) /*!< 0x00000020 */
6836 #define SYSCFG_CFGR1_IR_POL                   SYSCFG_CFGR1_IR_POL_Msk            /*!< IROut Polarity Selection */
6837 #define SYSCFG_CFGR1_IR_MOD_Pos               (6U)
6838 #define SYSCFG_CFGR1_IR_MOD_Msk               (0x3UL << SYSCFG_CFGR1_IR_MOD_Pos) /*!< 0x000000C0 */
6839 #define SYSCFG_CFGR1_IR_MOD                   SYSCFG_CFGR1_IR_MOD_Msk            /*!< IRDA Modulation Envelope signal source selection */
6840 #define SYSCFG_CFGR1_IR_MOD_0                 (0x1UL << SYSCFG_CFGR1_IR_MOD_Pos) /*!< 0x00000040 */
6841 #define SYSCFG_CFGR1_IR_MOD_1                 (0x2UL << SYSCFG_CFGR1_IR_MOD_Pos) /*!< 0x00000080 */
6842 #define SYSCFG_CFGR1_BOOSTEN_Pos              (8U)
6843 #define SYSCFG_CFGR1_BOOSTEN_Msk              (0x1UL << SYSCFG_CFGR1_BOOSTEN_Pos) /*!< 0x00000100 */
6844 #define SYSCFG_CFGR1_BOOSTEN                  SYSCFG_CFGR1_BOOSTEN_Msk            /*!< I/O analog switch voltage booster enable */
6845 #define SYSCFG_CFGR1_UCPD1_STROBE_Pos         (9U)
6846 #define SYSCFG_CFGR1_UCPD1_STROBE_Msk         (0x1UL << SYSCFG_CFGR1_UCPD1_STROBE_Pos) /*!< 0x00000200 */
6847 #define SYSCFG_CFGR1_UCPD1_STROBE             SYSCFG_CFGR1_UCPD1_STROBE_Msk            /*!< Strobe signal bit for UCPD1 */
6848 #define SYSCFG_CFGR1_UCPD2_STROBE_Pos         (10U)
6849 #define SYSCFG_CFGR1_UCPD2_STROBE_Msk         (0x1UL << SYSCFG_CFGR1_UCPD2_STROBE_Pos) /*!< 0x00000400 */
6850 #define SYSCFG_CFGR1_UCPD2_STROBE             SYSCFG_CFGR1_UCPD2_STROBE_Msk            /*!< Strobe signal bit for UCPD2 */
6851 #define SYSCFG_CFGR1_I2C_PB6_FMP_Pos          (16U)
6852 #define SYSCFG_CFGR1_I2C_PB6_FMP_Msk          (0x1UL << SYSCFG_CFGR1_I2C_PB6_FMP_Pos)  /*!< 0x00010000 */
6853 #define SYSCFG_CFGR1_I2C_PB6_FMP              SYSCFG_CFGR1_I2C_PB6_FMP_Msk             /*!< I2C PB6 Fast mode plus */
6854 #define SYSCFG_CFGR1_I2C_PB7_FMP_Pos          (17U)
6855 #define SYSCFG_CFGR1_I2C_PB7_FMP_Msk          (0x1UL << SYSCFG_CFGR1_I2C_PB7_FMP_Pos)  /*!< 0x00020000 */
6856 #define SYSCFG_CFGR1_I2C_PB7_FMP              SYSCFG_CFGR1_I2C_PB7_FMP_Msk             /*!< I2C PB7 Fast mode plus */
6857 #define SYSCFG_CFGR1_I2C_PB8_FMP_Pos          (18U)
6858 #define SYSCFG_CFGR1_I2C_PB8_FMP_Msk          (0x1UL << SYSCFG_CFGR1_I2C_PB8_FMP_Pos)  /*!< 0x00040000 */
6859 #define SYSCFG_CFGR1_I2C_PB8_FMP              SYSCFG_CFGR1_I2C_PB8_FMP_Msk             /*!< I2C PB8 Fast mode plus */
6860 #define SYSCFG_CFGR1_I2C_PB9_FMP_Pos          (19U)
6861 #define SYSCFG_CFGR1_I2C_PB9_FMP_Msk          (0x1UL << SYSCFG_CFGR1_I2C_PB9_FMP_Pos)  /*!< 0x00080000 */
6862 #define SYSCFG_CFGR1_I2C_PB9_FMP              SYSCFG_CFGR1_I2C_PB9_FMP_Msk             /*!< I2C PB9 Fast mode plus */
6863 #define SYSCFG_CFGR1_I2C1_FMP_Pos             (20U)
6864 #define SYSCFG_CFGR1_I2C1_FMP_Msk             (0x1UL << SYSCFG_CFGR1_I2C1_FMP_Pos)     /*!< 0x00100000 */
6865 #define SYSCFG_CFGR1_I2C1_FMP                 SYSCFG_CFGR1_I2C1_FMP_Msk                /*!< Enable Fast Mode Plus on PB10, PB11, PF6 and PF7  */
6866 #define SYSCFG_CFGR1_I2C2_FMP_Pos             (21U)
6867 #define SYSCFG_CFGR1_I2C2_FMP_Msk             (0x1UL << SYSCFG_CFGR1_I2C2_FMP_Pos)     /*!< 0x00200000 */
6868 #define SYSCFG_CFGR1_I2C2_FMP                 SYSCFG_CFGR1_I2C2_FMP_Msk                /*!< Enable I2C2 Fast mode plus  */
6869 #define SYSCFG_CFGR1_I2C_PA9_FMP_Pos          (22U)
6870 #define SYSCFG_CFGR1_I2C_PA9_FMP_Msk          (0x1UL << SYSCFG_CFGR1_I2C_PA9_FMP_Pos)  /*!< 0x00400000 */
6871 #define SYSCFG_CFGR1_I2C_PA9_FMP              SYSCFG_CFGR1_I2C_PA9_FMP_Msk             /*!< Enable Fast Mode Plus on PA9  */
6872 #define SYSCFG_CFGR1_I2C_PA10_FMP_Pos         (23U)
6873 #define SYSCFG_CFGR1_I2C_PA10_FMP_Msk         (0x1UL << SYSCFG_CFGR1_I2C_PA10_FMP_Pos) /*!< 0x00800000 */
6874 #define SYSCFG_CFGR1_I2C_PA10_FMP             SYSCFG_CFGR1_I2C_PA10_FMP_Msk            /*!< Enable Fast Mode Plus on PA10 */
6875 #define SYSCFG_CFGR1_I2C3_FMP_Pos             (24U)
6876 #define SYSCFG_CFGR1_I2C3_FMP_Msk             (0x1UL << SYSCFG_CFGR1_I2C3_FMP_Pos)     /*!< 0x01000000 */
6877 #define SYSCFG_CFGR1_I2C3_FMP                 SYSCFG_CFGR1_I2C3_FMP_Msk                /*!< Enable I2C3 Fast mode plus  */
6878 
6879 /******************  Bit definition for SYSCFG_CFGR2 register  ****************/
6880 #define SYSCFG_CFGR2_CLL_Pos                  (0U)
6881 #define SYSCFG_CFGR2_CLL_Msk                  (0x1UL << SYSCFG_CFGR2_CLL_Pos)   /*!< 0x00000001 */
6882 #define SYSCFG_CFGR2_CLL                      SYSCFG_CFGR2_CLL_Msk              /*!< Enables and locks the LOCKUP (Hardfault) output of CortexM0 with Break Input of TIMER1 */
6883 #define SYSCFG_CFGR2_SPL_Pos                  (1U)
6884 #define SYSCFG_CFGR2_SPL_Msk                  (0x1UL << SYSCFG_CFGR2_SPL_Pos)   /*!< 0x00000002 */
6885 #define SYSCFG_CFGR2_SPL                      SYSCFG_CFGR2_SPL_Msk              /*!< Enables and locks the SRAM_PARITY error signal with Break Input of TIMER1 */
6886 #define SYSCFG_CFGR2_ECCL_Pos                 (3U)
6887 #define SYSCFG_CFGR2_ECCL_Msk                 (0x1UL << SYSCFG_CFGR2_ECCL_Pos)  /*!< 0x00000008 */
6888 #define SYSCFG_CFGR2_ECCL                     SYSCFG_CFGR2_ECCL_Msk             /*!< ECCL */
6889 #define SYSCFG_CFGR2_SPF_Pos                  (8U)
6890 #define SYSCFG_CFGR2_SPF_Msk                  (0x1UL << SYSCFG_CFGR2_SPF_Pos)   /*!< 0x00000100 */
6891 #define SYSCFG_CFGR2_SPF                      SYSCFG_CFGR2_SPF_Msk              /*!< SRAM Parity error flag */
6892 #define SYSCFG_CFGR2_SRAM_PE                  SYSCFG_CFGR2_SPF                  /*!< SRAM Parity error flag (define maintained for legacy purpose) */
6893 
6894 #define SYSCFG_CFGR2_PA1_CDEN_Pos             (16U)
6895 #define SYSCFG_CFGR2_PA1_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PA1_CDEN_Pos)   /* 0x00010000 */
6896 #define SYSCFG_CFGR2_PA1_CDEN                 SYSCFG_CFGR2_PA1_CDEN_Msk              /*!< PA[1] Clamping Diode Enable */
6897 #define SYSCFG_CFGR2_PA3_CDEN_Pos             (17U)
6898 #define SYSCFG_CFGR2_PA3_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PA3_CDEN_Pos)   /* 0x00020000 */
6899 #define SYSCFG_CFGR2_PA3_CDEN                 SYSCFG_CFGR2_PA3_CDEN_Msk              /*!< PA[3] Clamping Diode Enable */
6900 #define SYSCFG_CFGR2_PA5_CDEN_Pos             (18U)
6901 #define SYSCFG_CFGR2_PA5_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PA5_CDEN_Pos)   /* 0x00040000 */
6902 #define SYSCFG_CFGR2_PA5_CDEN                 SYSCFG_CFGR2_PA5_CDEN_Msk              /*!< PA[5] Clamping Diode Enable */
6903 #define SYSCFG_CFGR2_PA6_CDEN_Pos             (19U)
6904 #define SYSCFG_CFGR2_PA6_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PA6_CDEN_Pos)   /* 0x00080000 */
6905 #define SYSCFG_CFGR2_PA6_CDEN                 SYSCFG_CFGR2_PA6_CDEN_Msk              /*!< PA[6] Clamping Diode Enable */
6906 #define SYSCFG_CFGR2_PA13_CDEN_Pos            (20U)
6907 #define SYSCFG_CFGR2_PA13_CDEN_Msk            (0x1UL << SYSCFG_CFGR2_PA13_CDEN_Pos)  /* 0x00100000 */
6908 #define SYSCFG_CFGR2_PA13_CDEN                 SYSCFG_CFGR2_PA13_CDEN_Msk            /*!< PA[13] Clamping Diode Enable */
6909 #define SYSCFG_CFGR2_PB0_CDEN_Pos             (21U)
6910 #define SYSCFG_CFGR2_PB0_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PB0_CDEN_Pos)   /* 0x00200000 */
6911 #define SYSCFG_CFGR2_PB0_CDEN                 SYSCFG_CFGR2_PB0_CDEN_Msk              /*!< PB[0] Clamping Diode Enable */
6912 #define SYSCFG_CFGR2_PB1_CDEN_Pos             (22U)
6913 #define SYSCFG_CFGR2_PB1_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PB1_CDEN_Pos)   /* 0x00400000 */
6914 #define SYSCFG_CFGR2_PB1_CDEN                 SYSCFG_CFGR2_PB1_CDEN_Msk              /*!< PB[1] Clamping Diode Enable */
6915 #define SYSCFG_CFGR2_PB2_CDEN_Pos             (23U)
6916 #define SYSCFG_CFGR2_PB2_CDEN_Msk             (0x1UL << SYSCFG_CFGR2_PB2_CDEN_Pos)   /* 0x00800000 */
6917 #define SYSCFG_CFGR2_PB2_CDEN                 SYSCFG_CFGR2_PB2_CDEN_Msk              /*!< PB[2] Clamping Diode Enable */
6918 /*****************  Bit definition for SYSCFG_ITLINEx ISR Wrapper register  ****************/
6919 #define SYSCFG_ITLINE0_SR_EWDG_Pos            (0U)
6920 #define SYSCFG_ITLINE0_SR_EWDG_Msk            (0x1UL << SYSCFG_ITLINE0_SR_EWDG_Pos) /*!< 0x00000001 */
6921 #define SYSCFG_ITLINE0_SR_EWDG                SYSCFG_ITLINE0_SR_EWDG_Msk       /*!< EWDG interrupt */
6922 #define SYSCFG_ITLINE2_SR_TAMPER_Pos          (0U)
6923 #define SYSCFG_ITLINE2_SR_TAMPER_Msk          (0x1UL << SYSCFG_ITLINE2_SR_TAMPER_Pos) /*!< 0x00000001 */
6924 #define SYSCFG_ITLINE2_SR_TAMPER              SYSCFG_ITLINE2_SR_TAMPER_Msk     /*!< TAMPER -> exti[21] interrupt */
6925 #define SYSCFG_ITLINE2_SR_RTC_Pos             (1U)
6926 #define SYSCFG_ITLINE2_SR_RTC_Msk             (0x1UL << SYSCFG_ITLINE2_SR_RTC_Pos) /*!< 0x00000002 */
6927 #define SYSCFG_ITLINE2_SR_RTC                 SYSCFG_ITLINE2_SR_RTC_Msk /*!< RTC -> exti[19] interrupt .... */
6928 #define SYSCFG_ITLINE3_SR_FLASH_ECC_Pos       (0U)
6929 #define SYSCFG_ITLINE3_SR_FLASH_ECC_Msk       (0x1UL << SYSCFG_ITLINE3_SR_FLASH_ECC_Pos) /*!< 0x00000001 */
6930 #define SYSCFG_ITLINE3_SR_FLASH_ECC           SYSCFG_ITLINE3_SR_FLASH_ECC_Msk  /*!< Flash ITF ECC interrupt */
6931 #define SYSCFG_ITLINE3_SR_FLASH_ITF_Pos       (1U)
6932 #define SYSCFG_ITLINE3_SR_FLASH_ITF_Msk       (0x1UL << SYSCFG_ITLINE3_SR_FLASH_ITF_Pos) /*!< 0x00000002 */
6933 #define SYSCFG_ITLINE3_SR_FLASH_ITF           SYSCFG_ITLINE3_SR_FLASH_ITF_Msk  /*!< FLASH ITF interrupt */
6934 #define SYSCFG_ITLINE4_SR_CLK_CTRL_Pos        (0U)
6935 #define SYSCFG_ITLINE4_SR_CLK_CTRL_Msk        (0x1UL << SYSCFG_ITLINE4_SR_CLK_CTRL_Pos) /*!< 0x00000001 */
6936 #define SYSCFG_ITLINE4_SR_CLK_CTRL            SYSCFG_ITLINE4_SR_CLK_CTRL_Msk   /*!< RCC interrupt */
6937 #define SYSCFG_ITLINE5_SR_EXTI0_Pos           (0U)
6938 #define SYSCFG_ITLINE5_SR_EXTI0_Msk           (0x1UL << SYSCFG_ITLINE5_SR_EXTI0_Pos) /*!< 0x00000001 */
6939 #define SYSCFG_ITLINE5_SR_EXTI0               SYSCFG_ITLINE5_SR_EXTI0_Msk      /*!< External Interrupt 0 */
6940 #define SYSCFG_ITLINE5_SR_EXTI1_Pos           (1U)
6941 #define SYSCFG_ITLINE5_SR_EXTI1_Msk           (0x1UL << SYSCFG_ITLINE5_SR_EXTI1_Pos) /*!< 0x00000002 */
6942 #define SYSCFG_ITLINE5_SR_EXTI1               SYSCFG_ITLINE5_SR_EXTI1_Msk      /*!< External Interrupt 1 */
6943 #define SYSCFG_ITLINE6_SR_EXTI2_Pos           (0U)
6944 #define SYSCFG_ITLINE6_SR_EXTI2_Msk           (0x1UL << SYSCFG_ITLINE6_SR_EXTI2_Pos) /*!< 0x00000001 */
6945 #define SYSCFG_ITLINE6_SR_EXTI2               SYSCFG_ITLINE6_SR_EXTI2_Msk      /*!< External Interrupt 2 */
6946 #define SYSCFG_ITLINE6_SR_EXTI3_Pos           (1U)
6947 #define SYSCFG_ITLINE6_SR_EXTI3_Msk           (0x1UL << SYSCFG_ITLINE6_SR_EXTI3_Pos) /*!< 0x00000002 */
6948 #define SYSCFG_ITLINE6_SR_EXTI3               SYSCFG_ITLINE6_SR_EXTI3_Msk      /*!< External Interrupt 3 */
6949 #define SYSCFG_ITLINE7_SR_EXTI4_Pos           (0U)
6950 #define SYSCFG_ITLINE7_SR_EXTI4_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI4_Pos) /*!< 0x00000001 */
6951 #define SYSCFG_ITLINE7_SR_EXTI4               SYSCFG_ITLINE7_SR_EXTI4_Msk      /*!< External Interrupt 4 */
6952 #define SYSCFG_ITLINE7_SR_EXTI5_Pos           (1U)
6953 #define SYSCFG_ITLINE7_SR_EXTI5_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI5_Pos) /*!< 0x00000002 */
6954 #define SYSCFG_ITLINE7_SR_EXTI5               SYSCFG_ITLINE7_SR_EXTI5_Msk      /*!< External Interrupt 5 */
6955 #define SYSCFG_ITLINE7_SR_EXTI6_Pos           (2U)
6956 #define SYSCFG_ITLINE7_SR_EXTI6_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI6_Pos) /*!< 0x00000004 */
6957 #define SYSCFG_ITLINE7_SR_EXTI6               SYSCFG_ITLINE7_SR_EXTI6_Msk      /*!< External Interrupt 6 */
6958 #define SYSCFG_ITLINE7_SR_EXTI7_Pos           (3U)
6959 #define SYSCFG_ITLINE7_SR_EXTI7_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI7_Pos) /*!< 0x00000008 */
6960 #define SYSCFG_ITLINE7_SR_EXTI7               SYSCFG_ITLINE7_SR_EXTI7_Msk      /*!< External Interrupt 7 */
6961 #define SYSCFG_ITLINE7_SR_EXTI8_Pos           (4U)
6962 #define SYSCFG_ITLINE7_SR_EXTI8_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI8_Pos) /*!< 0x00000010 */
6963 #define SYSCFG_ITLINE7_SR_EXTI8               SYSCFG_ITLINE7_SR_EXTI8_Msk      /*!< External Interrupt 8 */
6964 #define SYSCFG_ITLINE7_SR_EXTI9_Pos           (5U)
6965 #define SYSCFG_ITLINE7_SR_EXTI9_Msk           (0x1UL << SYSCFG_ITLINE7_SR_EXTI9_Pos) /*!< 0x00000020 */
6966 #define SYSCFG_ITLINE7_SR_EXTI9               SYSCFG_ITLINE7_SR_EXTI9_Msk      /*!< External Interrupt 9 */
6967 #define SYSCFG_ITLINE7_SR_EXTI10_Pos          (6U)
6968 #define SYSCFG_ITLINE7_SR_EXTI10_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI10_Pos) /*!< 0x00000040 */
6969 #define SYSCFG_ITLINE7_SR_EXTI10              SYSCFG_ITLINE7_SR_EXTI10_Msk     /*!< External Interrupt 10 */
6970 #define SYSCFG_ITLINE7_SR_EXTI11_Pos          (7U)
6971 #define SYSCFG_ITLINE7_SR_EXTI11_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI11_Pos) /*!< 0x00000080 */
6972 #define SYSCFG_ITLINE7_SR_EXTI11              SYSCFG_ITLINE7_SR_EXTI11_Msk     /*!< External Interrupt 11 */
6973 #define SYSCFG_ITLINE7_SR_EXTI12_Pos          (8U)
6974 #define SYSCFG_ITLINE7_SR_EXTI12_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI12_Pos) /*!< 0x00000100 */
6975 #define SYSCFG_ITLINE7_SR_EXTI12              SYSCFG_ITLINE7_SR_EXTI12_Msk     /*!< External Interrupt 12 */
6976 #define SYSCFG_ITLINE7_SR_EXTI13_Pos          (9U)
6977 #define SYSCFG_ITLINE7_SR_EXTI13_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI13_Pos) /*!< 0x00000200 */
6978 #define SYSCFG_ITLINE7_SR_EXTI13              SYSCFG_ITLINE7_SR_EXTI13_Msk     /*!< External Interrupt 13 */
6979 #define SYSCFG_ITLINE7_SR_EXTI14_Pos          (10U)
6980 #define SYSCFG_ITLINE7_SR_EXTI14_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI14_Pos) /*!< 0x00000400 */
6981 #define SYSCFG_ITLINE7_SR_EXTI14              SYSCFG_ITLINE7_SR_EXTI14_Msk     /*!< External Interrupt 14 */
6982 #define SYSCFG_ITLINE7_SR_EXTI15_Pos          (11U)
6983 #define SYSCFG_ITLINE7_SR_EXTI15_Msk          (0x1UL << SYSCFG_ITLINE7_SR_EXTI15_Pos) /*!< 0x00000800 */
6984 #define SYSCFG_ITLINE7_SR_EXTI15              SYSCFG_ITLINE7_SR_EXTI15_Msk     /*!< External Interrupt 15 */
6985 #define SYSCFG_ITLINE8_SR_USB_Pos             (2U)
6986 #define SYSCFG_ITLINE8_SR_USB_Msk             (0x1UL << SYSCFG_ITLINE8_SR_USB_Pos)   /*!< 0x00000004 */
6987 #define SYSCFG_ITLINE8_SR_USB                 SYSCFG_ITLINE8_SR_USB_Msk              /*!< USB Interrupt */
6988 #define SYSCFG_ITLINE9_SR_DMA1_CH1_Pos        (0U)
6989 #define SYSCFG_ITLINE9_SR_DMA1_CH1_Msk        (0x1UL << SYSCFG_ITLINE9_SR_DMA1_CH1_Pos) /*!< 0x00000001 */
6990 #define SYSCFG_ITLINE9_SR_DMA1_CH1            SYSCFG_ITLINE9_SR_DMA1_CH1_Msk   /*!< DMA1 Channel 1 Interrupt */
6991 #define SYSCFG_ITLINE10_SR_DMA1_CH2_Pos       (0U)
6992 #define SYSCFG_ITLINE10_SR_DMA1_CH2_Msk       (0x1UL << SYSCFG_ITLINE10_SR_DMA1_CH2_Pos) /*!< 0x00000001 */
6993 #define SYSCFG_ITLINE10_SR_DMA1_CH2           SYSCFG_ITLINE10_SR_DMA1_CH2_Msk  /*!< DMA1 Channel 2 Interrupt */
6994 #define SYSCFG_ITLINE10_SR_DMA1_CH3_Pos       (1U)
6995 #define SYSCFG_ITLINE10_SR_DMA1_CH3_Msk       (0x1UL << SYSCFG_ITLINE10_SR_DMA1_CH3_Pos) /*!< 0x00000002 */
6996 #define SYSCFG_ITLINE10_SR_DMA1_CH3           SYSCFG_ITLINE10_SR_DMA1_CH3_Msk  /*!< DMA2 Channel 3 Interrupt */
6997 #define SYSCFG_ITLINE11_SR_DMAMUX1_Pos        (0U)
6998 #define SYSCFG_ITLINE11_SR_DMAMUX1_Msk        (0x1UL << SYSCFG_ITLINE11_SR_DMAMUX1_Pos) /*!< 0x00000001 */
6999 #define SYSCFG_ITLINE11_SR_DMAMUX1            SYSCFG_ITLINE11_SR_DMAMUX1_Msk    /*!< DMAMUX Interrupt */
7000 #define SYSCFG_ITLINE11_SR_DMA1_CH4_Pos       (1U)
7001 #define SYSCFG_ITLINE11_SR_DMA1_CH4_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA1_CH4_Pos) /*!< 0x00000002 */
7002 #define SYSCFG_ITLINE11_SR_DMA1_CH4           SYSCFG_ITLINE11_SR_DMA1_CH4_Msk  /*!< DMA1 Channel 4 Interrupt */
7003 #define SYSCFG_ITLINE11_SR_DMA1_CH5_Pos       (2U)
7004 #define SYSCFG_ITLINE11_SR_DMA1_CH5_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA1_CH5_Pos) /*!< 0x00000004 */
7005 #define SYSCFG_ITLINE11_SR_DMA1_CH5           SYSCFG_ITLINE11_SR_DMA1_CH5_Msk  /*!< DMA1 Channel 5 Interrupt */
7006 #define SYSCFG_ITLINE11_SR_DMA1_CH6_Pos       (3U)
7007 #define SYSCFG_ITLINE11_SR_DMA1_CH6_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA1_CH6_Pos) /*!< 0x00000008 */
7008 #define SYSCFG_ITLINE11_SR_DMA1_CH6           SYSCFG_ITLINE11_SR_DMA1_CH6_Msk  /*!< DMA1 Channel 6 Interrupt */
7009 #define SYSCFG_ITLINE11_SR_DMA1_CH7_Pos       (4U)
7010 #define SYSCFG_ITLINE11_SR_DMA1_CH7_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA1_CH7_Pos) /*!< 0x00000010 */
7011 #define SYSCFG_ITLINE11_SR_DMA1_CH7           SYSCFG_ITLINE11_SR_DMA1_CH7_Msk  /*!< DMA1 Channel 7 Interrupt */
7012 #define SYSCFG_ITLINE11_SR_DMA2_CH1_Pos       (5U)
7013 #define SYSCFG_ITLINE11_SR_DMA2_CH1_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA2_CH1_Pos) /*!< 0x00000020 */
7014 #define SYSCFG_ITLINE11_SR_DMA2_CH1           SYSCFG_ITLINE11_SR_DMA2_CH1_Msk   /*!< DMA2 Channel 1 Interrupt */
7015 #define SYSCFG_ITLINE11_SR_DMA2_CH2_Pos       (6U)
7016 #define SYSCFG_ITLINE11_SR_DMA2_CH2_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA2_CH2_Pos) /*!< 0x00000040 */
7017 #define SYSCFG_ITLINE11_SR_DMA2_CH2           SYSCFG_ITLINE11_SR_DMA2_CH2_Msk  /*!< DMA2 Channel 2 Interrupt */
7018 #define SYSCFG_ITLINE11_SR_DMA2_CH3_Pos       (7U)
7019 #define SYSCFG_ITLINE11_SR_DMA2_CH3_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA2_CH3_Pos) /*!< 0x00000080 */
7020 #define SYSCFG_ITLINE11_SR_DMA2_CH3           SYSCFG_ITLINE11_SR_DMA2_CH3_Msk  /*!< DMA2 Channel 3 Interrupt */
7021 #define SYSCFG_ITLINE11_SR_DMA2_CH4_Pos       (8U)
7022 #define SYSCFG_ITLINE11_SR_DMA2_CH4_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA2_CH4_Pos) /*!< 0x00000100 */
7023 #define SYSCFG_ITLINE11_SR_DMA2_CH4           SYSCFG_ITLINE11_SR_DMA2_CH4_Msk  /*!< DMA2 Channel 4 Interrupt */
7024 #define SYSCFG_ITLINE11_SR_DMA2_CH5_Pos       (9U)
7025 #define SYSCFG_ITLINE11_SR_DMA2_CH5_Msk       (0x1UL << SYSCFG_ITLINE11_SR_DMA2_CH5_Pos) /*!< 0x00000200 */
7026 #define SYSCFG_ITLINE11_SR_DMA2_CH5           SYSCFG_ITLINE11_SR_DMA2_CH5_Msk  /*!< DMA2 Channel 5 Interrupt */
7027 #define SYSCFG_ITLINE12_SR_ADC_Pos            (0U)
7028 #define SYSCFG_ITLINE12_SR_ADC_Msk            (0x1UL << SYSCFG_ITLINE12_SR_ADC_Pos) /*!< 0x00000001 */
7029 #define SYSCFG_ITLINE12_SR_ADC                SYSCFG_ITLINE12_SR_ADC_Msk       /*!< ADC Interrupt */
7030 #define SYSCFG_ITLINE13_SR_TIM1_CCU_Pos       (0U)
7031 #define SYSCFG_ITLINE13_SR_TIM1_CCU_Msk       (0x1UL << SYSCFG_ITLINE13_SR_TIM1_CCU_Pos) /*!< 0x00000001 */
7032 #define SYSCFG_ITLINE13_SR_TIM1_CCU           SYSCFG_ITLINE13_SR_TIM1_CCU_Msk  /*!< TIM1 CCU Interrupt */
7033 #define SYSCFG_ITLINE13_SR_TIM1_TRG_Pos       (1U)
7034 #define SYSCFG_ITLINE13_SR_TIM1_TRG_Msk       (0x1UL << SYSCFG_ITLINE13_SR_TIM1_TRG_Pos) /*!< 0x00000002 */
7035 #define SYSCFG_ITLINE13_SR_TIM1_TRG           SYSCFG_ITLINE13_SR_TIM1_TRG_Msk  /*!< TIM1 TRG Interrupt */
7036 #define SYSCFG_ITLINE13_SR_TIM1_UPD_Pos       (2U)
7037 #define SYSCFG_ITLINE13_SR_TIM1_UPD_Msk       (0x1UL << SYSCFG_ITLINE13_SR_TIM1_UPD_Pos) /*!< 0x00000004 */
7038 #define SYSCFG_ITLINE13_SR_TIM1_UPD           SYSCFG_ITLINE13_SR_TIM1_UPD_Msk  /*!< TIM1 UPD Interrupt */
7039 #define SYSCFG_ITLINE13_SR_TIM1_BRK_Pos       (3U)
7040 #define SYSCFG_ITLINE13_SR_TIM1_BRK_Msk       (0x1UL << SYSCFG_ITLINE13_SR_TIM1_BRK_Pos) /*!< 0x00000008 */
7041 #define SYSCFG_ITLINE13_SR_TIM1_BRK           SYSCFG_ITLINE13_SR_TIM1_BRK_Msk  /*!< TIM1 BRK Interrupt */
7042 #define SYSCFG_ITLINE14_SR_TIM1_CC_Pos        (0U)
7043 #define SYSCFG_ITLINE14_SR_TIM1_CC_Msk        (0x1UL << SYSCFG_ITLINE14_SR_TIM1_CC_Pos) /*!< 0x00000001 */
7044 #define SYSCFG_ITLINE14_SR_TIM1_CC            SYSCFG_ITLINE14_SR_TIM1_CC_Msk   /*!< TIM1 CC Interrupt */
7045 #define SYSCFG_ITLINE16_SR_TIM3_GLB_Pos       (0U)
7046 #define SYSCFG_ITLINE16_SR_TIM3_GLB_Msk       (0x1UL << SYSCFG_ITLINE16_SR_TIM3_GLB_Pos) /*!< 0x00000001 */
7047 #define SYSCFG_ITLINE16_SR_TIM3_GLB           SYSCFG_ITLINE16_SR_TIM3_GLB_Msk  /*!< TIM3 GLB Interrupt */
7048 #define SYSCFG_ITLINE16_SR_TIM4_GLB_Pos       (1U)
7049 #define SYSCFG_ITLINE16_SR_TIM4_GLB_Msk       (0x1UL << SYSCFG_ITLINE16_SR_TIM4_GLB_Pos) /*!< 0x00000002 */
7050 #define SYSCFG_ITLINE16_SR_TIM4_GLB           SYSCFG_ITLINE16_SR_TIM4_GLB_Msk  /*!< TIM4 GLB Interrupt */
7051 #define SYSCFG_ITLINE17_SR_TIM6_GLB_Pos       (0U)
7052 #define SYSCFG_ITLINE17_SR_TIM6_GLB_Msk       (0x1UL << SYSCFG_ITLINE17_SR_TIM6_GLB_Pos) /*!< 0x00000001 */
7053 #define SYSCFG_ITLINE17_SR_TIM6_GLB           SYSCFG_ITLINE17_SR_TIM6_GLB_Msk  /*!< TIM6 GLB Interrupt */
7054 #define SYSCFG_ITLINE18_SR_TIM7_GLB_Pos       (0U)
7055 #define SYSCFG_ITLINE18_SR_TIM7_GLB_Msk       (0x1UL << SYSCFG_ITLINE18_SR_TIM7_GLB_Pos) /*!< 0x00000001 */
7056 #define SYSCFG_ITLINE18_SR_TIM7_GLB           SYSCFG_ITLINE18_SR_TIM7_GLB_Msk  /*!< TIM7 GLB Interrupt */
7057 #define SYSCFG_ITLINE19_SR_TIM14_GLB_Pos      (0U)
7058 #define SYSCFG_ITLINE19_SR_TIM14_GLB_Msk      (0x1UL << SYSCFG_ITLINE19_SR_TIM14_GLB_Pos) /*!< 0x00000001 */
7059 #define SYSCFG_ITLINE19_SR_TIM14_GLB          SYSCFG_ITLINE19_SR_TIM14_GLB_Msk /*!< TIM14 GLB Interrupt */
7060 #define SYSCFG_ITLINE20_SR_TIM15_GLB_Pos      (0U)
7061 #define SYSCFG_ITLINE20_SR_TIM15_GLB_Msk      (0x1UL << SYSCFG_ITLINE20_SR_TIM15_GLB_Pos) /*!< 0x00000001 */
7062 #define SYSCFG_ITLINE20_SR_TIM15_GLB          SYSCFG_ITLINE20_SR_TIM15_GLB_Msk /*!< TIM15 GLB Interrupt */
7063 #define SYSCFG_ITLINE21_SR_TIM16_GLB_Pos      (0U)
7064 #define SYSCFG_ITLINE21_SR_TIM16_GLB_Msk      (0x1UL << SYSCFG_ITLINE21_SR_TIM16_GLB_Pos) /*!< 0x00000001 */
7065 #define SYSCFG_ITLINE21_SR_TIM16_GLB          SYSCFG_ITLINE21_SR_TIM16_GLB_Msk /*!< TIM16 GLB Interrupt */
7066 #define SYSCFG_ITLINE22_SR_TIM17_GLB_Pos      (0U)
7067 #define SYSCFG_ITLINE22_SR_TIM17_GLB_Msk      (0x1UL << SYSCFG_ITLINE22_SR_TIM17_GLB_Pos) /*!< 0x00000001 */
7068 #define SYSCFG_ITLINE22_SR_TIM17_GLB          SYSCFG_ITLINE22_SR_TIM17_GLB_Msk /*!< TIM17 GLB Interrupt */
7069 #define SYSCFG_ITLINE23_SR_I2C1_GLB_Pos       (0U)
7070 #define SYSCFG_ITLINE23_SR_I2C1_GLB_Msk       (0x1UL << SYSCFG_ITLINE23_SR_I2C1_GLB_Pos) /*!< 0x00000001 */
7071 #define SYSCFG_ITLINE23_SR_I2C1_GLB           SYSCFG_ITLINE23_SR_I2C1_GLB_Msk  /*!< I2C1 GLB Interrupt -> exti[23] */
7072 #define SYSCFG_ITLINE24_SR_I2C2_GLB_Pos       (0U)
7073 #define SYSCFG_ITLINE24_SR_I2C2_GLB_Msk       (0x1UL << SYSCFG_ITLINE24_SR_I2C2_GLB_Pos) /*!< 0x00000001 */
7074 #define SYSCFG_ITLINE24_SR_I2C2_GLB           SYSCFG_ITLINE24_SR_I2C2_GLB_Msk  /*!< I2C2 GLB Interrupt  -> exti[22]*/
7075 #define SYSCFG_ITLINE24_SR_I2C3_GLB_Pos       (1U)
7076 #define SYSCFG_ITLINE24_SR_I2C3_GLB_Msk       (0x1UL << SYSCFG_ITLINE24_SR_I2C3_GLB_Pos) /*!< 0x00000002 */
7077 #define SYSCFG_ITLINE24_SR_I2C3_GLB           SYSCFG_ITLINE24_SR_I2C3_GLB_Msk  /*!< I2C3 GLB Interrupt  -> exti[24]*/
7078 #define SYSCFG_ITLINE25_SR_SPI1_Pos           (0U)
7079 #define SYSCFG_ITLINE25_SR_SPI1_Msk           (0x1UL << SYSCFG_ITLINE25_SR_SPI1_Pos) /*!< 0x00000001 */
7080 #define SYSCFG_ITLINE25_SR_SPI1               SYSCFG_ITLINE25_SR_SPI1_Msk      /*!< SPI1 Interrupt */
7081 #define SYSCFG_ITLINE26_SR_SPI2_Pos           (0U)
7082 #define SYSCFG_ITLINE26_SR_SPI2_Msk           (0x1UL << SYSCFG_ITLINE26_SR_SPI2_Pos) /*!< 0x00000001 */
7083 #define SYSCFG_ITLINE26_SR_SPI2               SYSCFG_ITLINE26_SR_SPI2_Msk      /*!< SPI2  Interrupt */
7084 #define SYSCFG_ITLINE26_SR_SPI3_Pos           (1U)
7085 #define SYSCFG_ITLINE26_SR_SPI3_Msk           (0x1UL << SYSCFG_ITLINE26_SR_SPI3_Pos) /*!< 0x00000002 */
7086 #define SYSCFG_ITLINE26_SR_SPI3               SYSCFG_ITLINE26_SR_SPI3_Msk      /*!< SPI3  Interrupt */
7087 #define SYSCFG_ITLINE27_SR_USART1_GLB_Pos     (0U)
7088 #define SYSCFG_ITLINE27_SR_USART1_GLB_Msk     (0x1UL << SYSCFG_ITLINE27_SR_USART1_GLB_Pos) /*!< 0x00000001 */
7089 #define SYSCFG_ITLINE27_SR_USART1_GLB         SYSCFG_ITLINE27_SR_USART1_GLB_Msk /*!< USART1 GLB Interrupt -> exti[25] */
7090 #define SYSCFG_ITLINE28_SR_USART2_GLB_Pos     (0U)
7091 #define SYSCFG_ITLINE28_SR_USART2_GLB_Msk     (0x1UL << SYSCFG_ITLINE28_SR_USART2_GLB_Pos) /*!< 0x00000001 */
7092 #define SYSCFG_ITLINE28_SR_USART2_GLB         SYSCFG_ITLINE28_SR_USART2_GLB_Msk /*!< USART2 GLB Interrupt -> exti[26] */
7093 #define SYSCFG_ITLINE29_SR_USART3_GLB_Pos     (0U)
7094 #define SYSCFG_ITLINE29_SR_USART3_GLB_Msk     (0x1UL << SYSCFG_ITLINE29_SR_USART3_GLB_Pos) /*!< 0x00000001 */
7095 #define SYSCFG_ITLINE29_SR_USART3_GLB         SYSCFG_ITLINE29_SR_USART3_GLB_Msk /*!< USART3 GLB Interrupt */
7096 #define SYSCFG_ITLINE29_SR_USART4_GLB_Pos     (1U)
7097 #define SYSCFG_ITLINE29_SR_USART4_GLB_Msk     (0x1UL << SYSCFG_ITLINE29_SR_USART4_GLB_Pos) /*!< 0x00000002 */
7098 #define SYSCFG_ITLINE29_SR_USART4_GLB         SYSCFG_ITLINE29_SR_USART4_GLB_Msk /*!< USART4 GLB Interrupt */
7099 #define SYSCFG_ITLINE29_SR_USART5_GLB_Pos     (3U)
7100 #define SYSCFG_ITLINE29_SR_USART5_GLB_Msk     (0x1UL << SYSCFG_ITLINE29_SR_USART5_GLB_Pos) /*!< 0x00000008 */
7101 #define SYSCFG_ITLINE29_SR_USART5_GLB         SYSCFG_ITLINE29_SR_USART5_GLB_Msk /*!< USART5 GLB Interrupt */
7102 #define SYSCFG_ITLINE29_SR_USART6_GLB_Pos     (4U)
7103 #define SYSCFG_ITLINE29_SR_USART6_GLB_Msk     (0x1UL << SYSCFG_ITLINE29_SR_USART6_GLB_Pos) /*!< 0x00000010 */
7104 #define SYSCFG_ITLINE29_SR_USART6_GLB         SYSCFG_ITLINE29_SR_USART6_GLB_Msk /*!< USART6 GLB Interrupt */
7105 
7106 /******************************************************************************/
7107 /*                                                                            */
7108 /*                                    TIM                                     */
7109 /*                                                                            */
7110 /******************************************************************************/
7111 /*******************  Bit definition for TIM_CR1 register  ********************/
7112 #define TIM_CR1_CEN_Pos           (0U)
7113 #define TIM_CR1_CEN_Msk           (0x1UL << TIM_CR1_CEN_Pos)                   /*!< 0x00000001 */
7114 #define TIM_CR1_CEN               TIM_CR1_CEN_Msk                              /*!<Counter enable */
7115 #define TIM_CR1_UDIS_Pos          (1U)
7116 #define TIM_CR1_UDIS_Msk          (0x1UL << TIM_CR1_UDIS_Pos)                  /*!< 0x00000002 */
7117 #define TIM_CR1_UDIS              TIM_CR1_UDIS_Msk                             /*!<Update disable */
7118 #define TIM_CR1_URS_Pos           (2U)
7119 #define TIM_CR1_URS_Msk           (0x1UL << TIM_CR1_URS_Pos)                   /*!< 0x00000004 */
7120 #define TIM_CR1_URS               TIM_CR1_URS_Msk                              /*!<Update request source */
7121 #define TIM_CR1_OPM_Pos           (3U)
7122 #define TIM_CR1_OPM_Msk           (0x1UL << TIM_CR1_OPM_Pos)                   /*!< 0x00000008 */
7123 #define TIM_CR1_OPM               TIM_CR1_OPM_Msk                              /*!<One pulse mode */
7124 #define TIM_CR1_DIR_Pos           (4U)
7125 #define TIM_CR1_DIR_Msk           (0x1UL << TIM_CR1_DIR_Pos)                   /*!< 0x00000010 */
7126 #define TIM_CR1_DIR               TIM_CR1_DIR_Msk                              /*!<Direction */
7127 
7128 #define TIM_CR1_CMS_Pos           (5U)
7129 #define TIM_CR1_CMS_Msk           (0x3UL << TIM_CR1_CMS_Pos)                   /*!< 0x00000060 */
7130 #define TIM_CR1_CMS               TIM_CR1_CMS_Msk                              /*!<CMS[1:0] bits (Center-aligned mode selection) */
7131 #define TIM_CR1_CMS_0             (0x1UL << TIM_CR1_CMS_Pos)                   /*!< 0x00000020 */
7132 #define TIM_CR1_CMS_1             (0x2UL << TIM_CR1_CMS_Pos)                   /*!< 0x00000040 */
7133 
7134 #define TIM_CR1_ARPE_Pos          (7U)
7135 #define TIM_CR1_ARPE_Msk          (0x1UL << TIM_CR1_ARPE_Pos)                  /*!< 0x00000080 */
7136 #define TIM_CR1_ARPE              TIM_CR1_ARPE_Msk                             /*!<Auto-reload preload enable */
7137 
7138 #define TIM_CR1_CKD_Pos           (8U)
7139 #define TIM_CR1_CKD_Msk           (0x3UL << TIM_CR1_CKD_Pos)                   /*!< 0x00000300 */
7140 #define TIM_CR1_CKD               TIM_CR1_CKD_Msk                              /*!<CKD[1:0] bits (clock division) */
7141 #define TIM_CR1_CKD_0             (0x1UL << TIM_CR1_CKD_Pos)                   /*!< 0x00000100 */
7142 #define TIM_CR1_CKD_1             (0x2UL << TIM_CR1_CKD_Pos)                   /*!< 0x00000200 */
7143 
7144 #define TIM_CR1_UIFREMAP_Pos      (11U)
7145 #define TIM_CR1_UIFREMAP_Msk      (0x1UL << TIM_CR1_UIFREMAP_Pos)              /*!< 0x00000800 */
7146 #define TIM_CR1_UIFREMAP          TIM_CR1_UIFREMAP_Msk                         /*!<Update interrupt flag remap */
7147 
7148 /*******************  Bit definition for TIM_CR2 register  ********************/
7149 #define TIM_CR2_CCPC_Pos          (0U)
7150 #define TIM_CR2_CCPC_Msk          (0x1UL << TIM_CR2_CCPC_Pos)                  /*!< 0x00000001 */
7151 #define TIM_CR2_CCPC              TIM_CR2_CCPC_Msk                             /*!<Capture/Compare Preloaded Control */
7152 #define TIM_CR2_CCUS_Pos          (2U)
7153 #define TIM_CR2_CCUS_Msk          (0x1UL << TIM_CR2_CCUS_Pos)                  /*!< 0x00000004 */
7154 #define TIM_CR2_CCUS              TIM_CR2_CCUS_Msk                             /*!<Capture/Compare Control Update Selection */
7155 #define TIM_CR2_CCDS_Pos          (3U)
7156 #define TIM_CR2_CCDS_Msk          (0x1UL << TIM_CR2_CCDS_Pos)                  /*!< 0x00000008 */
7157 #define TIM_CR2_CCDS              TIM_CR2_CCDS_Msk                             /*!<Capture/Compare DMA Selection */
7158 
7159 #define TIM_CR2_MMS_Pos           (4U)
7160 #define TIM_CR2_MMS_Msk           (0x7UL << TIM_CR2_MMS_Pos)                   /*!< 0x00000070 */
7161 #define TIM_CR2_MMS               TIM_CR2_MMS_Msk                              /*!<MMS[2:0] bits (Master Mode Selection) */
7162 #define TIM_CR2_MMS_0             (0x1UL << TIM_CR2_MMS_Pos)                   /*!< 0x00000010 */
7163 #define TIM_CR2_MMS_1             (0x2UL << TIM_CR2_MMS_Pos)                   /*!< 0x00000020 */
7164 #define TIM_CR2_MMS_2             (0x4UL << TIM_CR2_MMS_Pos)                   /*!< 0x00000040 */
7165 
7166 #define TIM_CR2_TI1S_Pos          (7U)
7167 #define TIM_CR2_TI1S_Msk          (0x1UL << TIM_CR2_TI1S_Pos)                  /*!< 0x00000080 */
7168 #define TIM_CR2_TI1S              TIM_CR2_TI1S_Msk                             /*!<TI1 Selection */
7169 #define TIM_CR2_OIS1_Pos          (8U)
7170 #define TIM_CR2_OIS1_Msk          (0x1UL << TIM_CR2_OIS1_Pos)                  /*!< 0x00000100 */
7171 #define TIM_CR2_OIS1              TIM_CR2_OIS1_Msk                             /*!<Output Idle state 1 (OC1 output) */
7172 #define TIM_CR2_OIS1N_Pos         (9U)
7173 #define TIM_CR2_OIS1N_Msk         (0x1UL << TIM_CR2_OIS1N_Pos)                 /*!< 0x00000200 */
7174 #define TIM_CR2_OIS1N             TIM_CR2_OIS1N_Msk                            /*!<Output Idle state 1 (OC1N output) */
7175 #define TIM_CR2_OIS2_Pos          (10U)
7176 #define TIM_CR2_OIS2_Msk          (0x1UL << TIM_CR2_OIS2_Pos)                  /*!< 0x00000400 */
7177 #define TIM_CR2_OIS2              TIM_CR2_OIS2_Msk                             /*!<Output Idle state 2 (OC2 output) */
7178 #define TIM_CR2_OIS2N_Pos         (11U)
7179 #define TIM_CR2_OIS2N_Msk         (0x1UL << TIM_CR2_OIS2N_Pos)                 /*!< 0x00000800 */
7180 #define TIM_CR2_OIS2N             TIM_CR2_OIS2N_Msk                            /*!<Output Idle state 2 (OC2N output) */
7181 #define TIM_CR2_OIS3_Pos          (12U)
7182 #define TIM_CR2_OIS3_Msk          (0x1UL << TIM_CR2_OIS3_Pos)                  /*!< 0x00001000 */
7183 #define TIM_CR2_OIS3              TIM_CR2_OIS3_Msk                             /*!<Output Idle state 3 (OC3 output) */
7184 #define TIM_CR2_OIS3N_Pos         (13U)
7185 #define TIM_CR2_OIS3N_Msk         (0x1UL << TIM_CR2_OIS3N_Pos)                 /*!< 0x00002000 */
7186 #define TIM_CR2_OIS3N             TIM_CR2_OIS3N_Msk                            /*!<Output Idle state 3 (OC3N output) */
7187 #define TIM_CR2_OIS4_Pos          (14U)
7188 #define TIM_CR2_OIS4_Msk          (0x1UL << TIM_CR2_OIS4_Pos)                  /*!< 0x00004000 */
7189 #define TIM_CR2_OIS4              TIM_CR2_OIS4_Msk                             /*!<Output Idle state 4 (OC4 output) */
7190 #define TIM_CR2_OIS5_Pos          (16U)
7191 #define TIM_CR2_OIS5_Msk          (0x1UL << TIM_CR2_OIS5_Pos)                  /*!< 0x00010000 */
7192 #define TIM_CR2_OIS5              TIM_CR2_OIS5_Msk                             /*!<Output Idle state 5 (OC5 output) */
7193 #define TIM_CR2_OIS6_Pos          (18U)
7194 #define TIM_CR2_OIS6_Msk          (0x1UL << TIM_CR2_OIS6_Pos)                  /*!< 0x00040000 */
7195 #define TIM_CR2_OIS6              TIM_CR2_OIS6_Msk                             /*!<Output Idle state 6 (OC6 output) */
7196 
7197 #define TIM_CR2_MMS2_Pos          (20U)
7198 #define TIM_CR2_MMS2_Msk          (0xFUL << TIM_CR2_MMS2_Pos)                  /*!< 0x00F00000 */
7199 #define TIM_CR2_MMS2              TIM_CR2_MMS2_Msk                             /*!<MMS[2:0] bits (Master Mode Selection) */
7200 #define TIM_CR2_MMS2_0            (0x1UL << TIM_CR2_MMS2_Pos)                  /*!< 0x00100000 */
7201 #define TIM_CR2_MMS2_1            (0x2UL << TIM_CR2_MMS2_Pos)                  /*!< 0x00200000 */
7202 #define TIM_CR2_MMS2_2            (0x4UL << TIM_CR2_MMS2_Pos)                  /*!< 0x00400000 */
7203 #define TIM_CR2_MMS2_3            (0x8UL << TIM_CR2_MMS2_Pos)                  /*!< 0x00800000 */
7204 
7205 /*******************  Bit definition for TIM_SMCR register  *******************/
7206 #define TIM_SMCR_SMS_Pos          (0U)
7207 #define TIM_SMCR_SMS_Msk          (0x10007UL << TIM_SMCR_SMS_Pos)              /*!< 0x00010007 */
7208 #define TIM_SMCR_SMS              TIM_SMCR_SMS_Msk                             /*!<SMS[2:0] bits (Slave mode selection) */
7209 #define TIM_SMCR_SMS_0            (0x00001UL << TIM_SMCR_SMS_Pos)              /*!< 0x00000001 */
7210 #define TIM_SMCR_SMS_1            (0x00002UL << TIM_SMCR_SMS_Pos)              /*!< 0x00000002 */
7211 #define TIM_SMCR_SMS_2            (0x00004UL << TIM_SMCR_SMS_Pos)              /*!< 0x00000004 */
7212 #define TIM_SMCR_SMS_3            (0x10000UL << TIM_SMCR_SMS_Pos)              /*!< 0x00010000 */
7213 
7214 #define TIM_SMCR_OCCS_Pos         (3U)
7215 #define TIM_SMCR_OCCS_Msk         (0x1UL << TIM_SMCR_OCCS_Pos)                 /*!< 0x00000008 */
7216 #define TIM_SMCR_OCCS             TIM_SMCR_OCCS_Msk                            /*!< OCREF clear selection */
7217 
7218 #define TIM_SMCR_TS_Pos           (4U)
7219 #define TIM_SMCR_TS_Msk           (0x30007UL << TIM_SMCR_TS_Pos)               /*!< 0x00300070 */
7220 #define TIM_SMCR_TS               TIM_SMCR_TS_Msk                              /*!<TS[2:0] bits (Trigger selection) */
7221 #define TIM_SMCR_TS_0             (0x00001UL << TIM_SMCR_TS_Pos)               /*!< 0x00000010 */
7222 #define TIM_SMCR_TS_1             (0x00002UL << TIM_SMCR_TS_Pos)               /*!< 0x00000020 */
7223 #define TIM_SMCR_TS_2             (0x00004UL << TIM_SMCR_TS_Pos)               /*!< 0x00000040 */
7224 #define TIM_SMCR_TS_3             (0x10000UL << TIM_SMCR_TS_Pos)               /*!< 0x00100000 */
7225 #define TIM_SMCR_TS_4             (0x20000UL << TIM_SMCR_TS_Pos)               /*!< 0x00200000 */
7226 
7227 #define TIM_SMCR_MSM_Pos          (7U)
7228 #define TIM_SMCR_MSM_Msk          (0x1UL << TIM_SMCR_MSM_Pos)                  /*!< 0x00000080 */
7229 #define TIM_SMCR_MSM              TIM_SMCR_MSM_Msk                             /*!<Master/slave mode */
7230 
7231 #define TIM_SMCR_ETF_Pos          (8U)
7232 #define TIM_SMCR_ETF_Msk          (0xFUL << TIM_SMCR_ETF_Pos)                  /*!< 0x00000F00 */
7233 #define TIM_SMCR_ETF              TIM_SMCR_ETF_Msk                             /*!<ETF[3:0] bits (External trigger filter) */
7234 #define TIM_SMCR_ETF_0            (0x1UL << TIM_SMCR_ETF_Pos)                  /*!< 0x00000100 */
7235 #define TIM_SMCR_ETF_1            (0x2UL << TIM_SMCR_ETF_Pos)                  /*!< 0x00000200 */
7236 #define TIM_SMCR_ETF_2            (0x4UL << TIM_SMCR_ETF_Pos)                  /*!< 0x00000400 */
7237 #define TIM_SMCR_ETF_3            (0x8UL << TIM_SMCR_ETF_Pos)                  /*!< 0x00000800 */
7238 
7239 #define TIM_SMCR_ETPS_Pos         (12U)
7240 #define TIM_SMCR_ETPS_Msk         (0x3UL << TIM_SMCR_ETPS_Pos)                 /*!< 0x00003000 */
7241 #define TIM_SMCR_ETPS             TIM_SMCR_ETPS_Msk                            /*!<ETPS[1:0] bits (External trigger prescaler) */
7242 #define TIM_SMCR_ETPS_0           (0x1UL << TIM_SMCR_ETPS_Pos)                 /*!< 0x00001000 */
7243 #define TIM_SMCR_ETPS_1           (0x2UL << TIM_SMCR_ETPS_Pos)                 /*!< 0x00002000 */
7244 
7245 #define TIM_SMCR_ECE_Pos          (14U)
7246 #define TIM_SMCR_ECE_Msk          (0x1UL << TIM_SMCR_ECE_Pos)                  /*!< 0x00004000 */
7247 #define TIM_SMCR_ECE              TIM_SMCR_ECE_Msk                             /*!<External clock enable */
7248 #define TIM_SMCR_ETP_Pos          (15U)
7249 #define TIM_SMCR_ETP_Msk          (0x1UL << TIM_SMCR_ETP_Pos)                  /*!< 0x00008000 */
7250 #define TIM_SMCR_ETP              TIM_SMCR_ETP_Msk                             /*!<External trigger polarity */
7251 
7252 /*******************  Bit definition for TIM_DIER register  *******************/
7253 #define TIM_DIER_UIE_Pos          (0U)
7254 #define TIM_DIER_UIE_Msk          (0x1UL << TIM_DIER_UIE_Pos)                  /*!< 0x00000001 */
7255 #define TIM_DIER_UIE              TIM_DIER_UIE_Msk                             /*!<Update interrupt enable */
7256 #define TIM_DIER_CC1IE_Pos        (1U)
7257 #define TIM_DIER_CC1IE_Msk        (0x1UL << TIM_DIER_CC1IE_Pos)                /*!< 0x00000002 */
7258 #define TIM_DIER_CC1IE            TIM_DIER_CC1IE_Msk                           /*!<Capture/Compare 1 interrupt enable */
7259 #define TIM_DIER_CC2IE_Pos        (2U)
7260 #define TIM_DIER_CC2IE_Msk        (0x1UL << TIM_DIER_CC2IE_Pos)                /*!< 0x00000004 */
7261 #define TIM_DIER_CC2IE            TIM_DIER_CC2IE_Msk                           /*!<Capture/Compare 2 interrupt enable */
7262 #define TIM_DIER_CC3IE_Pos        (3U)
7263 #define TIM_DIER_CC3IE_Msk        (0x1UL << TIM_DIER_CC3IE_Pos)                /*!< 0x00000008 */
7264 #define TIM_DIER_CC3IE            TIM_DIER_CC3IE_Msk                           /*!<Capture/Compare 3 interrupt enable */
7265 #define TIM_DIER_CC4IE_Pos        (4U)
7266 #define TIM_DIER_CC4IE_Msk        (0x1UL << TIM_DIER_CC4IE_Pos)                /*!< 0x00000010 */
7267 #define TIM_DIER_CC4IE            TIM_DIER_CC4IE_Msk                           /*!<Capture/Compare 4 interrupt enable */
7268 #define TIM_DIER_COMIE_Pos        (5U)
7269 #define TIM_DIER_COMIE_Msk        (0x1UL << TIM_DIER_COMIE_Pos)                /*!< 0x00000020 */
7270 #define TIM_DIER_COMIE            TIM_DIER_COMIE_Msk                           /*!<COM interrupt enable */
7271 #define TIM_DIER_TIE_Pos          (6U)
7272 #define TIM_DIER_TIE_Msk          (0x1UL << TIM_DIER_TIE_Pos)                  /*!< 0x00000040 */
7273 #define TIM_DIER_TIE              TIM_DIER_TIE_Msk                             /*!<Trigger interrupt enable */
7274 #define TIM_DIER_BIE_Pos          (7U)
7275 #define TIM_DIER_BIE_Msk          (0x1UL << TIM_DIER_BIE_Pos)                  /*!< 0x00000080 */
7276 #define TIM_DIER_BIE              TIM_DIER_BIE_Msk                             /*!<Break interrupt enable */
7277 #define TIM_DIER_UDE_Pos          (8U)
7278 #define TIM_DIER_UDE_Msk          (0x1UL << TIM_DIER_UDE_Pos)                  /*!< 0x00000100 */
7279 #define TIM_DIER_UDE              TIM_DIER_UDE_Msk                             /*!<Update DMA request enable */
7280 #define TIM_DIER_CC1DE_Pos        (9U)
7281 #define TIM_DIER_CC1DE_Msk        (0x1UL << TIM_DIER_CC1DE_Pos)                /*!< 0x00000200 */
7282 #define TIM_DIER_CC1DE            TIM_DIER_CC1DE_Msk                           /*!<Capture/Compare 1 DMA request enable */
7283 #define TIM_DIER_CC2DE_Pos        (10U)
7284 #define TIM_DIER_CC2DE_Msk        (0x1UL << TIM_DIER_CC2DE_Pos)                /*!< 0x00000400 */
7285 #define TIM_DIER_CC2DE            TIM_DIER_CC2DE_Msk                           /*!<Capture/Compare 2 DMA request enable */
7286 #define TIM_DIER_CC3DE_Pos        (11U)
7287 #define TIM_DIER_CC3DE_Msk        (0x1UL << TIM_DIER_CC3DE_Pos)                /*!< 0x00000800 */
7288 #define TIM_DIER_CC3DE            TIM_DIER_CC3DE_Msk                           /*!<Capture/Compare 3 DMA request enable */
7289 #define TIM_DIER_CC4DE_Pos        (12U)
7290 #define TIM_DIER_CC4DE_Msk        (0x1UL << TIM_DIER_CC4DE_Pos)                /*!< 0x00001000 */
7291 #define TIM_DIER_CC4DE            TIM_DIER_CC4DE_Msk                           /*!<Capture/Compare 4 DMA request enable */
7292 #define TIM_DIER_COMDE_Pos        (13U)
7293 #define TIM_DIER_COMDE_Msk        (0x1UL << TIM_DIER_COMDE_Pos)                /*!< 0x00002000 */
7294 #define TIM_DIER_COMDE            TIM_DIER_COMDE_Msk                           /*!<COM DMA request enable */
7295 #define TIM_DIER_TDE_Pos          (14U)
7296 #define TIM_DIER_TDE_Msk          (0x1UL << TIM_DIER_TDE_Pos)                  /*!< 0x00004000 */
7297 #define TIM_DIER_TDE              TIM_DIER_TDE_Msk                             /*!<Trigger DMA request enable */
7298 
7299 /********************  Bit definition for TIM_SR register  ********************/
7300 #define TIM_SR_UIF_Pos            (0U)
7301 #define TIM_SR_UIF_Msk            (0x1UL << TIM_SR_UIF_Pos)                    /*!< 0x00000001 */
7302 #define TIM_SR_UIF                TIM_SR_UIF_Msk                               /*!<Update interrupt Flag */
7303 #define TIM_SR_CC1IF_Pos          (1U)
7304 #define TIM_SR_CC1IF_Msk          (0x1UL << TIM_SR_CC1IF_Pos)                  /*!< 0x00000002 */
7305 #define TIM_SR_CC1IF              TIM_SR_CC1IF_Msk                             /*!<Capture/Compare 1 interrupt Flag */
7306 #define TIM_SR_CC2IF_Pos          (2U)
7307 #define TIM_SR_CC2IF_Msk          (0x1UL << TIM_SR_CC2IF_Pos)                  /*!< 0x00000004 */
7308 #define TIM_SR_CC2IF              TIM_SR_CC2IF_Msk                             /*!<Capture/Compare 2 interrupt Flag */
7309 #define TIM_SR_CC3IF_Pos          (3U)
7310 #define TIM_SR_CC3IF_Msk          (0x1UL << TIM_SR_CC3IF_Pos)                  /*!< 0x00000008 */
7311 #define TIM_SR_CC3IF              TIM_SR_CC3IF_Msk                             /*!<Capture/Compare 3 interrupt Flag */
7312 #define TIM_SR_CC4IF_Pos          (4U)
7313 #define TIM_SR_CC4IF_Msk          (0x1UL << TIM_SR_CC4IF_Pos)                  /*!< 0x00000010 */
7314 #define TIM_SR_CC4IF              TIM_SR_CC4IF_Msk                             /*!<Capture/Compare 4 interrupt Flag */
7315 #define TIM_SR_COMIF_Pos          (5U)
7316 #define TIM_SR_COMIF_Msk          (0x1UL << TIM_SR_COMIF_Pos)                  /*!< 0x00000020 */
7317 #define TIM_SR_COMIF              TIM_SR_COMIF_Msk                             /*!<COM interrupt Flag */
7318 #define TIM_SR_TIF_Pos            (6U)
7319 #define TIM_SR_TIF_Msk            (0x1UL << TIM_SR_TIF_Pos)                    /*!< 0x00000040 */
7320 #define TIM_SR_TIF                TIM_SR_TIF_Msk                               /*!<Trigger interrupt Flag */
7321 #define TIM_SR_BIF_Pos            (7U)
7322 #define TIM_SR_BIF_Msk            (0x1UL << TIM_SR_BIF_Pos)                    /*!< 0x00000080 */
7323 #define TIM_SR_BIF                TIM_SR_BIF_Msk                               /*!<Break interrupt Flag */
7324 #define TIM_SR_B2IF_Pos           (8U)
7325 #define TIM_SR_B2IF_Msk           (0x1UL << TIM_SR_B2IF_Pos)                   /*!< 0x00000100 */
7326 #define TIM_SR_B2IF               TIM_SR_B2IF_Msk                              /*!<Break 2 interrupt Flag */
7327 #define TIM_SR_CC1OF_Pos          (9U)
7328 #define TIM_SR_CC1OF_Msk          (0x1UL << TIM_SR_CC1OF_Pos)                  /*!< 0x00000200 */
7329 #define TIM_SR_CC1OF              TIM_SR_CC1OF_Msk                             /*!<Capture/Compare 1 Overcapture Flag */
7330 #define TIM_SR_CC2OF_Pos          (10U)
7331 #define TIM_SR_CC2OF_Msk          (0x1UL << TIM_SR_CC2OF_Pos)                  /*!< 0x00000400 */
7332 #define TIM_SR_CC2OF              TIM_SR_CC2OF_Msk                             /*!<Capture/Compare 2 Overcapture Flag */
7333 #define TIM_SR_CC3OF_Pos          (11U)
7334 #define TIM_SR_CC3OF_Msk          (0x1UL << TIM_SR_CC3OF_Pos)                  /*!< 0x00000800 */
7335 #define TIM_SR_CC3OF              TIM_SR_CC3OF_Msk                             /*!<Capture/Compare 3 Overcapture Flag */
7336 #define TIM_SR_CC4OF_Pos          (12U)
7337 #define TIM_SR_CC4OF_Msk          (0x1UL << TIM_SR_CC4OF_Pos)                  /*!< 0x00001000 */
7338 #define TIM_SR_CC4OF              TIM_SR_CC4OF_Msk                             /*!<Capture/Compare 4 Overcapture Flag */
7339 #define TIM_SR_SBIF_Pos           (13U)
7340 #define TIM_SR_SBIF_Msk           (0x1UL << TIM_SR_SBIF_Pos)                   /*!< 0x00002000 */
7341 #define TIM_SR_SBIF               TIM_SR_SBIF_Msk                              /*!<System Break interrupt Flag */
7342 #define TIM_SR_CC5IF_Pos          (16U)
7343 #define TIM_SR_CC5IF_Msk          (0x1UL << TIM_SR_CC5IF_Pos)                  /*!< 0x00010000 */
7344 #define TIM_SR_CC5IF              TIM_SR_CC5IF_Msk                             /*!<Capture/Compare 5 interrupt Flag */
7345 #define TIM_SR_CC6IF_Pos          (17U)
7346 #define TIM_SR_CC6IF_Msk          (0x1UL << TIM_SR_CC6IF_Pos)                  /*!< 0x00020000 */
7347 #define TIM_SR_CC6IF              TIM_SR_CC6IF_Msk                             /*!<Capture/Compare 6 interrupt Flag */
7348 
7349 
7350 /*******************  Bit definition for TIM_EGR register  ********************/
7351 #define TIM_EGR_UG_Pos            (0U)
7352 #define TIM_EGR_UG_Msk            (0x1UL << TIM_EGR_UG_Pos)                    /*!< 0x00000001 */
7353 #define TIM_EGR_UG                TIM_EGR_UG_Msk                               /*!<Update Generation */
7354 #define TIM_EGR_CC1G_Pos          (1U)
7355 #define TIM_EGR_CC1G_Msk          (0x1UL << TIM_EGR_CC1G_Pos)                  /*!< 0x00000002 */
7356 #define TIM_EGR_CC1G              TIM_EGR_CC1G_Msk                             /*!<Capture/Compare 1 Generation */
7357 #define TIM_EGR_CC2G_Pos          (2U)
7358 #define TIM_EGR_CC2G_Msk          (0x1UL << TIM_EGR_CC2G_Pos)                  /*!< 0x00000004 */
7359 #define TIM_EGR_CC2G              TIM_EGR_CC2G_Msk                             /*!<Capture/Compare 2 Generation */
7360 #define TIM_EGR_CC3G_Pos          (3U)
7361 #define TIM_EGR_CC3G_Msk          (0x1UL << TIM_EGR_CC3G_Pos)                  /*!< 0x00000008 */
7362 #define TIM_EGR_CC3G              TIM_EGR_CC3G_Msk                             /*!<Capture/Compare 3 Generation */
7363 #define TIM_EGR_CC4G_Pos          (4U)
7364 #define TIM_EGR_CC4G_Msk          (0x1UL << TIM_EGR_CC4G_Pos)                  /*!< 0x00000010 */
7365 #define TIM_EGR_CC4G              TIM_EGR_CC4G_Msk                             /*!<Capture/Compare 4 Generation */
7366 #define TIM_EGR_COMG_Pos          (5U)
7367 #define TIM_EGR_COMG_Msk          (0x1UL << TIM_EGR_COMG_Pos)                  /*!< 0x00000020 */
7368 #define TIM_EGR_COMG              TIM_EGR_COMG_Msk                             /*!<Capture/Compare Control Update Generation */
7369 #define TIM_EGR_TG_Pos            (6U)
7370 #define TIM_EGR_TG_Msk            (0x1UL << TIM_EGR_TG_Pos)                    /*!< 0x00000040 */
7371 #define TIM_EGR_TG                TIM_EGR_TG_Msk                               /*!<Trigger Generation */
7372 #define TIM_EGR_BG_Pos            (7U)
7373 #define TIM_EGR_BG_Msk            (0x1UL << TIM_EGR_BG_Pos)                    /*!< 0x00000080 */
7374 #define TIM_EGR_BG                TIM_EGR_BG_Msk                               /*!<Break Generation */
7375 #define TIM_EGR_B2G_Pos           (8U)
7376 #define TIM_EGR_B2G_Msk           (0x1UL << TIM_EGR_B2G_Pos)                   /*!< 0x00000100 */
7377 #define TIM_EGR_B2G               TIM_EGR_B2G_Msk                              /*!<Break 2 Generation */
7378 
7379 
7380 /******************  Bit definition for TIM_CCMR1 register  *******************/
7381 #define TIM_CCMR1_CC1S_Pos        (0U)
7382 #define TIM_CCMR1_CC1S_Msk        (0x3UL << TIM_CCMR1_CC1S_Pos)                /*!< 0x00000003 */
7383 #define TIM_CCMR1_CC1S            TIM_CCMR1_CC1S_Msk                           /*!<CC1S[1:0] bits (Capture/Compare 1 Selection) */
7384 #define TIM_CCMR1_CC1S_0          (0x1UL << TIM_CCMR1_CC1S_Pos)                /*!< 0x00000001 */
7385 #define TIM_CCMR1_CC1S_1          (0x2UL << TIM_CCMR1_CC1S_Pos)                /*!< 0x00000002 */
7386 
7387 #define TIM_CCMR1_OC1FE_Pos       (2U)
7388 #define TIM_CCMR1_OC1FE_Msk       (0x1UL << TIM_CCMR1_OC1FE_Pos)               /*!< 0x00000004 */
7389 #define TIM_CCMR1_OC1FE           TIM_CCMR1_OC1FE_Msk                          /*!<Output Compare 1 Fast enable */
7390 #define TIM_CCMR1_OC1PE_Pos       (3U)
7391 #define TIM_CCMR1_OC1PE_Msk       (0x1UL << TIM_CCMR1_OC1PE_Pos)               /*!< 0x00000008 */
7392 #define TIM_CCMR1_OC1PE           TIM_CCMR1_OC1PE_Msk                          /*!<Output Compare 1 Preload enable */
7393 
7394 #define TIM_CCMR1_OC1M_Pos        (4U)
7395 #define TIM_CCMR1_OC1M_Msk        (0x1007UL << TIM_CCMR1_OC1M_Pos)             /*!< 0x00010070 */
7396 #define TIM_CCMR1_OC1M            TIM_CCMR1_OC1M_Msk                           /*!<OC1M[2:0] bits (Output Compare 1 Mode) */
7397 #define TIM_CCMR1_OC1M_0          (0x0001UL << TIM_CCMR1_OC1M_Pos)             /*!< 0x00000010 */
7398 #define TIM_CCMR1_OC1M_1          (0x0002UL << TIM_CCMR1_OC1M_Pos)             /*!< 0x00000020 */
7399 #define TIM_CCMR1_OC1M_2          (0x0004UL << TIM_CCMR1_OC1M_Pos)             /*!< 0x00000040 */
7400 #define TIM_CCMR1_OC1M_3          (0x1000UL << TIM_CCMR1_OC1M_Pos)             /*!< 0x00010000 */
7401 
7402 #define TIM_CCMR1_OC1CE_Pos       (7U)
7403 #define TIM_CCMR1_OC1CE_Msk       (0x1UL << TIM_CCMR1_OC1CE_Pos)               /*!< 0x00000080 */
7404 #define TIM_CCMR1_OC1CE           TIM_CCMR1_OC1CE_Msk                          /*!<Output Compare 1 Clear Enable */
7405 
7406 #define TIM_CCMR1_CC2S_Pos        (8U)
7407 #define TIM_CCMR1_CC2S_Msk        (0x3UL << TIM_CCMR1_CC2S_Pos)                /*!< 0x00000300 */
7408 #define TIM_CCMR1_CC2S            TIM_CCMR1_CC2S_Msk                           /*!<CC2S[1:0] bits (Capture/Compare 2 Selection) */
7409 #define TIM_CCMR1_CC2S_0          (0x1UL << TIM_CCMR1_CC2S_Pos)                /*!< 0x00000100 */
7410 #define TIM_CCMR1_CC2S_1          (0x2UL << TIM_CCMR1_CC2S_Pos)                /*!< 0x00000200 */
7411 
7412 #define TIM_CCMR1_OC2FE_Pos       (10U)
7413 #define TIM_CCMR1_OC2FE_Msk       (0x1UL << TIM_CCMR1_OC2FE_Pos)               /*!< 0x00000400 */
7414 #define TIM_CCMR1_OC2FE           TIM_CCMR1_OC2FE_Msk                          /*!<Output Compare 2 Fast enable */
7415 #define TIM_CCMR1_OC2PE_Pos       (11U)
7416 #define TIM_CCMR1_OC2PE_Msk       (0x1UL << TIM_CCMR1_OC2PE_Pos)               /*!< 0x00000800 */
7417 #define TIM_CCMR1_OC2PE           TIM_CCMR1_OC2PE_Msk                          /*!<Output Compare 2 Preload enable */
7418 
7419 #define TIM_CCMR1_OC2M_Pos        (12U)
7420 #define TIM_CCMR1_OC2M_Msk        (0x1007UL << TIM_CCMR1_OC2M_Pos)             /*!< 0x01007000 */
7421 #define TIM_CCMR1_OC2M            TIM_CCMR1_OC2M_Msk                           /*!<OC2M[2:0] bits (Output Compare 2 Mode) */
7422 #define TIM_CCMR1_OC2M_0          (0x0001UL << TIM_CCMR1_OC2M_Pos)             /*!< 0x00001000 */
7423 #define TIM_CCMR1_OC2M_1          (0x0002UL << TIM_CCMR1_OC2M_Pos)             /*!< 0x00002000 */
7424 #define TIM_CCMR1_OC2M_2          (0x0004UL << TIM_CCMR1_OC2M_Pos)             /*!< 0x00004000 */
7425 #define TIM_CCMR1_OC2M_3          (0x1000UL << TIM_CCMR1_OC2M_Pos)             /*!< 0x01000000 */
7426 
7427 #define TIM_CCMR1_OC2CE_Pos       (15U)
7428 #define TIM_CCMR1_OC2CE_Msk       (0x1UL << TIM_CCMR1_OC2CE_Pos)               /*!< 0x00008000 */
7429 #define TIM_CCMR1_OC2CE           TIM_CCMR1_OC2CE_Msk                          /*!<Output Compare 2 Clear Enable */
7430 
7431 /*----------------------------------------------------------------------------*/
7432 #define TIM_CCMR1_IC1PSC_Pos      (2U)
7433 #define TIM_CCMR1_IC1PSC_Msk      (0x3UL << TIM_CCMR1_IC1PSC_Pos)              /*!< 0x0000000C */
7434 #define TIM_CCMR1_IC1PSC          TIM_CCMR1_IC1PSC_Msk                         /*!<IC1PSC[1:0] bits (Input Capture 1 Prescaler) */
7435 #define TIM_CCMR1_IC1PSC_0        (0x1UL << TIM_CCMR1_IC1PSC_Pos)              /*!< 0x00000004 */
7436 #define TIM_CCMR1_IC1PSC_1        (0x2UL << TIM_CCMR1_IC1PSC_Pos)              /*!< 0x00000008 */
7437 
7438 #define TIM_CCMR1_IC1F_Pos        (4U)
7439 #define TIM_CCMR1_IC1F_Msk        (0xFUL << TIM_CCMR1_IC1F_Pos)                /*!< 0x000000F0 */
7440 #define TIM_CCMR1_IC1F            TIM_CCMR1_IC1F_Msk                           /*!<IC1F[3:0] bits (Input Capture 1 Filter) */
7441 #define TIM_CCMR1_IC1F_0          (0x1UL << TIM_CCMR1_IC1F_Pos)                /*!< 0x00000010 */
7442 #define TIM_CCMR1_IC1F_1          (0x2UL << TIM_CCMR1_IC1F_Pos)                /*!< 0x00000020 */
7443 #define TIM_CCMR1_IC1F_2          (0x4UL << TIM_CCMR1_IC1F_Pos)                /*!< 0x00000040 */
7444 #define TIM_CCMR1_IC1F_3          (0x8UL << TIM_CCMR1_IC1F_Pos)                /*!< 0x00000080 */
7445 
7446 #define TIM_CCMR1_IC2PSC_Pos      (10U)
7447 #define TIM_CCMR1_IC2PSC_Msk      (0x3UL << TIM_CCMR1_IC2PSC_Pos)              /*!< 0x00000C00 */
7448 #define TIM_CCMR1_IC2PSC          TIM_CCMR1_IC2PSC_Msk                         /*!<IC2PSC[1:0] bits (Input Capture 2 Prescaler) */
7449 #define TIM_CCMR1_IC2PSC_0        (0x1UL << TIM_CCMR1_IC2PSC_Pos)              /*!< 0x00000400 */
7450 #define TIM_CCMR1_IC2PSC_1        (0x2UL << TIM_CCMR1_IC2PSC_Pos)              /*!< 0x00000800 */
7451 
7452 #define TIM_CCMR1_IC2F_Pos        (12U)
7453 #define TIM_CCMR1_IC2F_Msk        (0xFUL << TIM_CCMR1_IC2F_Pos)                /*!< 0x0000F000 */
7454 #define TIM_CCMR1_IC2F            TIM_CCMR1_IC2F_Msk                           /*!<IC2F[3:0] bits (Input Capture 2 Filter) */
7455 #define TIM_CCMR1_IC2F_0          (0x1UL << TIM_CCMR1_IC2F_Pos)                /*!< 0x00001000 */
7456 #define TIM_CCMR1_IC2F_1          (0x2UL << TIM_CCMR1_IC2F_Pos)                /*!< 0x00002000 */
7457 #define TIM_CCMR1_IC2F_2          (0x4UL << TIM_CCMR1_IC2F_Pos)                /*!< 0x00004000 */
7458 #define TIM_CCMR1_IC2F_3          (0x8UL << TIM_CCMR1_IC2F_Pos)                /*!< 0x00008000 */
7459 
7460 /******************  Bit definition for TIM_CCMR2 register  *******************/
7461 #define TIM_CCMR2_CC3S_Pos        (0U)
7462 #define TIM_CCMR2_CC3S_Msk        (0x3UL << TIM_CCMR2_CC3S_Pos)                /*!< 0x00000003 */
7463 #define TIM_CCMR2_CC3S            TIM_CCMR2_CC3S_Msk                           /*!<CC3S[1:0] bits (Capture/Compare 3 Selection) */
7464 #define TIM_CCMR2_CC3S_0          (0x1UL << TIM_CCMR2_CC3S_Pos)                /*!< 0x00000001 */
7465 #define TIM_CCMR2_CC3S_1          (0x2UL << TIM_CCMR2_CC3S_Pos)                /*!< 0x00000002 */
7466 
7467 #define TIM_CCMR2_OC3FE_Pos       (2U)
7468 #define TIM_CCMR2_OC3FE_Msk       (0x1UL << TIM_CCMR2_OC3FE_Pos)               /*!< 0x00000004 */
7469 #define TIM_CCMR2_OC3FE           TIM_CCMR2_OC3FE_Msk                          /*!<Output Compare 3 Fast enable */
7470 #define TIM_CCMR2_OC3PE_Pos       (3U)
7471 #define TIM_CCMR2_OC3PE_Msk       (0x1UL << TIM_CCMR2_OC3PE_Pos)               /*!< 0x00000008 */
7472 #define TIM_CCMR2_OC3PE           TIM_CCMR2_OC3PE_Msk                          /*!<Output Compare 3 Preload enable */
7473 
7474 #define TIM_CCMR2_OC3M_Pos        (4U)
7475 #define TIM_CCMR2_OC3M_Msk        (0x1007UL << TIM_CCMR2_OC3M_Pos)             /*!< 0x00010070 */
7476 #define TIM_CCMR2_OC3M            TIM_CCMR2_OC3M_Msk                           /*!<OC3M[2:0] bits (Output Compare 3 Mode) */
7477 #define TIM_CCMR2_OC3M_0          (0x0001UL << TIM_CCMR2_OC3M_Pos)             /*!< 0x00000010 */
7478 #define TIM_CCMR2_OC3M_1          (0x0002UL << TIM_CCMR2_OC3M_Pos)             /*!< 0x00000020 */
7479 #define TIM_CCMR2_OC3M_2          (0x0004UL << TIM_CCMR2_OC3M_Pos)             /*!< 0x00000040 */
7480 #define TIM_CCMR2_OC3M_3          (0x1000UL << TIM_CCMR2_OC3M_Pos)             /*!< 0x00010000 */
7481 
7482 #define TIM_CCMR2_OC3CE_Pos       (7U)
7483 #define TIM_CCMR2_OC3CE_Msk       (0x1UL << TIM_CCMR2_OC3CE_Pos)               /*!< 0x00000080 */
7484 #define TIM_CCMR2_OC3CE           TIM_CCMR2_OC3CE_Msk                          /*!<Output Compare 3 Clear Enable */
7485 
7486 #define TIM_CCMR2_CC4S_Pos        (8U)
7487 #define TIM_CCMR2_CC4S_Msk        (0x3UL << TIM_CCMR2_CC4S_Pos)                /*!< 0x00000300 */
7488 #define TIM_CCMR2_CC4S            TIM_CCMR2_CC4S_Msk                           /*!<CC4S[1:0] bits (Capture/Compare 4 Selection) */
7489 #define TIM_CCMR2_CC4S_0          (0x1UL << TIM_CCMR2_CC4S_Pos)                /*!< 0x00000100 */
7490 #define TIM_CCMR2_CC4S_1          (0x2UL << TIM_CCMR2_CC4S_Pos)                /*!< 0x00000200 */
7491 
7492 #define TIM_CCMR2_OC4FE_Pos       (10U)
7493 #define TIM_CCMR2_OC4FE_Msk       (0x1UL << TIM_CCMR2_OC4FE_Pos)               /*!< 0x00000400 */
7494 #define TIM_CCMR2_OC4FE           TIM_CCMR2_OC4FE_Msk                          /*!<Output Compare 4 Fast enable */
7495 #define TIM_CCMR2_OC4PE_Pos       (11U)
7496 #define TIM_CCMR2_OC4PE_Msk       (0x1UL << TIM_CCMR2_OC4PE_Pos)               /*!< 0x00000800 */
7497 #define TIM_CCMR2_OC4PE           TIM_CCMR2_OC4PE_Msk                          /*!<Output Compare 4 Preload enable */
7498 
7499 #define TIM_CCMR2_OC4M_Pos        (12U)
7500 #define TIM_CCMR2_OC4M_Msk        (0x1007UL << TIM_CCMR2_OC4M_Pos)             /*!< 0x01007000 */
7501 #define TIM_CCMR2_OC4M            TIM_CCMR2_OC4M_Msk                           /*!<OC4M[2:0] bits (Output Compare 4 Mode) */
7502 #define TIM_CCMR2_OC4M_0          (0x0001UL << TIM_CCMR2_OC4M_Pos)             /*!< 0x00001000 */
7503 #define TIM_CCMR2_OC4M_1          (0x0002UL << TIM_CCMR2_OC4M_Pos)             /*!< 0x00002000 */
7504 #define TIM_CCMR2_OC4M_2          (0x0004UL << TIM_CCMR2_OC4M_Pos)             /*!< 0x00004000 */
7505 #define TIM_CCMR2_OC4M_3          (0x1000UL << TIM_CCMR2_OC4M_Pos)             /*!< 0x01000000 */
7506 
7507 #define TIM_CCMR2_OC4CE_Pos       (15U)
7508 #define TIM_CCMR2_OC4CE_Msk       (0x1UL << TIM_CCMR2_OC4CE_Pos)               /*!< 0x00008000 */
7509 #define TIM_CCMR2_OC4CE           TIM_CCMR2_OC4CE_Msk                          /*!<Output Compare 4 Clear Enable */
7510 
7511 /*----------------------------------------------------------------------------*/
7512 #define TIM_CCMR2_IC3PSC_Pos      (2U)
7513 #define TIM_CCMR2_IC3PSC_Msk      (0x3UL << TIM_CCMR2_IC3PSC_Pos)              /*!< 0x0000000C */
7514 #define TIM_CCMR2_IC3PSC          TIM_CCMR2_IC3PSC_Msk                         /*!<IC3PSC[1:0] bits (Input Capture 3 Prescaler) */
7515 #define TIM_CCMR2_IC3PSC_0        (0x1UL << TIM_CCMR2_IC3PSC_Pos)              /*!< 0x00000004 */
7516 #define TIM_CCMR2_IC3PSC_1        (0x2UL << TIM_CCMR2_IC3PSC_Pos)              /*!< 0x00000008 */
7517 
7518 #define TIM_CCMR2_IC3F_Pos        (4U)
7519 #define TIM_CCMR2_IC3F_Msk        (0xFUL << TIM_CCMR2_IC3F_Pos)                /*!< 0x000000F0 */
7520 #define TIM_CCMR2_IC3F            TIM_CCMR2_IC3F_Msk                           /*!<IC3F[3:0] bits (Input Capture 3 Filter) */
7521 #define TIM_CCMR2_IC3F_0          (0x1UL << TIM_CCMR2_IC3F_Pos)                /*!< 0x00000010 */
7522 #define TIM_CCMR2_IC3F_1          (0x2UL << TIM_CCMR2_IC3F_Pos)                /*!< 0x00000020 */
7523 #define TIM_CCMR2_IC3F_2          (0x4UL << TIM_CCMR2_IC3F_Pos)                /*!< 0x00000040 */
7524 #define TIM_CCMR2_IC3F_3          (0x8UL << TIM_CCMR2_IC3F_Pos)                /*!< 0x00000080 */
7525 
7526 #define TIM_CCMR2_IC4PSC_Pos      (10U)
7527 #define TIM_CCMR2_IC4PSC_Msk      (0x3UL << TIM_CCMR2_IC4PSC_Pos)              /*!< 0x00000C00 */
7528 #define TIM_CCMR2_IC4PSC          TIM_CCMR2_IC4PSC_Msk                         /*!<IC4PSC[1:0] bits (Input Capture 4 Prescaler) */
7529 #define TIM_CCMR2_IC4PSC_0        (0x1UL << TIM_CCMR2_IC4PSC_Pos)              /*!< 0x00000400 */
7530 #define TIM_CCMR2_IC4PSC_1        (0x2UL << TIM_CCMR2_IC4PSC_Pos)              /*!< 0x00000800 */
7531 
7532 #define TIM_CCMR2_IC4F_Pos        (12U)
7533 #define TIM_CCMR2_IC4F_Msk        (0xFUL << TIM_CCMR2_IC4F_Pos)                /*!< 0x0000F000 */
7534 #define TIM_CCMR2_IC4F            TIM_CCMR2_IC4F_Msk                           /*!<IC4F[3:0] bits (Input Capture 4 Filter) */
7535 #define TIM_CCMR2_IC4F_0          (0x1UL << TIM_CCMR2_IC4F_Pos)                /*!< 0x00001000 */
7536 #define TIM_CCMR2_IC4F_1          (0x2UL << TIM_CCMR2_IC4F_Pos)                /*!< 0x00002000 */
7537 #define TIM_CCMR2_IC4F_2          (0x4UL << TIM_CCMR2_IC4F_Pos)                /*!< 0x00004000 */
7538 #define TIM_CCMR2_IC4F_3          (0x8UL << TIM_CCMR2_IC4F_Pos)                /*!< 0x00008000 */
7539 
7540 /******************  Bit definition for TIM_CCMR3 register  *******************/
7541 #define TIM_CCMR3_OC5FE_Pos       (2U)
7542 #define TIM_CCMR3_OC5FE_Msk       (0x1UL << TIM_CCMR3_OC5FE_Pos)               /*!< 0x00000004 */
7543 #define TIM_CCMR3_OC5FE           TIM_CCMR3_OC5FE_Msk                          /*!<Output Compare 5 Fast enable */
7544 #define TIM_CCMR3_OC5PE_Pos       (3U)
7545 #define TIM_CCMR3_OC5PE_Msk       (0x1UL << TIM_CCMR3_OC5PE_Pos)               /*!< 0x00000008 */
7546 #define TIM_CCMR3_OC5PE           TIM_CCMR3_OC5PE_Msk                          /*!<Output Compare 5 Preload enable */
7547 
7548 #define TIM_CCMR3_OC5M_Pos        (4U)
7549 #define TIM_CCMR3_OC5M_Msk        (0x1007UL << TIM_CCMR3_OC5M_Pos)             /*!< 0x00010070 */
7550 #define TIM_CCMR3_OC5M            TIM_CCMR3_OC5M_Msk                           /*!<OC5M[3:0] bits (Output Compare 5 Mode) */
7551 #define TIM_CCMR3_OC5M_0          (0x0001UL << TIM_CCMR3_OC5M_Pos)             /*!< 0x00000010 */
7552 #define TIM_CCMR3_OC5M_1          (0x0002UL << TIM_CCMR3_OC5M_Pos)             /*!< 0x00000020 */
7553 #define TIM_CCMR3_OC5M_2          (0x0004UL << TIM_CCMR3_OC5M_Pos)             /*!< 0x00000040 */
7554 #define TIM_CCMR3_OC5M_3          (0x1000UL << TIM_CCMR3_OC5M_Pos)             /*!< 0x00010000 */
7555 
7556 #define TIM_CCMR3_OC5CE_Pos       (7U)
7557 #define TIM_CCMR3_OC5CE_Msk       (0x1UL << TIM_CCMR3_OC5CE_Pos)               /*!< 0x00000080 */
7558 #define TIM_CCMR3_OC5CE           TIM_CCMR3_OC5CE_Msk                          /*!<Output Compare 5 Clear Enable */
7559 
7560 #define TIM_CCMR3_OC6FE_Pos       (10U)
7561 #define TIM_CCMR3_OC6FE_Msk       (0x1UL << TIM_CCMR3_OC6FE_Pos)               /*!< 0x00000400 */
7562 #define TIM_CCMR3_OC6FE           TIM_CCMR3_OC6FE_Msk                          /*!<Output Compare 6 Fast enable */
7563 #define TIM_CCMR3_OC6PE_Pos       (11U)
7564 #define TIM_CCMR3_OC6PE_Msk       (0x1UL << TIM_CCMR3_OC6PE_Pos)               /*!< 0x00000800 */
7565 #define TIM_CCMR3_OC6PE           TIM_CCMR3_OC6PE_Msk                          /*!<Output Compare 6 Preload enable */
7566 
7567 #define TIM_CCMR3_OC6M_Pos        (12U)
7568 #define TIM_CCMR3_OC6M_Msk        (0x1007UL << TIM_CCMR3_OC6M_Pos)             /*!< 0x01007000 */
7569 #define TIM_CCMR3_OC6M            TIM_CCMR3_OC6M_Msk                           /*!<OC6M[3:0] bits (Output Compare 6 Mode) */
7570 #define TIM_CCMR3_OC6M_0          (0x0001UL << TIM_CCMR3_OC6M_Pos)             /*!< 0x00001000 */
7571 #define TIM_CCMR3_OC6M_1          (0x0002UL << TIM_CCMR3_OC6M_Pos)             /*!< 0x00002000 */
7572 #define TIM_CCMR3_OC6M_2          (0x0004UL << TIM_CCMR3_OC6M_Pos)             /*!< 0x00004000 */
7573 #define TIM_CCMR3_OC6M_3          (0x1000UL << TIM_CCMR3_OC6M_Pos)             /*!< 0x01000000 */
7574 
7575 #define TIM_CCMR3_OC6CE_Pos       (15U)
7576 #define TIM_CCMR3_OC6CE_Msk       (0x1UL << TIM_CCMR3_OC6CE_Pos)               /*!< 0x00008000 */
7577 #define TIM_CCMR3_OC6CE           TIM_CCMR3_OC6CE_Msk                          /*!<Output Compare 6 Clear Enable */
7578 
7579 /*******************  Bit definition for TIM_CCER register  *******************/
7580 #define TIM_CCER_CC1E_Pos         (0U)
7581 #define TIM_CCER_CC1E_Msk         (0x1UL << TIM_CCER_CC1E_Pos)                 /*!< 0x00000001 */
7582 #define TIM_CCER_CC1E             TIM_CCER_CC1E_Msk                            /*!<Capture/Compare 1 output enable */
7583 #define TIM_CCER_CC1P_Pos         (1U)
7584 #define TIM_CCER_CC1P_Msk         (0x1UL << TIM_CCER_CC1P_Pos)                 /*!< 0x00000002 */
7585 #define TIM_CCER_CC1P             TIM_CCER_CC1P_Msk                            /*!<Capture/Compare 1 output Polarity */
7586 #define TIM_CCER_CC1NE_Pos        (2U)
7587 #define TIM_CCER_CC1NE_Msk        (0x1UL << TIM_CCER_CC1NE_Pos)                /*!< 0x00000004 */
7588 #define TIM_CCER_CC1NE            TIM_CCER_CC1NE_Msk                           /*!<Capture/Compare 1 Complementary output enable */
7589 #define TIM_CCER_CC1NP_Pos        (3U)
7590 #define TIM_CCER_CC1NP_Msk        (0x1UL << TIM_CCER_CC1NP_Pos)                /*!< 0x00000008 */
7591 #define TIM_CCER_CC1NP            TIM_CCER_CC1NP_Msk                           /*!<Capture/Compare 1 Complementary output Polarity */
7592 #define TIM_CCER_CC2E_Pos         (4U)
7593 #define TIM_CCER_CC2E_Msk         (0x1UL << TIM_CCER_CC2E_Pos)                 /*!< 0x00000010 */
7594 #define TIM_CCER_CC2E             TIM_CCER_CC2E_Msk                            /*!<Capture/Compare 2 output enable */
7595 #define TIM_CCER_CC2P_Pos         (5U)
7596 #define TIM_CCER_CC2P_Msk         (0x1UL << TIM_CCER_CC2P_Pos)                 /*!< 0x00000020 */
7597 #define TIM_CCER_CC2P             TIM_CCER_CC2P_Msk                            /*!<Capture/Compare 2 output Polarity */
7598 #define TIM_CCER_CC2NE_Pos        (6U)
7599 #define TIM_CCER_CC2NE_Msk        (0x1UL << TIM_CCER_CC2NE_Pos)                /*!< 0x00000040 */
7600 #define TIM_CCER_CC2NE            TIM_CCER_CC2NE_Msk                           /*!<Capture/Compare 2 Complementary output enable */
7601 #define TIM_CCER_CC2NP_Pos        (7U)
7602 #define TIM_CCER_CC2NP_Msk        (0x1UL << TIM_CCER_CC2NP_Pos)                /*!< 0x00000080 */
7603 #define TIM_CCER_CC2NP            TIM_CCER_CC2NP_Msk                           /*!<Capture/Compare 2 Complementary output Polarity */
7604 #define TIM_CCER_CC3E_Pos         (8U)
7605 #define TIM_CCER_CC3E_Msk         (0x1UL << TIM_CCER_CC3E_Pos)                 /*!< 0x00000100 */
7606 #define TIM_CCER_CC3E             TIM_CCER_CC3E_Msk                            /*!<Capture/Compare 3 output enable */
7607 #define TIM_CCER_CC3P_Pos         (9U)
7608 #define TIM_CCER_CC3P_Msk         (0x1UL << TIM_CCER_CC3P_Pos)                 /*!< 0x00000200 */
7609 #define TIM_CCER_CC3P             TIM_CCER_CC3P_Msk                            /*!<Capture/Compare 3 output Polarity */
7610 #define TIM_CCER_CC3NE_Pos        (10U)
7611 #define TIM_CCER_CC3NE_Msk        (0x1UL << TIM_CCER_CC3NE_Pos)                /*!< 0x00000400 */
7612 #define TIM_CCER_CC3NE            TIM_CCER_CC3NE_Msk                           /*!<Capture/Compare 3 Complementary output enable */
7613 #define TIM_CCER_CC3NP_Pos        (11U)
7614 #define TIM_CCER_CC3NP_Msk        (0x1UL << TIM_CCER_CC3NP_Pos)                /*!< 0x00000800 */
7615 #define TIM_CCER_CC3NP            TIM_CCER_CC3NP_Msk                           /*!<Capture/Compare 3 Complementary output Polarity */
7616 #define TIM_CCER_CC4E_Pos         (12U)
7617 #define TIM_CCER_CC4E_Msk         (0x1UL << TIM_CCER_CC4E_Pos)                 /*!< 0x00001000 */
7618 #define TIM_CCER_CC4E             TIM_CCER_CC4E_Msk                            /*!<Capture/Compare 4 output enable */
7619 #define TIM_CCER_CC4P_Pos         (13U)
7620 #define TIM_CCER_CC4P_Msk         (0x1UL << TIM_CCER_CC4P_Pos)                 /*!< 0x00002000 */
7621 #define TIM_CCER_CC4P             TIM_CCER_CC4P_Msk                            /*!<Capture/Compare 4 output Polarity */
7622 #define TIM_CCER_CC4NP_Pos        (15U)
7623 #define TIM_CCER_CC4NP_Msk        (0x1UL << TIM_CCER_CC4NP_Pos)                /*!< 0x00008000 */
7624 #define TIM_CCER_CC4NP            TIM_CCER_CC4NP_Msk                           /*!<Capture/Compare 4 Complementary output Polarity */
7625 #define TIM_CCER_CC5E_Pos         (16U)
7626 #define TIM_CCER_CC5E_Msk         (0x1UL << TIM_CCER_CC5E_Pos)                 /*!< 0x00010000 */
7627 #define TIM_CCER_CC5E             TIM_CCER_CC5E_Msk                            /*!<Capture/Compare 5 output enable */
7628 #define TIM_CCER_CC5P_Pos         (17U)
7629 #define TIM_CCER_CC5P_Msk         (0x1UL << TIM_CCER_CC5P_Pos)                 /*!< 0x00020000 */
7630 #define TIM_CCER_CC5P             TIM_CCER_CC5P_Msk                            /*!<Capture/Compare 5 output Polarity */
7631 #define TIM_CCER_CC6E_Pos         (20U)
7632 #define TIM_CCER_CC6E_Msk         (0x1UL << TIM_CCER_CC6E_Pos)                 /*!< 0x00100000 */
7633 #define TIM_CCER_CC6E             TIM_CCER_CC6E_Msk                            /*!<Capture/Compare 6 output enable */
7634 #define TIM_CCER_CC6P_Pos         (21U)
7635 #define TIM_CCER_CC6P_Msk         (0x1UL << TIM_CCER_CC6P_Pos)                 /*!< 0x00200000 */
7636 #define TIM_CCER_CC6P             TIM_CCER_CC6P_Msk                            /*!<Capture/Compare 6 output Polarity */
7637 
7638 /*******************  Bit definition for TIM_CNT register  ********************/
7639 #define TIM_CNT_CNT_Pos           (0U)
7640 #define TIM_CNT_CNT_Msk           (0xFFFFFFFFUL << TIM_CNT_CNT_Pos)            /*!< 0xFFFFFFFF */
7641 #define TIM_CNT_CNT               TIM_CNT_CNT_Msk                              /*!<Counter Value */
7642 #define TIM_CNT_UIFCPY_Pos        (31U)
7643 #define TIM_CNT_UIFCPY_Msk        (0x1UL << TIM_CNT_UIFCPY_Pos)                /*!< 0x80000000 */
7644 #define TIM_CNT_UIFCPY            TIM_CNT_UIFCPY_Msk                           /*!<Update interrupt flag copy (if UIFREMAP=1) */
7645 
7646 /*******************  Bit definition for TIM_PSC register  ********************/
7647 #define TIM_PSC_PSC_Pos           (0U)
7648 #define TIM_PSC_PSC_Msk           (0xFFFFUL << TIM_PSC_PSC_Pos)                /*!< 0x0000FFFF */
7649 #define TIM_PSC_PSC               TIM_PSC_PSC_Msk                              /*!<Prescaler Value */
7650 
7651 /*******************  Bit definition for TIM_ARR register  ********************/
7652 #define TIM_ARR_ARR_Pos           (0U)
7653 #define TIM_ARR_ARR_Msk           (0xFFFFFFFFUL << TIM_ARR_ARR_Pos)            /*!< 0xFFFFFFFF */
7654 #define TIM_ARR_ARR               TIM_ARR_ARR_Msk                              /*!<Actual auto-reload Value */
7655 
7656 /*******************  Bit definition for TIM_RCR register  ********************/
7657 #define TIM_RCR_REP_Pos           (0U)
7658 #define TIM_RCR_REP_Msk           (0xFFFFUL << TIM_RCR_REP_Pos)                /*!< 0x0000FFFF */
7659 #define TIM_RCR_REP               TIM_RCR_REP_Msk                              /*!<Repetition Counter Value */
7660 
7661 /*******************  Bit definition for TIM_CCR1 register  *******************/
7662 #define TIM_CCR1_CCR1_Pos         (0U)
7663 #define TIM_CCR1_CCR1_Msk         (0xFFFFUL << TIM_CCR1_CCR1_Pos)              /*!< 0x0000FFFF */
7664 #define TIM_CCR1_CCR1             TIM_CCR1_CCR1_Msk                            /*!<Capture/Compare 1 Value */
7665 
7666 /*******************  Bit definition for TIM_CCR2 register  *******************/
7667 #define TIM_CCR2_CCR2_Pos         (0U)
7668 #define TIM_CCR2_CCR2_Msk         (0xFFFFUL << TIM_CCR2_CCR2_Pos)              /*!< 0x0000FFFF */
7669 #define TIM_CCR2_CCR2             TIM_CCR2_CCR2_Msk                            /*!<Capture/Compare 2 Value */
7670 
7671 /*******************  Bit definition for TIM_CCR3 register  *******************/
7672 #define TIM_CCR3_CCR3_Pos         (0U)
7673 #define TIM_CCR3_CCR3_Msk         (0xFFFFUL << TIM_CCR3_CCR3_Pos)              /*!< 0x0000FFFF */
7674 #define TIM_CCR3_CCR3             TIM_CCR3_CCR3_Msk                            /*!<Capture/Compare 3 Value */
7675 
7676 /*******************  Bit definition for TIM_CCR4 register  *******************/
7677 #define TIM_CCR4_CCR4_Pos         (0U)
7678 #define TIM_CCR4_CCR4_Msk         (0xFFFFUL << TIM_CCR4_CCR4_Pos)              /*!< 0x0000FFFF */
7679 #define TIM_CCR4_CCR4             TIM_CCR4_CCR4_Msk                            /*!<Capture/Compare 4 Value */
7680 
7681 /*******************  Bit definition for TIM_CCR5 register  *******************/
7682 #define TIM_CCR5_CCR5_Pos         (0U)
7683 #define TIM_CCR5_CCR5_Msk         (0xFFFFFFFFUL << TIM_CCR5_CCR5_Pos)          /*!< 0xFFFFFFFF */
7684 #define TIM_CCR5_CCR5             TIM_CCR5_CCR5_Msk                            /*!<Capture/Compare 5 Value */
7685 #define TIM_CCR5_GC5C1_Pos        (29U)
7686 #define TIM_CCR5_GC5C1_Msk        (0x1UL << TIM_CCR5_GC5C1_Pos)                /*!< 0x20000000 */
7687 #define TIM_CCR5_GC5C1            TIM_CCR5_GC5C1_Msk                           /*!<Group Channel 5 and Channel 1 */
7688 #define TIM_CCR5_GC5C2_Pos        (30U)
7689 #define TIM_CCR5_GC5C2_Msk        (0x1UL << TIM_CCR5_GC5C2_Pos)                /*!< 0x40000000 */
7690 #define TIM_CCR5_GC5C2            TIM_CCR5_GC5C2_Msk                           /*!<Group Channel 5 and Channel 2 */
7691 #define TIM_CCR5_GC5C3_Pos        (31U)
7692 #define TIM_CCR5_GC5C3_Msk        (0x1UL << TIM_CCR5_GC5C3_Pos)                /*!< 0x80000000 */
7693 #define TIM_CCR5_GC5C3            TIM_CCR5_GC5C3_Msk                           /*!<Group Channel 5 and Channel 3 */
7694 
7695 /*******************  Bit definition for TIM_CCR6 register  *******************/
7696 #define TIM_CCR6_CCR6_Pos         (0U)
7697 #define TIM_CCR6_CCR6_Msk         (0xFFFFUL << TIM_CCR6_CCR6_Pos)              /*!< 0x0000FFFF */
7698 #define TIM_CCR6_CCR6             TIM_CCR6_CCR6_Msk                            /*!<Capture/Compare 6 Value */
7699 
7700 /*******************  Bit definition for TIM_BDTR register  *******************/
7701 #define TIM_BDTR_DTG_Pos          (0U)
7702 #define TIM_BDTR_DTG_Msk          (0xFFUL << TIM_BDTR_DTG_Pos)                 /*!< 0x000000FF */
7703 #define TIM_BDTR_DTG              TIM_BDTR_DTG_Msk                             /*!<DTG[0:7] bits (Dead-Time Generator set-up) */
7704 #define TIM_BDTR_DTG_0            (0x01UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000001 */
7705 #define TIM_BDTR_DTG_1            (0x02UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000002 */
7706 #define TIM_BDTR_DTG_2            (0x04UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000004 */
7707 #define TIM_BDTR_DTG_3            (0x08UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000008 */
7708 #define TIM_BDTR_DTG_4            (0x10UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000010 */
7709 #define TIM_BDTR_DTG_5            (0x20UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000020 */
7710 #define TIM_BDTR_DTG_6            (0x40UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000040 */
7711 #define TIM_BDTR_DTG_7            (0x80UL << TIM_BDTR_DTG_Pos)                 /*!< 0x00000080 */
7712 
7713 #define TIM_BDTR_LOCK_Pos         (8U)
7714 #define TIM_BDTR_LOCK_Msk         (0x3UL << TIM_BDTR_LOCK_Pos)                 /*!< 0x00000300 */
7715 #define TIM_BDTR_LOCK             TIM_BDTR_LOCK_Msk                            /*!<LOCK[1:0] bits (Lock Configuration) */
7716 #define TIM_BDTR_LOCK_0           (0x1UL << TIM_BDTR_LOCK_Pos)                 /*!< 0x00000100 */
7717 #define TIM_BDTR_LOCK_1           (0x2UL << TIM_BDTR_LOCK_Pos)                 /*!< 0x00000200 */
7718 
7719 #define TIM_BDTR_OSSI_Pos         (10U)
7720 #define TIM_BDTR_OSSI_Msk         (0x1UL << TIM_BDTR_OSSI_Pos)                 /*!< 0x00000400 */
7721 #define TIM_BDTR_OSSI             TIM_BDTR_OSSI_Msk                            /*!<Off-State Selection for Idle mode */
7722 #define TIM_BDTR_OSSR_Pos         (11U)
7723 #define TIM_BDTR_OSSR_Msk         (0x1UL << TIM_BDTR_OSSR_Pos)                 /*!< 0x00000800 */
7724 #define TIM_BDTR_OSSR             TIM_BDTR_OSSR_Msk                            /*!<Off-State Selection for Run mode */
7725 #define TIM_BDTR_BKE_Pos          (12U)
7726 #define TIM_BDTR_BKE_Msk          (0x1UL << TIM_BDTR_BKE_Pos)                  /*!< 0x00001000 */
7727 #define TIM_BDTR_BKE              TIM_BDTR_BKE_Msk                             /*!<Break enable for Break 1 */
7728 #define TIM_BDTR_BKP_Pos          (13U)
7729 #define TIM_BDTR_BKP_Msk          (0x1UL << TIM_BDTR_BKP_Pos)                  /*!< 0x00002000 */
7730 #define TIM_BDTR_BKP              TIM_BDTR_BKP_Msk                             /*!<Break Polarity for Break 1 */
7731 #define TIM_BDTR_AOE_Pos          (14U)
7732 #define TIM_BDTR_AOE_Msk          (0x1UL << TIM_BDTR_AOE_Pos)                  /*!< 0x00004000 */
7733 #define TIM_BDTR_AOE              TIM_BDTR_AOE_Msk                             /*!<Automatic Output enable */
7734 #define TIM_BDTR_MOE_Pos          (15U)
7735 #define TIM_BDTR_MOE_Msk          (0x1UL << TIM_BDTR_MOE_Pos)                  /*!< 0x00008000 */
7736 #define TIM_BDTR_MOE              TIM_BDTR_MOE_Msk                             /*!<Main Output enable */
7737 
7738 #define TIM_BDTR_BKF_Pos          (16U)
7739 #define TIM_BDTR_BKF_Msk          (0xFUL << TIM_BDTR_BKF_Pos)                  /*!< 0x000F0000 */
7740 #define TIM_BDTR_BKF              TIM_BDTR_BKF_Msk                             /*!<Break Filter for Break 1 */
7741 #define TIM_BDTR_BK2F_Pos         (20U)
7742 #define TIM_BDTR_BK2F_Msk         (0xFUL << TIM_BDTR_BK2F_Pos)                 /*!< 0x00F00000 */
7743 #define TIM_BDTR_BK2F             TIM_BDTR_BK2F_Msk                            /*!<Break Filter for Break 2 */
7744 
7745 #define TIM_BDTR_BK2E_Pos         (24U)
7746 #define TIM_BDTR_BK2E_Msk         (0x1UL << TIM_BDTR_BK2E_Pos)                 /*!< 0x01000000 */
7747 #define TIM_BDTR_BK2E             TIM_BDTR_BK2E_Msk                            /*!<Break enable for Break 2 */
7748 #define TIM_BDTR_BK2P_Pos         (25U)
7749 #define TIM_BDTR_BK2P_Msk         (0x1UL << TIM_BDTR_BK2P_Pos)                 /*!< 0x02000000 */
7750 #define TIM_BDTR_BK2P             TIM_BDTR_BK2P_Msk                            /*!<Break Polarity for Break 2 */
7751 
7752 #define TIM_BDTR_BKDSRM_Pos       (26U)
7753 #define TIM_BDTR_BKDSRM_Msk       (0x1UL << TIM_BDTR_BKDSRM_Pos)               /*!< 0x04000000 */
7754 #define TIM_BDTR_BKDSRM           TIM_BDTR_BKDSRM_Msk                          /*!<Break disarming/re-arming */
7755 #define TIM_BDTR_BK2DSRM_Pos      (27U)
7756 #define TIM_BDTR_BK2DSRM_Msk      (0x1UL << TIM_BDTR_BK2DSRM_Pos)              /*!< 0x08000000 */
7757 #define TIM_BDTR_BK2DSRM          TIM_BDTR_BK2DSRM_Msk                         /*!<Break2 disarming/re-arming */
7758 
7759 #define TIM_BDTR_BKBID_Pos        (28U)
7760 #define TIM_BDTR_BKBID_Msk        (0x1UL << TIM_BDTR_BKBID_Pos)                /*!< 0x10000000 */
7761 #define TIM_BDTR_BKBID            TIM_BDTR_BKBID_Msk                           /*!<Break BIDirectional */
7762 #define TIM_BDTR_BK2BID_Pos       (29U)
7763 #define TIM_BDTR_BK2BID_Msk       (0x1UL << TIM_BDTR_BK2BID_Pos)               /*!< 0x20000000 */
7764 #define TIM_BDTR_BK2BID           TIM_BDTR_BK2BID_Msk                          /*!<Break2 BIDirectional */
7765 
7766 /*******************  Bit definition for TIM_DCR register  ********************/
7767 #define TIM_DCR_DBA_Pos           (0U)
7768 #define TIM_DCR_DBA_Msk           (0x1FUL << TIM_DCR_DBA_Pos)                  /*!< 0x0000001F */
7769 #define TIM_DCR_DBA               TIM_DCR_DBA_Msk                              /*!<DBA[4:0] bits (DMA Base Address) */
7770 #define TIM_DCR_DBA_0             (0x01UL << TIM_DCR_DBA_Pos)                  /*!< 0x00000001 */
7771 #define TIM_DCR_DBA_1             (0x02UL << TIM_DCR_DBA_Pos)                  /*!< 0x00000002 */
7772 #define TIM_DCR_DBA_2             (0x04UL << TIM_DCR_DBA_Pos)                  /*!< 0x00000004 */
7773 #define TIM_DCR_DBA_3             (0x08UL << TIM_DCR_DBA_Pos)                  /*!< 0x00000008 */
7774 #define TIM_DCR_DBA_4             (0x10UL << TIM_DCR_DBA_Pos)                  /*!< 0x00000010 */
7775 
7776 #define TIM_DCR_DBL_Pos           (8U)
7777 #define TIM_DCR_DBL_Msk           (0x1FUL << TIM_DCR_DBL_Pos)                  /*!< 0x00001F00 */
7778 #define TIM_DCR_DBL               TIM_DCR_DBL_Msk                              /*!<DBL[4:0] bits (DMA Burst Length) */
7779 #define TIM_DCR_DBL_0             (0x01UL << TIM_DCR_DBL_Pos)                  /*!< 0x00000100 */
7780 #define TIM_DCR_DBL_1             (0x02UL << TIM_DCR_DBL_Pos)                  /*!< 0x00000200 */
7781 #define TIM_DCR_DBL_2             (0x04UL << TIM_DCR_DBL_Pos)                  /*!< 0x00000400 */
7782 #define TIM_DCR_DBL_3             (0x08UL << TIM_DCR_DBL_Pos)                  /*!< 0x00000800 */
7783 #define TIM_DCR_DBL_4             (0x10UL << TIM_DCR_DBL_Pos)                  /*!< 0x00001000 */
7784 
7785 /*******************  Bit definition for TIM_DMAR register  *******************/
7786 #define TIM_DMAR_DMAB_Pos         (0U)
7787 #define TIM_DMAR_DMAB_Msk         (0xFFFFUL << TIM_DMAR_DMAB_Pos)              /*!< 0x0000FFFF */
7788 #define TIM_DMAR_DMAB             TIM_DMAR_DMAB_Msk                            /*!<DMA register for burst accesses */
7789 
7790 /*******************  Bit definition for TIM1_OR1 register  *******************/
7791 #define TIM1_OR1_OCREF_CLR_Pos     (0U)
7792 #define TIM1_OR1_OCREF_CLR_Msk     (0x1UL << TIM1_OR1_OCREF_CLR_Pos)           /*!< 0x00000001 */
7793 #define TIM1_OR1_OCREF_CLR         TIM1_OR1_OCREF_CLR_Msk                      /*!<OCREF clear input selection */
7794 
7795 /*******************  Bit definition for TIM1_AF1 register  *******************/
7796 #define TIM1_AF1_BKINE_Pos        (0U)
7797 #define TIM1_AF1_BKINE_Msk        (0x1UL << TIM1_AF1_BKINE_Pos)                /*!< 0x00000001 */
7798 #define TIM1_AF1_BKINE            TIM1_AF1_BKINE_Msk                           /*!<BRK BKIN input enable */
7799 #define TIM1_AF1_BKCMP1E_Pos      (1U)
7800 #define TIM1_AF1_BKCMP1E_Msk      (0x1UL << TIM1_AF1_BKCMP1E_Pos)              /*!< 0x00000002 */
7801 #define TIM1_AF1_BKCMP1E          TIM1_AF1_BKCMP1E_Msk                         /*!<BRK COMP1 enable */
7802 #define TIM1_AF1_BKCMP2E_Pos      (2U)
7803 #define TIM1_AF1_BKCMP2E_Msk      (0x1UL << TIM1_AF1_BKCMP2E_Pos)              /*!< 0x00000004 */
7804 #define TIM1_AF1_BKCMP2E          TIM1_AF1_BKCMP2E_Msk                         /*!<BRK COMP2 enable */
7805 #define TIM1_AF1_BKINP_Pos        (9U)
7806 #define TIM1_AF1_BKINP_Msk        (0x1UL << TIM1_AF1_BKINP_Pos)                /*!< 0x00000200 */
7807 #define TIM1_AF1_BKINP            TIM1_AF1_BKINP_Msk                           /*!<BRK BKIN input polarity */
7808 #define TIM1_AF1_BKCMP1P_Pos      (10U)
7809 #define TIM1_AF1_BKCMP1P_Msk      (0x1UL << TIM1_AF1_BKCMP1P_Pos)              /*!< 0x00000400 */
7810 #define TIM1_AF1_BKCMP1P          TIM1_AF1_BKCMP1P_Msk                         /*!<BRK COMP1 input polarity */
7811 #define TIM1_AF1_BKCMP2P_Pos      (11U)
7812 #define TIM1_AF1_BKCMP2P_Msk      (0x1UL << TIM1_AF1_BKCMP2P_Pos)              /*!< 0x00000800 */
7813 #define TIM1_AF1_BKCMP2P          TIM1_AF1_BKCMP2P_Msk                         /*!<BRK COMP2 input polarity */
7814 
7815 #define TIM1_AF1_ETRSEL_Pos       (14U)
7816 #define TIM1_AF1_ETRSEL_Msk       (0xFUL << TIM1_AF1_ETRSEL_Pos)               /*!< 0x0003C000 */
7817 #define TIM1_AF1_ETRSEL           TIM1_AF1_ETRSEL_Msk                          /*!<ETRSEL[3:0] bits (TIM1 ETR source selection) */
7818 #define TIM1_AF1_ETRSEL_0         (0x1UL << TIM1_AF1_ETRSEL_Pos)               /*!< 0x00004000 */
7819 #define TIM1_AF1_ETRSEL_1         (0x2UL << TIM1_AF1_ETRSEL_Pos)               /*!< 0x00008000 */
7820 #define TIM1_AF1_ETRSEL_2         (0x4UL << TIM1_AF1_ETRSEL_Pos)               /*!< 0x00010000 */
7821 #define TIM1_AF1_ETRSEL_3         (0x8UL << TIM1_AF1_ETRSEL_Pos)               /*!< 0x00020000 */
7822 
7823 /*******************  Bit definition for TIM1_AF2 register  *******************/
7824 #define TIM1_AF2_BK2INE_Pos       (0U)
7825 #define TIM1_AF2_BK2INE_Msk       (0x1UL << TIM1_AF2_BK2INE_Pos)               /*!< 0x00000001 */
7826 #define TIM1_AF2_BK2INE           TIM1_AF2_BK2INE_Msk                          /*!<BRK2 BKIN2 input enable */
7827 #define TIM1_AF2_BK2CMP1E_Pos     (1U)
7828 #define TIM1_AF2_BK2CMP1E_Msk     (0x1UL << TIM1_AF2_BK2CMP1E_Pos)             /*!< 0x00000002 */
7829 #define TIM1_AF2_BK2CMP1E         TIM1_AF2_BK2CMP1E_Msk                        /*!<BRK2 COMP1 enable */
7830 #define TIM1_AF2_BK2CMP2E_Pos     (2U)
7831 #define TIM1_AF2_BK2CMP2E_Msk     (0x1UL << TIM1_AF2_BK2CMP2E_Pos)             /*!< 0x00000004 */
7832 #define TIM1_AF2_BK2CMP2E         TIM1_AF2_BK2CMP2E_Msk                        /*!<BRK2 COMP2 enable */
7833 #define TIM1_AF2_BK2INP_Pos       (9U)
7834 #define TIM1_AF2_BK2INP_Msk       (0x1UL << TIM1_AF2_BK2INP_Pos)               /*!< 0x00000200 */
7835 #define TIM1_AF2_BK2INP           TIM1_AF2_BK2INP_Msk                          /*!<BRK2 BKIN2 input polarity */
7836 #define TIM1_AF2_BK2CMP1P_Pos     (10U)
7837 #define TIM1_AF2_BK2CMP1P_Msk     (0x1UL << TIM1_AF2_BK2CMP1P_Pos)             /*!< 0x00000400 */
7838 #define TIM1_AF2_BK2CMP1P         TIM1_AF2_BK2CMP1P_Msk                        /*!<BRK2 COMP1 input polarity */
7839 #define TIM1_AF2_BK2CMP2P_Pos     (11U)
7840 #define TIM1_AF2_BK2CMP2P_Msk     (0x1UL << TIM1_AF2_BK2CMP2P_Pos)             /*!< 0x00000800 */
7841 #define TIM1_AF2_BK2CMP2P         TIM1_AF2_BK2CMP2P_Msk                        /*!<BRK2 COMP2 input polarity */
7842 
7843 
7844 /*******************  Bit definition for TIM3_OR1 register  *******************/
7845 #define TIM3_OR1_OCREF_CLR_Pos     (0U)
7846 #define TIM3_OR1_OCREF_CLR_Msk     (0x1UL << TIM3_OR1_OCREF_CLR_Pos)           /*!< 0x00000001 */
7847 #define TIM3_OR1_OCREF_CLR         TIM3_OR1_OCREF_CLR_Msk                      /*!<OCREF clear input selection */
7848 
7849 /*******************  Bit definition for TIM3_AF1 register  *******************/
7850 #define TIM3_AF1_ETRSEL_Pos       (14U)
7851 #define TIM3_AF1_ETRSEL_Msk       (0xFUL << TIM3_AF1_ETRSEL_Pos)               /*!< 0x0003C000 */
7852 #define TIM3_AF1_ETRSEL           TIM3_AF1_ETRSEL_Msk                          /*!<ETRSEL[3:0] bits (TIM3 ETR source selection) */
7853 #define TIM3_AF1_ETRSEL_0         (0x1UL << TIM3_AF1_ETRSEL_Pos)               /*!< 0x00004000 */
7854 #define TIM3_AF1_ETRSEL_1         (0x2UL << TIM3_AF1_ETRSEL_Pos)               /*!< 0x00008000 */
7855 #define TIM3_AF1_ETRSEL_2         (0x4UL << TIM3_AF1_ETRSEL_Pos)               /*!< 0x00010000 */
7856 #define TIM3_AF1_ETRSEL_3         (0x8UL << TIM3_AF1_ETRSEL_Pos)               /*!< 0x00020000 */
7857 
7858 /*******************  Bit definition for TIM4_OR1 register  *******************/
7859 #define TIM4_OR1_OCREF_CLR_Pos     (0U)
7860 #define TIM4_OR1_OCREF_CLR_Msk     (0x3UL << TIM4_OR1_OCREF_CLR_Pos)           /*!< 0x00000003 */
7861 #define TIM4_OR1_OCREF_CLR         TIM4_OR1_OCREF_CLR_Msk                      /*!< OCREF_CLR[1:0] input selection */
7862 #define TIM4_OR1_OCREF_CLR_0       (0x1UL << TIM4_OR1_OCREF_CLR_Pos)           /*!< 0x00000001 */
7863 #define TIM4_OR1_OCREF_CLR_1       (0x2UL << TIM4_OR1_OCREF_CLR_Pos)           /*!< 0x00000002 */
7864 
7865 /*******************  Bit definition for TIM4_AF1 register  *******************/
7866 #define TIM4_AF1_ETRSEL_Pos       (14U)
7867 #define TIM4_AF1_ETRSEL_Msk       (0xFUL << TIM4_AF1_ETRSEL_Pos)               /*!< 0x0003C000 */
7868 #define TIM4_AF1_ETRSEL           TIM4_AF1_ETRSEL_Msk                          /*!<ETRSEL[3:0] bits (TIM4 ETR source selection) */
7869 #define TIM4_AF1_ETRSEL_0         (0x1UL << TIM4_AF1_ETRSEL_Pos)               /*!< 0x00004000 */
7870 #define TIM4_AF1_ETRSEL_1         (0x2UL << TIM4_AF1_ETRSEL_Pos)               /*!< 0x00008000 */
7871 #define TIM4_AF1_ETRSEL_2         (0x4UL << TIM4_AF1_ETRSEL_Pos)               /*!< 0x00010000 */
7872 #define TIM4_AF1_ETRSEL_3         (0x8UL << TIM4_AF1_ETRSEL_Pos)               /*!< 0x00020000 */
7873 
7874 /*******************  Bit definition for TIM14_AF1 register  *******************/
7875 #define TIM14_AF1_ETRSEL_Pos      (14U)
7876 #define TIM14_AF1_ETRSEL_Msk      (0xFUL << TIM14_AF1_ETRSEL_Pos)              /*!< 0x0003C000 */
7877 #define TIM14_AF1_ETRSEL          TIM14_AF1_ETRSEL_Msk                         /*!<ETRSEL[3:0] bits (TIM14 ETR source selection) */
7878 #define TIM14_AF1_ETRSEL_0        (0x1UL << TIM14_AF1_ETRSEL_Pos)              /*!< 0x00004000 */
7879 #define TIM14_AF1_ETRSEL_1        (0x2UL << TIM14_AF1_ETRSEL_Pos)              /*!< 0x00008000 */
7880 #define TIM14_AF1_ETRSEL_2        (0x4UL << TIM14_AF1_ETRSEL_Pos)              /*!< 0x00010000 */
7881 #define TIM14_AF1_ETRSEL_3        (0x8UL << TIM14_AF1_ETRSEL_Pos)              /*!< 0x00020000 */
7882 
7883 /*******************  Bit definition for TIM15_AF1 register  ******************/
7884 #define TIM15_AF1_BKINE_Pos      (0U)
7885 #define TIM15_AF1_BKINE_Msk      (0x1UL << TIM15_AF1_BKINE_Pos)                /*!< 0x00000001 */
7886 #define TIM15_AF1_BKINE          TIM15_AF1_BKINE_Msk                           /*!<BRK BKIN input enable */
7887 #define TIM15_AF1_BKCMP1E_Pos    (1U)
7888 #define TIM15_AF1_BKCMP1E_Msk    (0x1UL << TIM15_AF1_BKCMP1E_Pos)              /*!< 0x00000002 */
7889 #define TIM15_AF1_BKCMP1E        TIM15_AF1_BKCMP1E_Msk                         /*!<BRK COMP1 enable */
7890 #define TIM15_AF1_BKCMP2E_Pos    (2U)
7891 #define TIM15_AF1_BKCMP2E_Msk    (0x1UL << TIM15_AF1_BKCMP2E_Pos)              /*!< 0x00000004 */
7892 #define TIM15_AF1_BKCMP2E        TIM15_AF1_BKCMP2E_Msk                         /*!<BRK COMP2 enable */
7893 #define TIM15_AF1_BKINP_Pos      (9U)
7894 #define TIM15_AF1_BKINP_Msk      (0x1UL << TIM15_AF1_BKINP_Pos)                /*!< 0x00000200 */
7895 #define TIM15_AF1_BKINP          TIM15_AF1_BKINP_Msk                           /*!<BRK BKIN input polarity */
7896 #define TIM15_AF1_BKCMP1P_Pos    (10U)
7897 #define TIM15_AF1_BKCMP1P_Msk    (0x1UL << TIM15_AF1_BKCMP1P_Pos)              /*!< 0x00000400 */
7898 #define TIM15_AF1_BKCMP1P        TIM15_AF1_BKCMP1P_Msk                         /*!<BRK COMP1 input polarity */
7899 #define TIM15_AF1_BKCMP2P_Pos    (11U)
7900 #define TIM15_AF1_BKCMP2P_Msk    (0x1UL << TIM15_AF1_BKCMP2P_Pos)              /*!< 0x00000800 */
7901 #define TIM15_AF1_BKCMP2P        TIM15_AF1_BKCMP2P_Msk                         /*!<BRK COMP2 input polarity */
7902 
7903 /*******************  Bit definition for TIM16_AF1 register  ******************/
7904 #define TIM16_AF1_BKINE_Pos      (0U)
7905 #define TIM16_AF1_BKINE_Msk      (0x1UL << TIM16_AF1_BKINE_Pos)                /*!< 0x00000001 */
7906 #define TIM16_AF1_BKINE          TIM16_AF1_BKINE_Msk                           /*!<BRK BKIN input enable */
7907 #define TIM16_AF1_BKCMP1E_Pos    (1U)
7908 #define TIM16_AF1_BKCMP1E_Msk    (0x1UL << TIM16_AF1_BKCMP1E_Pos)              /*!< 0x00000002 */
7909 #define TIM16_AF1_BKCMP1E        TIM16_AF1_BKCMP1E_Msk                         /*!<BRK COMP1 enable */
7910 #define TIM16_AF1_BKCMP2E_Pos    (2U)
7911 #define TIM16_AF1_BKCMP2E_Msk    (0x1UL << TIM16_AF1_BKCMP2E_Pos)              /*!< 0x00000004 */
7912 #define TIM16_AF1_BKCMP2E        TIM16_AF1_BKCMP2E_Msk                         /*!<BRK COMP2 enable */
7913 #define TIM16_AF1_BKINP_Pos      (9U)
7914 #define TIM16_AF1_BKINP_Msk      (0x1UL << TIM16_AF1_BKINP_Pos)                /*!< 0x00000200 */
7915 #define TIM16_AF1_BKINP          TIM16_AF1_BKINP_Msk                           /*!<BRK BKIN input polarity */
7916 #define TIM16_AF1_BKCMP1P_Pos    (10U)
7917 #define TIM16_AF1_BKCMP1P_Msk    (0x1UL << TIM16_AF1_BKCMP1P_Pos)              /*!< 0x00000400 */
7918 #define TIM16_AF1_BKCMP1P        TIM16_AF1_BKCMP1P_Msk                         /*!<BRK COMP1 input polarity */
7919 #define TIM16_AF1_BKCMP2P_Pos    (11U)
7920 #define TIM16_AF1_BKCMP2P_Msk    (0x1UL << TIM16_AF1_BKCMP2P_Pos)              /*!< 0x00000800 */
7921 #define TIM16_AF1_BKCMP2P        TIM16_AF1_BKCMP2P_Msk                         /*!<BRK COMP2 input polarity */
7922 
7923 /*******************  Bit definition for TIM17_AF1 register  ******************/
7924 #define TIM17_AF1_BKINE_Pos      (0U)
7925 #define TIM17_AF1_BKINE_Msk      (0x1UL << TIM17_AF1_BKINE_Pos)                /*!< 0x00000001 */
7926 #define TIM17_AF1_BKINE          TIM17_AF1_BKINE_Msk                           /*!<BRK BKIN input enable */
7927 #define TIM17_AF1_BKCMP1E_Pos    (1U)
7928 #define TIM17_AF1_BKCMP1E_Msk    (0x1UL << TIM17_AF1_BKCMP1E_Pos)              /*!< 0x00000002 */
7929 #define TIM17_AF1_BKCMP1E        TIM17_AF1_BKCMP1E_Msk                         /*!<BRK COMP1 enable */
7930 #define TIM17_AF1_BKCMP2E_Pos    (2U)
7931 #define TIM17_AF1_BKCMP2E_Msk    (0x1UL << TIM17_AF1_BKCMP2E_Pos)              /*!< 0x00000004 */
7932 #define TIM17_AF1_BKCMP2E        TIM17_AF1_BKCMP2E_Msk                         /*!<BRK COMP2 enable */
7933 #define TIM17_AF1_BKINP_Pos      (9U)
7934 #define TIM17_AF1_BKINP_Msk      (0x1UL << TIM17_AF1_BKINP_Pos)                /*!< 0x00000200 */
7935 #define TIM17_AF1_BKINP          TIM17_AF1_BKINP_Msk                           /*!<BRK BKIN input polarity */
7936 #define TIM17_AF1_BKCMP1P_Pos    (10U)
7937 #define TIM17_AF1_BKCMP1P_Msk    (0x1UL << TIM17_AF1_BKCMP1P_Pos)              /*!< 0x00000400 */
7938 #define TIM17_AF1_BKCMP1P        TIM17_AF1_BKCMP1P_Msk                         /*!<BRK COMP1 input polarity */
7939 #define TIM17_AF1_BKCMP2P_Pos    (11U)
7940 #define TIM17_AF1_BKCMP2P_Msk    (0x1UL << TIM17_AF1_BKCMP2P_Pos)              /*!< 0x00000800 */
7941 #define TIM17_AF1_BKCMP2P        TIM17_AF1_BKCMP2P_Msk                         /*!<BRK COMP2 input polarity */
7942 
7943 /*******************  Bit definition for TIM_TISEL register  *********************/
7944 #define TIM_TISEL_TI1SEL_Pos      (0U)
7945 #define TIM_TISEL_TI1SEL_Msk      (0xFUL << TIM_TISEL_TI1SEL_Pos)              /*!< 0x0000000F */
7946 #define TIM_TISEL_TI1SEL          TIM_TISEL_TI1SEL_Msk                         /*!<TI1SEL[3:0] bits (TIM TI1 SEL)*/
7947 #define TIM_TISEL_TI1SEL_0        (0x1UL << TIM_TISEL_TI1SEL_Pos)              /*!< 0x00000001 */
7948 #define TIM_TISEL_TI1SEL_1        (0x2UL << TIM_TISEL_TI1SEL_Pos)              /*!< 0x00000002 */
7949 #define TIM_TISEL_TI1SEL_2        (0x4UL << TIM_TISEL_TI1SEL_Pos)              /*!< 0x00000004 */
7950 #define TIM_TISEL_TI1SEL_3        (0x8UL << TIM_TISEL_TI1SEL_Pos)              /*!< 0x00000008 */
7951 
7952 #define TIM_TISEL_TI2SEL_Pos      (8U)
7953 #define TIM_TISEL_TI2SEL_Msk      (0xFUL << TIM_TISEL_TI2SEL_Pos)              /*!< 0x00000F00 */
7954 #define TIM_TISEL_TI2SEL          TIM_TISEL_TI2SEL_Msk                         /*!<TI2SEL[3:0] bits (TIM TI2 SEL)*/
7955 #define TIM_TISEL_TI2SEL_0        (0x1UL << TIM_TISEL_TI2SEL_Pos)              /*!< 0x00000100 */
7956 #define TIM_TISEL_TI2SEL_1        (0x2UL << TIM_TISEL_TI2SEL_Pos)              /*!< 0x00000200 */
7957 #define TIM_TISEL_TI2SEL_2        (0x4UL << TIM_TISEL_TI2SEL_Pos)              /*!< 0x00000400 */
7958 #define TIM_TISEL_TI2SEL_3        (0x8UL << TIM_TISEL_TI2SEL_Pos)              /*!< 0x00000800 */
7959 
7960 #define TIM_TISEL_TI3SEL_Pos      (16U)
7961 #define TIM_TISEL_TI3SEL_Msk      (0xFUL << TIM_TISEL_TI3SEL_Pos)              /*!< 0x000F0000 */
7962 #define TIM_TISEL_TI3SEL          TIM_TISEL_TI3SEL_Msk                         /*!<TI3SEL[3:0] bits (TIM TI3 SEL)*/
7963 #define TIM_TISEL_TI3SEL_0        (0x1UL << TIM_TISEL_TI3SEL_Pos)              /*!< 0x00010000 */
7964 #define TIM_TISEL_TI3SEL_1        (0x2UL << TIM_TISEL_TI3SEL_Pos)              /*!< 0x00020000 */
7965 #define TIM_TISEL_TI3SEL_2        (0x4UL << TIM_TISEL_TI3SEL_Pos)              /*!< 0x00040000 */
7966 #define TIM_TISEL_TI3SEL_3        (0x8UL << TIM_TISEL_TI3SEL_Pos)              /*!< 0x00080000 */
7967 
7968 #define TIM_TISEL_TI4SEL_Pos      (24U)
7969 #define TIM_TISEL_TI4SEL_Msk      (0xFUL << TIM_TISEL_TI4SEL_Pos)              /*!< 0x0F000000 */
7970 #define TIM_TISEL_TI4SEL          TIM_TISEL_TI4SEL_Msk                         /*!<TI4SEL[3:0] bits (TIM TI4 SEL)*/
7971 #define TIM_TISEL_TI4SEL_0        (0x1UL << TIM_TISEL_TI4SEL_Pos)              /*!< 0x01000000 */
7972 #define TIM_TISEL_TI4SEL_1        (0x2UL << TIM_TISEL_TI4SEL_Pos)              /*!< 0x02000000 */
7973 #define TIM_TISEL_TI4SEL_2        (0x4UL << TIM_TISEL_TI4SEL_Pos)              /*!< 0x04000000 */
7974 #define TIM_TISEL_TI4SEL_3        (0x8UL << TIM_TISEL_TI4SEL_Pos)              /*!< 0x08000000 */
7975 
7976 
7977 
7978 /******************************************************************************/
7979 /*                                                                            */
7980 /*      Universal Synchronous Asynchronous Receiver Transmitter (USART)       */
7981 /*                                                                            */
7982 /******************************************************************************/
7983 /******************  Bit definition for USART_CR1 register  *******************/
7984 #define USART_CR1_UE_Pos             (0U)
7985 #define USART_CR1_UE_Msk             (0x1UL << USART_CR1_UE_Pos)               /*!< 0x00000001 */
7986 #define USART_CR1_UE                 USART_CR1_UE_Msk                          /*!< USART Enable */
7987 #define USART_CR1_UESM_Pos           (1U)
7988 #define USART_CR1_UESM_Msk           (0x1UL << USART_CR1_UESM_Pos)             /*!< 0x00000002 */
7989 #define USART_CR1_UESM               USART_CR1_UESM_Msk                        /*!< USART Enable in STOP Mode */
7990 #define USART_CR1_RE_Pos             (2U)
7991 #define USART_CR1_RE_Msk             (0x1UL << USART_CR1_RE_Pos)               /*!< 0x00000004 */
7992 #define USART_CR1_RE                 USART_CR1_RE_Msk                          /*!< Receiver Enable */
7993 #define USART_CR1_TE_Pos             (3U)
7994 #define USART_CR1_TE_Msk             (0x1UL << USART_CR1_TE_Pos)               /*!< 0x00000008 */
7995 #define USART_CR1_TE                 USART_CR1_TE_Msk                          /*!< Transmitter Enable */
7996 #define USART_CR1_IDLEIE_Pos         (4U)
7997 #define USART_CR1_IDLEIE_Msk         (0x1UL << USART_CR1_IDLEIE_Pos)           /*!< 0x00000010 */
7998 #define USART_CR1_IDLEIE             USART_CR1_IDLEIE_Msk                      /*!< IDLE Interrupt Enable */
7999 #define USART_CR1_RXNEIE_RXFNEIE_Pos   (5U)
8000 #define USART_CR1_RXNEIE_RXFNEIE_Msk   (0x1UL << USART_CR1_RXNEIE_RXFNEIE_Pos) /*!< 0x00000020 */
8001 #define USART_CR1_RXNEIE_RXFNEIE       USART_CR1_RXNEIE_RXFNEIE_Msk            /*!< RXNE/RXFIFO not empty Interrupt Enable */
8002 #define USART_CR1_TCIE_Pos           (6U)
8003 #define USART_CR1_TCIE_Msk           (0x1UL << USART_CR1_TCIE_Pos)             /*!< 0x00000040 */
8004 #define USART_CR1_TCIE               USART_CR1_TCIE_Msk                        /*!< Transmission Complete Interrupt Enable */
8005 #define USART_CR1_TXEIE_TXFNFIE_Pos  (7U)
8006 #define USART_CR1_TXEIE_TXFNFIE_Msk   (0x1UL << USART_CR1_TXEIE_TXFNFIE_Pos)   /*!< 0x00000080 */
8007 #define USART_CR1_TXEIE_TXFNFIE       USART_CR1_TXEIE_TXFNFIE_Msk              /*!< TXE/TXFIFO not full Interrupt Enable */
8008 #define USART_CR1_PEIE_Pos           (8U)
8009 #define USART_CR1_PEIE_Msk           (0x1UL << USART_CR1_PEIE_Pos)             /*!< 0x00000100 */
8010 #define USART_CR1_PEIE               USART_CR1_PEIE_Msk                        /*!< PE Interrupt Enable */
8011 #define USART_CR1_PS_Pos             (9U)
8012 #define USART_CR1_PS_Msk             (0x1UL << USART_CR1_PS_Pos)               /*!< 0x00000200 */
8013 #define USART_CR1_PS                 USART_CR1_PS_Msk                          /*!< Parity Selection */
8014 #define USART_CR1_PCE_Pos            (10U)
8015 #define USART_CR1_PCE_Msk            (0x1UL << USART_CR1_PCE_Pos)              /*!< 0x00000400 */
8016 #define USART_CR1_PCE                USART_CR1_PCE_Msk                         /*!< Parity Control Enable */
8017 #define USART_CR1_WAKE_Pos           (11U)
8018 #define USART_CR1_WAKE_Msk           (0x1UL << USART_CR1_WAKE_Pos)             /*!< 0x00000800 */
8019 #define USART_CR1_WAKE               USART_CR1_WAKE_Msk                        /*!< Receiver Wakeup method */
8020 #define USART_CR1_M_Pos              (12U)
8021 #define USART_CR1_M_Msk              (0x10001UL << USART_CR1_M_Pos)            /*!< 0x10001000 */
8022 #define USART_CR1_M                  USART_CR1_M_Msk                           /*!< Word length */
8023 #define USART_CR1_M0_Pos             (12U)
8024 #define USART_CR1_M0_Msk             (0x1UL << USART_CR1_M0_Pos)               /*!< 0x00001000 */
8025 #define USART_CR1_M0                 USART_CR1_M0_Msk                          /*!< Word length - Bit 0 */
8026 #define USART_CR1_MME_Pos            (13U)
8027 #define USART_CR1_MME_Msk            (0x1UL << USART_CR1_MME_Pos)              /*!< 0x00002000 */
8028 #define USART_CR1_MME                USART_CR1_MME_Msk                         /*!< Mute Mode Enable */
8029 #define USART_CR1_CMIE_Pos           (14U)
8030 #define USART_CR1_CMIE_Msk           (0x1UL << USART_CR1_CMIE_Pos)             /*!< 0x00004000 */
8031 #define USART_CR1_CMIE               USART_CR1_CMIE_Msk                        /*!< Character match interrupt enable */
8032 #define USART_CR1_OVER8_Pos          (15U)
8033 #define USART_CR1_OVER8_Msk          (0x1UL << USART_CR1_OVER8_Pos)            /*!< 0x00008000 */
8034 #define USART_CR1_OVER8              USART_CR1_OVER8_Msk                       /*!< Oversampling by 8-bit or 16-bit mode */
8035 #define USART_CR1_DEDT_Pos           (16U)
8036 #define USART_CR1_DEDT_Msk           (0x1FUL << USART_CR1_DEDT_Pos)            /*!< 0x001F0000 */
8037 #define USART_CR1_DEDT               USART_CR1_DEDT_Msk                        /*!< DEDT[4:0] bits (Driver Enable Deassertion Time) */
8038 #define USART_CR1_DEDT_0             (0x01UL << USART_CR1_DEDT_Pos)            /*!< 0x00010000 */
8039 #define USART_CR1_DEDT_1             (0x02UL << USART_CR1_DEDT_Pos)            /*!< 0x00020000 */
8040 #define USART_CR1_DEDT_2             (0x04UL << USART_CR1_DEDT_Pos)            /*!< 0x00040000 */
8041 #define USART_CR1_DEDT_3             (0x08UL << USART_CR1_DEDT_Pos)            /*!< 0x00080000 */
8042 #define USART_CR1_DEDT_4             (0x10UL << USART_CR1_DEDT_Pos)            /*!< 0x00100000 */
8043 #define USART_CR1_DEAT_Pos           (21U)
8044 #define USART_CR1_DEAT_Msk           (0x1FUL << USART_CR1_DEAT_Pos)            /*!< 0x03E00000 */
8045 #define USART_CR1_DEAT               USART_CR1_DEAT_Msk                        /*!< DEAT[4:0] bits (Driver Enable Assertion Time) */
8046 #define USART_CR1_DEAT_0             (0x01UL << USART_CR1_DEAT_Pos)            /*!< 0x00200000 */
8047 #define USART_CR1_DEAT_1             (0x02UL << USART_CR1_DEAT_Pos)            /*!< 0x00400000 */
8048 #define USART_CR1_DEAT_2             (0x04UL << USART_CR1_DEAT_Pos)            /*!< 0x00800000 */
8049 #define USART_CR1_DEAT_3             (0x08UL << USART_CR1_DEAT_Pos)            /*!< 0x01000000 */
8050 #define USART_CR1_DEAT_4             (0x10UL << USART_CR1_DEAT_Pos)            /*!< 0x02000000 */
8051 #define USART_CR1_RTOIE_Pos          (26U)
8052 #define USART_CR1_RTOIE_Msk          (0x1UL << USART_CR1_RTOIE_Pos)            /*!< 0x04000000 */
8053 #define USART_CR1_RTOIE              USART_CR1_RTOIE_Msk                       /*!< Receive Time Out interrupt enable */
8054 #define USART_CR1_EOBIE_Pos          (27U)
8055 #define USART_CR1_EOBIE_Msk          (0x1UL << USART_CR1_EOBIE_Pos)            /*!< 0x08000000 */
8056 #define USART_CR1_EOBIE              USART_CR1_EOBIE_Msk                       /*!< End of Block interrupt enable */
8057 #define USART_CR1_M1_Pos             (28U)
8058 #define USART_CR1_M1_Msk             (0x1UL << USART_CR1_M1_Pos)               /*!< 0x10000000 */
8059 #define USART_CR1_M1                 USART_CR1_M1_Msk                          /*!< Word length - Bit 1 */
8060 #define USART_CR1_FIFOEN_Pos         (29U)
8061 #define USART_CR1_FIFOEN_Msk         (0x1UL << USART_CR1_FIFOEN_Pos)           /*!< 0x20000000 */
8062 #define USART_CR1_FIFOEN             USART_CR1_FIFOEN_Msk                      /*!< FIFO mode enable */
8063 #define USART_CR1_TXFEIE_Pos         (30U)
8064 #define USART_CR1_TXFEIE_Msk         (0x1UL << USART_CR1_TXFEIE_Pos)           /*!< 0x40000000 */
8065 #define USART_CR1_TXFEIE             USART_CR1_TXFEIE_Msk                      /*!< TXFIFO empty interrupt enable */
8066 #define USART_CR1_RXFFIE_Pos         (31U)
8067 #define USART_CR1_RXFFIE_Msk         (0x1UL << USART_CR1_RXFFIE_Pos)           /*!< 0x80000000 */
8068 #define USART_CR1_RXFFIE             USART_CR1_RXFFIE_Msk                      /*!< RXFIFO Full interrupt enable */
8069 
8070 /******************  Bit definition for USART_CR2 register  *******************/
8071 #define USART_CR2_SLVEN_Pos          (0U)
8072 #define USART_CR2_SLVEN_Msk          (0x1UL << USART_CR2_SLVEN_Pos)            /*!< 0x00000001 */
8073 #define USART_CR2_SLVEN              USART_CR2_SLVEN_Msk                       /*!< Synchronous Slave mode enable */
8074 #define USART_CR2_DIS_NSS_Pos        (3U)
8075 #define USART_CR2_DIS_NSS_Msk        (0x1UL << USART_CR2_DIS_NSS_Pos)          /*!< 0x00000008 */
8076 #define USART_CR2_DIS_NSS            USART_CR2_DIS_NSS_Msk                     /*!< NSS input pin disable for SPI slave selection */
8077 #define USART_CR2_ADDM7_Pos          (4U)
8078 #define USART_CR2_ADDM7_Msk          (0x1UL << USART_CR2_ADDM7_Pos)            /*!< 0x00000010 */
8079 #define USART_CR2_ADDM7              USART_CR2_ADDM7_Msk                       /*!< 7-bit or 4-bit Address Detection */
8080 #define USART_CR2_LBDL_Pos           (5U)
8081 #define USART_CR2_LBDL_Msk           (0x1UL << USART_CR2_LBDL_Pos)             /*!< 0x00000020 */
8082 #define USART_CR2_LBDL               USART_CR2_LBDL_Msk                        /*!< LIN Break Detection Length */
8083 #define USART_CR2_LBDIE_Pos          (6U)
8084 #define USART_CR2_LBDIE_Msk          (0x1UL << USART_CR2_LBDIE_Pos)            /*!< 0x00000040 */
8085 #define USART_CR2_LBDIE              USART_CR2_LBDIE_Msk                       /*!< LIN Break Detection Interrupt Enable */
8086 #define USART_CR2_LBCL_Pos           (8U)
8087 #define USART_CR2_LBCL_Msk           (0x1UL << USART_CR2_LBCL_Pos)             /*!< 0x00000100 */
8088 #define USART_CR2_LBCL               USART_CR2_LBCL_Msk                        /*!< Last Bit Clock pulse */
8089 #define USART_CR2_CPHA_Pos           (9U)
8090 #define USART_CR2_CPHA_Msk           (0x1UL << USART_CR2_CPHA_Pos)             /*!< 0x00000200 */
8091 #define USART_CR2_CPHA               USART_CR2_CPHA_Msk                        /*!< Clock Phase */
8092 #define USART_CR2_CPOL_Pos           (10U)
8093 #define USART_CR2_CPOL_Msk           (0x1UL << USART_CR2_CPOL_Pos)             /*!< 0x00000400 */
8094 #define USART_CR2_CPOL               USART_CR2_CPOL_Msk                        /*!< Clock Polarity */
8095 #define USART_CR2_CLKEN_Pos          (11U)
8096 #define USART_CR2_CLKEN_Msk          (0x1UL << USART_CR2_CLKEN_Pos)            /*!< 0x00000800 */
8097 #define USART_CR2_CLKEN              USART_CR2_CLKEN_Msk                       /*!< Clock Enable */
8098 #define USART_CR2_STOP_Pos           (12U)
8099 #define USART_CR2_STOP_Msk           (0x3UL << USART_CR2_STOP_Pos)             /*!< 0x00003000 */
8100 #define USART_CR2_STOP               USART_CR2_STOP_Msk                        /*!< STOP[1:0] bits (STOP bits) */
8101 #define USART_CR2_STOP_0             (0x1UL << USART_CR2_STOP_Pos)             /*!< 0x00001000 */
8102 #define USART_CR2_STOP_1             (0x2UL << USART_CR2_STOP_Pos)             /*!< 0x00002000 */
8103 #define USART_CR2_LINEN_Pos          (14U)
8104 #define USART_CR2_LINEN_Msk          (0x1UL << USART_CR2_LINEN_Pos)            /*!< 0x00004000 */
8105 #define USART_CR2_LINEN              USART_CR2_LINEN_Msk                       /*!< LIN mode enable */
8106 #define USART_CR2_SWAP_Pos           (15U)
8107 #define USART_CR2_SWAP_Msk           (0x1UL << USART_CR2_SWAP_Pos)             /*!< 0x00008000 */
8108 #define USART_CR2_SWAP               USART_CR2_SWAP_Msk                        /*!< SWAP TX/RX pins */
8109 #define USART_CR2_RXINV_Pos          (16U)
8110 #define USART_CR2_RXINV_Msk          (0x1UL << USART_CR2_RXINV_Pos)            /*!< 0x00010000 */
8111 #define USART_CR2_RXINV              USART_CR2_RXINV_Msk                       /*!< RX pin active level inversion */
8112 #define USART_CR2_TXINV_Pos          (17U)
8113 #define USART_CR2_TXINV_Msk          (0x1UL << USART_CR2_TXINV_Pos)            /*!< 0x00020000 */
8114 #define USART_CR2_TXINV              USART_CR2_TXINV_Msk                       /*!< TX pin active level inversion */
8115 #define USART_CR2_DATAINV_Pos        (18U)
8116 #define USART_CR2_DATAINV_Msk        (0x1UL << USART_CR2_DATAINV_Pos)          /*!< 0x00040000 */
8117 #define USART_CR2_DATAINV            USART_CR2_DATAINV_Msk                     /*!< Binary data inversion */
8118 #define USART_CR2_MSBFIRST_Pos       (19U)
8119 #define USART_CR2_MSBFIRST_Msk       (0x1UL << USART_CR2_MSBFIRST_Pos)         /*!< 0x00080000 */
8120 #define USART_CR2_MSBFIRST           USART_CR2_MSBFIRST_Msk                    /*!< Most Significant Bit First */
8121 #define USART_CR2_ABREN_Pos          (20U)
8122 #define USART_CR2_ABREN_Msk          (0x1UL << USART_CR2_ABREN_Pos)            /*!< 0x00100000 */
8123 #define USART_CR2_ABREN              USART_CR2_ABREN_Msk                       /*!< Auto Baud-Rate Enable*/
8124 #define USART_CR2_ABRMODE_Pos        (21U)
8125 #define USART_CR2_ABRMODE_Msk        (0x3UL << USART_CR2_ABRMODE_Pos)          /*!< 0x00600000 */
8126 #define USART_CR2_ABRMODE            USART_CR2_ABRMODE_Msk                     /*!< ABRMOD[1:0] bits (Auto Baud-Rate Mode) */
8127 #define USART_CR2_ABRMODE_0          (0x1UL << USART_CR2_ABRMODE_Pos)          /*!< 0x00200000 */
8128 #define USART_CR2_ABRMODE_1          (0x2UL << USART_CR2_ABRMODE_Pos)          /*!< 0x00400000 */
8129 #define USART_CR2_RTOEN_Pos          (23U)
8130 #define USART_CR2_RTOEN_Msk          (0x1UL << USART_CR2_RTOEN_Pos)            /*!< 0x00800000 */
8131 #define USART_CR2_RTOEN              USART_CR2_RTOEN_Msk                       /*!< Receiver Time-Out enable */
8132 #define USART_CR2_ADD_Pos            (24U)
8133 #define USART_CR2_ADD_Msk            (0xFFUL << USART_CR2_ADD_Pos)             /*!< 0xFF000000 */
8134 #define USART_CR2_ADD                USART_CR2_ADD_Msk                         /*!< Address of the USART node */
8135 
8136 /******************  Bit definition for USART_CR3 register  *******************/
8137 #define USART_CR3_EIE_Pos            (0U)
8138 #define USART_CR3_EIE_Msk            (0x1UL << USART_CR3_EIE_Pos)              /*!< 0x00000001 */
8139 #define USART_CR3_EIE                USART_CR3_EIE_Msk                         /*!< Error Interrupt Enable */
8140 #define USART_CR3_IREN_Pos           (1U)
8141 #define USART_CR3_IREN_Msk           (0x1UL << USART_CR3_IREN_Pos)             /*!< 0x00000002 */
8142 #define USART_CR3_IREN               USART_CR3_IREN_Msk                        /*!< IrDA mode Enable */
8143 #define USART_CR3_IRLP_Pos           (2U)
8144 #define USART_CR3_IRLP_Msk           (0x1UL << USART_CR3_IRLP_Pos)             /*!< 0x00000004 */
8145 #define USART_CR3_IRLP               USART_CR3_IRLP_Msk                        /*!< IrDA Low-Power */
8146 #define USART_CR3_HDSEL_Pos          (3U)
8147 #define USART_CR3_HDSEL_Msk          (0x1UL << USART_CR3_HDSEL_Pos)            /*!< 0x00000008 */
8148 #define USART_CR3_HDSEL              USART_CR3_HDSEL_Msk                       /*!< Half-Duplex Selection */
8149 #define USART_CR3_NACK_Pos           (4U)
8150 #define USART_CR3_NACK_Msk           (0x1UL << USART_CR3_NACK_Pos)             /*!< 0x00000010 */
8151 #define USART_CR3_NACK               USART_CR3_NACK_Msk                        /*!< SmartCard NACK enable */
8152 #define USART_CR3_SCEN_Pos           (5U)
8153 #define USART_CR3_SCEN_Msk           (0x1UL << USART_CR3_SCEN_Pos)             /*!< 0x00000020 */
8154 #define USART_CR3_SCEN               USART_CR3_SCEN_Msk                        /*!< SmartCard mode enable */
8155 #define USART_CR3_DMAR_Pos           (6U)
8156 #define USART_CR3_DMAR_Msk           (0x1UL << USART_CR3_DMAR_Pos)             /*!< 0x00000040 */
8157 #define USART_CR3_DMAR               USART_CR3_DMAR_Msk                        /*!< DMA Enable Receiver */
8158 #define USART_CR3_DMAT_Pos           (7U)
8159 #define USART_CR3_DMAT_Msk           (0x1UL << USART_CR3_DMAT_Pos)             /*!< 0x00000080 */
8160 #define USART_CR3_DMAT               USART_CR3_DMAT_Msk                        /*!< DMA Enable Transmitter */
8161 #define USART_CR3_RTSE_Pos           (8U)
8162 #define USART_CR3_RTSE_Msk           (0x1UL << USART_CR3_RTSE_Pos)             /*!< 0x00000100 */
8163 #define USART_CR3_RTSE               USART_CR3_RTSE_Msk                        /*!< RTS Enable */
8164 #define USART_CR3_CTSE_Pos           (9U)
8165 #define USART_CR3_CTSE_Msk           (0x1UL << USART_CR3_CTSE_Pos)             /*!< 0x00000200 */
8166 #define USART_CR3_CTSE               USART_CR3_CTSE_Msk                        /*!< CTS Enable */
8167 #define USART_CR3_CTSIE_Pos          (10U)
8168 #define USART_CR3_CTSIE_Msk          (0x1UL << USART_CR3_CTSIE_Pos)            /*!< 0x00000400 */
8169 #define USART_CR3_CTSIE              USART_CR3_CTSIE_Msk                       /*!< CTS Interrupt Enable */
8170 #define USART_CR3_ONEBIT_Pos         (11U)
8171 #define USART_CR3_ONEBIT_Msk         (0x1UL << USART_CR3_ONEBIT_Pos)           /*!< 0x00000800 */
8172 #define USART_CR3_ONEBIT             USART_CR3_ONEBIT_Msk                      /*!< One sample bit method enable */
8173 #define USART_CR3_OVRDIS_Pos         (12U)
8174 #define USART_CR3_OVRDIS_Msk         (0x1UL << USART_CR3_OVRDIS_Pos)           /*!< 0x00001000 */
8175 #define USART_CR3_OVRDIS             USART_CR3_OVRDIS_Msk                      /*!< Overrun Disable */
8176 #define USART_CR3_DDRE_Pos           (13U)
8177 #define USART_CR3_DDRE_Msk           (0x1UL << USART_CR3_DDRE_Pos)             /*!< 0x00002000 */
8178 #define USART_CR3_DDRE               USART_CR3_DDRE_Msk                        /*!< DMA Disable on Reception Error */
8179 #define USART_CR3_DEM_Pos            (14U)
8180 #define USART_CR3_DEM_Msk            (0x1UL << USART_CR3_DEM_Pos)              /*!< 0x00004000 */
8181 #define USART_CR3_DEM                USART_CR3_DEM_Msk                         /*!< Driver Enable Mode */
8182 #define USART_CR3_DEP_Pos            (15U)
8183 #define USART_CR3_DEP_Msk            (0x1UL << USART_CR3_DEP_Pos)              /*!< 0x00008000 */
8184 #define USART_CR3_DEP                USART_CR3_DEP_Msk                         /*!< Driver Enable Polarity Selection */
8185 #define USART_CR3_SCARCNT_Pos        (17U)
8186 #define USART_CR3_SCARCNT_Msk        (0x7UL << USART_CR3_SCARCNT_Pos)          /*!< 0x000E0000 */
8187 #define USART_CR3_SCARCNT            USART_CR3_SCARCNT_Msk                     /*!< SCARCNT[2:0] bits (SmartCard Auto-Retry Count) */
8188 #define USART_CR3_SCARCNT_0          (0x1UL << USART_CR3_SCARCNT_Pos)          /*!< 0x00020000 */
8189 #define USART_CR3_SCARCNT_1          (0x2UL << USART_CR3_SCARCNT_Pos)          /*!< 0x00040000 */
8190 #define USART_CR3_SCARCNT_2          (0x4UL << USART_CR3_SCARCNT_Pos)          /*!< 0x00080000 */
8191 #define USART_CR3_WUS_Pos            (20U)
8192 #define USART_CR3_WUS_Msk            (0x3UL << USART_CR3_WUS_Pos)              /*!< 0x00300000 */
8193 #define USART_CR3_WUS                USART_CR3_WUS_Msk                         /*!< WUS[1:0] bits (Wake UP Interrupt Flag Selection) */
8194 #define USART_CR3_WUS_0              (0x1UL << USART_CR3_WUS_Pos)              /*!< 0x00100000 */
8195 #define USART_CR3_WUS_1              (0x2UL << USART_CR3_WUS_Pos)              /*!< 0x00200000 */
8196 #define USART_CR3_WUFIE_Pos          (22U)
8197 #define USART_CR3_WUFIE_Msk          (0x1UL << USART_CR3_WUFIE_Pos)            /*!< 0x00400000 */
8198 #define USART_CR3_WUFIE              USART_CR3_WUFIE_Msk                       /*!< Wake Up Interrupt Enable */
8199 #define USART_CR3_TXFTIE_Pos         (23U)
8200 #define USART_CR3_TXFTIE_Msk         (0x1UL << USART_CR3_TXFTIE_Pos)           /*!< 0x00800000 */
8201 #define USART_CR3_TXFTIE             USART_CR3_TXFTIE_Msk                      /*!< TXFIFO threshold interrupt enable */
8202 #define USART_CR3_TCBGTIE_Pos        (24U)
8203 #define USART_CR3_TCBGTIE_Msk        (0x1UL << USART_CR3_TCBGTIE_Pos)          /*!< 0x01000000 */
8204 #define USART_CR3_TCBGTIE            USART_CR3_TCBGTIE_Msk                     /*!< Transmission Complete Before Guard Time Interrupt Enable */
8205 #define USART_CR3_RXFTCFG_Pos        (25U)
8206 #define USART_CR3_RXFTCFG_Msk        (0x7UL << USART_CR3_RXFTCFG_Pos)          /*!< 0x0E000000 */
8207 #define USART_CR3_RXFTCFG            USART_CR3_RXFTCFG_Msk                     /*!< RXFIFO FIFO threshold configuration */
8208 #define USART_CR3_RXFTCFG_0          (0x1UL << USART_CR3_RXFTCFG_Pos)          /*!< 0x02000000 */
8209 #define USART_CR3_RXFTCFG_1          (0x2UL << USART_CR3_RXFTCFG_Pos)          /*!< 0x04000000 */
8210 #define USART_CR3_RXFTCFG_2          (0x4UL << USART_CR3_RXFTCFG_Pos)          /*!< 0x08000000 */
8211 #define USART_CR3_RXFTIE_Pos         (28U)
8212 #define USART_CR3_RXFTIE_Msk         (0x1UL << USART_CR3_RXFTIE_Pos)           /*!< 0x10000000 */
8213 #define USART_CR3_RXFTIE             USART_CR3_RXFTIE_Msk                      /*!< RXFIFO threshold interrupt enable */
8214 #define USART_CR3_TXFTCFG_Pos        (29U)
8215 #define USART_CR3_TXFTCFG_Msk        (0x7UL << USART_CR3_TXFTCFG_Pos)          /*!< 0xE0000000 */
8216 #define USART_CR3_TXFTCFG            USART_CR3_TXFTCFG_Msk                     /*!< TXFIFO threshold configuration */
8217 #define USART_CR3_TXFTCFG_0          (0x1UL << USART_CR3_TXFTCFG_Pos)          /*!< 0x20000000 */
8218 #define USART_CR3_TXFTCFG_1          (0x2UL << USART_CR3_TXFTCFG_Pos)          /*!< 0x40000000 */
8219 #define USART_CR3_TXFTCFG_2          (0x4UL << USART_CR3_TXFTCFG_Pos)          /*!< 0x80000000 */
8220 
8221 /******************  Bit definition for USART_BRR register  *******************/
8222 #define USART_BRR_BRR                ((uint16_t)0xFFFF)                        /*!< USART  Baud rate register [15:0] */
8223 
8224 /******************  Bit definition for USART_GTPR register  ******************/
8225 #define USART_GTPR_PSC_Pos           (0U)
8226 #define USART_GTPR_PSC_Msk           (0xFFUL << USART_GTPR_PSC_Pos)            /*!< 0x000000FF */
8227 #define USART_GTPR_PSC               USART_GTPR_PSC_Msk                        /*!< PSC[7:0] bits (Prescaler value) */
8228 #define USART_GTPR_GT_Pos            (8U)
8229 #define USART_GTPR_GT_Msk            (0xFFUL << USART_GTPR_GT_Pos)             /*!< 0x0000FF00 */
8230 #define USART_GTPR_GT                USART_GTPR_GT_Msk                         /*!< GT[7:0] bits (Guard time value) */
8231 
8232 /*******************  Bit definition for USART_RTOR register  *****************/
8233 #define USART_RTOR_RTO_Pos           (0U)
8234 #define USART_RTOR_RTO_Msk           (0xFFFFFFUL << USART_RTOR_RTO_Pos)        /*!< 0x00FFFFFF */
8235 #define USART_RTOR_RTO               USART_RTOR_RTO_Msk                        /*!< Receiver Time Out Value */
8236 #define USART_RTOR_BLEN_Pos          (24U)
8237 #define USART_RTOR_BLEN_Msk          (0xFFUL << USART_RTOR_BLEN_Pos)           /*!< 0xFF000000 */
8238 #define USART_RTOR_BLEN              USART_RTOR_BLEN_Msk                       /*!< Block Length */
8239 
8240 /*******************  Bit definition for USART_RQR register  ******************/
8241 #define USART_RQR_ABRRQ        ((uint16_t)0x0001)                              /*!< Auto-Baud Rate Request */
8242 #define USART_RQR_SBKRQ        ((uint16_t)0x0002)                              /*!< Send Break Request */
8243 #define USART_RQR_MMRQ         ((uint16_t)0x0004)                              /*!< Mute Mode Request */
8244 #define USART_RQR_RXFRQ        ((uint16_t)0x0008)                              /*!< Receive Data flush Request */
8245 #define USART_RQR_TXFRQ        ((uint16_t)0x0010)                              /*!< Transmit data flush Request */
8246 
8247 /*******************  Bit definition for USART_ISR register  ******************/
8248 #define USART_ISR_PE_Pos             (0U)
8249 #define USART_ISR_PE_Msk             (0x1UL << USART_ISR_PE_Pos)               /*!< 0x00000001 */
8250 #define USART_ISR_PE                 USART_ISR_PE_Msk                          /*!< Parity Error */
8251 #define USART_ISR_FE_Pos             (1U)
8252 #define USART_ISR_FE_Msk             (0x1UL << USART_ISR_FE_Pos)               /*!< 0x00000002 */
8253 #define USART_ISR_FE                 USART_ISR_FE_Msk                          /*!< Framing Error */
8254 #define USART_ISR_NE_Pos             (2U)
8255 #define USART_ISR_NE_Msk             (0x1UL << USART_ISR_NE_Pos)               /*!< 0x00000004 */
8256 #define USART_ISR_NE                 USART_ISR_NE_Msk                          /*!< Noise detected Flag */
8257 #define USART_ISR_ORE_Pos            (3U)
8258 #define USART_ISR_ORE_Msk            (0x1UL << USART_ISR_ORE_Pos)              /*!< 0x00000008 */
8259 #define USART_ISR_ORE                USART_ISR_ORE_Msk                         /*!< OverRun Error */
8260 #define USART_ISR_IDLE_Pos           (4U)
8261 #define USART_ISR_IDLE_Msk           (0x1UL << USART_ISR_IDLE_Pos)             /*!< 0x00000010 */
8262 #define USART_ISR_IDLE               USART_ISR_IDLE_Msk                        /*!< IDLE line detected */
8263 #define USART_ISR_RXNE_RXFNE_Pos     (5U)
8264 #define USART_ISR_RXNE_RXFNE_Msk     (0x1UL << USART_ISR_RXNE_RXFNE_Pos)       /*!< 0x00000020 */
8265 #define USART_ISR_RXNE_RXFNE         USART_ISR_RXNE_RXFNE_Msk                  /*!< Read Data Register Not Empty/RXFIFO Not Empty */
8266 #define USART_ISR_TC_Pos             (6U)
8267 #define USART_ISR_TC_Msk             (0x1UL << USART_ISR_TC_Pos)               /*!< 0x00000040 */
8268 #define USART_ISR_TC                 USART_ISR_TC_Msk                          /*!< Transmission Complete */
8269 #define USART_ISR_TXE_TXFNF_Pos      (7U)
8270 #define USART_ISR_TXE_TXFNF_Msk      (0x1UL << USART_ISR_TXE_TXFNF_Pos)        /*!< 0x00000080 */
8271 #define USART_ISR_TXE_TXFNF          USART_ISR_TXE_TXFNF_Msk                   /*!< Transmit Data Register Empty/TXFIFO Not Full */
8272 #define USART_ISR_LBDF_Pos           (8U)
8273 #define USART_ISR_LBDF_Msk           (0x1UL << USART_ISR_LBDF_Pos)             /*!< 0x00000100 */
8274 #define USART_ISR_LBDF               USART_ISR_LBDF_Msk                        /*!< LIN Break Detection Flag */
8275 #define USART_ISR_CTSIF_Pos          (9U)
8276 #define USART_ISR_CTSIF_Msk          (0x1UL << USART_ISR_CTSIF_Pos)            /*!< 0x00000200 */
8277 #define USART_ISR_CTSIF              USART_ISR_CTSIF_Msk                       /*!< CTS interrupt flag */
8278 #define USART_ISR_CTS_Pos            (10U)
8279 #define USART_ISR_CTS_Msk            (0x1UL << USART_ISR_CTS_Pos)              /*!< 0x00000400 */
8280 #define USART_ISR_CTS                USART_ISR_CTS_Msk                         /*!< CTS flag */
8281 #define USART_ISR_RTOF_Pos           (11U)
8282 #define USART_ISR_RTOF_Msk           (0x1UL << USART_ISR_RTOF_Pos)             /*!< 0x00000800 */
8283 #define USART_ISR_RTOF               USART_ISR_RTOF_Msk                        /*!< Receiver Time Out */
8284 #define USART_ISR_EOBF_Pos           (12U)
8285 #define USART_ISR_EOBF_Msk           (0x1UL << USART_ISR_EOBF_Pos)             /*!< 0x00001000 */
8286 #define USART_ISR_EOBF               USART_ISR_EOBF_Msk                        /*!< End Of Block Flag */
8287 #define USART_ISR_UDR_Pos            (13U)
8288 #define USART_ISR_UDR_Msk            (0x1UL << USART_ISR_UDR_Pos)              /*!< 0x00002000 */
8289 #define USART_ISR_UDR                 USART_ISR_UDR_Msk                        /*!< SPI Slave Underrun Error Flag */
8290 #define USART_ISR_ABRE_Pos           (14U)
8291 #define USART_ISR_ABRE_Msk           (0x1UL << USART_ISR_ABRE_Pos)             /*!< 0x00004000 */
8292 #define USART_ISR_ABRE               USART_ISR_ABRE_Msk                        /*!< Auto-Baud Rate Error */
8293 #define USART_ISR_ABRF_Pos           (15U)
8294 #define USART_ISR_ABRF_Msk           (0x1UL << USART_ISR_ABRF_Pos)             /*!< 0x00008000 */
8295 #define USART_ISR_ABRF               USART_ISR_ABRF_Msk                        /*!< Auto-Baud Rate Flag */
8296 #define USART_ISR_BUSY_Pos           (16U)
8297 #define USART_ISR_BUSY_Msk           (0x1UL << USART_ISR_BUSY_Pos)             /*!< 0x00010000 */
8298 #define USART_ISR_BUSY               USART_ISR_BUSY_Msk                        /*!< Busy Flag */
8299 #define USART_ISR_CMF_Pos            (17U)
8300 #define USART_ISR_CMF_Msk            (0x1UL << USART_ISR_CMF_Pos)              /*!< 0x00020000 */
8301 #define USART_ISR_CMF                USART_ISR_CMF_Msk                         /*!< Character Match Flag */
8302 #define USART_ISR_SBKF_Pos           (18U)
8303 #define USART_ISR_SBKF_Msk           (0x1UL << USART_ISR_SBKF_Pos)             /*!< 0x00040000 */
8304 #define USART_ISR_SBKF               USART_ISR_SBKF_Msk                        /*!< Send Break Flag */
8305 #define USART_ISR_RWU_Pos            (19U)
8306 #define USART_ISR_RWU_Msk            (0x1UL << USART_ISR_RWU_Pos)              /*!< 0x00080000 */
8307 #define USART_ISR_RWU                USART_ISR_RWU_Msk                         /*!< Receive Wake Up from mute mode Flag */
8308 #define USART_ISR_WUF_Pos            (20U)
8309 #define USART_ISR_WUF_Msk            (0x1UL << USART_ISR_WUF_Pos)              /*!< 0x00100000 */
8310 #define USART_ISR_WUF                USART_ISR_WUF_Msk                         /*!< Wake Up from stop mode Flag */
8311 #define USART_ISR_TEACK_Pos          (21U)
8312 #define USART_ISR_TEACK_Msk          (0x1UL << USART_ISR_TEACK_Pos)            /*!< 0x00200000 */
8313 #define USART_ISR_TEACK              USART_ISR_TEACK_Msk                       /*!< Transmit Enable Acknowledge Flag */
8314 #define USART_ISR_REACK_Pos          (22U)
8315 #define USART_ISR_REACK_Msk          (0x1UL << USART_ISR_REACK_Pos)            /*!< 0x00400000 */
8316 #define USART_ISR_REACK              USART_ISR_REACK_Msk                       /*!< Receive Enable Acknowledge Flag */
8317 #define USART_ISR_TXFE_Pos           (23U)
8318 #define USART_ISR_TXFE_Msk           (0x1UL << USART_ISR_TXFE_Pos)             /*!< 0x00800000 */
8319 #define USART_ISR_TXFE               USART_ISR_TXFE_Msk                        /*!< TXFIFO Empty Flag */
8320 #define USART_ISR_RXFF_Pos           (24U)
8321 #define USART_ISR_RXFF_Msk           (0x1UL << USART_ISR_RXFF_Pos)             /*!< 0x01000000 */
8322 #define USART_ISR_RXFF               USART_ISR_RXFF_Msk                        /*!< RXFIFO Full Flag */
8323 #define USART_ISR_TCBGT_Pos          (25U)
8324 #define USART_ISR_TCBGT_Msk          (0x1UL << USART_ISR_TCBGT_Pos)            /*!< 0x02000000 */
8325 #define USART_ISR_TCBGT              USART_ISR_TCBGT_Msk                       /*!< Transmission Complete Before Guard Time Completion Flag */
8326 #define USART_ISR_RXFT_Pos           (26U)
8327 #define USART_ISR_RXFT_Msk           (0x1UL << USART_ISR_RXFT_Pos)             /*!< 0x04000000 */
8328 #define USART_ISR_RXFT               USART_ISR_RXFT_Msk                        /*!< RXFIFO Threshold Flag */
8329 #define USART_ISR_TXFT_Pos           (27U)
8330 #define USART_ISR_TXFT_Msk           (0x1UL << USART_ISR_TXFT_Pos)             /*!< 0x08000000 */
8331 #define USART_ISR_TXFT               USART_ISR_TXFT_Msk                        /*!< TXFIFO Threshold Flag */
8332 
8333 /*******************  Bit definition for USART_ICR register  ******************/
8334 #define USART_ICR_PECF_Pos           (0U)
8335 #define USART_ICR_PECF_Msk           (0x1UL << USART_ICR_PECF_Pos)             /*!< 0x00000001 */
8336 #define USART_ICR_PECF               USART_ICR_PECF_Msk                        /*!< Parity Error Clear Flag */
8337 #define USART_ICR_FECF_Pos           (1U)
8338 #define USART_ICR_FECF_Msk           (0x1UL << USART_ICR_FECF_Pos)             /*!< 0x00000002 */
8339 #define USART_ICR_FECF               USART_ICR_FECF_Msk                        /*!< Framing Error Clear Flag */
8340 #define USART_ICR_NECF_Pos           (2U)
8341 #define USART_ICR_NECF_Msk           (0x1UL << USART_ICR_NECF_Pos)             /*!< 0x00000004 */
8342 #define USART_ICR_NECF               USART_ICR_NECF_Msk                        /*!< Noise Error detected Clear Flag */
8343 #define USART_ICR_ORECF_Pos          (3U)
8344 #define USART_ICR_ORECF_Msk          (0x1UL << USART_ICR_ORECF_Pos)            /*!< 0x00000008 */
8345 #define USART_ICR_ORECF              USART_ICR_ORECF_Msk                       /*!< OverRun Error Clear Flag */
8346 #define USART_ICR_IDLECF_Pos         (4U)
8347 #define USART_ICR_IDLECF_Msk         (0x1UL << USART_ICR_IDLECF_Pos)           /*!< 0x00000010 */
8348 #define USART_ICR_IDLECF             USART_ICR_IDLECF_Msk                      /*!< IDLE line detected Clear Flag */
8349 #define USART_ICR_TXFECF_Pos         (5U)
8350 #define USART_ICR_TXFECF_Msk         (0x1UL << USART_ICR_TXFECF_Pos)           /*!< 0x00000020 */
8351 #define USART_ICR_TXFECF             USART_ICR_TXFECF_Msk                      /*!< TXFIFO Empty Clear Flag */
8352 #define USART_ICR_TCCF_Pos           (6U)
8353 #define USART_ICR_TCCF_Msk           (0x1UL << USART_ICR_TCCF_Pos)             /*!< 0x00000040 */
8354 #define USART_ICR_TCCF               USART_ICR_TCCF_Msk                        /*!< Transmission Complete Clear Flag */
8355 #define USART_ICR_TCBGTCF_Pos        (7U)
8356 #define USART_ICR_TCBGTCF_Msk        (0x1UL << USART_ICR_TCBGTCF_Pos)          /*!< 0x00000080 */
8357 #define USART_ICR_TCBGTCF            USART_ICR_TCBGTCF_Msk                     /*!< Transmission Complete Before Guard Time Clear Flag */
8358 #define USART_ICR_LBDCF_Pos          (8U)
8359 #define USART_ICR_LBDCF_Msk          (0x1UL << USART_ICR_LBDCF_Pos)            /*!< 0x00000100 */
8360 #define USART_ICR_LBDCF              USART_ICR_LBDCF_Msk                       /*!< LIN Break Detection Clear Flag */
8361 #define USART_ICR_CTSCF_Pos          (9U)
8362 #define USART_ICR_CTSCF_Msk          (0x1UL << USART_ICR_CTSCF_Pos)            /*!< 0x00000200 */
8363 #define USART_ICR_CTSCF              USART_ICR_CTSCF_Msk                       /*!< CTS Interrupt Clear Flag */
8364 #define USART_ICR_RTOCF_Pos          (11U)
8365 #define USART_ICR_RTOCF_Msk          (0x1UL << USART_ICR_RTOCF_Pos)            /*!< 0x00000800 */
8366 #define USART_ICR_RTOCF              USART_ICR_RTOCF_Msk                       /*!< Receiver Time Out Clear Flag */
8367 #define USART_ICR_EOBCF_Pos          (12U)
8368 #define USART_ICR_EOBCF_Msk          (0x1UL << USART_ICR_EOBCF_Pos)            /*!< 0x00001000 */
8369 #define USART_ICR_EOBCF              USART_ICR_EOBCF_Msk                       /*!< End Of Block Clear Flag */
8370 #define USART_ICR_UDRCF_Pos          (13U)
8371 #define USART_ICR_UDRCF_Msk          (0x1UL << USART_ICR_UDRCF_Pos)            /*!< 0x00002000 */
8372 #define USART_ICR_UDRCF              USART_ICR_UDRCF_Msk                       /*!< SPI Slave Underrun Clear Flag */
8373 #define USART_ICR_CMCF_Pos           (17U)
8374 #define USART_ICR_CMCF_Msk           (0x1UL << USART_ICR_CMCF_Pos)             /*!< 0x00020000 */
8375 #define USART_ICR_CMCF               USART_ICR_CMCF_Msk                        /*!< Character Match Clear Flag */
8376 #define USART_ICR_WUCF_Pos           (20U)
8377 #define USART_ICR_WUCF_Msk           (0x1UL << USART_ICR_WUCF_Pos)             /*!< 0x00100000 */
8378 #define USART_ICR_WUCF               USART_ICR_WUCF_Msk                        /*!< Wake Up from stop mode Clear Flag */
8379 
8380 /*******************  Bit definition for USART_RDR register  ******************/
8381 #define USART_RDR_RDR_Pos             (0U)
8382 #define USART_RDR_RDR_Msk             (0x1FFUL << USART_RDR_RDR_Pos)           /*!< 0x000001FF */
8383 #define USART_RDR_RDR                 USART_RDR_RDR_Msk                        /*!< RDR[8:0] bits (Receive Data value) */
8384 
8385 /*******************  Bit definition for USART_TDR register  ******************/
8386 #define USART_TDR_TDR_Pos             (0U)
8387 #define USART_TDR_TDR_Msk             (0x1FFUL << USART_TDR_TDR_Pos)           /*!< 0x000001FF */
8388 #define USART_TDR_TDR                 USART_TDR_TDR_Msk                        /*!< TDR[8:0] bits (Transmit Data value) */
8389 
8390 /*******************  Bit definition for USART_PRESC register  ****************/
8391 #define USART_PRESC_PRESCALER_Pos    (0U)
8392 #define USART_PRESC_PRESCALER_Msk    (0xFUL << USART_PRESC_PRESCALER_Pos)      /*!< 0x0000000F */
8393 #define USART_PRESC_PRESCALER        USART_PRESC_PRESCALER_Msk                 /*!< PRESCALER[3:0] bits (Clock prescaler) */
8394 #define USART_PRESC_PRESCALER_0      (0x1UL << USART_PRESC_PRESCALER_Pos)      /*!< 0x00000001 */
8395 #define USART_PRESC_PRESCALER_1      (0x2UL << USART_PRESC_PRESCALER_Pos)      /*!< 0x00000002 */
8396 #define USART_PRESC_PRESCALER_2      (0x4UL << USART_PRESC_PRESCALER_Pos)      /*!< 0x00000004 */
8397 #define USART_PRESC_PRESCALER_3      (0x8UL << USART_PRESC_PRESCALER_Pos)      /*!< 0x00000008 */
8398 
8399 
8400 /******************************************************************************/
8401 /*                                                                            */
8402 /*                            Window WATCHDOG                                 */
8403 /*                                                                            */
8404 /******************************************************************************/
8405 /*******************  Bit definition for WWDG_CR register  ********************/
8406 #define WWDG_CR_T_Pos           (0U)
8407 #define WWDG_CR_T_Msk           (0x7FUL << WWDG_CR_T_Pos)                      /*!< 0x0000007F */
8408 #define WWDG_CR_T               WWDG_CR_T_Msk                                  /*!<T[6:0] bits (7-Bit counter (MSB to LSB)) */
8409 #define WWDG_CR_T_0             (0x01UL << WWDG_CR_T_Pos)                      /*!< 0x00000001 */
8410 #define WWDG_CR_T_1             (0x02UL << WWDG_CR_T_Pos)                      /*!< 0x00000002 */
8411 #define WWDG_CR_T_2             (0x04UL << WWDG_CR_T_Pos)                      /*!< 0x00000004 */
8412 #define WWDG_CR_T_3             (0x08UL << WWDG_CR_T_Pos)                      /*!< 0x00000008 */
8413 #define WWDG_CR_T_4             (0x10UL << WWDG_CR_T_Pos)                      /*!< 0x00000010 */
8414 #define WWDG_CR_T_5             (0x20UL << WWDG_CR_T_Pos)                      /*!< 0x00000020 */
8415 #define WWDG_CR_T_6             (0x40UL << WWDG_CR_T_Pos)                      /*!< 0x00000040 */
8416 
8417 #define WWDG_CR_WDGA_Pos        (7U)
8418 #define WWDG_CR_WDGA_Msk        (0x1UL << WWDG_CR_WDGA_Pos)                    /*!< 0x00000080 */
8419 #define WWDG_CR_WDGA            WWDG_CR_WDGA_Msk                               /*!<Activation bit */
8420 
8421 /*******************  Bit definition for WWDG_CFR register  *******************/
8422 #define WWDG_CFR_W_Pos          (0U)
8423 #define WWDG_CFR_W_Msk          (0x7FUL << WWDG_CFR_W_Pos)                     /*!< 0x0000007F */
8424 #define WWDG_CFR_W              WWDG_CFR_W_Msk                                 /*!<W[6:0] bits (7-bit window value) */
8425 #define WWDG_CFR_W_0            (0x01UL << WWDG_CFR_W_Pos)                     /*!< 0x00000001 */
8426 #define WWDG_CFR_W_1            (0x02UL << WWDG_CFR_W_Pos)                     /*!< 0x00000002 */
8427 #define WWDG_CFR_W_2            (0x04UL << WWDG_CFR_W_Pos)                     /*!< 0x00000004 */
8428 #define WWDG_CFR_W_3            (0x08UL << WWDG_CFR_W_Pos)                     /*!< 0x00000008 */
8429 #define WWDG_CFR_W_4            (0x10UL << WWDG_CFR_W_Pos)                     /*!< 0x00000010 */
8430 #define WWDG_CFR_W_5            (0x20UL << WWDG_CFR_W_Pos)                     /*!< 0x00000020 */
8431 #define WWDG_CFR_W_6            (0x40UL << WWDG_CFR_W_Pos)                     /*!< 0x00000040 */
8432 
8433 #define WWDG_CFR_WDGTB_Pos      (11U)
8434 #define WWDG_CFR_WDGTB_Msk      (0x7UL << WWDG_CFR_WDGTB_Pos)                  /*!< 0x00003800 */
8435 #define WWDG_CFR_WDGTB          WWDG_CFR_WDGTB_Msk                             /*!<WDGTB[2:0] bits (Timer Base) */
8436 #define WWDG_CFR_WDGTB_0        (0x1UL << WWDG_CFR_WDGTB_Pos)                  /*!< 0x00000800 */
8437 #define WWDG_CFR_WDGTB_1        (0x2UL << WWDG_CFR_WDGTB_Pos)                  /*!< 0x00001000 */
8438 #define WWDG_CFR_WDGTB_2        (0x4UL << WWDG_CFR_WDGTB_Pos)                  /*!< 0x00002000 */
8439 
8440 #define WWDG_CFR_EWI_Pos        (9U)
8441 #define WWDG_CFR_EWI_Msk        (0x1UL << WWDG_CFR_EWI_Pos)                    /*!< 0x00000200 */
8442 #define WWDG_CFR_EWI            WWDG_CFR_EWI_Msk                               /*!<Early Wakeup Interrupt */
8443 
8444 /*******************  Bit definition for WWDG_SR register  ********************/
8445 #define WWDG_SR_EWIF_Pos        (0U)
8446 #define WWDG_SR_EWIF_Msk        (0x1UL << WWDG_SR_EWIF_Pos)                    /*!< 0x00000001 */
8447 #define WWDG_SR_EWIF            WWDG_SR_EWIF_Msk                               /*!<Early Wakeup Interrupt Flag */
8448 
8449 /******************************************************************************/
8450 /*                                                                            */
8451 /*                                Debug MCU                                   */
8452 /*                                                                            */
8453 /******************************************************************************/
8454 /********************  Bit definition for DBG_IDCODE register  *************/
8455 #define DBG_IDCODE_DEV_ID_Pos                          (0U)
8456 #define DBG_IDCODE_DEV_ID_Msk                          (0xFFFUL << DBG_IDCODE_DEV_ID_Pos)  /*!< 0x00000FFF */
8457 #define DBG_IDCODE_DEV_ID                              DBG_IDCODE_DEV_ID_Msk
8458 #define DBG_IDCODE_REV_ID_Pos                          (16U)
8459 #define DBG_IDCODE_REV_ID_Msk                          (0xFFFFUL << DBG_IDCODE_REV_ID_Pos) /*!< 0xFFFF0000 */
8460 #define DBG_IDCODE_REV_ID                              DBG_IDCODE_REV_ID_Msk
8461 
8462 /********************  Bit definition for DBG_CR register  *****************/
8463 #define DBG_CR_DBG_STOP_Pos                            (1U)
8464 #define DBG_CR_DBG_STOP_Msk                            (0x1UL << DBG_CR_DBG_STOP_Pos)      /*!< 0x00000002 */
8465 #define DBG_CR_DBG_STOP                                DBG_CR_DBG_STOP_Msk
8466 #define DBG_CR_DBG_STANDBY_Pos                         (2U)
8467 #define DBG_CR_DBG_STANDBY_Msk                         (0x1UL << DBG_CR_DBG_STANDBY_Pos)   /*!< 0x00000004 */
8468 #define DBG_CR_DBG_STANDBY                             DBG_CR_DBG_STANDBY_Msk
8469 
8470 
8471 /********************  Bit definition for DBG_APB_FZ1 register  ***********/
8472 #define DBG_APB_FZ1_DBG_TIM3_STOP_Pos                  (1U)
8473 #define DBG_APB_FZ1_DBG_TIM3_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_TIM3_STOP_Pos) /*!< 0x00000002 */
8474 #define DBG_APB_FZ1_DBG_TIM3_STOP                      DBG_APB_FZ1_DBG_TIM3_STOP_Msk
8475 #define DBG_APB_FZ1_DBG_TIM4_STOP_Pos                  (2U)
8476 #define DBG_APB_FZ1_DBG_TIM4_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_TIM4_STOP_Pos) /*!< 0x00000004 */
8477 #define DBG_APB_FZ1_DBG_TIM4_STOP                      DBG_APB_FZ1_DBG_TIM4_STOP_Msk
8478 #define DBG_APB_FZ1_DBG_TIM6_STOP_Pos                  (4U)
8479 #define DBG_APB_FZ1_DBG_TIM6_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_TIM6_STOP_Pos) /*!< 0x00000010 */
8480 #define DBG_APB_FZ1_DBG_TIM6_STOP                      DBG_APB_FZ1_DBG_TIM6_STOP_Msk
8481 #define DBG_APB_FZ1_DBG_TIM7_STOP_Pos                  (5U)
8482 #define DBG_APB_FZ1_DBG_TIM7_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_TIM7_STOP_Pos) /*!< 0x00000020 */
8483 #define DBG_APB_FZ1_DBG_TIM7_STOP                      DBG_APB_FZ1_DBG_TIM7_STOP_Msk
8484 #define DBG_APB_FZ1_DBG_RTC_STOP_Pos                   (10U)
8485 #define DBG_APB_FZ1_DBG_RTC_STOP_Msk                   (0x1UL << DBG_APB_FZ1_DBG_RTC_STOP_Pos)  /*!< 0x00000400 */
8486 #define DBG_APB_FZ1_DBG_RTC_STOP                       DBG_APB_FZ1_DBG_RTC_STOP_Msk
8487 #define DBG_APB_FZ1_DBG_WWDG_STOP_Pos                  (11U)
8488 #define DBG_APB_FZ1_DBG_WWDG_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_WWDG_STOP_Pos) /*!< 0x00000800 */
8489 #define DBG_APB_FZ1_DBG_WWDG_STOP                      DBG_APB_FZ1_DBG_WWDG_STOP_Msk
8490 #define DBG_APB_FZ1_DBG_IWDG_STOP_Pos                  (12U)
8491 #define DBG_APB_FZ1_DBG_IWDG_STOP_Msk                  (0x1UL << DBG_APB_FZ1_DBG_IWDG_STOP_Pos) /*!< 0x00001000 */
8492 #define DBG_APB_FZ1_DBG_IWDG_STOP                      DBG_APB_FZ1_DBG_IWDG_STOP_Msk
8493 #define DBG_APB_FZ1_DBG_I2C1_SMBUS_TIMEOUT_STOP_Pos    (21U)
8494 #define DBG_APB_FZ1_DBG_I2C1_SMBUS_TIMEOUT_STOP_Msk    (0x1UL << DBG_APB_FZ1_DBG_I2C1_SMBUS_TIMEOUT_STOP_Pos) /*!< 0x00200000 */
8495 #define DBG_APB_FZ1_DBG_I2C1_SMBUS_TIMEOUT_STOP        DBG_APB_FZ1_DBG_I2C1_SMBUS_TIMEOUT_STOP_Msk
8496 #define DBG_APB_FZ1_DBG_I2C2_SMBUS_TIMEOUT_STOP_Pos    (22U)
8497 #define DBG_APB_FZ1_DBG_I2C2_SMBUS_TIMEOUT_STOP_Msk    (0x1UL << DBG_APB_FZ1_DBG_I2C2_SMBUS_TIMEOUT_STOP_Pos) /*!< 0x00400000 */
8498 #define DBG_APB_FZ1_DBG_I2C2_SMBUS_TIMEOUT_STOP        DBG_APB_FZ1_DBG_I2C2_SMBUS_TIMEOUT_STOP_Msk
8499 
8500 /********************  Bit definition for DBG_APB_FZ2 register  ************/
8501 #define DBG_APB_FZ2_DBG_TIM1_STOP_Pos                  (11U)
8502 #define DBG_APB_FZ2_DBG_TIM1_STOP_Msk                  (0x1UL << DBG_APB_FZ2_DBG_TIM1_STOP_Pos)  /*!< 0x00000800 */
8503 #define DBG_APB_FZ2_DBG_TIM1_STOP                      DBG_APB_FZ2_DBG_TIM1_STOP_Msk
8504 #define DBG_APB_FZ2_DBG_TIM14_STOP_Pos                 (15U)
8505 #define DBG_APB_FZ2_DBG_TIM14_STOP_Msk                 (0x1UL << DBG_APB_FZ2_DBG_TIM14_STOP_Pos) /*!< 0x00008000 */
8506 #define DBG_APB_FZ2_DBG_TIM14_STOP                     DBG_APB_FZ2_DBG_TIM14_STOP_Msk
8507 #define DBG_APB_FZ2_DBG_TIM15_STOP_Pos                 (16U)
8508 #define DBG_APB_FZ2_DBG_TIM15_STOP_Msk                 (0x1UL << DBG_APB_FZ2_DBG_TIM15_STOP_Pos) /*!< 0x00010000 */
8509 #define DBG_APB_FZ2_DBG_TIM15_STOP                     DBG_APB_FZ2_DBG_TIM15_STOP_Msk
8510 #define DBG_APB_FZ2_DBG_TIM16_STOP_Pos                 (17U)
8511 #define DBG_APB_FZ2_DBG_TIM16_STOP_Msk                 (0x1UL << DBG_APB_FZ2_DBG_TIM16_STOP_Pos) /*!< 0x00020000 */
8512 #define DBG_APB_FZ2_DBG_TIM16_STOP                     DBG_APB_FZ2_DBG_TIM16_STOP_Msk
8513 #define DBG_APB_FZ2_DBG_TIM17_STOP_Pos                 (18U)
8514 #define DBG_APB_FZ2_DBG_TIM17_STOP_Msk                 (0x1UL << DBG_APB_FZ2_DBG_TIM17_STOP_Pos) /*!< 0x00040000 */
8515 #define DBG_APB_FZ2_DBG_TIM17_STOP                     DBG_APB_FZ2_DBG_TIM17_STOP_Msk
8516 
8517 /******************************************************************************/
8518 /*                                                                            */
8519 /*                         USB Dual Role Device FS Endpoint registers         */
8520 /*                                                                            */
8521 /******************************************************************************/
8522 
8523 /******************  Bits definition for USB_DRD_CNTR register  *******************/
8524 #define USB_CNTR_HOST_Pos               (31U)
8525 #define USB_CNTR_HOST_Msk               (0x1UL << USB_CNTR_HOST_Pos)    /*!< 0x80000000 */
8526 #define USB_CNTR_HOST                   USB_CNTR_HOST_Msk               /*!< Host Mode  */
8527 #define USB_CNTR_THR512M_Pos            (16U)
8528 #define USB_CNTR_THR512M_Msk            (0x1UL << USB_CNTR_THR512M_Pos)  /*!< 0x00010000 */
8529 #define USB_CNTR_THR512M                USB_CNTR_THR512M_Msk             /*!< 512byte Threshold interrupt mask */
8530 #define USB_CNTR_CTRM_Pos               (15U)
8531 #define USB_CNTR_CTRM_Msk               (0x1UL << USB_CNTR_CTRM_Pos)    /*!< 0x00008000 */
8532 #define USB_CNTR_CTRM                   USB_CNTR_CTRM_Msk               /*!< Correct Transfer Mask */
8533 #define USB_CNTR_PMAOVRM_Pos            (14U)
8534 #define USB_CNTR_PMAOVRM_Msk            (0x1UL << USB_CNTR_PMAOVRM_Pos) /*!< 0x00004000 */
8535 #define USB_CNTR_PMAOVRM                USB_CNTR_PMAOVRM_Msk            /*!< DMA OVeR/underrun Mask */
8536 #define USB_CNTR_ERRM_Pos               (13U)
8537 #define USB_CNTR_ERRM_Msk               (0x1UL << USB_CNTR_ERRM_Pos)    /*!< 0x00002000 */
8538 #define USB_CNTR_ERRM                   USB_CNTR_ERRM_Msk               /*!< ERRor Mask */
8539 #define USB_CNTR_WKUPM_Pos              (12U)
8540 #define USB_CNTR_WKUPM_Msk              (0x1UL << USB_CNTR_WKUPM_Pos)   /*!< 0x00001000 */
8541 #define USB_CNTR_WKUPM                  USB_CNTR_WKUPM_Msk              /*!< WaKe UP Mask */
8542 #define USB_CNTR_SUSPM_Pos              (11U)
8543 #define USB_CNTR_SUSPM_Msk              (0x1UL << USB_CNTR_SUSPM_Pos)   /*!< 0x00000800 */
8544 #define USB_CNTR_SUSPM                  USB_CNTR_SUSPM_Msk              /*!< SUSPend Mask */
8545 #define USB_CNTR_RESETM_Pos             (10U)
8546 #define USB_CNTR_RESETM_Msk             (0x1UL << USB_CNTR_RESETM_Pos)  /*!< 0x00000400 */
8547 #define USB_CNTR_RESETM                 USB_CNTR_RESETM_Msk             /*!< RESET Mask */
8548 #define USB_CNTR_DCON                   USB_CNTR_RESETM_Msk             /*!< Disconnection Connection Mask */
8549 #define USB_CNTR_SOFM_Pos               (9U)
8550 #define USB_CNTR_SOFM_Msk               (0x1UL << USB_CNTR_SOFM_Pos)    /*!< 0x00000200 */
8551 #define USB_CNTR_SOFM                   USB_CNTR_SOFM_Msk               /*!< Start Of Frame Mask */
8552 #define USB_CNTR_ESOFM_Pos              (8U)
8553 #define USB_CNTR_ESOFM_Msk              (0x1UL << USB_CNTR_ESOFM_Pos)   /*!< 0x00000100 */
8554 #define USB_CNTR_ESOFM                  USB_CNTR_ESOFM_Msk              /*!< Expected Start Of Frame Mask */
8555 #define USB_CNTR_L1REQM_Pos             (7U)
8556 #define USB_CNTR_L1REQM_Msk             (0x1UL << USB_CNTR_L1REQM_Pos)  /*!< 0x00000080 */
8557 #define USB_CNTR_L1REQM                 USB_CNTR_L1REQM_Msk             /*!< LPM L1 state request interrupt Mask */
8558 #define USB_CNTR_L1XACT_Pos             (6U)
8559 #define USB_CNTR_L1XACT_Msk             (0x1UL << USB_CNTR_L1XACT_Pos)  /*!< 0x00000040 */
8560 #define USB_CNTR_L1XACT                 USB_CNTR_L1XACT_Msk             /*!< Host LPM L1 transaction request Mask */
8561 #define USB_CNTR_L1RES_Pos              (5U)
8562 #define USB_CNTR_L1RES_Msk              (0x1UL << USB_CNTR_L1RES_Pos)   /*!< 0x00000020 */
8563 #define USB_CNTR_L1RES                  USB_CNTR_L1RES_Msk              /*!< LPM L1 Resume request/ Remote Wakeup Mask */
8564 #define USB_CNTR_L2RES_Pos              (4U)
8565 #define USB_CNTR_L2RES_Msk              (0x1UL << USB_CNTR_L2RES_Pos)   /*!< 0x00000010 */
8566 #define USB_CNTR_L2RES                  USB_CNTR_L2RES_Msk              /*!< L2 Remote Wakeup / Resume driver Mask */
8567 #define USB_CNTR_SUSPEN_Pos             (3U)
8568 #define USB_CNTR_SUSPEN_Msk             (0x1UL << USB_CNTR_SUSPEN_Pos)  /*!< 0x00000008 */
8569 #define USB_CNTR_SUSPEN                 USB_CNTR_SUSPEN_Msk             /*!< Suspend state enable Mask */
8570 #define USB_CNTR_SUSPRDY_Pos            (2U)
8571 #define USB_CNTR_SUSPRDY_Msk            (0x1UL << USB_CNTR_SUSPRDY_Pos) /*!< 0x00000004 */
8572 #define USB_CNTR_SUSPRDY                USB_CNTR_SUSPRDY_Msk            /*!< Suspend state effective Mask */
8573 #define USB_CNTR_PDWN_Pos               (1U)
8574 #define USB_CNTR_PDWN_Msk               (0x1UL << USB_CNTR_PDWN_Pos)    /*!< 0x00000002 */
8575 #define USB_CNTR_PDWN                   USB_CNTR_PDWN_Msk               /*!< Power DoWN Mask */
8576 #define USB_CNTR_USBRST_Pos             (0U)
8577 #define USB_CNTR_USBRST_Msk             (0x1UL << USB_CNTR_USBRST_Pos)  /*!< 0x00000001 */
8578 #define USB_CNTR_USBRST                 USB_CNTR_USBRST_Msk             /*!< USB Reset Mask */
8579 
8580 /******************  Bits definition for USB_DRD_ISTR register  *******************/
8581 #define USB_ISTR_IDN_Pos                (0U)
8582 #define USB_ISTR_IDN_Msk                (0xFUL << USB_ISTR_IDN_Pos)     /*!< 0x0000000F */
8583 #define USB_ISTR_IDN                    USB_ISTR_IDN_Msk                /*!< EndPoint IDentifier (read-only bit) Mask */
8584 #define USB_ISTR_DIR_Pos                (4U)
8585 #define USB_ISTR_DIR_Msk                (0x1UL << USB_ISTR_DIR_Pos)     /*!< 0x00000010 */
8586 #define USB_ISTR_DIR                    USB_ISTR_DIR_Msk                /*!< DIRection of transaction (read-only bit) Mask */
8587 #define USB_ISTR_L1REQ_Pos              (7U)
8588 #define USB_ISTR_L1REQ_Msk              (0x1UL << USB_ISTR_L1REQ_Pos)   /*!< 0x00000080 */
8589 #define USB_ISTR_L1REQ                  USB_ISTR_L1REQ_Msk              /*!< LPM L1 state request Mask */
8590 #define USB_ISTR_ESOF_Pos               (8U)
8591 #define USB_ISTR_ESOF_Msk               (0x1UL << USB_ISTR_ESOF_Pos)    /*!< 0x00000100 */
8592 #define USB_ISTR_ESOF                   USB_ISTR_ESOF_Msk               /*!< Expected Start Of Frame (clear-only bit) Mask */
8593 #define USB_ISTR_SOF_Pos                (9U)
8594 #define USB_ISTR_SOF_Msk                (0x1UL << USB_ISTR_SOF_Pos)     /*!< 0x00000200 */
8595 #define USB_ISTR_SOF                    USB_ISTR_SOF_Msk                /*!< Start Of Frame (clear-only bit) Mask */
8596 #define USB_ISTR_RESET_Pos              (10U)
8597 #define USB_ISTR_RESET_Msk              (0x1UL << USB_ISTR_RESET_Pos)   /*!< 0x00000400 */
8598 #define USB_ISTR_RESET                  USB_ISTR_RESET_Msk              /*!< RESET Mask */
8599 #define USB_ISTR_DCON_Pos               (10U)
8600 #define USB_ISTR_DCON_Msk               (0x1UL << USB_ISTR_DCON_Pos)    /*!< 0x00000400 */
8601 #define USB_ISTR_DCON                   USB_ISTR_DCON_Msk               /*!< HOST MODE-Device Connection or disconnection Mask */
8602 #define USB_ISTR_SUSP_Pos               (11U)
8603 #define USB_ISTR_SUSP_Msk               (0x1UL << USB_ISTR_SUSP_Pos)    /*!< 0x00000800 */
8604 #define USB_ISTR_SUSP                   USB_ISTR_SUSP_Msk               /*!< SUSPend (clear-only bit) Mask */
8605 #define USB_ISTR_WKUP_Pos               (12U)
8606 #define USB_ISTR_WKUP_Msk               (0x1UL << USB_ISTR_WKUP_Pos)    /*!< 0x00001000 */
8607 #define USB_ISTR_WKUP                   USB_ISTR_WKUP_Msk               /*!< WaKe UP (clear-only bit) Mask */
8608 #define USB_ISTR_ERR_Pos                (13U)
8609 #define USB_ISTR_ERR_Msk                (0x1UL << USB_ISTR_ERR_Pos)     /*!< 0x00002000 */
8610 #define USB_ISTR_ERR                    USB_ISTR_ERR_Msk                /*!< ERRor (clear-only bit) Mask */
8611 #define USB_ISTR_PMAOVR_Pos             (14U)
8612 #define USB_ISTR_PMAOVR_Msk             (0x1UL << USB_ISTR_PMAOVR_Pos)  /*!< 0x00004000 */
8613 #define USB_ISTR_PMAOVR                 USB_ISTR_PMAOVR_Msk             /*!< PMA OVeR/underrun (clear-only bit) Mask */
8614 #define USB_ISTR_CTR_Pos                (15U)
8615 #define USB_ISTR_CTR_Msk                (0x1UL << USB_ISTR_CTR_Pos)     /*!< 0x00008000 */
8616 #define USB_ISTR_CTR                    USB_ISTR_CTR_Msk                /*!< Correct TRansfer (clear-only bit) Mask */
8617 #define USB_ISTR_THR512_Pos             (16U)
8618 #define USB_ISTR_THR512_Msk             (0x1UL << USB_ISTR_THR512_Pos)  /*!< 0x00010000 */
8619 #define USB_ISTR_THR512                 USB_ISTR_THR512_Msk             /*!< 512byte threshold interrupt (used with isochrnous single buffer ) */
8620 #define USB_ISTR_DCON_STAT_Pos          (29U)
8621 #define USB_ISTR_DCON_STAT_Msk          (0x1UL << USB_ISTR_DCON_STAT_Pos)/*!< 0x20000000 */
8622 #define USB_ISTR_DCON_STAT              USB_ISTR_DCON_STAT_Msk           /*!< Device Connection status (connected/Disconnected) don't cause an interrupt */
8623 #define USB_ISTR_LS_DCONN_Pos           (30U)
8624 #define USB_ISTR_LS_DCONN_Msk           (0x1UL << USB_ISTR_LS_DCONN_Pos)/*!< 0x40000000 */
8625 #define USB_ISTR_LS_DCONN               USB_ISTR_LS_DCONN_Msk           /*!< LS_DCONN Mask */
8626 
8627 /******************  Bits definition for USB_DRD_FNR register  ********************/
8628 #define USB_FNR_FN_Pos                  (0U)
8629 #define USB_FNR_FN_Msk                  (0x7FFUL << USB_FNR_FN_Pos)     /*!< 0x000007FF */
8630 #define USB_FNR_FN                      USB_FNR_FN_Msk                  /*!< Frame Number Mask */
8631 #define USB_FNR_LSOF_Pos                (11U)
8632 #define USB_FNR_LSOF_Msk                (0x3UL << USB_FNR_LSOF_Pos)     /*!< 0x00001800 */
8633 #define USB_FNR_LSOF                    USB_FNR_LSOF_Msk                /*!< Lost SOF  Mask */
8634 #define USB_FNR_LCK_Pos                 (13U)
8635 #define USB_FNR_LCK_Msk                 (0x1UL << USB_FNR_LCK_Pos)      /*!< 0x00002000 */
8636 #define USB_FNR_LCK                     USB_FNR_LCK_Msk                 /*!< LoCKed Mask */
8637 #define USB_FNR_RXDM_Pos                (14U)
8638 #define USB_FNR_RXDM_Msk                (0x1UL << USB_FNR_RXDM_Pos)     /*!< 0x00004000 */
8639 #define USB_FNR_RXDM                    USB_FNR_RXDM_Msk                /*!< status of D- data line Mask */
8640 #define USB_FNR_RXDP_Pos                (15U)
8641 #define USB_FNR_RXDP_Msk                (0x1UL << USB_FNR_RXDP_Pos)     /*!< 0x00008000 */
8642 #define USB_FNR_RXDP                    USB_FNR_RXDP_Msk                /*!< status of D+ data line Mask */
8643 
8644 /******************  Bits definition for USB_DRD_DADDR register    ****************/
8645 #define USB_DADDR_ADD_Pos               (0U)
8646 #define USB_DADDR_ADD_Msk               (0x7FUL << USB_DADDR_ADD_Pos)   /*!< 0x0000007F */
8647 #define USB_DADDR_ADD                   USB_DADDR_ADD_Msk               /*!<  ADD[6:0] bits (Device Address)Mask */
8648 #define USB_DADDR_ADD0_Pos              (0U)
8649 #define USB_DADDR_ADD0_Msk              (0x1UL << USB_DADDR_ADD0_Pos)   /*!< 0x00000001 */
8650 #define USB_DADDR_ADD0                  USB_DADDR_ADD0_Msk              /*!< Bit 0 Mask */
8651 #define USB_DADDR_ADD1_Pos              (1U)
8652 #define USB_DADDR_ADD1_Msk              (0x1UL << USB_DADDR_ADD1_Pos)   /*!< 0x00000002 */
8653 #define USB_DADDR_ADD1                  USB_DADDR_ADD1_Msk              /*!< Bit 1 Mask */
8654 #define USB_DADDR_ADD2_Pos              (2U)
8655 #define USB_DADDR_ADD2_Msk              (0x1UL << USB_DADDR_ADD2_Pos)   /*!< 0x00000004 */
8656 #define USB_DADDR_ADD2                  USB_DADDR_ADD2_Msk              /*!< Bit 2 Mask */
8657 #define USB_DADDR_ADD3_Pos              (3U)
8658 #define USB_DADDR_ADD3_Msk              (0x1UL << USB_DADDR_ADD3_Pos)   /*!< 0x00000008 */
8659 #define USB_DADDR_ADD3                  USB_DADDR_ADD3_Msk              /*!< Bit 3 Mask */
8660 #define USB_DADDR_ADD4_Pos              (4U)
8661 #define USB_DADDR_ADD4_Msk              (0x1UL << USB_DADDR_ADD4_Pos)   /*!< 0x00000010 */
8662 #define USB_DADDR_ADD4                  USB_DADDR_ADD4_Msk              /*!< Bit 4 Mask */
8663 #define USB_DADDR_ADD5_Pos              (5U)
8664 #define USB_DADDR_ADD5_Msk              (0x1UL << USB_DADDR_ADD5_Pos)   /*!< 0x00000020 */
8665 #define USB_DADDR_ADD5                  USB_DADDR_ADD5_Msk              /*!< Bit 5 Mask */
8666 #define USB_DADDR_ADD6_Pos              (6U)
8667 #define USB_DADDR_ADD6_Msk              (0x1UL << USB_DADDR_ADD6_Pos)   /*!< 0x00000040 */
8668 #define USB_DADDR_ADD6                  USB_DADDR_ADD6_Msk              /*!< Bit 6 Mask */
8669 #define USB_DADDR_EF_Pos                (7U)
8670 #define USB_DADDR_EF_Msk                (0x1UL << USB_DADDR_EF_Pos)     /*!< 0x00000080 */
8671 #define USB_DADDR_EF                    USB_DADDR_EF_Msk                /*!< Enable Function Mask */
8672 
8673 /******************  Bit definition for USB_DRD_BTABLE register  ******************/
8674 #define USB_BTABLE_BTABLE_Pos          (3U)
8675 #define USB_BTABLE_BTABLE_Msk          (0xFFF8UL << USB_BTABLE_BTABLE_Pos)/*!< 0x00000000 */
8676 #define USB_BTABLE_BTABLE              USB_BTABLE_BTABLE_Msk              /*!< Buffer Table Mask */
8677 
8678 /*******************  Bit definition for LPMCSR register  *********************/
8679 #define USB_LPMCSR_LMPEN_Pos           (0U)
8680 #define USB_LPMCSR_LMPEN_Msk           (0x1UL << USB_LPMCSR_LMPEN_Pos)  /*!< 0x00000001 */
8681 #define USB_LPMCSR_LMPEN               USB_LPMCSR_LMPEN_Msk             /*!< LPM support enable Mask */
8682 #define USB_LPMCSR_LPMACK_Pos          (1U)
8683 #define USB_LPMCSR_LPMACK_Msk          (0x1UL << USB_LPMCSR_LPMACK_Pos) /*!< 0x00000002 */
8684 #define USB_LPMCSR_LPMACK              USB_LPMCSR_LPMACK_Msk            /*!< LPM Token acknowledge enable Mask */
8685 #define USB_LPMCSR_REMWAKE_Pos         (3U)
8686 #define USB_LPMCSR_REMWAKE_Msk         (0x1UL << USB_LPMCSR_REMWAKE_Pos)/*!< 0x00000008 */
8687 #define USB_LPMCSR_REMWAKE             USB_LPMCSR_REMWAKE_Msk           /*!< bRemoteWake value received with last ACKed LPM Token Mask */
8688 #define USB_LPMCSR_BESL_Pos            (4U)
8689 #define USB_LPMCSR_BESL_Msk            (0xFUL << USB_LPMCSR_BESL_Pos)   /*!< 0x000000F0 */
8690 #define USB_LPMCSR_BESL                USB_LPMCSR_BESL_Msk              /*!< BESL value received with last ACKed LPM Token Mask */
8691 
8692 /******************  Bits definition for USB_DRD_BCDR register  *******************/
8693 #define USB_BCDR_BCDEN_Pos             (0U)
8694 #define USB_BCDR_BCDEN_Msk             (0x1UL << USB_BCDR_BCDEN_Pos)    /*!< 0x00000001 */
8695 #define USB_BCDR_BCDEN                 USB_BCDR_BCDEN_Msk               /*!< Battery charging detector (BCD) enable Mask */
8696 #define USB_BCDR_DCDEN_Pos             (1U)
8697 #define USB_BCDR_DCDEN_Msk             (0x1UL << USB_BCDR_DCDEN_Pos)    /*!< 0x00000002 */
8698 #define USB_BCDR_DCDEN                 USB_BCDR_DCDEN_Msk               /*!< Data contact detection (DCD) mode enable Mask */
8699 #define USB_BCDR_PDEN_Pos              (2U)
8700 #define USB_BCDR_PDEN_Msk              (0x1UL << USB_BCDR_PDEN_Pos)     /*!< 0x00000004 */
8701 #define USB_BCDR_PDEN                  USB_BCDR_PDEN_Msk                /*!< Primary detection (PD) mode enable Mask */
8702 #define USB_BCDR_SDEN_Pos              (3U)
8703 #define USB_BCDR_SDEN_Msk              (0x1UL << USB_BCDR_SDEN_Pos)     /*!< 0x00000008 */
8704 #define USB_BCDR_SDEN                  USB_BCDR_SDEN_Msk                /*!< Secondary detection (SD) mode enable Mask */
8705 #define USB_BCDR_DCDET_Pos             (4U)
8706 #define USB_BCDR_DCDET_Msk             (0x1UL << USB_BCDR_DCDET_Pos)    /*!< 0x00000010 */
8707 #define USB_BCDR_DCDET                 USB_BCDR_DCDET_Msk               /*!< Data contact detection (DCD) status Mask */
8708 #define USB_BCDR_PDET_Pos              (5U)
8709 #define USB_BCDR_PDET_Msk              (0x1UL << USB_BCDR_PDET_Pos)     /*!< 0x00000020 */
8710 #define USB_BCDR_PDET                  USB_BCDR_PDET_Msk                /*!< Primary detection (PD) status Mask */
8711 #define USB_BCDR_SDET_Pos              (6U)
8712 #define USB_BCDR_SDET_Msk              (0x1UL << USB_BCDR_SDET_Pos)     /*!< 0x00000040 */
8713 #define USB_BCDR_SDET                  USB_BCDR_SDET_Msk                /*!< Secondary detection (SD) status Mask */
8714 #define USB_BCDR_PS2DET_Pos            (7U)
8715 #define USB_BCDR_PS2DET_Msk            (0x1UL << USB_BCDR_PS2DET_Pos)   /*!< 0x00000080 */
8716 #define USB_BCDR_PS2DET                USB_BCDR_PS2DET_Msk              /*!< PS2 port or proprietary charger detected Mask */
8717 #define USB_BCDR_DPPU_Pos              (15U)
8718 #define USB_BCDR_DPPU_Msk              (0x1UL << USB_BCDR_DPPU_Pos)     /*!< 0x00008000 */
8719 #define USB_BCDR_DPPU                  USB_BCDR_DPPU_Msk                /*!< DP Pull-up Enable Mask */
8720 #define USB_BCDR_DPPD_Pos              (15U)
8721 #define USB_BCDR_DPPD_Msk              (0x1UL << USB_BCDR_DPPD_Pos)     /*!< 0x00008000 */
8722 #define USB_BCDR_DPPD                  USB_BCDR_DPPD_Msk                /*!< DP Pull-Down Enable Mask */
8723 
8724 /******************  Bits definition for USB_DRD_CHEP register  *******************/
8725 #define USB_CHEP_ERRRX_Pos             (26U)
8726 #define USB_CHEP_ERRRX_Msk             (0x01UL << USB_CHEP_ERRRX_Pos)   /*!< 0x04000000 */
8727 #define USB_CHEP_ERRRX                 USB_CHEP_ERRRX_Msk               /*!< Receive error */
8728 #define USB_EP_ERRRX                   USB_CHEP_ERRRX_Msk               /*!< EP Receive error */
8729 #define USB_CH_ERRRX                   USB_CHEP_ERRRX_Msk               /*!< CH Receive error */
8730 #define USB_CHEP_ERRTX_Pos             (25U)
8731 #define USB_CHEP_ERRTX_Msk             (0x01UL << USB_CHEP_ERRTX_Pos)   /*!< 0x02000000 */
8732 #define USB_CHEP_ERRTX                 USB_CHEP_ERRTX_Msk               /*!< Transmit error */
8733 #define USB_EP_ERRTX                   USB_CHEP_ERRTX_Msk               /*!< EP Transmit error */
8734 #define USB_CH_ERRTX                   USB_CHEP_ERRTX_Msk               /*!< CH Transmit error */
8735 #define USB_CHEP_LSEP_Pos              (24U)
8736 #define USB_CHEP_LSEP_Msk              (0x01UL << USB_CHEP_LSEP_Pos)    /*!< 0x01000000 */
8737 #define USB_CHEP_LSEP                  USB_CHEP_LSEP_Msk                /*!< Low Speed Endpoint (host with Hub Only) */
8738 #define USB_CHEP_NAK_Pos               (23U)
8739 #define USB_CHEP_NAK_Msk               (0x01UL << USB_CHEP_NAK_Pos)     /*!< 0x00800000 */
8740 #define USB_CHEP_NAK                   USB_CHEP_NAK_Msk                 /*!< Previous NAK detected */
8741 #define USB_CHEP_DEVADDR_Pos           (16U)
8742 #define USB_CHEP_DEVADDR_Msk           (0x7FU << USB_CHEP_DEVADDR_Pos)  /*!< 0x7F000000 */
8743 #define USB_CHEP_DEVADDR               USB_CHEP_DEVADDR_Msk             /* Target Endpoint address*/
8744 #define USB_CHEP_VTRX_Pos              (15U)
8745 #define USB_CHEP_VTRX_Msk              (0x1UL << USB_CHEP_VTRX_Pos)     /*!< 0x00008000 */
8746 #define USB_CHEP_VTRX                  USB_CHEP_VTRX_Msk                /*!< USB valid transaction received Mask */
8747 #define USB_EP_VTRX                    USB_CHEP_VTRX_Msk                /*!< USB Endpoint valid transaction received Mask */
8748 #define USB_CH_VTRX                    USB_CHEP_VTRX_Msk                /*!< USB valid Channel transaction received Mask */
8749 #define USB_CHEP_DTOG_RX_Pos           (14U)
8750 #define USB_CHEP_DTOG_RX_Msk           (0x1UL << USB_CHEP_DTOG_RX_Pos)  /*!< 0x00004000 */
8751 #define USB_CHEP_DTOG_RX               USB_CHEP_DTOG_RX_Msk             /*!< Data Toggle, for reception transfers Mask */
8752 #define USB_EP_DTOG_RX                 USB_CHEP_DTOG_RX_Msk             /*!< EP Data Toggle, for reception transfers Mask */
8753 #define USB_CH_DTOG_RX                 USB_CHEP_DTOG_RX_Msk             /*!< CH Data Toggle, for reception transfers Mask */
8754 #define USB_CHEP_RX_STRX_Pos           (12U)
8755 #define USB_CHEP_RX_STRX_Msk           (0x3UL << USB_CHEP_RX_STRX_Pos)  /*!< 0x00003000 */
8756 #define USB_CHEP_RX_STRX               USB_CHEP_RX_STRX_Msk             /*!< Status bits, for reception transfers Mask */
8757 #define USB_EP_RX_STRX                 USB_CHEP_RX_STRX_Msk             /*!< Status bits, for EP reception transfers Mask */
8758 #define USB_CH_RX_STRX                 USB_CHEP_RX_STRX_Msk             /*!< Status bits, for CH reception transfers Mask */
8759 #define USB_CHEP_SETUP_Pos             (11U)
8760 #define USB_CHEP_SETUP_Msk             (0x1UL << USB_CHEP_SETUP_Pos)    /*!< 0x00000800 */
8761 #define USB_CHEP_SETUP                 USB_CHEP_SETUP_Msk               /*!< Setup transaction completed Mask */
8762 #define USB_EP_SETUP                   USB_CHEP_SETUP_Msk               /*!< EP Setup transaction completed Mask */
8763 #define USB_CH_SETUP                   USB_CHEP_SETUP_Msk               /*!< CH Setup transaction completed Mask */
8764 #define USB_CHEP_UTYPE_Pos             (9U)
8765 #define USB_CHEP_UTYPE_Msk             (0x3UL << USB_CHEP_UTYPE_Pos)    /*!< 0x00000600 */
8766 #define USB_CHEP_UTYPE                 USB_CHEP_UTYPE_Msk               /*!< USB type of transaction Mask */
8767 #define USB_EP_UTYPE                   USB_CHEP_UTYPE_Msk               /*!< USB type of EP transaction Mask */
8768 #define USB_CH_UTYPE                   USB_CHEP_UTYPE_Msk               /*!< USB type of CH transaction Mask */
8769 #define USB_CHEP_KIND_Pos              (8U)
8770 #define USB_CHEP_KIND_Msk              (0x1UL << USB_CHEP_KIND_Pos)     /*!< 0x00000100 */
8771 #define USB_CHEP_KIND                  USB_CHEP_KIND_Msk                /*!< EndPoint KIND Mask */
8772 #define USB_EP_KIND                    USB_CHEP_KIND_Msk                /*!< EndPoint KIND Mask */
8773 #define USB_CH_KIND                    USB_CHEP_KIND_Msk                /*!< Channel KIND Mask */
8774 #define USB_CHEP_VTTX_Pos              (7U)
8775 #define USB_CHEP_VTTX_Msk              (0x1UL << USB_CHEP_VTTX_Pos)     /*!< 0x00000080 */
8776 #define USB_CHEP_VTTX                  USB_CHEP_VTTX_Msk                /*!< Valid USB transaction transmitted Mask */
8777 #define USB_EP_VTTX                    USB_CHEP_VTTX_Msk                /*!< USB Endpoint valid transaction transmitted Mask */
8778 #define USB_CH_VTTX                    USB_CHEP_VTTX_Msk                /*!< USB valid Channel transaction transmitted Mask */
8779 #define USB_CHEP_DTOG_TX_Pos           (6U)
8780 #define USB_CHEP_DTOG_TX_Msk           (0x1UL << USB_CHEP_DTOG_TX_Pos)  /*!< 0x00000040 */
8781 #define USB_CHEP_DTOG_TX               USB_CHEP_DTOG_TX_Msk             /*!< Data Toggle, for transmission transfers Mask */
8782 #define USB_EP_DTOG_TX                 USB_CHEP_DTOG_TX_Msk             /*!< EP Data Toggle, for transmission transfers Mask */
8783 #define USB_CH_DTOG_TX                 USB_CHEP_DTOG_TX_Msk             /*!< CH Data Toggle, for transmission transfers Mask */
8784 #define USB_CHEP_TX_STTX_Pos           (4U)
8785 #define USB_CHEP_TX_STTX_Msk           (0x3UL << USB_CHEP_TX_STTX_Pos)  /*!< 0x00000030 */
8786 #define USB_CHEP_TX_STTX               USB_CHEP_TX_STTX_Msk             /*!< Status bits, for transmission transfers Mask */
8787 #define USB_EP_TX_STTX                 USB_CHEP_TX_STTX_Msk             /*!< Status bits, for EP transmission transfers Mask */
8788 #define USB_CH_TX_STTX                 USB_CHEP_TX_STTX_Msk             /*!< Status bits, for CH transmission transfers Mask */
8789 #define USB_CHEP_ADDR_Pos              (0U)
8790 #define USB_CHEP_ADDR_Msk              (0xFUL << USB_CHEP_ADDR_Pos)     /*!< 0x0000000F */
8791 #define USB_CHEP_ADDR                  USB_CHEP_ADDR_Msk                /*!< Endpoint address Mask */
8792 
8793 
8794 /* EndPoint Register MASK (no toggle fields) */
8795 #define USB_CHEP_REG_MASK                          (USB_CHEP_ERRRX | USB_CHEP_ERRTX | USB_CHEP_LSEP | \
8796                                                     USB_CHEP_DEVADDR | USB_CHEP_VTRX | USB_CHEP_SETUP | \
8797                                                     USB_CHEP_UTYPE | USB_CHEP_KIND | USB_CHEP_VTTX | USB_CHEP_ADDR |\
8798                                                     USB_CHEP_NAK) /* 0x07FF8F8F */
8799 
8800 #define USB_CHEP_TX_DTOGMASK                       (USB_CHEP_TX_STTX | USB_CHEP_REG_MASK)
8801 #define USB_CHEP_RX_DTOGMASK                       (USB_CHEP_RX_STRX | USB_CHEP_REG_MASK)
8802 
8803 #define USB_CHEP_TX_DTOG1                          (0x00000010UL)           /*!< Channel/EndPoint TX Data Toggle bit1 */
8804 #define USB_CHEP_TX_DTOG2                          (0x00000020UL)           /*!< Channel/EndPoint TX Data Toggle bit2 */
8805 #define USB_CHEP_RX_DTOG1                          (0x00001000UL)           /*!< Channel/EndPoint RX Data Toggle bit1 */
8806 #define USB_CHEP_RX_DTOG2                          (0x00002000UL)           /*!< Channel/EndPoint RX Data Toggle bit1 */
8807 
8808 /*!< EP_TYPE[1:0] Channel/EndPoint TYPE */
8809 #define USB_EP_TYPE_MASK                           (0x00000600UL)           /*!< Channel/EndPoint TYPE Mask */
8810 #define USB_EP_BULK                                (0x00000000UL)           /*!< Channel/EndPoint BULK */
8811 #define USB_EP_CONTROL                             (0x00000200UL)           /*!< Channel/EndPoint CONTROL */
8812 #define USB_EP_ISOCHRONOUS                         (0x00000400UL)           /*!< Channel/EndPoint ISOCHRONOUS */
8813 #define USB_EP_INTERRUPT                           (0x00000600UL)           /*!< Channel/EndPoint INTERRUPT */
8814 
8815 #define USB_EP_T_MASK                              ((~USB_EP_UTYPE) & USB_CHEP_REG_MASK) /* =0x898F */
8816 #define USB_CH_T_MASK                              ((~USB_CH_UTYPE) & USB_CHEP_REG_MASK) /* =0x898F */
8817 
8818 #define USB_EP_KIND_MASK                           ((~USB_EP_KIND) & USB_CHEP_REG_MASK) /*!< EP_KIND EndPoint KIND */
8819 #define USB_CH_KIND_MASK                           ((~USB_CH_KIND) & USB_CHEP_REG_MASK) /*!< EP_KIND EndPoint KIND */
8820 
8821 /*!< STAT_TX[1:0] STATus for TX transfer */
8822 #define USB_EP_TX_DIS                              (0x00000000UL)           /*!< EndPoint TX Disabled */
8823 #define USB_EP_TX_STALL                            (0x00000010UL)           /*!< EndPoint TX STALLed */
8824 #define USB_EP_TX_NAK                              (0x00000020UL)           /*!< EndPoint TX NAKed */
8825 #define USB_EP_TX_VALID                            (0x00000030UL)           /*!< EndPoint TX VALID */
8826 
8827 #define USB_CH_TX_DIS                              (0x00000000UL)           /*!< Channel TX Disabled */
8828 #define USB_CH_TX_STALL                            (0x00000010UL)           /*!< Channel TX STALLed */
8829 #define USB_CH_TX_NAK                              (0x00000020UL)           /*!< Channel TX NAKed */
8830 #define USB_CH_TX_VALID                            (0x00000030UL)           /*!< Channel TX VALID */
8831 
8832 #define USB_EP_TX_ACK_SBUF                         (0x00000000UL)           /*!< ACK single buffer mode */
8833 #define USB_EP_TX_ACK_DBUF                         (0x00000030UL)           /*!< ACK Double buffer mode */
8834 
8835 #define USB_CH_TX_ACK_SBUF                         (0x00000000UL)           /*!< ACK single buffer mode */
8836 #define USB_CH_TX_ACK_DBUF                         (0x00000030UL)           /*!< ACK Double buffer mode */
8837 
8838 /*!< STAT_RX[1:0] STATus for RX transfer */
8839 #define USB_EP_RX_DIS                              (0x00000000UL)           /*!< EndPoint RX Disabled */
8840 #define USB_EP_RX_STALL                            (0x00001000UL)           /*!< EndPoint RX STALLed */
8841 #define USB_EP_RX_NAK                              (0x00002000UL)           /*!< EndPoint RX NAKed */
8842 #define USB_EP_RX_VALID                            (0x00003000UL)           /*!< EndPoint RX VALID */
8843 
8844 #define USB_EP_RX_ACK_SBUF                         (0x00000000UL)           /*!< ACK single buffer mode */
8845 #define USB_EP_RX_ACK_DBUF                         (0x00003000UL)           /*!< ACK Double buffer mode */
8846 
8847 
8848 
8849 #define USB_CH_RX_DIS                              (0x00000000UL)           /*!< EndPoint RX Disabled */
8850 #define USB_CH_RX_STALL                            (0x00001000UL)           /*!< EndPoint RX STALLed */
8851 #define USB_CH_RX_NAK                              (0x00002000UL)           /*!< Channel RX NAKed */
8852 #define USB_CH_RX_VALID                            (0x00003000UL)           /*!< Channel RX VALID */
8853 
8854 #define USB_CH_RX_ACK_SBUF                         (0x00000000UL)           /*!< ACK single buffer mode */
8855 #define USB_CH_RX_ACK_DBUF                         (0x00003000UL)           /*!< ACK Double buffer mode */
8856 
8857 /*! <used For Double Buffer Enable Disable */
8858 #define USB_CHEP_DB_MSK                            (0xFFFF0F0FUL)
8859 
8860 /*Buffer Descriptor Mask*/
8861 #define USB_PMA_TXBD_ADDMSK                        (0xFFFF0000UL)
8862 #define USB_PMA_TXBD_COUNTMSK                      (0x0000FFFFUL)
8863 #define USB_PMA_RXBD_ADDMSK                        (0xFFFF0000UL)
8864 #define USB_PMA_RXBD_COUNTMSK                      (0x0000FFFFUL)
8865 
8866 
8867 /** @addtogroup Exported_macros
8868   * @{
8869   */
8870 
8871 /******************************* ADC Instances ********************************/
8872 #define IS_ADC_ALL_INSTANCE(INSTANCE) ((INSTANCE) == ADC1)
8873 
8874 #define IS_ADC_COMMON_INSTANCE(INSTANCE) ((INSTANCE) == ADC1_COMMON)
8875 
8876 
8877 
8878 
8879 /******************************* CRC Instances ********************************/
8880 #define IS_CRC_ALL_INSTANCE(INSTANCE) ((INSTANCE) == CRC)
8881 
8882 
8883 /******************************** DMA Instances *******************************/
8884 #define IS_DMA_ALL_INSTANCE(INSTANCE) (((INSTANCE) == DMA1_Channel1) || \
8885                                        ((INSTANCE) == DMA1_Channel2) || \
8886                                        ((INSTANCE) == DMA1_Channel3) || \
8887                                        ((INSTANCE) == DMA1_Channel4) || \
8888                                        ((INSTANCE) == DMA1_Channel5) || \
8889                                        ((INSTANCE) == DMA1_Channel6) || \
8890                                        ((INSTANCE) == DMA1_Channel7) || \
8891                                        ((INSTANCE) == DMA2_Channel1) || \
8892                                        ((INSTANCE) == DMA2_Channel2) || \
8893                                        ((INSTANCE) == DMA2_Channel3) || \
8894                                        ((INSTANCE) == DMA2_Channel4) || \
8895                                        ((INSTANCE) == DMA2_Channel5))
8896 
8897 /******************************** DMAMUX Instances ****************************/
8898 #define IS_DMAMUX_ALL_INSTANCE(INSTANCE) ((INSTANCE) == DMAMUX1)
8899 
8900 #define IS_DMAMUX_REQUEST_GEN_ALL_INSTANCE(INSTANCE) (((INSTANCE) == DMAMUX1_RequestGenerator0) || \
8901                                                       ((INSTANCE) == DMAMUX1_RequestGenerator1) || \
8902                                                       ((INSTANCE) == DMAMUX1_RequestGenerator2) || \
8903                                                       ((INSTANCE) == DMAMUX1_RequestGenerator3))
8904 
8905 /******************************* GPIO Instances *******************************/
8906 #define IS_GPIO_ALL_INSTANCE(INSTANCE) (((INSTANCE) == GPIOA) || \
8907                                         ((INSTANCE) == GPIOB) || \
8908                                         ((INSTANCE) == GPIOC) || \
8909                                         ((INSTANCE) == GPIOD) || \
8910                                         ((INSTANCE) == GPIOE) || \
8911                                         ((INSTANCE) == GPIOF))
8912 /******************************* GPIO AF Instances ****************************/
8913 #define IS_GPIO_AF_INSTANCE(INSTANCE)   IS_GPIO_ALL_INSTANCE(INSTANCE)
8914 
8915 /**************************** GPIO Lock Instances *****************************/
8916 #define IS_GPIO_LOCK_INSTANCE(INSTANCE) (((INSTANCE) == GPIOA) || \
8917                                          ((INSTANCE) == GPIOB) || \
8918                                          ((INSTANCE) == GPIOC))
8919 
8920 /******************************** I2C Instances *******************************/
8921 #define IS_I2C_ALL_INSTANCE(INSTANCE) (((INSTANCE) == I2C1) || \
8922                                        ((INSTANCE) == I2C2) || \
8923                                        ((INSTANCE) == I2C3))
8924 
8925 
8926 /****************************** RTC Instances *********************************/
8927 #define IS_RTC_ALL_INSTANCE(INSTANCE)  ((INSTANCE) == RTC)
8928 
8929 /****************************** SMBUS Instances *******************************/
8930 #define IS_SMBUS_ALL_INSTANCE(INSTANCE)(((INSTANCE) == I2C1) || \
8931                                         ((INSTANCE) == I2C2))
8932 
8933 /****************************** WAKEUP_FROMSTOP Instances *******************************/
8934 #define IS_I2C_WAKEUP_FROMSTOP_INSTANCE(INSTANCE)(((INSTANCE) == I2C1) || \
8935                                                   ((INSTANCE) == I2C2))
8936 
8937 /******************************** SPI Instances *******************************/
8938 #define IS_SPI_ALL_INSTANCE(INSTANCE) (((INSTANCE) == SPI1) || \
8939                                        ((INSTANCE) == SPI2) || \
8940                                        ((INSTANCE) == SPI3))
8941 
8942 
8943 /******************************** SPI Instances *******************************/
8944 #define IS_I2S_ALL_INSTANCE(INSTANCE) (((INSTANCE) == SPI1) || \
8945                                        ((INSTANCE) == SPI2))
8946 
8947 
8948 /****************** TIM Instances : All supported instances *******************/
8949 #define IS_TIM_INSTANCE(INSTANCE)       (((INSTANCE) == TIM1)   || \
8950                                          ((INSTANCE) == TIM3)   || \
8951                                          ((INSTANCE) == TIM4)   || \
8952                                          ((INSTANCE) == TIM6)   || \
8953                                          ((INSTANCE) == TIM7)   || \
8954                                          ((INSTANCE) == TIM14)  || \
8955                                          ((INSTANCE) == TIM15)  || \
8956                                          ((INSTANCE) == TIM16)  || \
8957                                          ((INSTANCE) == TIM17))
8958 
8959 /****************** TIM Instances : supporting 32 bits counter ****************/
8960 #define IS_TIM_32B_COUNTER_INSTANCE(INSTANCE) (0)
8961 
8962 /****************** TIM Instances : supporting the break function *************/
8963 #define IS_TIM_BREAK_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1)    || \
8964                                             ((INSTANCE) == TIM15)   || \
8965                                             ((INSTANCE) == TIM16)   || \
8966                                             ((INSTANCE) == TIM17))
8967 
8968 /************** TIM Instances : supporting Break source selection *************/
8969 #define IS_TIM_BREAKSOURCE_INSTANCE(INSTANCE) (((INSTANCE) == TIM1)   || \
8970                                                ((INSTANCE) == TIM15)  || \
8971                                                ((INSTANCE) == TIM16)  || \
8972                                                ((INSTANCE) == TIM17))
8973 
8974 /****************** TIM Instances : supporting 2 break inputs *****************/
8975 #define IS_TIM_BKIN2_INSTANCE(INSTANCE)    ((INSTANCE) == TIM1)
8976 
8977 /************* TIM Instances : at least 1 capture/compare channel *************/
8978 #define IS_TIM_CC1_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)   || \
8979                                          ((INSTANCE) == TIM3)   || \
8980                                          ((INSTANCE) == TIM4)   || \
8981                                          ((INSTANCE) == TIM14)  || \
8982                                          ((INSTANCE) == TIM15)  || \
8983                                          ((INSTANCE) == TIM16)  || \
8984                                          ((INSTANCE) == TIM17))
8985 
8986 /************ TIM Instances : at least 2 capture/compare channels *************/
8987 #define IS_TIM_CC2_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)   || \
8988                                          ((INSTANCE) == TIM3)   || \
8989                                          ((INSTANCE) == TIM4)   || \
8990                                          ((INSTANCE) == TIM15))
8991 
8992 /************ TIM Instances : at least 3 capture/compare channels *************/
8993 #define IS_TIM_CC3_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)   || \
8994                                          ((INSTANCE) == TIM3)   || \
8995                                          ((INSTANCE) == TIM4))
8996 
8997 /************ TIM Instances : at least 4 capture/compare channels *************/
8998 #define IS_TIM_CC4_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)   || \
8999                                          ((INSTANCE) == TIM3)   || \
9000                                          ((INSTANCE) == TIM4))
9001 
9002 /****************** TIM Instances : at least 5 capture/compare channels *******/
9003 #define IS_TIM_CC5_INSTANCE(INSTANCE)   ((INSTANCE) == TIM1)
9004 
9005 /****************** TIM Instances : at least 6 capture/compare channels *******/
9006 #define IS_TIM_CC6_INSTANCE(INSTANCE)   ((INSTANCE) == TIM1)
9007 
9008 /************ TIM Instances : DMA requests generation (TIMx_DIER.COMDE) *******/
9009 #define IS_TIM_CCDMA_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1)   || \
9010                                             ((INSTANCE) == TIM15)  || \
9011                                             ((INSTANCE) == TIM16)  || \
9012                                             ((INSTANCE) == TIM17))
9013 
9014 /****************** TIM Instances : DMA requests generation (TIMx_DIER.UDE) ***/
9015 #define IS_TIM_DMA_INSTANCE(INSTANCE)      (((INSTANCE) == TIM1)   || \
9016                                             ((INSTANCE) == TIM3)   || \
9017                                             ((INSTANCE) == TIM4)   || \
9018                                             ((INSTANCE) == TIM6)   || \
9019                                             ((INSTANCE) == TIM7)   || \
9020                                             ((INSTANCE) == TIM15)  || \
9021                                             ((INSTANCE) == TIM16)  || \
9022                                             ((INSTANCE) == TIM17))
9023 
9024 /************ TIM Instances : DMA requests generation (TIMx_DIER.CCxDE) *******/
9025 #define IS_TIM_DMA_CC_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)   || \
9026                                             ((INSTANCE) == TIM3)   || \
9027                                             ((INSTANCE) == TIM4)   || \
9028                                             ((INSTANCE) == TIM14)  || \
9029                                             ((INSTANCE) == TIM15)  || \
9030                                             ((INSTANCE) == TIM16)  || \
9031                                             ((INSTANCE) == TIM17))
9032 
9033 /******************** TIM Instances : DMA burst feature ***********************/
9034 #define IS_TIM_DMABURST_INSTANCE(INSTANCE) (((INSTANCE) == TIM1)   || \
9035                                             ((INSTANCE) == TIM3)   || \
9036                                             ((INSTANCE) == TIM4)   || \
9037                                             ((INSTANCE) == TIM15)  || \
9038                                             ((INSTANCE) == TIM16)  || \
9039                                             ((INSTANCE) == TIM17))
9040 
9041 /******************* TIM Instances : output(s) available **********************/
9042 #define IS_TIM_CCX_INSTANCE(INSTANCE, CHANNEL) \
9043     ((((INSTANCE) == TIM1) &&                  \
9044      (((CHANNEL) == TIM_CHANNEL_1) ||          \
9045       ((CHANNEL) == TIM_CHANNEL_2) ||          \
9046       ((CHANNEL) == TIM_CHANNEL_3) ||          \
9047       ((CHANNEL) == TIM_CHANNEL_4) ||          \
9048       ((CHANNEL) == TIM_CHANNEL_5) ||          \
9049       ((CHANNEL) == TIM_CHANNEL_6)))           \
9050      ||                                        \
9051      (((INSTANCE) == TIM3) &&                  \
9052      (((CHANNEL) == TIM_CHANNEL_1) ||          \
9053       ((CHANNEL) == TIM_CHANNEL_2) ||          \
9054       ((CHANNEL) == TIM_CHANNEL_3) ||          \
9055       ((CHANNEL) == TIM_CHANNEL_4)))           \
9056      ||                                        \
9057      (((INSTANCE) == TIM4) &&                  \
9058      (((CHANNEL) == TIM_CHANNEL_1) ||          \
9059       ((CHANNEL) == TIM_CHANNEL_2) ||          \
9060       ((CHANNEL) == TIM_CHANNEL_3) ||          \
9061       ((CHANNEL) == TIM_CHANNEL_4)))           \
9062      ||                                        \
9063      (((INSTANCE) == TIM14) &&                 \
9064      (((CHANNEL) == TIM_CHANNEL_1)))           \
9065      ||                                        \
9066      (((INSTANCE) == TIM15) &&                 \
9067      (((CHANNEL) == TIM_CHANNEL_1) ||          \
9068       ((CHANNEL) == TIM_CHANNEL_2)))           \
9069      ||                                        \
9070      (((INSTANCE) == TIM16) &&                 \
9071      (((CHANNEL) == TIM_CHANNEL_1)))           \
9072      ||                                        \
9073      (((INSTANCE) == TIM17) &&                 \
9074       (((CHANNEL) == TIM_CHANNEL_1))))
9075 
9076 /****************** TIM Instances : supporting complementary output(s) ********/
9077 #define IS_TIM_CCXN_INSTANCE(INSTANCE, CHANNEL) \
9078    ((((INSTANCE) == TIM1) &&                    \
9079      (((CHANNEL) == TIM_CHANNEL_1) ||           \
9080       ((CHANNEL) == TIM_CHANNEL_2) ||           \
9081       ((CHANNEL) == TIM_CHANNEL_3)))            \
9082     ||                                          \
9083     (((INSTANCE) == TIM15) &&                   \
9084      ((CHANNEL) == TIM_CHANNEL_1))              \
9085     ||                                          \
9086     (((INSTANCE) == TIM16) &&                   \
9087      ((CHANNEL) == TIM_CHANNEL_1))              \
9088     ||                                          \
9089     (((INSTANCE) == TIM17) &&                   \
9090      ((CHANNEL) == TIM_CHANNEL_1)))
9091 
9092 /****************** TIM Instances : supporting clock division *****************/
9093 #define IS_TIM_CLOCK_DIVISION_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)    || \
9094                                                     ((INSTANCE) == TIM3)    || \
9095                                                     ((INSTANCE) == TIM4)    || \
9096                                                     ((INSTANCE) == TIM14)   || \
9097                                                     ((INSTANCE) == TIM15)   || \
9098                                                     ((INSTANCE) == TIM16)   || \
9099                                                     ((INSTANCE) == TIM17))
9100 
9101 /****** TIM Instances : supporting external clock mode 1 for ETRF input *******/
9102 #define IS_TIM_CLOCKSOURCE_ETRMODE1_INSTANCE(INSTANCE) (((INSTANCE) == TIM1) || \
9103                                                         ((INSTANCE) == TIM3) || \
9104                                                         ((INSTANCE) == TIM4))
9105 
9106 /****** TIM Instances : supporting external clock mode 2 for ETRF input *******/
9107 #define IS_TIM_CLOCKSOURCE_ETRMODE2_INSTANCE(INSTANCE) (((INSTANCE) == TIM1) || \
9108                                                         ((INSTANCE) == TIM3) || \
9109                                                         ((INSTANCE) == TIM4))
9110 
9111 /****************** TIM Instances : supporting external clock mode 1 for TIX inputs*/
9112 #define IS_TIM_CLOCKSOURCE_TIX_INSTANCE(INSTANCE)      (((INSTANCE) == TIM1) || \
9113                                                         ((INSTANCE) == TIM3) || \
9114                                                         ((INSTANCE) == TIM4) || \
9115                                                         ((INSTANCE) == TIM15))
9116 
9117 /****************** TIM Instances : supporting internal trigger inputs(ITRX) *******/
9118 #define IS_TIM_CLOCKSOURCE_ITRX_INSTANCE(INSTANCE)     (((INSTANCE) == TIM1) || \
9119                                                         ((INSTANCE) == TIM3) || \
9120                                                         ((INSTANCE) == TIM4) || \
9121                                                         ((INSTANCE) == TIM15))
9122 
9123 /****************** TIM Instances : supporting combined 3-phase PWM mode ******/
9124 #define IS_TIM_COMBINED3PHASEPWM_INSTANCE(INSTANCE)    ((INSTANCE) == TIM1)
9125 
9126 /****************** TIM Instances : supporting commutation event generation ***/
9127 #define IS_TIM_COMMUTATION_EVENT_INSTANCE(INSTANCE) (((INSTANCE) == TIM1)   || \
9128                                                      ((INSTANCE) == TIM15)  || \
9129                                                      ((INSTANCE) == TIM16)  || \
9130                                                      ((INSTANCE) == TIM17))
9131 
9132 /****************** TIM Instances : supporting counting mode selection ********/
9133 #define IS_TIM_COUNTER_MODE_SELECT_INSTANCE(INSTANCE)  (((INSTANCE) == TIM1) || \
9134                                                         ((INSTANCE) == TIM3) || \
9135                                                         ((INSTANCE) == TIM4))
9136 
9137 /****************** TIM Instances : supporting encoder interface **************/
9138 #define IS_TIM_ENCODER_INTERFACE_INSTANCE(INSTANCE)  (((INSTANCE) == TIM1)  || \
9139                                                       ((INSTANCE) == TIM3)  || \
9140                                                       ((INSTANCE) == TIM4))
9141 
9142 /****************** TIM Instances : supporting Hall sensor interface **********/
9143 #define IS_TIM_HALL_SENSOR_INTERFACE_INSTANCE(INSTANCE) (((INSTANCE) == TIM1)   || \
9144                                                          ((INSTANCE) == TIM3)   || \
9145                                                          ((INSTANCE) == TIM4))
9146 
9147 /**************** TIM Instances : external trigger input available ************/
9148 #define IS_TIM_ETR_INSTANCE(INSTANCE)      (((INSTANCE) == TIM1)  || \
9149                                             ((INSTANCE) == TIM3)  || \
9150                                             ((INSTANCE) == TIM4))
9151 
9152 /************* TIM Instances : supporting ETR source selection ***************/
9153 #define IS_TIM_ETRSEL_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1)  || \
9154                                              ((INSTANCE) == TIM3)  || \
9155                                              ((INSTANCE) == TIM4))
9156 
9157 /****** TIM Instances : Master mode available (TIMx_CR2.MMS available )********/
9158 #define IS_TIM_MASTER_INSTANCE(INSTANCE)   (((INSTANCE) == TIM1)  || \
9159                                             ((INSTANCE) == TIM3)  || \
9160                                             ((INSTANCE) == TIM4)  || \
9161                                             ((INSTANCE) == TIM6)  || \
9162                                             ((INSTANCE) == TIM7)  || \
9163                                             ((INSTANCE) == TIM15))
9164 
9165 /*********** TIM Instances : Slave mode available (TIMx_SMCR available )*******/
9166 #define IS_TIM_SLAVE_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1)  || \
9167                                             ((INSTANCE) == TIM3)  || \
9168                                             ((INSTANCE) == TIM4)  || \
9169                                             ((INSTANCE) == TIM15))
9170 
9171 /****************** TIM Instances : supporting OCxREF clear *******************/
9172 #define IS_TIM_OCXREF_CLEAR_INSTANCE(INSTANCE)        (((INSTANCE) == TIM1) || \
9173                                                        ((INSTANCE) == TIM3) || \
9174                                                        ((INSTANCE) == TIM4))
9175 
9176 /****************** TIM Instances : supporting bitfield OCCS in SMCR register *******************/
9177 #define IS_TIM_OCCS_INSTANCE(INSTANCE)                (((INSTANCE) == TIM1)  || \
9178                                                        ((INSTANCE) == TIM3))
9179 
9180 /****************** TIM Instances : remapping capability **********************/
9181 #define IS_TIM_REMAP_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1)  || \
9182                                             ((INSTANCE) == TIM3)  || \
9183                                             ((INSTANCE) == TIM4))
9184 
9185 /****************** TIM Instances : supporting repetition counter *************/
9186 #define IS_TIM_REPETITION_COUNTER_INSTANCE(INSTANCE)  (((INSTANCE) == TIM1)  || \
9187                                                        ((INSTANCE) == TIM15) || \
9188                                                        ((INSTANCE) == TIM16) || \
9189                                                        ((INSTANCE) == TIM17))
9190 
9191 /****************** TIM Instances : supporting ADC triggering through TRGO2 ***/
9192 #define IS_TIM_TRGO2_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1))
9193 
9194 /******************* TIM Instances : Timer input XOR function *****************/
9195 #define IS_TIM_XOR_INSTANCE(INSTANCE)      (((INSTANCE) == TIM1)   || \
9196                                             ((INSTANCE) == TIM3)   || \
9197                                             ((INSTANCE) == TIM4)   || \
9198                                             ((INSTANCE) == TIM15))
9199 
9200 /******************* TIM Instances : Timer input selection ********************/
9201 #define IS_TIM_TISEL_INSTANCE(INSTANCE) (((INSTANCE) == TIM1)   || \
9202                                          ((INSTANCE) == TIM3)   || \
9203                                          ((INSTANCE) == TIM4)   || \
9204                                          ((INSTANCE) == TIM14)  || \
9205                                          ((INSTANCE) == TIM15)  || \
9206                                          ((INSTANCE) == TIM16)  || \
9207                                          ((INSTANCE) == TIM17))
9208 
9209 /************ TIM Instances : Advanced timers  ********************************/
9210 #define IS_TIM_ADVANCED_INSTANCE(INSTANCE)    (((INSTANCE) == TIM1))
9211 
9212 /******************** UART Instances : Asynchronous mode **********************/
9213 #define IS_UART_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9214                                     ((INSTANCE) == USART2) || \
9215                                     ((INSTANCE) == USART3) || \
9216                                     ((INSTANCE) == USART4) || \
9217                                     ((INSTANCE) == USART5) || \
9218                                     ((INSTANCE) == USART6))
9219 
9220 
9221 /******************** USART Instances : Synchronous mode **********************/
9222 #define IS_USART_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9223                                      ((INSTANCE) == USART2) || \
9224                                      ((INSTANCE) == USART3) || \
9225                                      ((INSTANCE) == USART4) || \
9226                                      ((INSTANCE) == USART5) || \
9227                                      ((INSTANCE) == USART6))
9228 
9229 /****************** UART Instances : Hardware Flow control ********************/
9230 #define IS_UART_HWFLOW_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9231                                            ((INSTANCE) == USART2) || \
9232                                            ((INSTANCE) == USART3) || \
9233                                            ((INSTANCE) == USART4) || \
9234                                            ((INSTANCE) == USART5) || \
9235                                            ((INSTANCE) == USART6))
9236 
9237 /********************* USART Instances : Smard card mode ***********************/
9238 #define IS_SMARTCARD_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9239                                          ((INSTANCE) == USART2) || \
9240                                          ((INSTANCE) == USART3))
9241 /****************** UART Instances : Auto Baud Rate detection ****************/
9242 #define IS_USART_AUTOBAUDRATE_DETECTION_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9243                                                             ((INSTANCE) == USART2) || \
9244                                                             ((INSTANCE) == USART3))
9245 
9246 /******************** UART Instances : Half-Duplex mode **********************/
9247 #define IS_UART_HALFDUPLEX_INSTANCE(INSTANCE)   (((INSTANCE) == USART1) || \
9248                                                  ((INSTANCE) == USART2) || \
9249                                                  ((INSTANCE) == USART3) || \
9250                                                  ((INSTANCE) == USART4) || \
9251                                                  ((INSTANCE) == USART5) || \
9252                                                  ((INSTANCE) == USART6))
9253 
9254 /******************** UART Instances : LIN mode **********************/
9255 #define IS_UART_LIN_INSTANCE(INSTANCE)   (((INSTANCE) == USART1) || \
9256                                           ((INSTANCE) == USART2) || \
9257                                           ((INSTANCE) == USART3))
9258 /******************** UART Instances : Wake-up from Stop mode **********************/
9259 #define IS_UART_WAKEUP_FROMSTOP_INSTANCE(INSTANCE)   (((INSTANCE) == USART1) || \
9260                                                       ((INSTANCE) == USART2) || \
9261                                                       ((INSTANCE) == USART3))
9262 
9263 /****************** UART Instances : Driver Enable *****************/
9264 #define IS_UART_DRIVER_ENABLE_INSTANCE(INSTANCE)   (((INSTANCE) == USART1) || \
9265                                                     ((INSTANCE) == USART2) || \
9266                                                     ((INSTANCE) == USART3) || \
9267                                                     ((INSTANCE) == USART4) || \
9268                                                     ((INSTANCE) == USART5) || \
9269                                                     ((INSTANCE) == USART6))
9270 
9271 /****************** UART Instances : SPI Slave selection mode ***************/
9272 #define IS_UART_SPI_SLAVE_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9273                                               ((INSTANCE) == USART2) || \
9274                                               ((INSTANCE) == USART3) || \
9275                                               ((INSTANCE) == USART4) || \
9276                                               ((INSTANCE) == USART5) || \
9277                                               ((INSTANCE) == USART6))
9278 
9279 /****************** UART Instances : Driver Enable *****************/
9280 #define IS_UART_FIFO_INSTANCE(INSTANCE)     (((INSTANCE) == USART1) || \
9281                                              ((INSTANCE) == USART2) || \
9282                                              ((INSTANCE) == USART3))
9283 
9284 /*********************** UART Instances : IRDA mode ***************************/
9285 #define IS_IRDA_INSTANCE(INSTANCE) (((INSTANCE) == USART1) || \
9286                                     ((INSTANCE) == USART2) || \
9287                                     ((INSTANCE) == USART3))
9288 
9289 #define IS_LPUART_INSTANCE(INSTANCE)    (0U)
9290 
9291 /****************************** IWDG Instances ********************************/
9292 #define IS_IWDG_ALL_INSTANCE(INSTANCE)  ((INSTANCE) == IWDG)
9293 
9294 /****************************** WWDG Instances ********************************/
9295 #define IS_WWDG_ALL_INSTANCE(INSTANCE)  ((INSTANCE) == WWDG)
9296 
9297 
9298 /****************************** USB Instances ********************************/
9299 #define IS_USB_ALL_INSTANCE(INSTANCE) ((INSTANCE) == USB_DRD_FS)
9300 
9301 /*********************** USB OTG PCD Instances ********************************/
9302 #define IS_PCD_ALL_INSTANCE(INSTANCE) (((INSTANCE) == USB_DRD_FS))
9303 
9304 /*********************** USB OTG HCD Instances ********************************/
9305 #define IS_HCD_ALL_INSTANCE(INSTANCE) (((INSTANCE) == USB_DRD_FS))
9306 
9307 /******************************************************************************/
9308 /*  For a painless codes migration between the STM32G0xx device product       */
9309 /*  lines, the aliases defined below are put in place to overcome the         */
9310 /*  differences in the interrupt handlers and IRQn definitions.               */
9311 /*  No need to update developed interrupt code when moving across             */
9312 /*  product lines within the same STM32G0 Family                              */
9313 /******************************************************************************/
9314 /* Aliases for IRQn_Type */
9315 #define SVC_IRQn              SVCall_IRQn
9316 
9317 /**
9318   * @}
9319   */
9320 
9321  /**
9322   * @}
9323   */
9324 
9325 /**
9326   * @}
9327   */
9328 
9329 #ifdef __cplusplus
9330 }
9331 #endif /* __cplusplus */
9332 
9333 #endif /* STM32G0B0xx_H */
9334 
9335 /**
9336   * @}
9337   */
9338 
9339   /**
9340   * @}
9341   */
9342