a14011380e
Sync CubeMX regen output for the 6 newly assigned output pins:
KO5=PC15, KO4=PF5, KO_LED1=PF2, KO_LED2=PF3, KO_LED3=PE6,
KO_24V=PF4. All are push-pull, no-pull, low initial level in
MX_GPIO_Init. The BSP driver does not own these pins yet; the
drivable output count stays 4 (ioboard_do_write 4-bit mask).
netTask stack reduced from 1408 to 960 words, in both .ioc
FREERTOS.Tasks01 and freertos.c generated region. Rebuilt the
cubemx-survival baseline for the ioc-task-stacks drift (only that
one entry changed); --check now returns 0.
Keil full rebuild verified: 0 errors, 0 warnings. Refilled the
RAM budget ledger and memory snapshot from the authoritative map
along with the trend row and size attestation; --gate and --scan
both return 0. Regenerated the managed task tables in README and
AGENTS from freertos.c (netTask 960); task-table --check passes.
Doc sync and the 6-pin question were committed in 795ce970.
221 lines
6.4 KiB
C
221 lines
6.4 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) 2026 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 "stm32f4xx_hal.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 */
|
|
|
|
/* Exported functions prototypes ---------------------------------------------*/
|
|
void Error_Handler(void);
|
|
|
|
/* USER CODE BEGIN EFP */
|
|
|
|
/* USER CODE END EFP */
|
|
|
|
/* Private defines -----------------------------------------------------------*/
|
|
#define IN_D4_Pin GPIO_PIN_2
|
|
#define IN_D4_GPIO_Port GPIOE
|
|
#define HC165_IN2_Pin GPIO_PIN_3
|
|
#define HC165_IN2_GPIO_Port GPIOE
|
|
#define IN_E4_Pin GPIO_PIN_4
|
|
#define IN_E4_GPIO_Port GPIOE
|
|
#define CH395_INT_Pin GPIO_PIN_5
|
|
#define CH395_INT_GPIO_Port GPIOE
|
|
#define KO_LED3_Pin GPIO_PIN_6
|
|
#define KO_LED3_GPIO_Port GPIOE
|
|
#define KO6_Pin GPIO_PIN_14
|
|
#define KO6_GPIO_Port GPIOC
|
|
#define KO5_Pin GPIO_PIN_15
|
|
#define KO5_GPIO_Port GPIOC
|
|
#define TRIP_LED_Pin GPIO_PIN_0
|
|
#define TRIP_LED_GPIO_Port GPIOF
|
|
#define ERT_LED_Pin GPIO_PIN_1
|
|
#define ERT_LED_GPIO_Port GPIOF
|
|
#define KO_LED1_Pin GPIO_PIN_2
|
|
#define KO_LED1_GPIO_Port GPIOF
|
|
#define KO_LED2_Pin GPIO_PIN_3
|
|
#define KO_LED2_GPIO_Port GPIOF
|
|
#define KO_24V_Pin GPIO_PIN_4
|
|
#define KO_24V_GPIO_Port GPIOF
|
|
#define KO4_Pin GPIO_PIN_5
|
|
#define KO4_GPIO_Port GPIOF
|
|
#define CLZ_LED_Pin GPIO_PIN_6
|
|
#define CLZ_LED_GPIO_Port GPIOF
|
|
#define HC165_LD_Pin GPIO_PIN_2
|
|
#define HC165_LD_GPIO_Port GPIOC
|
|
#define HC165_CLK_Pin GPIO_PIN_3
|
|
#define HC165_CLK_GPIO_Port GPIOC
|
|
#define ADC9_RES_Pin GPIO_PIN_0
|
|
#define ADC9_RES_GPIO_Port GPIOA
|
|
#define ADC10_IC_Pin GPIO_PIN_1
|
|
#define ADC10_IC_GPIO_Port GPIOA
|
|
#define ADC11_IN_Pin GPIO_PIN_2
|
|
#define ADC11_IN_GPIO_Port GPIOA
|
|
#define ADC12_UC_Pin GPIO_PIN_3
|
|
#define ADC12_UC_GPIO_Port GPIOA
|
|
#define ADC13_RES_Pin GPIO_PIN_4
|
|
#define ADC13_RES_GPIO_Port GPIOA
|
|
#define ADC14_TEMP_Pin GPIO_PIN_5
|
|
#define ADC14_TEMP_GPIO_Port GPIOA
|
|
#define ADC15_IB_Pin GPIO_PIN_6
|
|
#define ADC15_IB_GPIO_Port GPIOA
|
|
#define ADC16_RES_Pin GPIO_PIN_7
|
|
#define ADC16_RES_GPIO_Port GPIOA
|
|
#define ADC17_UB_Pin GPIO_PIN_4
|
|
#define ADC17_UB_GPIO_Port GPIOC
|
|
#define LED1_Pin GPIO_PIN_5
|
|
#define LED1_GPIO_Port GPIOC
|
|
#define LED2_Pin GPIO_PIN_0
|
|
#define LED2_GPIO_Port GPIOB
|
|
#define LED3_Pin GPIO_PIN_1
|
|
#define LED3_GPIO_Port GPIOB
|
|
#define LED4_Pin GPIO_PIN_2
|
|
#define LED4_GPIO_Port GPIOB
|
|
#define LED5_Pin GPIO_PIN_11
|
|
#define LED5_GPIO_Port GPIOF
|
|
#define LED6_Pin GPIO_PIN_12
|
|
#define LED6_GPIO_Port GPIOF
|
|
#define DB0_Pin GPIO_PIN_0
|
|
#define DB0_GPIO_Port GPIOG
|
|
#define DB1_Pin GPIO_PIN_1
|
|
#define DB1_GPIO_Port GPIOG
|
|
#define ST_TX2_Pin GPIO_PIN_10
|
|
#define ST_TX2_GPIO_Port GPIOB
|
|
#define ST_RX2_Pin GPIO_PIN_11
|
|
#define ST_RX2_GPIO_Port GPIOB
|
|
#define CH395_SCS_Pin GPIO_PIN_12
|
|
#define CH395_SCS_GPIO_Port GPIOB
|
|
#define CH395F_SCK_Pin GPIO_PIN_13
|
|
#define CH395F_SCK_GPIO_Port GPIOB
|
|
#define CH395F_SDO_Pin GPIO_PIN_14
|
|
#define CH395F_SDO_GPIO_Port GPIOB
|
|
#define CH395F_SDOB15_Pin GPIO_PIN_15
|
|
#define CH395F_SDOB15_GPIO_Port GPIOB
|
|
#define DB2_Pin GPIO_PIN_2
|
|
#define DB2_GPIO_Port GPIOG
|
|
#define DB3_Pin GPIO_PIN_3
|
|
#define DB3_GPIO_Port GPIOG
|
|
#define DB4_Pin GPIO_PIN_4
|
|
#define DB4_GPIO_Port GPIOG
|
|
#define DB5_Pin GPIO_PIN_5
|
|
#define DB5_GPIO_Port GPIOG
|
|
#define DB6_Pin GPIO_PIN_6
|
|
#define DB6_GPIO_Port GPIOG
|
|
#define DB7_Pin GPIO_PIN_7
|
|
#define DB7_GPIO_Port GPIOG
|
|
#define DB8_Pin GPIO_PIN_8
|
|
#define DB8_GPIO_Port GPIOG
|
|
#define TP_FRSTDATA_Pin GPIO_PIN_6
|
|
#define TP_FRSTDATA_GPIO_Port GPIOC
|
|
#define TP_BUSY_Pin GPIO_PIN_7
|
|
#define TP_BUSY_GPIO_Port GPIOC
|
|
#define TP_BUSY_EXTI_IRQn EXTI9_5_IRQn
|
|
#define TP_RD_Pin GPIO_PIN_8
|
|
#define TP_RD_GPIO_Port GPIOC
|
|
#define TP_CONVST_Pin GPIO_PIN_9
|
|
#define TP_CONVST_GPIO_Port GPIOC
|
|
#define TP_OS2_Pin GPIO_PIN_8
|
|
#define TP_OS2_GPIO_Port GPIOA
|
|
#define TP_OS1_Pin GPIO_PIN_11
|
|
#define TP_OS1_GPIO_Port GPIOA
|
|
#define TP_OS0_Pin GPIO_PIN_12
|
|
#define TP_OS0_GPIO_Port GPIOA
|
|
#define ST_DIR4_Pin GPIO_PIN_15
|
|
#define ST_DIR4_GPIO_Port GPIOA
|
|
#define ST_TX4_Pin GPIO_PIN_10
|
|
#define ST_TX4_GPIO_Port GPIOC
|
|
#define ST_RX4_Pin GPIO_PIN_11
|
|
#define ST_RX4_GPIO_Port GPIOC
|
|
#define ST_TX1_Pin GPIO_PIN_12
|
|
#define ST_TX1_GPIO_Port GPIOC
|
|
#define ST_RX1_Pin GPIO_PIN_2
|
|
#define ST_RX1_GPIO_Port GPIOD
|
|
#define ST_TX3_Pin GPIO_PIN_5
|
|
#define ST_TX3_GPIO_Port GPIOD
|
|
#define ST_RX3_Pin GPIO_PIN_6
|
|
#define ST_RX3_GPIO_Port GPIOD
|
|
#define DB9_Pin GPIO_PIN_9
|
|
#define DB9_GPIO_Port GPIOG
|
|
#define DB10_Pin GPIO_PIN_10
|
|
#define DB10_GPIO_Port GPIOG
|
|
#define DB11_Pin GPIO_PIN_11
|
|
#define DB11_GPIO_Port GPIOG
|
|
#define DB12_Pin GPIO_PIN_12
|
|
#define DB12_GPIO_Port GPIOG
|
|
#define DB13_Pin GPIO_PIN_13
|
|
#define DB13_GPIO_Port GPIOG
|
|
#define DB14_Pin GPIO_PIN_14
|
|
#define DB14_GPIO_Port GPIOG
|
|
#define DB15_Pin GPIO_PIN_15
|
|
#define DB15_GPIO_Port GPIOG
|
|
#define GD_SCLK_Pin GPIO_PIN_3
|
|
#define GD_SCLK_GPIO_Port GPIOB
|
|
#define GD_SO_Pin GPIO_PIN_4
|
|
#define GD_SO_GPIO_Port GPIOB
|
|
#define GD_SI_Pin GPIO_PIN_5
|
|
#define GD_SI_GPIO_Port GPIOB
|
|
#define SD_SCL_Pin GPIO_PIN_6
|
|
#define SD_SCL_GPIO_Port GPIOB
|
|
#define SD_SDA_Pin GPIO_PIN_7
|
|
#define SD_SDA_GPIO_Port GPIOB
|
|
#define GD_WP_Pin GPIO_PIN_8
|
|
#define GD_WP_GPIO_Port GPIOB
|
|
#define GD_CS_Pin GPIO_PIN_0
|
|
#define GD_CS_GPIO_Port GPIOE
|
|
#define GD_HOLD_Pin GPIO_PIN_1
|
|
#define GD_HOLD_GPIO_Port GPIOE
|
|
|
|
/* USER CODE BEGIN Private defines */
|
|
|
|
/* USER CODE END Private defines */
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* __MAIN_H */
|