1 /* USER CODE BEGIN Header */ 2 /** 3 ****************************************************************************** 4 * @file : main.h 5 * @brief : Header for main.c file. 6 * This file contains the common defines of the application. 7 ****************************************************************************** 8 * @attention 9 * 10 * Copyright (c) 2024 STMicroelectronics. 11 * All rights reserved. 12 * 13 * This software is licensed under terms that can be found in the LICENSE file 14 * in the root directory of this software component. 15 * If no LICENSE file comes with this software, it is provided AS-IS. 16 * 17 ****************************************************************************** 18 */ 19 /* USER CODE END Header */ 20 21 /* Define to prevent recursive inclusion -------------------------------------*/ 22 #ifndef __MAIN_H 23 #define __MAIN_H 24 25 #ifdef __cplusplus 26 extern "C" { 27 #endif 28 29 /* Includes ------------------------------------------------------------------*/ 30 #include "stm32h5xx_hal.h" 31 #include "stm32h5xx_ll_ucpd.h" 32 #include "stm32h5xx_ll_bus.h" 33 #include "stm32h5xx_ll_cortex.h" 34 #include "stm32h5xx_ll_rcc.h" 35 #include "stm32h5xx_ll_system.h" 36 #include "stm32h5xx_ll_utils.h" 37 #include "stm32h5xx_ll_pwr.h" 38 #include "stm32h5xx_ll_gpio.h" 39 #include "stm32h5xx_ll_dma.h" 40 41 #include "stm32h5xx_ll_exti.h" 42 43 /* Private includes ----------------------------------------------------------*/ 44 /* USER CODE BEGIN Includes */ 45 46 /* USER CODE END Includes */ 47 48 /* Exported types ------------------------------------------------------------*/ 49 /* USER CODE BEGIN ET */ 50 51 /* USER CODE END ET */ 52 53 /* Exported constants --------------------------------------------------------*/ 54 /* USER CODE BEGIN EC */ 55 56 /* USER CODE END EC */ 57 58 /* Exported macro ------------------------------------------------------------*/ 59 /* USER CODE BEGIN EM */ 60 61 /* USER CODE END EM */ 62 63 void HAL_TIM_MspPostInit(TIM_HandleTypeDef *htim); 64 65 /* Exported functions prototypes ---------------------------------------------*/ 66 void Error_Handler(void); 67 68 /* USER CODE BEGIN EFP */ 69 70 /* USER CODE END EFP */ 71 72 /* Private defines -----------------------------------------------------------*/ 73 #define TRACE_CK_Pin GPIO_PIN_2 74 #define TRACE_CK_GPIO_Port GPIOE 75 #define TRACE_D0_Pin GPIO_PIN_3 76 #define TRACE_D0_GPIO_Port GPIOE 77 #define TRACE_D1_Pin GPIO_PIN_4 78 #define TRACE_D1_GPIO_Port GPIOE 79 #define TRACE_D2_Pin GPIO_PIN_5 80 #define TRACE_D2_GPIO_Port GPIOE 81 #define TRACE_D3_Pin GPIO_PIN_6 82 #define TRACE_D3_GPIO_Port GPIOE 83 #define USER_BUTTON_Pin GPIO_PIN_13 84 #define USER_BUTTON_GPIO_Port GPIOC 85 #define LED2_YELLOW_Pin GPIO_PIN_4 86 #define LED2_YELLOW_GPIO_Port GPIOF 87 #define RMII_MDC_Pin GPIO_PIN_1 88 #define RMII_MDC_GPIO_Port GPIOC 89 #define RMII_REF_CLK_Pin GPIO_PIN_1 90 #define RMII_REF_CLK_GPIO_Port GPIOA 91 #define RMII_MDIO_Pin GPIO_PIN_2 92 #define RMII_MDIO_GPIO_Port GPIOA 93 #define VBUS_SENSE_Pin GPIO_PIN_4 94 #define VBUS_SENSE_GPIO_Port GPIOA 95 #define RMII_CRS_DV_Pin GPIO_PIN_7 96 #define RMII_CRS_DV_GPIO_Port GPIOA 97 #define RMII_RXD0_Pin GPIO_PIN_4 98 #define RMII_RXD0_GPIO_Port GPIOC 99 #define RMII_RXD1_Pin GPIO_PIN_5 100 #define RMII_RXD1_GPIO_Port GPIOC 101 #define LED1_GREEN_Pin GPIO_PIN_0 102 #define LED1_GREEN_GPIO_Port GPIOB 103 #define UCPD_CC1_Pin GPIO_PIN_13 104 #define UCPD_CC1_GPIO_Port GPIOB 105 #define UCPD_CC2_Pin GPIO_PIN_14 106 #define UCPD_CC2_GPIO_Port GPIOB 107 #define RMII_TXD1_Pin GPIO_PIN_15 108 #define RMII_TXD1_GPIO_Port GPIOB 109 #define T_VCP_TX_Pin GPIO_PIN_8 110 #define T_VCP_TX_GPIO_Port GPIOD 111 #define T_VCP_RX_Pin GPIO_PIN_9 112 #define T_VCP_RX_GPIO_Port GPIOD 113 #define LED3_RED_Pin GPIO_PIN_4 114 #define LED3_RED_GPIO_Port GPIOG 115 #define UCPD_FLT_Pin GPIO_PIN_7 116 #define UCPD_FLT_GPIO_Port GPIOG 117 #define UCPD_DBn_Pin GPIO_PIN_9 118 #define UCPD_DBn_GPIO_Port GPIOA 119 #define USB_FS_N_Pin GPIO_PIN_11 120 #define USB_FS_N_GPIO_Port GPIOA 121 #define USB_FS_P_Pin GPIO_PIN_12 122 #define USB_FS_P_GPIO_Port GPIOA 123 #define SWDIO_Pin GPIO_PIN_13 124 #define SWDIO_GPIO_Port GPIOA 125 #define SWCLK_Pin GPIO_PIN_14 126 #define SWCLK_GPIO_Port GPIOA 127 #define T_JTDI_Pin GPIO_PIN_15 128 #define T_JTDI_GPIO_Port GPIOA 129 #define RMII_TXT_EN_Pin GPIO_PIN_11 130 #define RMII_TXT_EN_GPIO_Port GPIOG 131 #define RMI_TXD0_Pin GPIO_PIN_13 132 #define RMI_TXD0_GPIO_Port GPIOG 133 #define SWO_Pin GPIO_PIN_3 134 #define SWO_GPIO_Port GPIOB 135 #define ARD_D1_TX_Pin GPIO_PIN_6 136 #define ARD_D1_TX_GPIO_Port GPIOB 137 #define ARD_D0_RX_Pin GPIO_PIN_7 138 #define ARD_D0_RX_GPIO_Port GPIOB 139 140 /* USER CODE BEGIN Private defines */ 141 142 /* USER CODE END Private defines */ 143 144 #ifdef __cplusplus 145 } 146 #endif 147 148 #endif /* __MAIN_H */ 149