192 lines
6.1 KiB
C
192 lines
6.1 KiB
C
/* USER CODE BEGIN Header */
|
|
/**
|
|
******************************************************************************
|
|
* @file : main.h
|
|
* @brief : Header for main.c file.
|
|
* This file contains the common defines of the application.
|
|
******************************************************************************
|
|
* @attention
|
|
*
|
|
* Copyright (c) 2023 STMicroelectronics.
|
|
* All rights reserved.
|
|
*
|
|
* This software is licensed under terms that can be found in the LICENSE file
|
|
* in the root directory of this software component.
|
|
* If no LICENSE file comes with this software, it is provided AS-IS.
|
|
*
|
|
******************************************************************************
|
|
*/
|
|
/* USER CODE END Header */
|
|
|
|
/* Define to prevent recursive inclusion -------------------------------------*/
|
|
#ifndef __MAIN_H
|
|
#define __MAIN_H
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/* Includes ------------------------------------------------------------------*/
|
|
#include "stm32f7xx_hal.h"
|
|
|
|
#include "stm32f7xx_ll_dma.h"
|
|
#include "stm32f7xx_ll_spi.h"
|
|
#include "stm32f7xx_ll_tim.h"
|
|
#include "stm32f7xx_ll_usart.h"
|
|
#include "stm32f7xx_ll_rcc.h"
|
|
#include "stm32f7xx_ll_bus.h"
|
|
#include "stm32f7xx_ll_cortex.h"
|
|
#include "stm32f7xx_ll_system.h"
|
|
#include "stm32f7xx_ll_utils.h"
|
|
#include "stm32f7xx_ll_pwr.h"
|
|
#include "stm32f7xx_ll_gpio.h"
|
|
|
|
#include "stm32f7xx_ll_exti.h"
|
|
|
|
/* Private includes ----------------------------------------------------------*/
|
|
/* USER CODE BEGIN Includes */
|
|
|
|
/* USER CODE END Includes */
|
|
|
|
/* Exported types ------------------------------------------------------------*/
|
|
/* USER CODE BEGIN ET */
|
|
|
|
/* USER CODE END ET */
|
|
|
|
/* Exported constants --------------------------------------------------------*/
|
|
/* USER CODE BEGIN EC */
|
|
|
|
/* USER CODE END EC */
|
|
|
|
/* Exported macro ------------------------------------------------------------*/
|
|
/* USER CODE BEGIN EM */
|
|
|
|
/* USER CODE END EM */
|
|
|
|
void HAL_TIM_MspPostInit(TIM_HandleTypeDef *htim);
|
|
|
|
/* Exported functions prototypes ---------------------------------------------*/
|
|
void Error_Handler(void);
|
|
|
|
/* Private defines -----------------------------------------------------------*/
|
|
#define INP_0_Pin GPIO_PIN_3
|
|
#define INP_0_GPIO_Port GPIOF
|
|
#define INP_1_Pin GPIO_PIN_4
|
|
#define INP_1_GPIO_Port GPIOF
|
|
#define ADC_MPD2_CS_Pin GPIO_PIN_6
|
|
#define ADC_MPD2_CS_GPIO_Port GPIOF
|
|
#define SPI5_CNV_Pin GPIO_PIN_9
|
|
#define SPI5_CNV_GPIO_Port GPIOF
|
|
#define ADC_ThrLD2_CS_Pin GPIO_PIN_10
|
|
#define ADC_ThrLD2_CS_GPIO_Port GPIOF
|
|
#define EN_5V2_Pin GPIO_PIN_7
|
|
#define EN_5V2_GPIO_Port GPIOC
|
|
#define EN_5V1_Pin GPIO_PIN_3
|
|
#define EN_5V1_GPIO_Port GPIOC
|
|
#define AD9102_RESET_Pin GPIO_PIN_6
|
|
#define AD9102_RESET_GPIO_Port GPIOC
|
|
#define TECEN1_Pin GPIO_PIN_0
|
|
#define TECEN1_GPIO_Port GPIOA
|
|
#define TECEN2_Pin GPIO_PIN_1
|
|
#define TECEN2_GPIO_Port GPIOA
|
|
#define REF2_ON_Pin GPIO_PIN_3
|
|
#define REF2_ON_GPIO_Port GPIOA
|
|
#define DAC_TEC2_CS_Pin GPIO_PIN_8
|
|
#define DAC_TEC2_CS_GPIO_Port GPIOE
|
|
#define DAC_LD2_CS_Pin GPIO_PIN_6
|
|
#define DAC_LD2_CS_GPIO_Port GPIOA
|
|
#define LD2_EN_Pin GPIO_PIN_4
|
|
#define LD2_EN_GPIO_Port GPIOC
|
|
#define TEC2_PD_Pin GPIO_PIN_5
|
|
#define TEC2_PD_GPIO_Port GPIOC
|
|
#define TEC2_FLAG1_Pin GPIO_PIN_11
|
|
#define TEC2_FLAG1_GPIO_Port GPIOF
|
|
#define TEC2_FLAG2_Pin GPIO_PIN_12
|
|
#define TEC2_FLAG2_GPIO_Port GPIOF
|
|
#define TEC1_FLAG1_Pin GPIO_PIN_13
|
|
#define TEC1_FLAG1_GPIO_Port GPIOF
|
|
#define TEC1_FLAG2_Pin GPIO_PIN_14
|
|
#define TEC1_FLAG2_GPIO_Port GPIOF
|
|
#define ADC_MPD1_CS_Pin GPIO_PIN_10
|
|
#define ADC_MPD1_CS_GPIO_Port GPIOE
|
|
#define ADC_ThrLD1_CS_Pin GPIO_PIN_11
|
|
#define ADC_ThrLD1_CS_GPIO_Port GPIOE
|
|
#define SPI4_CNV_Pin GPIO_PIN_14
|
|
#define SPI4_CNV_GPIO_Port GPIOE
|
|
#define REF0_EN_Pin GPIO_PIN_10
|
|
#define REF0_EN_GPIO_Port GPIOB
|
|
#define TEC1_PD_Pin GPIO_PIN_11
|
|
#define TEC1_PD_GPIO_Port GPIOB
|
|
#define DAC_TEC1_CS_Pin GPIO_PIN_12
|
|
#define DAC_TEC1_CS_GPIO_Port GPIOD
|
|
#define DAC_LD1_CS_Pin GPIO_PIN_14
|
|
#define DAC_LD1_CS_GPIO_Port GPIOB
|
|
#define LD1_EN_Pin GPIO_PIN_8
|
|
#define LD1_EN_GPIO_Port GPIOD
|
|
#define AD9102_CS_Pin GPIO_PIN_12
|
|
#define AD9102_CS_GPIO_Port GPIOB
|
|
#define AD9833_CS_Pin GPIO_PIN_13
|
|
#define AD9833_CS_GPIO_Port GPIOD
|
|
#define AD9833_MCLK_Pin GPIO_PIN_9
|
|
#define AD9833_MCLK_GPIO_Port GPIOE
|
|
#define DS1809_UC_Pin GPIO_PIN_2
|
|
#define DS1809_UC_GPIO_Port GPIOE
|
|
#define DS1809_DC_Pin GPIO_PIN_3
|
|
#define DS1809_DC_GPIO_Port GPIOE
|
|
#define AD9102_TRIG_Pin GPIO_PIN_11
|
|
#define AD9102_TRIG_GPIO_Port GPIOD
|
|
#define USB_FLAG_Pin GPIO_PIN_8
|
|
#define USB_FLAG_GPIO_Port GPIOA
|
|
#define SDMMC1_EN_Pin GPIO_PIN_0
|
|
#define SDMMC1_EN_GPIO_Port GPIOD
|
|
#define TEST_01_Pin GPIO_PIN_1
|
|
#define TEST_01_GPIO_Port GPIOD
|
|
#define OUT_0_Pin GPIO_PIN_10
|
|
#define OUT_0_GPIO_Port GPIOG
|
|
#define OUT_1_Pin GPIO_PIN_11
|
|
#define OUT_1_GPIO_Port GPIOG
|
|
#define OUT_2_Pin GPIO_PIN_12
|
|
#define OUT_2_GPIO_Port GPIOG
|
|
#define OUT_3_Pin GPIO_PIN_13
|
|
#define OUT_3_GPIO_Port GPIOG
|
|
#define OUT_4_Pin GPIO_PIN_14
|
|
#define OUT_4_GPIO_Port GPIOG
|
|
#define OUT_5_Pin GPIO_PIN_15
|
|
#define OUT_5_GPIO_Port GPIOG
|
|
#define OUT_6_Pin GPIO_PIN_4
|
|
#define OUT_6_GPIO_Port GPIOB
|
|
#define OUT_7_Pin GPIO_PIN_5
|
|
#define OUT_7_GPIO_Port GPIOB
|
|
#define OUT_8_Pin GPIO_PIN_6
|
|
#define OUT_8_GPIO_Port GPIOB
|
|
#define OUT_9_Pin GPIO_PIN_7
|
|
#define OUT_9_GPIO_Port GPIOB
|
|
|
|
/* USER CODE BEGIN Private defines */
|
|
/* Board-level extensions only. Application-layer types live under App/. */
|
|
#define UI_LCD_RS_Pin GPIO_PIN_9
|
|
#define UI_LCD_RS_GPIO_Port GPIOG
|
|
#define UI_LCD_V0_REF_Pin GPIO_PIN_7
|
|
#define UI_LCD_V0_REF_GPIO_Port GPIOD
|
|
#define UI_LCD_CONTRAST_PWM_Pin GPIO_PIN_8
|
|
#define UI_LCD_CONTRAST_PWM_GPIO_Port GPIOB
|
|
#define UI_LCD_E_Pin OUT_0_Pin
|
|
#define UI_LCD_E_GPIO_Port OUT_0_GPIO_Port
|
|
#define UI_BUTTON_Pin OUT_1_Pin
|
|
#define UI_BUTTON_GPIO_Port OUT_1_GPIO_Port
|
|
#define UI_LCD_D4_Pin OUT_2_Pin
|
|
#define UI_LCD_D4_GPIO_Port OUT_2_GPIO_Port
|
|
#define UI_LCD_D5_Pin OUT_3_Pin
|
|
#define UI_LCD_D5_GPIO_Port OUT_3_GPIO_Port
|
|
#define UI_LCD_D6_Pin OUT_4_Pin
|
|
#define UI_LCD_D6_GPIO_Port OUT_4_GPIO_Port
|
|
#define UI_LCD_D7_Pin OUT_5_Pin
|
|
#define UI_LCD_D7_GPIO_Port OUT_5_GPIO_Port
|
|
/* USER CODE END Private defines */
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* __MAIN_H */
|