From abd118ef2d74d46717a95f0c3309237fc3c1f170 Mon Sep 17 00:00:00 2001 From: roccomarco Date: Sat, 1 Jul 2017 11:39:03 +0000 Subject: Updated CMSIS headers for STM32 MCUs git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10267 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h | 8299 +++++++++++++++++------- 1 file changed, 5813 insertions(+), 2486 deletions(-) (limited to 'os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h') diff --git a/os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h b/os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h index 536addc3e..26815665c 100644 --- a/os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h +++ b/os/common/ext/CMSIS/ST/STM32F4xx/stm32f410tx.h @@ -2,19 +2,19 @@ ****************************************************************************** * @file stm32f410tx.h * @author MCD Application Team - * @version V2.5.0 - * @date 22-April-2016 - * @brief CMSIS STM32F410Tx Device Peripheral Access Layer Header File. + * @version V2.6.1 + * @date 14-February-2017 + * @brief CMSIS STM32F410Tx Device Peripheral Access Layer Header File. * * This file contains: * - Data structures and the address mapping for all peripherals * - peripherals registers declarations and bits definition - * - Macros to access peripheral’s registers hardware + * - Macros to access peripheral’s registers hardware * ****************************************************************************** * @attention * - *

© COPYRIGHT(c) 2016 STMicroelectronics

+ *

© COPYRIGHT(c) 2017 STMicroelectronics

* * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: @@ -41,7 +41,7 @@ ****************************************************************************** */ -/** @addtogroup CMSIS +/** @addtogroup CMSIS_Device * @{ */ @@ -55,7 +55,6 @@ #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - /** @addtogroup Configuration_section_for_CMSIS * @{ @@ -73,7 +72,7 @@ /** * @} */ - + /** @addtogroup Peripheral_interrupt_number_definition * @{ */ @@ -115,7 +114,7 @@ typedef enum ADC_IRQn = 18, /*!< ADC1 global Interrupts */ EXTI9_5_IRQn = 23, /*!< External Line[9:5] Interrupts */ TIM1_BRK_TIM9_IRQn = 24, /*!< TIM1 Break interrupt and TIM9 global interrupt */ - TIM1_UP_IRQn = 25, /*!< TIM1 Update Interrupt */ + TIM1_UP_IRQn = 25, /*!< TIM1 Update Interrupt */ TIM1_TRG_COM_TIM11_IRQn = 26, /*!< TIM1 Trigger and Commutation Interrupt and TIM11 global interrupt */ TIM1_CC_IRQn = 27, /*!< TIM1 Capture Compare Interrupt */ I2C1_EV_IRQn = 31, /*!< I2C1 Event Interrupt */ @@ -263,7 +262,6 @@ typedef struct __IO uint32_t HIFCR; /*!< DMA high interrupt flag clear register, Address offset: 0x0C */ } DMA_TypeDef; - /** * @brief External Interrupt/Event Controller */ @@ -313,17 +311,16 @@ typedef struct /** * @brief System configuration controller */ - + typedef struct { __IO uint32_t MEMRMP; /*!< SYSCFG memory remap register, Address offset: 0x00 */ __IO uint32_t PMC; /*!< SYSCFG peripheral mode configuration register, Address offset: 0x04 */ __IO uint32_t EXTICR[4]; /*!< SYSCFG external interrupt configuration registers, Address offset: 0x08-0x14 */ uint32_t RESERVED; /*!< Reserved, 0x18 */ - uint32_t CFGR2; /*!< Reserved, 0x1C */ + __IO uint32_t CFGR2; /*!< SYSCFG Configuration register2, Address offset: 0x1C */ __IO uint32_t CMPCR; /*!< SYSCFG Compensation cell control register, Address offset: 0x20 */ - uint32_t RESERVED1[2]; /*!< Reserved, 0x24-0x28 */ - __IO uint32_t CFGR; /*!< SYSCFG Configuration register, Address offset: 0x2C */ + __IO uint32_t CFGR; /*!< SYSCFG Configuration register, Address offset: 0x24 */ } SYSCFG_TypeDef; /** @@ -375,6 +372,7 @@ typedef struct __IO uint32_t SR; /*!< IWDG Status register, Address offset: 0x0C */ } IWDG_TypeDef; + /** * @brief Power Control */ @@ -414,11 +412,10 @@ typedef struct __IO uint32_t CSR; /*!< RCC clock control & status register, Address offset: 0x74 */ uint32_t RESERVED6[2]; /*!< Reserved, 0x78-0x7C */ __IO uint32_t SSCGR; /*!< RCC spread spectrum clock generation register, Address offset: 0x80 */ - uint32_t RESERVED7[2]; /*!< Reserved, 0x84-0x88 */ - __IO uint32_t DCKCFGR; /*!< RCC Dedicated Clocks configuration register, Address offset: 0x8C */ - __IO uint32_t CKGATENR; /*!< RCC Clocks Gated ENable Register, Address offset: 0x90 */ + uint32_t RESERVED7[2]; /*!< Reserved, 0x84-0x88 */ + __IO uint32_t DCKCFGR; /*!< RCC DCKCFGR configuration register, Address offset: 0x8C */ + __IO uint32_t CKGATENR; /*!< RCC Clocks Gated ENable Register, Address offset: 0x90 */ __IO uint32_t DCKCFGR2; /*!< RCC Dedicated Clocks configuration register 2, Address offset: 0x94 */ - } RCC_TypeDef; /** @@ -486,6 +483,7 @@ typedef struct __IO uint32_t I2SPR; /*!< SPI_I2S prescaler register, Address offset: 0x20 */ } SPI_TypeDef; + /** * @brief TIM */ @@ -541,7 +539,6 @@ typedef struct __IO uint32_t SR; /*!< WWDG Status register, Address offset: 0x08 */ } WWDG_TypeDef; - /** * @brief RNG */ @@ -570,15 +567,21 @@ typedef struct __IO uint32_t OR; /*!< LPTIM Option register, Address offset: 0x20 */ } LPTIM_TypeDef; -/** - * @brief Peripheral_memory_map +/** + * @} + */ + +/** @addtogroup Peripheral_memory_map + * @{ */ #define FLASH_BASE 0x08000000U /*!< FLASH(up to 1 MB) base address in the alias region */ #define SRAM1_BASE 0x20000000U /*!< SRAM1(32 KB) base address in the alias region */ #define PERIPH_BASE 0x40000000U /*!< Peripheral base address in the alias region */ #define SRAM1_BB_BASE 0x22000000U /*!< SRAM1(32 KB) base address in the bit-band region */ #define PERIPH_BB_BASE 0x42000000U /*!< Peripheral base address in the bit-band region */ -#define FLASH_END 0x0801FFFFU /*!< FLASH end address */ +#define FLASH_END 0x0801FFFFU /*!< FLASH end address */ +#define FLASH_OTP_BASE 0x1FFF7800U /*!< Base address of : (up to 528 Bytes) embedded FLASH OTP Area */ +#define FLASH_OTP_END 0x1FFF7A0FU /*!< End address of : (up to 528 Bytes) embedded FLASH OTP Area */ /* Legacy defines */ #define SRAM_BASE SRAM1_BASE @@ -602,12 +605,14 @@ typedef struct #define FMPI2C1_BASE (APB1PERIPH_BASE + 0x6000U) #define PWR_BASE (APB1PERIPH_BASE + 0x7000U) #define DAC_BASE (APB1PERIPH_BASE + 0x7400U) + /*!< APB2 peripherals */ #define TIM1_BASE (APB2PERIPH_BASE + 0x0000U) #define USART1_BASE (APB2PERIPH_BASE + 0x1000U) -#define USART6_BASE (APB2PERIPH_BASE + 0x1400U) #define ADC1_BASE (APB2PERIPH_BASE + 0x2000U) -#define ADC_BASE (APB2PERIPH_BASE + 0x2300U) +#define ADC1_COMMON_BASE (APB2PERIPH_BASE + 0x2300U) +/* Legacy define */ +#define ADC_BASE ADC1_COMMON_BASE #define SPI1_BASE (APB2PERIPH_BASE + 0x3000U) #define SYSCFG_BASE (APB2PERIPH_BASE + 0x3800U) #define EXTI_BASE (APB2PERIPH_BASE + 0x3C00U) @@ -640,15 +645,19 @@ typedef struct #define DMA2_Stream5_BASE (DMA2_BASE + 0x088U) #define DMA2_Stream6_BASE (DMA2_BASE + 0x0A0U) #define DMA2_Stream7_BASE (DMA2_BASE + 0x0B8U) + #define RNG_BASE (PERIPH_BASE + 0x80000U) -/* Debug MCU registers base address */ +/*!< Debug MCU registers base address */ #define DBGMCU_BASE 0xE0042000U +#define UID_BASE 0x1FFF7A10U /*!< Unique device ID register base address */ +#define FLASHSIZE_BASE 0x1FFF7A22U /*!< FLASH Size register base address */ +#define PACKAGE_BASE 0x1FFF7BF0U /*!< Package size register base address */ /** * @} */ - + /** @addtogroup Peripheral_declaration * @{ */ @@ -663,12 +672,14 @@ typedef struct #define FMPI2C1 ((FMPI2C_TypeDef *) FMPI2C1_BASE) #define LPTIM1 ((LPTIM_TypeDef *) LPTIM1_BASE) #define PWR ((PWR_TypeDef *) PWR_BASE) -#define DAC ((DAC_TypeDef *) DAC_BASE) +#define DAC1 ((DAC_TypeDef *) DAC_BASE) +#define DAC ((DAC_TypeDef *) DAC_BASE) /* Kept for legacy purpose */ #define TIM1 ((TIM_TypeDef *) TIM1_BASE) #define USART1 ((USART_TypeDef *) USART1_BASE) -#define USART6 ((USART_TypeDef *) USART6_BASE) -#define ADC ((ADC_Common_TypeDef *) ADC_BASE) #define ADC1 ((ADC_TypeDef *) ADC1_BASE) +#define ADC1_COMMON ((ADC_Common_TypeDef *) ADC1_COMMON_BASE) +/* Legacy define */ +#define ADC ADC1_COMMON #define SPI1 ((SPI_TypeDef *) SPI1_BASE) #define SYSCFG ((SYSCFG_TypeDef *) SYSCFG_BASE) #define EXTI ((EXTI_TypeDef *) EXTI_BASE) @@ -700,7 +711,6 @@ typedef struct #define DMA2_Stream6 ((DMA_Stream_TypeDef *) DMA2_Stream6_BASE) #define DMA2_Stream7 ((DMA_Stream_TypeDef *) DMA2_Stream7_BASE) #define RNG ((RNG_TypeDef *) RNG_BASE) - #define DBGMCU ((DBGMCU_TypeDef *) DBGMCU_BASE) /** @@ -724,366 +734,557 @@ typedef struct /* Analog to Digital Converter */ /* */ /******************************************************************************/ + /******************** Bit definition for ADC_SR register ********************/ -#define ADC_SR_AWD 0x00000001U /*!