A low cost DIY sound pressure level sensor for enabling environmental noise awareness. https://lukasschwarz.org/noise-sensor
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

85 lines
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) 2021 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 "stm32g0xx_hal.h"
  29. /* Private includes ----------------------------------------------------------*/
  30. /* USER CODE BEGIN Includes */
  31. /* USER CODE END Includes */
  32. /* Exported types ------------------------------------------------------------*/
  33. /* USER CODE BEGIN ET */
  34. /* USER CODE END ET */
  35. /* Exported constants --------------------------------------------------------*/
  36. /* USER CODE BEGIN EC */
  37. /* USER CODE END EC */
  38. /* Exported macro ------------------------------------------------------------*/
  39. /* USER CODE BEGIN EM */
  40. /* USER CODE END EM */
  41. /* Exported functions prototypes ---------------------------------------------*/
  42. void Error_Handler(void);
  43. /* USER CODE BEGIN EFP */
  44. /* USER CODE END EFP */
  45. /* Private defines -----------------------------------------------------------*/
  46. #define Device_ID_Pin GPIO_PIN_2
  47. #define Device_ID_GPIO_Port GPIOA
  48. #define NSS_Pin GPIO_PIN_5
  49. #define NSS_GPIO_Port GPIOA
  50. #define LED_Pin GPIO_PIN_6
  51. #define LED_GPIO_Port GPIOA
  52. #define RESET_Pin GPIO_PIN_7
  53. #define RESET_GPIO_Port GPIOA
  54. #define BAT_Monitor_Pin GPIO_PIN_1
  55. #define BAT_Monitor_GPIO_Port GPIOB
  56. #define I2C_Address_Pin GPIO_PIN_6
  57. #define I2C_Address_GPIO_Port GPIOC
  58. /* USER CODE BEGIN Private defines */
  59. /* USER CODE END Private defines */
  60. #ifdef __cplusplus
  61. }
  62. #endif
  63. #endif /* __MAIN_H */
  64. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/