Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 
 
 

84 lignes
2.5 KiB

  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. * <h2><center>&copy; Copyright (c) 2026 STMicroelectronics.
  11. * All rights reserved.</center></h2>
  12. *
  13. * This software component is licensed by ST under BSD 3-Clause license,
  14. * the "License"; You may not use this file except in compliance with the
  15. * License. You may obtain a copy of the License at:
  16. * opensource.org/licenses/BSD-3-Clause
  17. *
  18. ******************************************************************************
  19. */
  20. /* USER CODE END Header */
  21. /* Define to prevent recursive inclusion -------------------------------------*/
  22. #ifndef __MAIN_H
  23. #define __MAIN_H
  24. #ifdef __cplusplus
  25. extern "C" {
  26. #endif
  27. /* Includes ------------------------------------------------------------------*/
  28. #include "stm32f4xx_hal.h"
  29. /* Private includes ----------------------------------------------------------*/
  30. /* USER CODE BEGIN Includes */
  31. #include <app_cfg.h>
  32. #include <os_cfg.h>
  33. #include <ucos_ii.h>
  34. /* USER CODE END Includes */
  35. /* Exported types ------------------------------------------------------------*/
  36. /* USER CODE BEGIN ET */
  37. /* USER CODE END ET */
  38. /* Exported constants --------------------------------------------------------*/
  39. /* USER CODE BEGIN EC */
  40. /* USER CODE END EC */
  41. /* Exported macro ------------------------------------------------------------*/
  42. /* USER CODE BEGIN EM */
  43. /* USER CODE END EM */
  44. /* Exported functions prototypes ---------------------------------------------*/
  45. void Error_Handler(void);
  46. /* USER CODE BEGIN EFP */
  47. /* USER CODE END EFP */
  48. /* USER CODE BEGIN ET */
  49. extern UART_HandleTypeDef huart1;
  50. /* USER CODE END ET */
  51. /* Private defines -----------------------------------------------------------*/
  52. /* USER CODE BEGIN Private defines */
  53. #define LED_GPIO_PORT GPIOF
  54. #define LED_GPIO_PIN GPIO_PIN_6
  55. #define LED_ON() HAL_GPIO_WritePin(LED_GPIO_PORT, LED_GPIO_PIN, GPIO_PIN_RESET)
  56. #define LED_OFF() HAL_GPIO_WritePin(LED_GPIO_PORT, LED_GPIO_PIN, GPIO_PIN_SET)
  57. #define LED_TOGGLE() HAL_GPIO_TogglePin(LED_GPIO_PORT, LED_GPIO_PIN)
  58. /* USER CODE END Private defines */
  59. #ifdef __cplusplus
  60. }
  61. #endif
  62. #endif /* __MAIN_H */
  63. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/