main.h 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  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 "stm32f1xx_hal.h"
  28. /* Private includes ----------------------------------------------------------*/
  29. /* USER CODE BEGIN Includes */
  30. #include "stdio.h"
  31. #include "string.h"
  32. #include "stdbool.h"
  33. #include "mba32a.h"
  34. #include "ml307a.h"
  35. #include "ConfigMacros.h"
  36. #include "key.h"
  37. #include "interface.h"
  38. #include "dtuaes.h"
  39. #include "tt808.h"
  40. /* USER CODE END Includes */
  41. /* Exported types ------------------------------------------------------------*/
  42. /* USER CODE BEGIN ET */
  43. /* USER CODE END ET */
  44. /* Exported constants --------------------------------------------------------*/
  45. /* USER CODE BEGIN EC */
  46. /* USER CODE END EC */
  47. /* Exported macro ------------------------------------------------------------*/
  48. /* USER CODE BEGIN EM */
  49. /* USER CODE END EM */
  50. /* Exported functions prototypes ---------------------------------------------*/
  51. void Error_Handler(void);
  52. /* USER CODE BEGIN EFP */
  53. /* USER CODE END EFP */
  54. /* Private defines -----------------------------------------------------------*/
  55. #define WDI_Pin GPIO_PIN_0
  56. #define WDI_GPIO_Port GPIOC
  57. #define REST_4G_Pin GPIO_PIN_1
  58. #define REST_4G_GPIO_Port GPIOA
  59. #define CS_Pin GPIO_PIN_4
  60. #define CS_GPIO_Port GPIOA
  61. #define SCL_Pin GPIO_PIN_5
  62. #define SCL_GPIO_Port GPIOA
  63. #define DC_Pin GPIO_PIN_6
  64. #define DC_GPIO_Port GPIOA
  65. #define SDA_Pin GPIO_PIN_7
  66. #define SDA_GPIO_Port GPIOA
  67. #define RES_Pin GPIO_PIN_4
  68. #define RES_GPIO_Port GPIOC
  69. #define SCK_2_Pin GPIO_PIN_13
  70. #define SCK_2_GPIO_Port GPIOB
  71. #define SDA_2_Pin GPIO_PIN_15
  72. #define SDA_2_GPIO_Port GPIOB
  73. #define REST_433_Pin GPIO_PIN_7
  74. #define REST_433_GPIO_Port GPIOC
  75. #define REST_BT_Pin GPIO_PIN_15
  76. #define REST_BT_GPIO_Port GPIOA
  77. /* USER CODE BEGIN Private defines */
  78. extern LockSNu8 locksnu8;
  79. extern uint8_t smac1[2];
  80. extern uint8_t smac2[2];
  81. extern uint8_t smac3[2];
  82. extern uint8_t smac4[2];
  83. void readLockStatusinit(void);
  84. /* USER CODE END Private defines */
  85. #ifdef __cplusplus
  86. }
  87. #endif
  88. #endif /* __MAIN_H */