main.h 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  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. /* 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 "stm32f4xx_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 C0_CAN1_ENABLE_Pin GPIO_PIN_0
  46. #define C0_CAN1_ENABLE_GPIO_Port GPIOC
  47. #define A4_ADC_12V_Pin GPIO_PIN_4
  48. #define A4_ADC_12V_GPIO_Port GPIOA
  49. #define B0_ADC_FMU_5V_Pin GPIO_PIN_0
  50. #define B0_ADC_FMU_5V_GPIO_Port GPIOB
  51. #define B1_ADC_BATTER_Pin GPIO_PIN_1
  52. #define B1_ADC_BATTER_GPIO_Port GPIOB
  53. #define C9_CAN2_ENABLE_Pin GPIO_PIN_9
  54. #define C9_CAN2_ENABLE_GPIO_Port GPIOC
  55. #define A8_LIQUID_Pin GPIO_PIN_8
  56. #define A8_LIQUID_GPIO_Port GPIOA
  57. #define A9_FMU_USART_Pin GPIO_PIN_9
  58. #define A9_FMU_USART_GPIO_Port GPIOA
  59. #define A10_FMU_USART_Pin GPIO_PIN_10
  60. #define A10_FMU_USART_GPIO_Port GPIOA
  61. #define C10_LED_B_Pin GPIO_PIN_10
  62. #define C10_LED_B_GPIO_Port GPIOC
  63. #define C11_LED_R_Pin GPIO_PIN_11
  64. #define C11_LED_R_GPIO_Port GPIOC
  65. #define C10_LED_G_Pin GPIO_PIN_12
  66. #define C10_LED_G_GPIO_Port GPIOC
  67. #define B8_CAN1_Pin GPIO_PIN_8
  68. #define B8_CAN1_GPIO_Port GPIOB
  69. #define B9_CAN1_Pin GPIO_PIN_9
  70. #define B9_CAN1_GPIO_Port GPIOB
  71. /* USER CODE BEGIN Private defines */
  72. /* USER CODE END Private defines */
  73. #ifdef __cplusplus
  74. }
  75. #endif
  76. #endif /* __MAIN_H */