Rev 2 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2 | Rev 9 | ||
---|---|---|---|
Line 6... | Line 6... | ||
6 | * This file should be copied to the application folder and renamed |
6 | * This file should be copied to the application folder and renamed |
7 | * to stm32f1xx_hal_conf.h. |
7 | * to stm32f1xx_hal_conf.h. |
8 | ****************************************************************************** |
8 | ****************************************************************************** |
9 | * @attention |
9 | * @attention |
10 | * |
10 | * |
11 | * <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2> |
11 | * <h2><center>© Copyright (c) 2017 STMicroelectronics. |
- | 12 | * All rights reserved.</center></h2> |
|
12 | * |
13 | * |
13 | * Redistribution and use in source and binary forms, with or without modification, |
14 | * This software component is licensed by ST under BSD 3-Clause license, |
14 | * are permitted provided that the following conditions are met: |
15 | * the "License"; You may not use this file except in compliance with the |
15 | * 1. Redistributions of source code must retain the above copyright notice, |
- | |
16 | * this list of conditions and the following disclaimer. |
- | |
17 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
- | |
18 | * this list of conditions and the following disclaimer in the documentation |
- | |
19 | * and/or other materials provided with the distribution. |
16 | * License. You may obtain a copy of the License at: |
20 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
- | |
21 | * may be used to endorse or promote products derived from this software |
17 | * opensource.org/licenses/BSD-3-Clause |
22 | * without specific prior written permission. |
- | |
23 | * |
- | |
24 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
- | |
25 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
- | |
26 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
- | |
27 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
- | |
28 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
- | |
29 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
- | |
30 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
- | |
31 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
- | |
32 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
- | |
33 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
- | |
34 | * |
18 | * |
35 | ****************************************************************************** |
19 | ****************************************************************************** |
36 | */ |
20 | */ |
37 | 21 | ||
38 | /* Define to prevent recursive inclusion -------------------------------------*/ |
22 | /* Define to prevent recursive inclusion -------------------------------------*/ |
Line 58... | Line 42... | ||
58 | #define HAL_CORTEX_MODULE_ENABLED |
42 | #define HAL_CORTEX_MODULE_ENABLED |
59 | #define HAL_CRC_MODULE_ENABLED |
43 | #define HAL_CRC_MODULE_ENABLED |
60 | #define HAL_DAC_MODULE_ENABLED |
44 | #define HAL_DAC_MODULE_ENABLED |
61 | #define HAL_DMA_MODULE_ENABLED |
45 | #define HAL_DMA_MODULE_ENABLED |
62 | #define HAL_ETH_MODULE_ENABLED |
46 | #define HAL_ETH_MODULE_ENABLED |
- | 47 | #define HAL_EXTI_MODULE_ENABLED |
|
63 | #define HAL_FLASH_MODULE_ENABLED |
48 | #define HAL_FLASH_MODULE_ENABLED |
64 | #define HAL_GPIO_MODULE_ENABLED |
49 | #define HAL_GPIO_MODULE_ENABLED |
65 | #define HAL_HCD_MODULE_ENABLED |
50 | #define HAL_HCD_MODULE_ENABLED |
66 | #define HAL_I2C_MODULE_ENABLED |
51 | #define HAL_I2C_MODULE_ENABLED |
67 | #define HAL_I2S_MODULE_ENABLED |
52 | #define HAL_I2S_MODULE_ENABLED |
Line 113... | Line 98... | ||
113 | 98 | ||
114 | /** |
99 | /** |
115 | * @brief Internal Low Speed oscillator (LSI) value. |
100 | * @brief Internal Low Speed oscillator (LSI) value. |
116 | */ |
101 | */ |
117 | #if !defined (LSI_VALUE) |
102 | #if !defined (LSI_VALUE) |
118 | #define LSI_VALUE 32000U /*!< LSI Typical Value in Hz */ |
103 | #define LSI_VALUE 40000U /*!< LSI Typical Value in Hz */ |
119 | #endif /* LSI_VALUE */ /*!< Value of the Internal Low Speed oscillator in Hz |
104 | #endif /* LSI_VALUE */ /*!< Value of the Internal Low Speed oscillator in Hz |
120 | The real value may vary depending on the variations |
105 | The real value may vary depending on the variations |
121 | in voltage and temperature. */ |
106 | in voltage and temperature. */ |
122 | /** |
107 | /** |
123 | * @brief External Low Speed oscillator (LSE) value. |
108 | * @brief External Low Speed oscillator (LSE) value. |
Line 141... | Line 126... | ||
141 | #define VDD_VALUE 3300U /*!< Value of VDD in mv */ |
126 | #define VDD_VALUE 3300U /*!< Value of VDD in mv */ |
142 | #define TICK_INT_PRIORITY 0x0FU /*!< tick interrupt priority */ |
127 | #define TICK_INT_PRIORITY 0x0FU /*!< tick interrupt priority */ |
143 | #define USE_RTOS 0U |
128 | #define USE_RTOS 0U |
144 | #define PREFETCH_ENABLE 1U |
129 | #define PREFETCH_ENABLE 1U |
145 | 130 | ||
- | 131 | #define USE_HAL_ADC_REGISTER_CALLBACKS 0U /* ADC register callback disabled */ |
|
- | 132 | #define USE_HAL_CAN_REGISTER_CALLBACKS 0U /* CAN register callback disabled */ |
|
- | 133 | #define USE_HAL_CEC_REGISTER_CALLBACKS 0U /* CEC register callback disabled */ |
|
- | 134 | #define USE_HAL_DAC_REGISTER_CALLBACKS 0U /* DAC register callback disabled */ |
|
- | 135 | #define USE_HAL_ETH_REGISTER_CALLBACKS 0U /* ETH register callback disabled */ |
|
- | 136 | #define USE_HAL_HCD_REGISTER_CALLBACKS 0U /* HCD register callback disabled */ |
|
- | 137 | #define USE_HAL_I2C_REGISTER_CALLBACKS 0U /* I2C register callback disabled */ |
|
- | 138 | #define USE_HAL_I2S_REGISTER_CALLBACKS 0U /* I2S register callback disabled */ |
|
- | 139 | #define USE_HAL_MMC_REGISTER_CALLBACKS 0U /* MMC register callback disabled */ |
|
- | 140 | #define USE_HAL_NAND_REGISTER_CALLBACKS 0U /* NAND register callback disabled */ |
|
- | 141 | #define USE_HAL_NOR_REGISTER_CALLBACKS 0U /* NOR register callback disabled */ |
|
- | 142 | #define USE_HAL_PCCARD_REGISTER_CALLBACKS 0U /* PCCARD register callback disabled */ |
|
- | 143 | #define USE_HAL_PCD_REGISTER_CALLBACKS 0U /* PCD register callback disabled */ |
|
- | 144 | #define USE_HAL_RTC_REGISTER_CALLBACKS 0U /* RTC register callback disabled */ |
|
- | 145 | #define USE_HAL_SD_REGISTER_CALLBACKS 0U /* SD register callback disabled */ |
|
- | 146 | #define USE_HAL_SMARTCARD_REGISTER_CALLBACKS 0U /* SMARTCARD register callback disabled */ |
|
- | 147 | #define USE_HAL_IRDA_REGISTER_CALLBACKS 0U /* IRDA register callback disabled */ |
|
- | 148 | #define USE_HAL_SRAM_REGISTER_CALLBACKS 0U /* SRAM register callback disabled */ |
|
- | 149 | #define USE_HAL_SPI_REGISTER_CALLBACKS 0U /* SPI register callback disabled */ |
|
- | 150 | #define USE_HAL_TIM_REGISTER_CALLBACKS 0U /* TIM register callback disabled */ |
|
- | 151 | #define USE_HAL_UART_REGISTER_CALLBACKS 0U /* UART register callback disabled */ |
|
- | 152 | #define USE_HAL_USART_REGISTER_CALLBACKS 0U /* USART register callback disabled */ |
|
- | 153 | #define USE_HAL_WWDG_REGISTER_CALLBACKS 0U /* WWDG register callback disabled */ |
|
- | 154 | ||
146 | /* ########################## Assert Selection ############################## */ |
155 | /* ########################## Assert Selection ############################## */ |
147 | /** |
156 | /** |
148 | * @brief Uncomment the line below to expanse the "assert_param" macro in the |
157 | * @brief Uncomment the line below to expanse the "assert_param" macro in the |
149 | * HAL drivers code |
158 | * HAL drivers code |
150 | */ |
159 | */ |
Line 236... | Line 245... | ||
236 | 245 | ||
237 | #ifdef HAL_GPIO_MODULE_ENABLED |
246 | #ifdef HAL_GPIO_MODULE_ENABLED |
238 | #include "stm32f1xx_hal_gpio.h" |
247 | #include "stm32f1xx_hal_gpio.h" |
239 | #endif /* HAL_GPIO_MODULE_ENABLED */ |
248 | #endif /* HAL_GPIO_MODULE_ENABLED */ |
240 | 249 | ||
- | 250 | #ifdef HAL_EXTI_MODULE_ENABLED |
|
- | 251 | #include "stm32f1xx_hal_exti.h" |
|
- | 252 | #endif /* HAL_EXTI_MODULE_ENABLED */ |
|
- | 253 | ||
241 | #ifdef HAL_DMA_MODULE_ENABLED |
254 | #ifdef HAL_DMA_MODULE_ENABLED |
242 | #include "stm32f1xx_hal_dma.h" |
255 | #include "stm32f1xx_hal_dma.h" |
243 | #endif /* HAL_DMA_MODULE_ENABLED */ |
256 | #endif /* HAL_DMA_MODULE_ENABLED */ |
244 | 257 | ||
245 | #ifdef HAL_ETH_MODULE_ENABLED |
258 | #ifdef HAL_ETH_MODULE_ENABLED |
Line 360... | Line 373... | ||
360 | 373 | ||
361 | /* Exported macro ------------------------------------------------------------*/ |
374 | /* Exported macro ------------------------------------------------------------*/ |
362 | #ifdef USE_FULL_ASSERT |
375 | #ifdef USE_FULL_ASSERT |
363 | /** |
376 | /** |
364 | * @brief The assert_param macro is used for function's parameters check. |
377 | * @brief The assert_param macro is used for function's parameters check. |
365 | * @param expr: If expr is false, it calls assert_failed function |
378 | * @param expr If expr is false, it calls assert_failed function |
366 | * which reports the name of the source file and the source |
379 | * which reports the name of the source file and the source |
367 | * line number of the call that failed. |
380 | * line number of the call that failed. |
368 | * If expr is true, it returns no value. |
381 | * If expr is true, it returns no value. |
369 | * @retval None |
382 | * @retval None |
370 | */ |
383 | */ |
371 | #define assert_param(expr) ((expr) ? (void)0U : assert_failed((uint8_t *)__FILE__, __LINE__)) |
384 | #define assert_param(expr) ((expr) ? (void)0U : assert_failed((uint8_t *)__FILE__, __LINE__)) |
372 | /* Exported functions ------------------------------------------------------- */ |
385 | /* Exported functions ------------------------------------------------------- */ |
373 | void assert_failed(uint8_t *file, uint32_t line); |
386 | void assert_failed(uint8_t* file, uint32_t line); |
374 | #else |
387 | #else |
375 | #define assert_param(expr) ((void)0U) |
388 | #define assert_param(expr) ((void)0U) |
376 | #endif /* USE_FULL_ASSERT */ |
389 | #endif /* USE_FULL_ASSERT */ |
377 | 390 | ||
378 | 391 |