main.h 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  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) 2022 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. /* Define to prevent recursive inclusion -------------------------------------*/
  21. #ifndef __MAIN_H
  22. #define __MAIN_H
  23. #ifdef __cplusplus
  24. extern "C" {
  25. #endif
  26. /* Includes ------------------------------------------------------------------*/
  27. #include "stm32h7xx_hal.h"
  28. /* Private includes ----------------------------------------------------------*/
  29. /* USER CODE BEGIN Includes */
  30. /* USER CODE END Includes */
  31. /* Exported types ------------------------------------------------------------*/
  32. /* USER CODE BEGIN ET */
  33. /* USER CODE END ET */
  34. /* Exported constants --------------------------------------------------------*/
  35. /* USER CODE BEGIN EC */
  36. /* USER CODE END EC */
  37. /* Exported macro ------------------------------------------------------------*/
  38. /* USER CODE BEGIN EM */
  39. /* USER CODE END EM */
  40. /* Exported functions prototypes ---------------------------------------------*/
  41. void Error_Handler(void);
  42. /* USER CODE BEGIN EFP */
  43. /* USER CODE END EFP */
  44. /* Private defines -----------------------------------------------------------*/
  45. #define MII_TX_EN_Pin GPIO_PIN_11
  46. #define MII_TX_EN_GPIO_Port GPIOG
  47. #define OSC32_OUT_Pin GPIO_PIN_15
  48. #define OSC32_OUT_GPIO_Port GPIOC
  49. #define OSC32_IN_Pin GPIO_PIN_14
  50. #define OSC32_IN_GPIO_Port GPIOC
  51. #define MII_TXD3_Pin GPIO_PIN_2
  52. #define MII_TXD3_GPIO_Port GPIOE
  53. #define MII_TXD1_Pin GPIO_PIN_12
  54. #define MII_TXD1_GPIO_Port GPIOG
  55. #define MII_TXD0_Pin GPIO_PIN_13
  56. #define MII_TXD0_GPIO_Port GPIOG
  57. #define MII_RX_ER_Pin GPIO_PIN_10
  58. #define MII_RX_ER_GPIO_Port GPIOI
  59. #define OSC_OUT_Pin GPIO_PIN_1
  60. #define OSC_OUT_GPIO_Port GPIOH
  61. #define OSC_IN_Pin GPIO_PIN_0
  62. #define OSC_IN_GPIO_Port GPIOH
  63. #define MII_MDC_Pin GPIO_PIN_1
  64. #define MII_MDC_GPIO_Port GPIOC
  65. #define MII_TXD2_Pin GPIO_PIN_2
  66. #define MII_TXD2_GPIO_Port GPIOC
  67. #define MII_TX_CLK_Pin GPIO_PIN_3
  68. #define MII_TX_CLK_GPIO_Port GPIOC
  69. #define MII_MDIO_Pin GPIO_PIN_2
  70. #define MII_MDIO_GPIO_Port GPIOA
  71. #define MII_CRS_Pin GPIO_PIN_0
  72. #define MII_CRS_GPIO_Port GPIOA
  73. #define MII_RXD0_Pin GPIO_PIN_4
  74. #define MII_RXD0_GPIO_Port GPIOC
  75. #define MII_RXD3_Pin GPIO_PIN_1
  76. #define MII_RXD3_GPIO_Port GPIOB
  77. #define MII_COL_Pin GPIO_PIN_3
  78. #define MII_COL_GPIO_Port GPIOA
  79. #define MII_RXD1_Pin GPIO_PIN_5
  80. #define MII_RXD1_GPIO_Port GPIOC
  81. #define MII_RXD2_Pin GPIO_PIN_0
  82. #define MII_RXD2_GPIO_Port GPIOB
  83. /* USER CODE BEGIN Private defines */
  84. /* USER CODE END Private defines */
  85. #ifdef __cplusplus
  86. }
  87. #endif
  88. #endif /* __MAIN_H */