export board-specific macro for stm32 pins based on board yaml #3298

proteus meta progress
This commit is contained in:
Andrey 2021-10-25 14:22:46 -04:00
parent 719ecae60f
commit 53d16c67fe
2 changed files with 19 additions and 10 deletions

View File

@ -119,17 +119,11 @@ static void setupDefaultSensorInputs() {
engineConfiguration->triggerInputPins[1] = GPIO_UNASSIGNED;
engineConfiguration->triggerInputPins[2] = GPIO_UNASSIGNED;
// CLT = Analog Temp 3 = PB0
engineConfiguration->clt.adcChannel = EFI_ADC_8;
// IAT = Analog Temp 2 = PC5
engineConfiguration->iat.adcChannel = EFI_ADC_15;
// TPS = Analog volt 2 = PC1
engineConfiguration->tps1_1AdcChannel = EFI_ADC_11;
// MAP = Analog volt 1 = PC0
engineConfiguration->map.sensor.hwChannel = EFI_ADC_10;
engineConfiguration->clt.adcChannel = PROTEUS_IN_CLT;
engineConfiguration->iat.adcChannel = PROTEUS_IN_IAT;
engineConfiguration->tps1_1AdcChannel = PROTEUS_IN_TPS;
engineConfiguration->map.sensor.hwChannel = PROTEUS_IN_MAP;
// pin #28 WBO AFR "Analog Volt 10"
engineConfiguration->afr.hwChannel = EFI_ADC_5;

View File

@ -54,6 +54,21 @@
#define PROTEUS_HS_11 GPIOG_3
#define PROTEUS_HS_12 GPIOG_2
// IAT = Analog Temp 2 = PC5
#define PROTEUS_IN_ANALOG_TEMP_2 EFI_ADC_15
#define PROTEUS_IN_IAT PROTEUS_IN_ANALOG_TEMP_2
// CLT = Analog Temp 3 = PB0
#define PROTEUS_IN_ANALOG_TEMP_3 EFI_ADC_8
#define PROTEUS_IN_CLT PROTEUS_IN_ANALOG_TEMP_3
// MAP = Analog volt 1 = PC0
#define PROTEUS_IN_ANALOG_VOLT_1 EFI_ADC_10
#define PROTEUS_IN_MAP PROTEUS_IN_ANALOG_VOLT_1
// TPS = Analog volt 2 = PC1
#define PROTEUS_IN_ANALOG_VOLT_2 EFI_ADC_11
#define PROTEUS_IN_TPS PROTEUS_IN_ANALOG_VOLT_2
#define PROTEUS_VR_1 GPIOE_7
#define PROTEUS_VR_2 GPIOE_8