Initial commit
mbed-dev-master/targets/TARGET_STM/TARGET_STM32F4/device/stm32f4xx_hal_conf.h@0:bb348c97df44, 2020-09-16 (annotated)
- Committer:
- lypinator
- Date:
- Wed Sep 16 01:11:49 2020 +0000
- Revision:
- 0:bb348c97df44
Added PWM
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
lypinator | 0:bb348c97df44 | 1 | /** |
lypinator | 0:bb348c97df44 | 2 | ****************************************************************************** |
lypinator | 0:bb348c97df44 | 3 | * @file stm32f4xx_hal_conf.h |
lypinator | 0:bb348c97df44 | 4 | * @author MCD Application Team |
lypinator | 0:bb348c97df44 | 5 | * @brief HAL configuration file. |
lypinator | 0:bb348c97df44 | 6 | ****************************************************************************** |
lypinator | 0:bb348c97df44 | 7 | * @attention |
lypinator | 0:bb348c97df44 | 8 | * |
lypinator | 0:bb348c97df44 | 9 | * <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2> |
lypinator | 0:bb348c97df44 | 10 | * |
lypinator | 0:bb348c97df44 | 11 | * Redistribution and use in source and binary forms, with or without modification, |
lypinator | 0:bb348c97df44 | 12 | * are permitted provided that the following conditions are met: |
lypinator | 0:bb348c97df44 | 13 | * 1. Redistributions of source code must retain the above copyright notice, |
lypinator | 0:bb348c97df44 | 14 | * this list of conditions and the following disclaimer. |
lypinator | 0:bb348c97df44 | 15 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
lypinator | 0:bb348c97df44 | 16 | * this list of conditions and the following disclaimer in the documentation |
lypinator | 0:bb348c97df44 | 17 | * and/or other materials provided with the distribution. |
lypinator | 0:bb348c97df44 | 18 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
lypinator | 0:bb348c97df44 | 19 | * may be used to endorse or promote products derived from this software |
lypinator | 0:bb348c97df44 | 20 | * without specific prior written permission. |
lypinator | 0:bb348c97df44 | 21 | * |
lypinator | 0:bb348c97df44 | 22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
lypinator | 0:bb348c97df44 | 23 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
lypinator | 0:bb348c97df44 | 24 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
lypinator | 0:bb348c97df44 | 25 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
lypinator | 0:bb348c97df44 | 26 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
lypinator | 0:bb348c97df44 | 27 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
lypinator | 0:bb348c97df44 | 28 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
lypinator | 0:bb348c97df44 | 29 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
lypinator | 0:bb348c97df44 | 30 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
lypinator | 0:bb348c97df44 | 31 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
lypinator | 0:bb348c97df44 | 32 | * |
lypinator | 0:bb348c97df44 | 33 | ****************************************************************************** |
lypinator | 0:bb348c97df44 | 34 | */ |
lypinator | 0:bb348c97df44 | 35 | |
lypinator | 0:bb348c97df44 | 36 | /* Define to prevent recursive inclusion -------------------------------------*/ |
lypinator | 0:bb348c97df44 | 37 | #ifndef __STM32F4xx_HAL_CONF_H |
lypinator | 0:bb348c97df44 | 38 | #define __STM32F4xx_HAL_CONF_H |
lypinator | 0:bb348c97df44 | 39 | |
lypinator | 0:bb348c97df44 | 40 | #ifdef __cplusplus |
lypinator | 0:bb348c97df44 | 41 | extern "C" { |
lypinator | 0:bb348c97df44 | 42 | #endif |
lypinator | 0:bb348c97df44 | 43 | |
lypinator | 0:bb348c97df44 | 44 | /* Exported types ------------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 45 | /* Exported constants --------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 46 | |
lypinator | 0:bb348c97df44 | 47 | /* ########################## Module Selection ############################## */ |
lypinator | 0:bb348c97df44 | 48 | /** |
lypinator | 0:bb348c97df44 | 49 | * @brief This is the list of modules to be used in the HAL driver |
lypinator | 0:bb348c97df44 | 50 | */ |
lypinator | 0:bb348c97df44 | 51 | #define HAL_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 52 | #define HAL_ADC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 53 | /* #define HAL_CAN_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 54 | #define HAL_CAN_LEGACY_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 55 | #define HAL_CRC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 56 | #define HAL_CEC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 57 | #define HAL_CRYP_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 58 | #define HAL_DAC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 59 | #define HAL_DCMI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 60 | #define HAL_DMA_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 61 | #define HAL_DMA2D_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 62 | #define HAL_ETH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 63 | #define HAL_FLASH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 64 | #define HAL_NAND_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 65 | #define HAL_NOR_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 66 | #define HAL_PCCARD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 67 | #define HAL_SRAM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 68 | #define HAL_SDRAM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 69 | #define HAL_HASH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 70 | #define HAL_GPIO_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 71 | #define HAL_I2C_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 72 | #define HAL_I2S_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 73 | #define HAL_IWDG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 74 | #define HAL_LTDC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 75 | #define HAL_DSI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 76 | #define HAL_PWR_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 77 | #define HAL_QSPI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 78 | #define HAL_RCC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 79 | #define HAL_RNG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 80 | #define HAL_RTC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 81 | #define HAL_SAI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 82 | #define HAL_SD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 83 | #define HAL_SPI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 84 | #define HAL_TIM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 85 | #define HAL_UART_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 86 | #define HAL_USART_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 87 | #define HAL_IRDA_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 88 | #define HAL_SMARTCARD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 89 | #define HAL_WWDG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 90 | #define HAL_CORTEX_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 91 | #define HAL_PCD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 92 | #define HAL_HCD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 93 | #define HAL_FMPI2C_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 94 | #define HAL_SPDIFRX_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 95 | #define HAL_DFSDM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 96 | #define HAL_LPTIM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 97 | #define HAL_MMC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 98 | |
lypinator | 0:bb348c97df44 | 99 | /* ########################## HSE/HSI Values adaptation ##################### */ |
lypinator | 0:bb348c97df44 | 100 | /** |
lypinator | 0:bb348c97df44 | 101 | * @brief Adjust the value of External High Speed oscillator (HSE) used in your application. |
lypinator | 0:bb348c97df44 | 102 | * This value is used by the RCC HAL module to compute the system frequency |
lypinator | 0:bb348c97df44 | 103 | * (when HSE is used as system clock source, directly or through the PLL). |
lypinator | 0:bb348c97df44 | 104 | */ |
lypinator | 0:bb348c97df44 | 105 | #if !defined (HSE_VALUE) |
lypinator | 0:bb348c97df44 | 106 | #define HSE_VALUE ((uint32_t)8000000U) /*!< Value of the External oscillator in Hz */ |
lypinator | 0:bb348c97df44 | 107 | #endif /* HSE_VALUE */ |
lypinator | 0:bb348c97df44 | 108 | |
lypinator | 0:bb348c97df44 | 109 | #if !defined (HSE_STARTUP_TIMEOUT) |
lypinator | 0:bb348c97df44 | 110 | #define HSE_STARTUP_TIMEOUT 100U /*!< Time out for HSE start up, in ms */ |
lypinator | 0:bb348c97df44 | 111 | #endif /* HSE_STARTUP_TIMEOUT */ |
lypinator | 0:bb348c97df44 | 112 | |
lypinator | 0:bb348c97df44 | 113 | /** |
lypinator | 0:bb348c97df44 | 114 | * @brief Internal High Speed oscillator (HSI) value. |
lypinator | 0:bb348c97df44 | 115 | * This value is used by the RCC HAL module to compute the system frequency |
lypinator | 0:bb348c97df44 | 116 | * (when HSI is used as system clock source, directly or through the PLL). |
lypinator | 0:bb348c97df44 | 117 | */ |
lypinator | 0:bb348c97df44 | 118 | #if !defined (HSI_VALUE) |
lypinator | 0:bb348c97df44 | 119 | #define HSI_VALUE 16000000U /*!< Value of the Internal oscillator in Hz */ |
lypinator | 0:bb348c97df44 | 120 | #endif /* HSI_VALUE */ |
lypinator | 0:bb348c97df44 | 121 | |
lypinator | 0:bb348c97df44 | 122 | /** |
lypinator | 0:bb348c97df44 | 123 | * @brief Internal Low Speed oscillator (LSI) value. |
lypinator | 0:bb348c97df44 | 124 | */ |
lypinator | 0:bb348c97df44 | 125 | #if !defined (LSI_VALUE) |
lypinator | 0:bb348c97df44 | 126 | #define LSI_VALUE 32000U /*!< LSI Typical Value in Hz */ |
lypinator | 0:bb348c97df44 | 127 | #endif /* LSI_VALUE */ /*!< Value of the Internal Low Speed oscillator in Hz |
lypinator | 0:bb348c97df44 | 128 | The real value may vary depending on the variations |
lypinator | 0:bb348c97df44 | 129 | in voltage and temperature. */ |
lypinator | 0:bb348c97df44 | 130 | /** |
lypinator | 0:bb348c97df44 | 131 | * @brief External Low Speed oscillator (LSE) value. |
lypinator | 0:bb348c97df44 | 132 | */ |
lypinator | 0:bb348c97df44 | 133 | #if !defined (LSE_VALUE) |
lypinator | 0:bb348c97df44 | 134 | #define LSE_VALUE 32768U /*!< Value of the External Low Speed oscillator in Hz */ |
lypinator | 0:bb348c97df44 | 135 | #endif /* LSE_VALUE */ |
lypinator | 0:bb348c97df44 | 136 | |
lypinator | 0:bb348c97df44 | 137 | #if !defined (LSE_STARTUP_TIMEOUT) |
lypinator | 0:bb348c97df44 | 138 | #define LSE_STARTUP_TIMEOUT 5000U /*!< Time out for LSE start up, in ms */ |
lypinator | 0:bb348c97df44 | 139 | #endif /* LSE_STARTUP_TIMEOUT */ |
lypinator | 0:bb348c97df44 | 140 | |
lypinator | 0:bb348c97df44 | 141 | /** |
lypinator | 0:bb348c97df44 | 142 | * @brief External clock source for I2S peripheral |
lypinator | 0:bb348c97df44 | 143 | * This value is used by the I2S HAL module to compute the I2S clock source |
lypinator | 0:bb348c97df44 | 144 | * frequency, this source is inserted directly through I2S_CKIN pad. |
lypinator | 0:bb348c97df44 | 145 | */ |
lypinator | 0:bb348c97df44 | 146 | #if !defined (EXTERNAL_CLOCK_VALUE) |
lypinator | 0:bb348c97df44 | 147 | #define EXTERNAL_CLOCK_VALUE 12288000U /*!< Value of the External oscillator in Hz*/ |
lypinator | 0:bb348c97df44 | 148 | #endif /* EXTERNAL_CLOCK_VALUE */ |
lypinator | 0:bb348c97df44 | 149 | |
lypinator | 0:bb348c97df44 | 150 | /* Tip: To avoid modifying this file each time you need to use different HSE, |
lypinator | 0:bb348c97df44 | 151 | === you can define the HSE value in your toolchain compiler preprocessor. */ |
lypinator | 0:bb348c97df44 | 152 | |
lypinator | 0:bb348c97df44 | 153 | /* ########################### System Configuration ######################### */ |
lypinator | 0:bb348c97df44 | 154 | /** |
lypinator | 0:bb348c97df44 | 155 | * @brief This is the HAL system configuration section |
lypinator | 0:bb348c97df44 | 156 | */ |
lypinator | 0:bb348c97df44 | 157 | #define VDD_VALUE 3300U /*!< Value of VDD in mv */ |
lypinator | 0:bb348c97df44 | 158 | #define TICK_INT_PRIORITY 0x0FU /*!< tick interrupt priority */ |
lypinator | 0:bb348c97df44 | 159 | #define USE_RTOS 0U |
lypinator | 0:bb348c97df44 | 160 | #define PREFETCH_ENABLE 1U |
lypinator | 0:bb348c97df44 | 161 | #define INSTRUCTION_CACHE_ENABLE 1U |
lypinator | 0:bb348c97df44 | 162 | #define DATA_CACHE_ENABLE 1U |
lypinator | 0:bb348c97df44 | 163 | |
lypinator | 0:bb348c97df44 | 164 | /* ########################## Assert Selection ############################## */ |
lypinator | 0:bb348c97df44 | 165 | /** |
lypinator | 0:bb348c97df44 | 166 | * @brief Uncomment the line below to expanse the "assert_param" macro in the |
lypinator | 0:bb348c97df44 | 167 | * HAL drivers code |
lypinator | 0:bb348c97df44 | 168 | */ |
lypinator | 0:bb348c97df44 | 169 | /* #define USE_FULL_ASSERT 1U */ |
lypinator | 0:bb348c97df44 | 170 | |
lypinator | 0:bb348c97df44 | 171 | /* ################## Ethernet peripheral configuration ##################### */ |
lypinator | 0:bb348c97df44 | 172 | |
lypinator | 0:bb348c97df44 | 173 | /* Section 1 : Ethernet peripheral configuration */ |
lypinator | 0:bb348c97df44 | 174 | |
lypinator | 0:bb348c97df44 | 175 | /* MAC ADDRESS: MAC_ADDR0:MAC_ADDR1:MAC_ADDR2:MAC_ADDR3:MAC_ADDR4:MAC_ADDR5 */ |
lypinator | 0:bb348c97df44 | 176 | #define MAC_ADDR0 2U |
lypinator | 0:bb348c97df44 | 177 | #define MAC_ADDR1 0U |
lypinator | 0:bb348c97df44 | 178 | #define MAC_ADDR2 0U |
lypinator | 0:bb348c97df44 | 179 | #define MAC_ADDR3 0U |
lypinator | 0:bb348c97df44 | 180 | #define MAC_ADDR4 0U |
lypinator | 0:bb348c97df44 | 181 | #define MAC_ADDR5 0U |
lypinator | 0:bb348c97df44 | 182 | |
lypinator | 0:bb348c97df44 | 183 | /* Definition of the Ethernet driver buffers size and count */ |
lypinator | 0:bb348c97df44 | 184 | #define ETH_RX_BUF_SIZE ETH_MAX_PACKET_SIZE /* buffer size for receive */ |
lypinator | 0:bb348c97df44 | 185 | #define ETH_TX_BUF_SIZE ETH_MAX_PACKET_SIZE /* buffer size for transmit */ |
lypinator | 0:bb348c97df44 | 186 | #define ETH_RXBUFNB 4U /* 4 Rx buffers of size ETH_RX_BUF_SIZE */ |
lypinator | 0:bb348c97df44 | 187 | #define ETH_TXBUFNB 4U /* 4 Tx buffers of size ETH_TX_BUF_SIZE */ |
lypinator | 0:bb348c97df44 | 188 | |
lypinator | 0:bb348c97df44 | 189 | /* Section 2: PHY configuration section */ |
lypinator | 0:bb348c97df44 | 190 | |
lypinator | 0:bb348c97df44 | 191 | /* DP83848 PHY Address*/ |
lypinator | 0:bb348c97df44 | 192 | #define DP83848_PHY_ADDRESS 0x01U |
lypinator | 0:bb348c97df44 | 193 | /* PHY Reset delay these values are based on a 1 ms Systick interrupt*/ |
lypinator | 0:bb348c97df44 | 194 | #define PHY_RESET_DELAY 0x000000FFU |
lypinator | 0:bb348c97df44 | 195 | /* PHY Configuration delay */ |
lypinator | 0:bb348c97df44 | 196 | #define PHY_CONFIG_DELAY 0x00000FFFU |
lypinator | 0:bb348c97df44 | 197 | |
lypinator | 0:bb348c97df44 | 198 | #define PHY_READ_TO 0x0000FFFFU |
lypinator | 0:bb348c97df44 | 199 | #define PHY_WRITE_TO 0x0000FFFFU |
lypinator | 0:bb348c97df44 | 200 | |
lypinator | 0:bb348c97df44 | 201 | /* Section 3: Common PHY Registers */ |
lypinator | 0:bb348c97df44 | 202 | |
lypinator | 0:bb348c97df44 | 203 | #define PHY_BCR ((uint16_t)0x0000) /*!< Transceiver Basic Control Register */ |
lypinator | 0:bb348c97df44 | 204 | #define PHY_BSR ((uint16_t)0x0001) /*!< Transceiver Basic Status Register */ |
lypinator | 0:bb348c97df44 | 205 | |
lypinator | 0:bb348c97df44 | 206 | #define PHY_RESET ((uint16_t)0x8000) /*!< PHY Reset */ |
lypinator | 0:bb348c97df44 | 207 | #define PHY_LOOPBACK ((uint16_t)0x4000) /*!< Select loop-back mode */ |
lypinator | 0:bb348c97df44 | 208 | #define PHY_FULLDUPLEX_100M ((uint16_t)0x2100) /*!< Set the full-duplex mode at 100 Mb/s */ |
lypinator | 0:bb348c97df44 | 209 | #define PHY_HALFDUPLEX_100M ((uint16_t)0x2000) /*!< Set the half-duplex mode at 100 Mb/s */ |
lypinator | 0:bb348c97df44 | 210 | #define PHY_FULLDUPLEX_10M ((uint16_t)0x0100) /*!< Set the full-duplex mode at 10 Mb/s */ |
lypinator | 0:bb348c97df44 | 211 | #define PHY_HALFDUPLEX_10M ((uint16_t)0x0000) /*!< Set the half-duplex mode at 10 Mb/s */ |
lypinator | 0:bb348c97df44 | 212 | #define PHY_AUTONEGOTIATION ((uint16_t)0x1000) /*!< Enable auto-negotiation function */ |
lypinator | 0:bb348c97df44 | 213 | #define PHY_RESTART_AUTONEGOTIATION ((uint16_t)0x0200) /*!< Restart auto-negotiation function */ |
lypinator | 0:bb348c97df44 | 214 | #define PHY_POWERDOWN ((uint16_t)0x0800) /*!< Select the power down mode */ |
lypinator | 0:bb348c97df44 | 215 | #define PHY_ISOLATE ((uint16_t)0x0400) /*!< Isolate PHY from MII */ |
lypinator | 0:bb348c97df44 | 216 | |
lypinator | 0:bb348c97df44 | 217 | #define PHY_AUTONEGO_COMPLETE ((uint16_t)0x0020) /*!< Auto-Negotiation process completed */ |
lypinator | 0:bb348c97df44 | 218 | #define PHY_LINKED_STATUS ((uint16_t)0x0004) /*!< Valid link established */ |
lypinator | 0:bb348c97df44 | 219 | #define PHY_JABBER_DETECTION ((uint16_t)0x0002) /*!< Jabber condition detected */ |
lypinator | 0:bb348c97df44 | 220 | |
lypinator | 0:bb348c97df44 | 221 | /* Section 4: Extended PHY Registers */ |
lypinator | 0:bb348c97df44 | 222 | |
lypinator | 0:bb348c97df44 | 223 | #define PHY_SR ((uint16_t)0x0010) /*!< PHY status register Offset */ |
lypinator | 0:bb348c97df44 | 224 | #define PHY_MICR ((uint16_t)0x0011) /*!< MII Interrupt Control Register */ |
lypinator | 0:bb348c97df44 | 225 | #define PHY_MISR ((uint16_t)0x0012) /*!< MII Interrupt Status and Misc. Control Register */ |
lypinator | 0:bb348c97df44 | 226 | |
lypinator | 0:bb348c97df44 | 227 | #define PHY_LINK_STATUS ((uint16_t)0x0001) /*!< PHY Link mask */ |
lypinator | 0:bb348c97df44 | 228 | #define PHY_SPEED_STATUS ((uint16_t)0x0002) /*!< PHY Speed mask */ |
lypinator | 0:bb348c97df44 | 229 | #define PHY_DUPLEX_STATUS ((uint16_t)0x0004) /*!< PHY Duplex mask */ |
lypinator | 0:bb348c97df44 | 230 | |
lypinator | 0:bb348c97df44 | 231 | #define PHY_MICR_INT_EN ((uint16_t)0x0002) /*!< PHY Enable interrupts */ |
lypinator | 0:bb348c97df44 | 232 | #define PHY_MICR_INT_OE ((uint16_t)0x0001) /*!< PHY Enable output interrupt events */ |
lypinator | 0:bb348c97df44 | 233 | |
lypinator | 0:bb348c97df44 | 234 | #define PHY_MISR_LINK_INT_EN ((uint16_t)0x0020) /*!< Enable Interrupt on change of link status */ |
lypinator | 0:bb348c97df44 | 235 | #define PHY_LINK_INTERRUPT ((uint16_t)0x2000) /*!< PHY link status interrupt mask */ |
lypinator | 0:bb348c97df44 | 236 | |
lypinator | 0:bb348c97df44 | 237 | /* ################## SPI peripheral configuration ########################## */ |
lypinator | 0:bb348c97df44 | 238 | |
lypinator | 0:bb348c97df44 | 239 | /* CRC FEATURE: Use to activate CRC feature inside HAL SPI Driver |
lypinator | 0:bb348c97df44 | 240 | * Activated: CRC code is present inside driver |
lypinator | 0:bb348c97df44 | 241 | * Deactivated: CRC code cleaned from driver |
lypinator | 0:bb348c97df44 | 242 | */ |
lypinator | 0:bb348c97df44 | 243 | |
lypinator | 0:bb348c97df44 | 244 | #define USE_SPI_CRC 1U |
lypinator | 0:bb348c97df44 | 245 | |
lypinator | 0:bb348c97df44 | 246 | /* Includes ------------------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 247 | /** |
lypinator | 0:bb348c97df44 | 248 | * @brief Include module's header file |
lypinator | 0:bb348c97df44 | 249 | */ |
lypinator | 0:bb348c97df44 | 250 | |
lypinator | 0:bb348c97df44 | 251 | #ifdef HAL_RCC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 252 | #include "stm32f4xx_hal_rcc.h" |
lypinator | 0:bb348c97df44 | 253 | #endif /* HAL_RCC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 254 | |
lypinator | 0:bb348c97df44 | 255 | #ifdef HAL_GPIO_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 256 | #include "stm32f4xx_hal_gpio.h" |
lypinator | 0:bb348c97df44 | 257 | #endif /* HAL_GPIO_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 258 | |
lypinator | 0:bb348c97df44 | 259 | #ifdef HAL_DMA_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 260 | #include "stm32f4xx_hal_dma.h" |
lypinator | 0:bb348c97df44 | 261 | #endif /* HAL_DMA_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 262 | |
lypinator | 0:bb348c97df44 | 263 | #ifdef HAL_CORTEX_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 264 | #include "stm32f4xx_hal_cortex.h" |
lypinator | 0:bb348c97df44 | 265 | #endif /* HAL_CORTEX_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 266 | |
lypinator | 0:bb348c97df44 | 267 | #ifdef HAL_ADC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 268 | #include "stm32f4xx_hal_adc.h" |
lypinator | 0:bb348c97df44 | 269 | #endif /* HAL_ADC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 270 | |
lypinator | 0:bb348c97df44 | 271 | #ifdef HAL_CAN_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 272 | #include "stm32f4xx_hal_can.h" |
lypinator | 0:bb348c97df44 | 273 | #endif /* HAL_CAN_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 274 | |
lypinator | 0:bb348c97df44 | 275 | #ifdef HAL_CAN_LEGACY_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 276 | #include "stm32f4xx_hal_can_legacy.h" |
lypinator | 0:bb348c97df44 | 277 | #endif /* HAL_CAN_LEGACY_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 278 | |
lypinator | 0:bb348c97df44 | 279 | #ifdef HAL_CRC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 280 | #include "stm32f4xx_hal_crc.h" |
lypinator | 0:bb348c97df44 | 281 | #endif /* HAL_CRC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 282 | |
lypinator | 0:bb348c97df44 | 283 | #ifdef HAL_CRYP_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 284 | #include "stm32f4xx_hal_cryp.h" |
lypinator | 0:bb348c97df44 | 285 | #endif /* HAL_CRYP_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 286 | |
lypinator | 0:bb348c97df44 | 287 | #ifdef HAL_DMA2D_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 288 | #include "stm32f4xx_hal_dma2d.h" |
lypinator | 0:bb348c97df44 | 289 | #endif /* HAL_DMA2D_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 290 | |
lypinator | 0:bb348c97df44 | 291 | #ifdef HAL_DAC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 292 | #include "stm32f4xx_hal_dac.h" |
lypinator | 0:bb348c97df44 | 293 | #endif /* HAL_DAC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 294 | |
lypinator | 0:bb348c97df44 | 295 | #ifdef HAL_DCMI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 296 | #include "stm32f4xx_hal_dcmi.h" |
lypinator | 0:bb348c97df44 | 297 | #endif /* HAL_DCMI_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 298 | |
lypinator | 0:bb348c97df44 | 299 | #ifdef HAL_ETH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 300 | #include "stm32f4xx_hal_eth.h" |
lypinator | 0:bb348c97df44 | 301 | #endif /* HAL_ETH_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 302 | |
lypinator | 0:bb348c97df44 | 303 | #ifdef HAL_FLASH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 304 | #include "stm32f4xx_hal_flash.h" |
lypinator | 0:bb348c97df44 | 305 | #endif /* HAL_FLASH_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 306 | |
lypinator | 0:bb348c97df44 | 307 | #ifdef HAL_SRAM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 308 | #include "stm32f4xx_hal_sram.h" |
lypinator | 0:bb348c97df44 | 309 | #endif /* HAL_SRAM_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 310 | |
lypinator | 0:bb348c97df44 | 311 | #ifdef HAL_NOR_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 312 | #include "stm32f4xx_hal_nor.h" |
lypinator | 0:bb348c97df44 | 313 | #endif /* HAL_NOR_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 314 | |
lypinator | 0:bb348c97df44 | 315 | #ifdef HAL_NAND_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 316 | #include "stm32f4xx_hal_nand.h" |
lypinator | 0:bb348c97df44 | 317 | #endif /* HAL_NAND_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 318 | |
lypinator | 0:bb348c97df44 | 319 | #ifdef HAL_PCCARD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 320 | #include "stm32f4xx_hal_pccard.h" |
lypinator | 0:bb348c97df44 | 321 | #endif /* HAL_PCCARD_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 322 | |
lypinator | 0:bb348c97df44 | 323 | #ifdef HAL_SDRAM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 324 | #include "stm32f4xx_hal_sdram.h" |
lypinator | 0:bb348c97df44 | 325 | #endif /* HAL_SDRAM_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 326 | |
lypinator | 0:bb348c97df44 | 327 | #ifdef HAL_HASH_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 328 | #include "stm32f4xx_hal_hash.h" |
lypinator | 0:bb348c97df44 | 329 | #endif /* HAL_HASH_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 330 | |
lypinator | 0:bb348c97df44 | 331 | #ifdef HAL_I2C_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 332 | #include "stm32f4xx_hal_i2c.h" |
lypinator | 0:bb348c97df44 | 333 | #endif /* HAL_I2C_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 334 | |
lypinator | 0:bb348c97df44 | 335 | #ifdef HAL_I2S_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 336 | #include "stm32f4xx_hal_i2s.h" |
lypinator | 0:bb348c97df44 | 337 | #endif /* HAL_I2S_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 338 | |
lypinator | 0:bb348c97df44 | 339 | #ifdef HAL_IWDG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 340 | #include "stm32f4xx_hal_iwdg.h" |
lypinator | 0:bb348c97df44 | 341 | #endif /* HAL_IWDG_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 342 | |
lypinator | 0:bb348c97df44 | 343 | #ifdef HAL_LTDC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 344 | #include "stm32f4xx_hal_ltdc.h" |
lypinator | 0:bb348c97df44 | 345 | #endif /* HAL_LTDC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 346 | |
lypinator | 0:bb348c97df44 | 347 | #ifdef HAL_PWR_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 348 | #include "stm32f4xx_hal_pwr.h" |
lypinator | 0:bb348c97df44 | 349 | #endif /* HAL_PWR_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 350 | |
lypinator | 0:bb348c97df44 | 351 | #ifdef HAL_RNG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 352 | #include "stm32f4xx_hal_rng.h" |
lypinator | 0:bb348c97df44 | 353 | #endif /* HAL_RNG_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 354 | |
lypinator | 0:bb348c97df44 | 355 | #ifdef HAL_RTC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 356 | #include "stm32f4xx_hal_rtc.h" |
lypinator | 0:bb348c97df44 | 357 | #endif /* HAL_RTC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 358 | |
lypinator | 0:bb348c97df44 | 359 | #ifdef HAL_SAI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 360 | #include "stm32f4xx_hal_sai.h" |
lypinator | 0:bb348c97df44 | 361 | #endif /* HAL_SAI_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 362 | |
lypinator | 0:bb348c97df44 | 363 | #ifdef HAL_SD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 364 | #include "stm32f4xx_hal_sd.h" |
lypinator | 0:bb348c97df44 | 365 | #endif /* HAL_SD_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 366 | |
lypinator | 0:bb348c97df44 | 367 | #ifdef HAL_SPI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 368 | #include "stm32f4xx_hal_spi.h" |
lypinator | 0:bb348c97df44 | 369 | #endif /* HAL_SPI_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 370 | |
lypinator | 0:bb348c97df44 | 371 | #ifdef HAL_TIM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 372 | #include "stm32f4xx_hal_tim.h" |
lypinator | 0:bb348c97df44 | 373 | #endif /* HAL_TIM_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 374 | |
lypinator | 0:bb348c97df44 | 375 | #ifdef HAL_UART_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 376 | #include "stm32f4xx_hal_uart.h" |
lypinator | 0:bb348c97df44 | 377 | #endif /* HAL_UART_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 378 | |
lypinator | 0:bb348c97df44 | 379 | #ifdef HAL_USART_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 380 | #include "stm32f4xx_hal_usart.h" |
lypinator | 0:bb348c97df44 | 381 | #endif /* HAL_USART_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 382 | |
lypinator | 0:bb348c97df44 | 383 | #ifdef HAL_IRDA_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 384 | #include "stm32f4xx_hal_irda.h" |
lypinator | 0:bb348c97df44 | 385 | #endif /* HAL_IRDA_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 386 | |
lypinator | 0:bb348c97df44 | 387 | #ifdef HAL_SMARTCARD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 388 | #include "stm32f4xx_hal_smartcard.h" |
lypinator | 0:bb348c97df44 | 389 | #endif /* HAL_SMARTCARD_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 390 | |
lypinator | 0:bb348c97df44 | 391 | #ifdef HAL_WWDG_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 392 | #include "stm32f4xx_hal_wwdg.h" |
lypinator | 0:bb348c97df44 | 393 | #endif /* HAL_WWDG_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 394 | |
lypinator | 0:bb348c97df44 | 395 | #ifdef HAL_PCD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 396 | #include "stm32f4xx_hal_pcd.h" |
lypinator | 0:bb348c97df44 | 397 | #endif /* HAL_PCD_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 398 | |
lypinator | 0:bb348c97df44 | 399 | #ifdef HAL_HCD_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 400 | #include "stm32f4xx_hal_hcd.h" |
lypinator | 0:bb348c97df44 | 401 | #endif /* HAL_HCD_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 402 | |
lypinator | 0:bb348c97df44 | 403 | #ifdef HAL_DSI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 404 | #include "stm32f4xx_hal_dsi.h" |
lypinator | 0:bb348c97df44 | 405 | #endif /* HAL_DSI_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 406 | |
lypinator | 0:bb348c97df44 | 407 | #ifdef HAL_QSPI_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 408 | #include "stm32f4xx_hal_qspi.h" |
lypinator | 0:bb348c97df44 | 409 | #endif /* HAL_QSPI_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 410 | |
lypinator | 0:bb348c97df44 | 411 | #ifdef HAL_CEC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 412 | #include "stm32f4xx_hal_cec.h" |
lypinator | 0:bb348c97df44 | 413 | #endif /* HAL_CEC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 414 | |
lypinator | 0:bb348c97df44 | 415 | #ifdef HAL_FMPI2C_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 416 | #include "stm32f4xx_hal_fmpi2c.h" |
lypinator | 0:bb348c97df44 | 417 | #endif /* HAL_FMPI2C_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 418 | |
lypinator | 0:bb348c97df44 | 419 | #ifdef HAL_SPDIFRX_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 420 | #include "stm32f4xx_hal_spdifrx.h" |
lypinator | 0:bb348c97df44 | 421 | #endif /* HAL_SPDIFRX_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 422 | |
lypinator | 0:bb348c97df44 | 423 | #ifdef HAL_DFSDM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 424 | #include "stm32f4xx_hal_dfsdm.h" |
lypinator | 0:bb348c97df44 | 425 | #endif /* HAL_DFSDM_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 426 | |
lypinator | 0:bb348c97df44 | 427 | #ifdef HAL_LPTIM_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 428 | #include "stm32f4xx_hal_lptim.h" |
lypinator | 0:bb348c97df44 | 429 | #endif /* HAL_LPTIM_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 430 | |
lypinator | 0:bb348c97df44 | 431 | #ifdef HAL_MMC_MODULE_ENABLED |
lypinator | 0:bb348c97df44 | 432 | #include "stm32f4xx_hal_mmc.h" |
lypinator | 0:bb348c97df44 | 433 | #endif /* HAL_MMC_MODULE_ENABLED */ |
lypinator | 0:bb348c97df44 | 434 | |
lypinator | 0:bb348c97df44 | 435 | /* Exported macro ------------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 436 | #ifdef USE_FULL_ASSERT |
lypinator | 0:bb348c97df44 | 437 | /* ALL MBED targets use same stm32_assert.h */ |
lypinator | 0:bb348c97df44 | 438 | #include "stm32_assert.h" |
lypinator | 0:bb348c97df44 | 439 | #else |
lypinator | 0:bb348c97df44 | 440 | #define assert_param(expr) ((void)0U) |
lypinator | 0:bb348c97df44 | 441 | #endif /* USE_FULL_ASSERT */ |
lypinator | 0:bb348c97df44 | 442 | |
lypinator | 0:bb348c97df44 | 443 | |
lypinator | 0:bb348c97df44 | 444 | #ifdef __cplusplus |
lypinator | 0:bb348c97df44 | 445 | } |
lypinator | 0:bb348c97df44 | 446 | #endif |
lypinator | 0:bb348c97df44 | 447 | |
lypinator | 0:bb348c97df44 | 448 | #endif /* __STM32F4xx_HAL_CONF_H */ |
lypinator | 0:bb348c97df44 | 449 | |
lypinator | 0:bb348c97df44 | 450 | |
lypinator | 0:bb348c97df44 | 451 | /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ |