export board-specific macro for stm32 pins based on board yaml #3298
This commit is contained in:
parent
0f026220ca
commit
948d7161aa
|
@ -1,4 +1,3 @@
|
|||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
# copyright: Michael Holzer
|
||||
|
||||
pins:
|
||||
|
|
|
@ -70,12 +70,12 @@ static void setupDefaultSensorInputs() {
|
|||
|
||||
void boardInitHardware() {
|
||||
|
||||
alphaTachPullUp.initPin("a-tach", H144_OUT_IO1);
|
||||
alphaTempPullUp.initPin("a-temp", H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", H144_OUT_IO2);
|
||||
alphaCrankNPullUp.initPin("a-crank-n", H144_OUT_IO5);
|
||||
alpha2stepPullDown.initPin("a-2step", H144_OUT_IO7);
|
||||
alphaCamPullDown.initPin("a-cam", H144_OUT_IO8);
|
||||
alphaTachPullUp.initPin("a-tach", Gpio::H144_OUT_IO1);
|
||||
alphaTempPullUp.initPin("a-temp", Gpio::H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", Gpio::H144_OUT_IO2);
|
||||
alphaCrankNPullUp.initPin("a-crank-n", Gpio::H144_OUT_IO5);
|
||||
alpha2stepPullDown.initPin("a-2step", Gpio::H144_OUT_IO7);
|
||||
alphaCamPullDown.initPin("a-cam", Gpio::H144_OUT_IO8);
|
||||
boardOnConfigurationChange(nullptr);
|
||||
}
|
||||
|
||||
|
@ -105,7 +105,7 @@ void setBoardConfigOverrides() {
|
|||
configureHellenMegaAccCS2Pin();
|
||||
setHellenMegaEnPin();
|
||||
} else {
|
||||
setHellenEnPin(H144_OUT_IO3);
|
||||
setHellenEnPin(Gpio::H144_OUT_IO3);
|
||||
}
|
||||
|
||||
setDefaultHellenAtPullUps();
|
||||
|
@ -127,19 +127,19 @@ void setBoardDefaultConfiguration() {
|
|||
int16_t hellenBoardId = engine->engineState.hellenBoardId;
|
||||
if (isMegaModuleRevision()) {
|
||||
setHellenMMbaro();
|
||||
engineConfiguration->map.sensor.hwChannel = Gpio::H144_IN_MAP3; // On-board MAP
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP3; // On-board MAP
|
||||
engineConfiguration->map.sensor.type = MT_MPXH6400;
|
||||
} else {
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP2; // B2 external signal
|
||||
engineConfiguration->baroSensor.type = MT_MPXH6400;
|
||||
engineConfiguration->baroSensor.hwChannel = Gpio::H144_IN_MAP3; // On-board MAP
|
||||
engineConfiguration->baroSensor.hwChannel = H144_IN_MAP3; // On-board MAP
|
||||
}
|
||||
|
||||
engineConfiguration->boardUseTempPullUp = true;
|
||||
|
||||
engineConfiguration->acSwitch = Gpio::Unassigned;
|
||||
engineConfiguration->fuelPumpPin = H144_OUT_PWM2;
|
||||
engineConfiguration->fanPin = H144_OUT_PWM4;
|
||||
engineConfiguration->fuelPumpPin = Gpio::H144_OUT_PWM2;
|
||||
engineConfiguration->fanPin = Gpio::H144_OUT_PWM4;
|
||||
engineConfiguration->mainRelayPin = Gpio::Unassigned;
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM3;
|
||||
|
||||
|
@ -152,7 +152,7 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
// ? engineConfiguration->malfunctionIndicatorPin = Gpio::G4; //1E - Check Engine Light
|
||||
engineConfiguration->vrThreshold[0].pin = H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[0].pin = Gpio::H144_OUT_PWM6;
|
||||
}
|
||||
|
||||
void boardPrepareForStop() {
|
||||
|
|
|
@ -15,8 +15,7 @@ pins:
|
|||
color: red
|
||||
|
||||
- pin: A3
|
||||
# H144_OUT_PWM2
|
||||
id: C6
|
||||
meta: H144_OUT_PWM2
|
||||
class: outputs
|
||||
function: Fuel Pump Relay Output (low)
|
||||
type: ls
|
||||
|
@ -24,8 +23,7 @@ pins:
|
|||
color: purple
|
||||
|
||||
- pin: A4
|
||||
# H144_OUT_PWM3
|
||||
id: C7
|
||||
meta: H144_OUT_PWM3
|
||||
class: outputs
|
||||
function: Tachometer Output
|
||||
ts_name: A4 - Tachometer
|
||||
|
@ -127,8 +125,7 @@ pins:
|
|||
color: blue
|
||||
|
||||
- pin: C1
|
||||
# H144_OUT_PWM4
|
||||
id: C8
|
||||
meta: H144_OUT_PWM4
|
||||
class: outputs
|
||||
function: Fan Relay or 5A Power Output (low)
|
||||
type: ls
|
||||
|
@ -191,8 +188,7 @@ pins:
|
|||
color: brown
|
||||
|
||||
- pin: C8
|
||||
# H144_OUT_PWM1
|
||||
id: D13
|
||||
meta: H144_OUT_PWM1
|
||||
class: outputs
|
||||
function: Idle Output (low)
|
||||
type: ls
|
||||
|
|
|
@ -44,7 +44,7 @@ static void setupEtb() {
|
|||
// DIS - disables motor (enable low)
|
||||
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = H144_GP1;
|
||||
// Disable pin
|
||||
|
@ -105,24 +105,24 @@ static bool is_F_OrOlder() {
|
|||
}
|
||||
|
||||
void boardInitHardware() {
|
||||
alphaTachPullUp.initPin("a-tach", H144_OUT_IO1);
|
||||
alphaTempPullUp.initPin("a-temp", H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", H144_OUT_IO2);
|
||||
alphaCrankNPullUp.initPin("a-crank-n", H144_OUT_IO5);
|
||||
alpha2stepPullDown.initPin("a-2step", H144_OUT_IO7);
|
||||
alphaCamVrPullUp.initPin("a-cam-vr", H144_OUT_IO9);
|
||||
alphaTachPullUp.initPin("a-tach", Gpio::H144_OUT_IO1);
|
||||
alphaTempPullUp.initPin("a-temp", Gpio::H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", Gpio::H144_OUT_IO2);
|
||||
alphaCrankNPullUp.initPin("a-crank-n", Gpio::H144_OUT_IO5);
|
||||
alpha2stepPullDown.initPin("a-2step", Gpio::H144_OUT_IO7);
|
||||
alphaCamVrPullUp.initPin("a-cam-vr", Gpio::H144_OUT_IO9);
|
||||
if (is_F_OrOlder()) {
|
||||
alphaD2PullDown.initPin("a-d2", H144_LS_5);
|
||||
alphaCamPullDown.initPin("a-cam", H144_OUT_IO8);
|
||||
alphaD3PullDown.initPin("a-d3", H144_LS_6);
|
||||
alphaD2PullDown.initPin("a-d2", Gpio::H144_LS_5);
|
||||
alphaCamPullDown.initPin("a-cam", Gpio::H144_OUT_IO8);
|
||||
alphaD3PullDown.initPin("a-d3", Gpio::H144_LS_6);
|
||||
} else {
|
||||
alphaD2PullDown.initPin("a-d2", Gpio::H144_OUT_IO13;);
|
||||
alphaD2PullDown.initPin("a-d2", Gpio::H144_OUT_IO13);
|
||||
alphaCamPullDown.initPin("a-cam", H144_GP4);
|
||||
alphaD3PullDown.initPin("a-d3", H144_OUT_IO8);
|
||||
alphaD3PullDown.initPin("a-d3", Gpio::H144_OUT_IO8);
|
||||
}
|
||||
|
||||
alphaD4PullDown.initPin("a-d4", Gpio::H144_LS_7);
|
||||
alphaD5PullDown.initPin("a-d5", H144_LS_8);
|
||||
alphaD5PullDown.initPin("a-d5", Gpio::H144_LS_8);
|
||||
boardOnConfigurationChange(nullptr);
|
||||
}
|
||||
|
||||
|
@ -147,7 +147,7 @@ void setBoardConfigOverrides() {
|
|||
setupVbatt();
|
||||
|
||||
if (is_F_OrOlder()) {
|
||||
setHellenEnPin(H144_OUT_IO3);
|
||||
setHellenEnPin(Gpio::H144_OUT_IO3);
|
||||
setHellenSdCardSpi2();
|
||||
} else {
|
||||
setHellenMegaEnPin();
|
||||
|
@ -174,8 +174,8 @@ void setBoardDefaultConfiguration() {
|
|||
setupEtb();
|
||||
if (is_F_OrOlder()) {
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_IO13;;
|
||||
engineConfiguration->vvtPins[0] = H144_OUT_PWM7;
|
||||
engineConfiguration->vvtPins[1] = H144_OUT_PWM8;
|
||||
engineConfiguration->vvtPins[0] = Gpio::H144_OUT_PWM7;
|
||||
engineConfiguration->vvtPins[1] = Gpio::H144_OUT_PWM8;
|
||||
} else {
|
||||
engineConfiguration->vvtPins[0] = Gpio::H144_IGN_7;
|
||||
engineConfiguration->vvtPins[1] = Gpio::H144_IGN_8;
|
||||
|
@ -185,10 +185,10 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
// todo: should be conditional? currently set best for newest boards based on MegaModule
|
||||
setHellenMMbaro();
|
||||
engineConfiguration->map.sensor.hwChannel = Gpio::H144_IN_MAP3; // On-board MAP
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP3; // On-board MAP
|
||||
engineConfiguration->map.sensor.type = MT_MPXH6400;
|
||||
// engineConfiguration->baroSensor.type = MT_MPXH6400;
|
||||
// engineConfiguration->baroSensor.hwChannel = Gpio::H144_IN_MAP3; // On-board MAP
|
||||
// engineConfiguration->baroSensor.hwChannel = H144_IN_MAP3; // On-board MAP
|
||||
|
||||
engineConfiguration->boardUseTempPullUp = true;
|
||||
|
||||
|
@ -210,8 +210,8 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
// ? engineConfiguration->malfunctionIndicatorPin = Gpio::G4; //1E - Check Engine Light
|
||||
engineConfiguration->vrThreshold[0].pin = H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[1].pin = H144_OUT_PWM4;
|
||||
engineConfiguration->vrThreshold[0].pin = Gpio::H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[1].pin = Gpio::H144_OUT_PWM4;
|
||||
}
|
||||
|
||||
void boardPrepareForStop() {
|
||||
|
|
|
@ -43,7 +43,7 @@ static void setupEtb() {
|
|||
// DIS - disables motor (enable low)
|
||||
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = H144_GP1;
|
||||
// Disable pin
|
||||
|
@ -100,7 +100,7 @@ static void setupDefaultSensorInputs() {
|
|||
engineConfiguration->mafAdcChannel = EFI_ADC_NONE;
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP2;
|
||||
engineConfiguration->baroSensor.type = MT_MPXH6400;
|
||||
// engineConfiguration->baroSensor.hwChannel = Gpio::H144_IN_MAP3;
|
||||
// engineConfiguration->baroSensor.hwChannel = H144_IN_MAP3;
|
||||
|
||||
engineConfiguration->afr.hwChannel = EFI_ADC_NONE;
|
||||
|
||||
|
@ -110,18 +110,18 @@ static void setupDefaultSensorInputs() {
|
|||
}
|
||||
|
||||
void boardInitHardware() {
|
||||
setHellenEnPin(H144_OUT_IO3);
|
||||
setHellenEnPin(Gpio::H144_OUT_IO3);
|
||||
|
||||
alphaTempPullUp.initPin("a-temp", H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", H144_OUT_IO5);
|
||||
alphaTachPullUp.initPin("a-tach", H144_OUT_IO6);
|
||||
alpha2stepPullDown.initPin("a-2step", H144_OUT_IO7);
|
||||
alphaCamPullDown.initPin("a-cam", H144_OUT_IO8);
|
||||
//alphaCamVrPullUp.initPin("a-cam-vr", H144_OUT_IO9);
|
||||
alphaTempPullUp.initPin("a-temp", Gpio::H144_OUT_IO4);
|
||||
alphaCrankPPullUp.initPin("a-crank-p", Gpio::H144_OUT_IO5);
|
||||
alphaTachPullUp.initPin("a-tach", Gpio::H144_OUT_IO6);
|
||||
alpha2stepPullDown.initPin("a-2step", Gpio::H144_OUT_IO7);
|
||||
alphaCamPullDown.initPin("a-cam", Gpio::H144_OUT_IO8);
|
||||
//alphaCamVrPullUp.initPin("a-cam-vr", Gpio::H144_OUT_IO9);
|
||||
alphaD2PullDown.initPin("a-d2", H_SPI3_SCK);
|
||||
alphaD3PullDown.initPin("a-d3", H_SPI3_MISO);
|
||||
alphaD4PullDown.initPin("a-d4", H_SPI3_MOSI);
|
||||
//alphaD5PullDown.initPin("a-d5", H144_LS_8);
|
||||
//alphaD5PullDown.initPin("a-d5", Gpio::H144_LS_8);
|
||||
boardOnConfigurationChange(nullptr);
|
||||
}
|
||||
|
||||
|
@ -162,8 +162,8 @@ void setBoardDefaultConfiguration() {
|
|||
setInjectorPins();
|
||||
setIgnitionPins();
|
||||
setupEtb();
|
||||
engineConfiguration->vvtPins[0] = H144_OUT_PWM7;
|
||||
engineConfiguration->vvtPins[1] = H144_OUT_PWM8;
|
||||
engineConfiguration->vvtPins[0] = Gpio::H144_OUT_PWM7;
|
||||
engineConfiguration->vvtPins[1] = Gpio::H144_OUT_PWM8;
|
||||
|
||||
engineConfiguration->boardUseTempPullUp = true;
|
||||
|
||||
|
@ -183,8 +183,8 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
// ? engineConfiguration->malfunctionIndicatorPin = Gpio::G4; //1E - Check Engine Light
|
||||
engineConfiguration->vrThreshold[0].pin = H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[1].pin = H144_OUT_PWM4;
|
||||
engineConfiguration->vrThreshold[0].pin = Gpio::H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[1].pin = Gpio::H144_OUT_PWM4;
|
||||
|
||||
hellenWbo();
|
||||
}
|
||||
|
|
|
@ -39,11 +39,11 @@ static void setupEtb() {
|
|||
// DIS - disables motor (enable low)
|
||||
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM1;
|
||||
// Disable pin
|
||||
engineConfiguration->etbIo[0].disablePin = H144_OUT_IO1;
|
||||
engineConfiguration->etbIo[0].disablePin = Gpio::H144_OUT_IO1;
|
||||
// Unused
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::Unassigned;
|
||||
|
||||
|
@ -80,7 +80,7 @@ static void setupDefaultSensorInputs() {
|
|||
engineConfiguration->mafAdcChannel = H144_IN_MAP1;
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP2;
|
||||
engineConfiguration->baroSensor.type = MT_MPXH6400;
|
||||
engineConfiguration->baroSensor.hwChannel = Gpio::H144_IN_MAP3;
|
||||
engineConfiguration->baroSensor.hwChannel = H144_IN_MAP3;
|
||||
|
||||
engineConfiguration->afr.hwChannel = EFI_ADC_NONE;
|
||||
|
||||
|
@ -90,7 +90,7 @@ static void setupDefaultSensorInputs() {
|
|||
}
|
||||
|
||||
void boardInitHardware() {
|
||||
setHellenEnPin(H144_OUT_IO3);
|
||||
setHellenEnPin(Gpio::H144_OUT_IO3);
|
||||
|
||||
boardOnConfigurationChange(nullptr);
|
||||
}
|
||||
|
@ -123,8 +123,8 @@ void setBoardDefaultConfiguration() {
|
|||
setIgnitionPins();
|
||||
setupEtb();
|
||||
engineConfiguration->acSwitch = Gpio::Unassigned;
|
||||
// engineConfiguration->fuelPumpPin = Gpio::Unassigned;//H144_OUT_PWM2;
|
||||
// engineConfiguration->fanPin = Gpio::Unassigned;//H144_OUT_PWM4;
|
||||
// engineConfiguration->fuelPumpPin = Gpio::Unassigned;//Gpio::H144_OUT_PWM2;
|
||||
// engineConfiguration->fanPin = Gpio::Unassigned;//Gpio::H144_OUT_PWM4;
|
||||
engineConfiguration->mainRelayPin = Gpio::Unassigned;
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM3;
|
||||
|
||||
|
@ -150,7 +150,7 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->clutchDownPinMode = PI_PULLDOWN;
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
// ? engineConfiguration->malfunctionIndicatorPin = Gpio::G4; //1E - Check Engine Light
|
||||
engineConfiguration->vrThreshold[0].pin = H144_OUT_PWM4;
|
||||
engineConfiguration->vrThreshold[0].pin = Gpio::H144_OUT_PWM4;
|
||||
}
|
||||
|
||||
void boardPrepareForStop() {
|
||||
|
|
|
@ -26,7 +26,7 @@ static void setInjectorPins() {
|
|||
engineConfiguration->clutchDownPin = Gpio::C4; // Clutch switch input
|
||||
engineConfiguration->clutchDownPinMode = PI_PULLDOWN;
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
engineConfiguration->malfunctionIndicatorPin = H144_OUT_IO8;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_IO8;
|
||||
}
|
||||
|
||||
static void setIgnitionPins() {
|
||||
|
@ -92,11 +92,11 @@ void setBoardConfigOverrides() {
|
|||
|
||||
//ETB1
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM8;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM8;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_IO13;;
|
||||
// Disable pin
|
||||
engineConfiguration->etbIo[0].disablePin = H144_OUT_IO4;
|
||||
engineConfiguration->etbIo[0].disablePin = Gpio::H144_OUT_IO4;
|
||||
// Unused
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::Unassigned;
|
||||
|
||||
|
@ -120,14 +120,14 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->luaOutputPins[0] = Gpio::H144_OUT_IO6; // starter relay
|
||||
|
||||
engineConfiguration->boostControlPin = H144_OUT_PWM5;
|
||||
engineConfiguration->boostControlPin = Gpio::H144_OUT_PWM5;
|
||||
engineConfiguration->brakePedalPin = H144_IN_RES2;
|
||||
// engineConfiguration->acSwitch =
|
||||
// engineConfiguration->acRelayPin =
|
||||
engineConfiguration->fuelPumpPin = H144_OUT_IO5;
|
||||
engineConfiguration->fuelPumpPin = Gpio::H144_OUT_IO5;
|
||||
engineConfiguration->fanPin = Gpio::H144_OUT_IO12;
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO3;
|
||||
engineConfiguration->tachOutputPin = H144_OUT_PWM7;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO3;
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM7;
|
||||
engineConfiguration->alternatorControlPin = Gpio::H144_OUT_PWM1;
|
||||
// engineConfiguration->fan2Pin =
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ void setBoardConfigOverrides() {
|
|||
|
||||
// //ETB1
|
||||
// // PWM pin
|
||||
// engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2;
|
||||
// engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2;
|
||||
// // DIR pin
|
||||
// engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM3;
|
||||
// // Disable pin
|
||||
|
@ -114,7 +114,7 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->canTxPin = H176_CAN_TX;
|
||||
engineConfiguration->canRxPin = H176_CAN_RX;
|
||||
|
||||
engineConfiguration->vvtPins[0] = H144_OUT_PWM4;
|
||||
engineConfiguration->vvtPins[0] = Gpio::H144_OUT_PWM4;
|
||||
|
||||
gppwm_channel *vtsControl = &engineConfiguration->gppwm[0];
|
||||
// vtsControl->pin = Gpio::H144_OUT_IO6;
|
||||
|
@ -122,8 +122,8 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->fuelPumpPin = Gpio::H144_OUT_IO13;;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::H144_LS_6;
|
||||
engineConfiguration->fanPin = Gpio::H144_OUT_IO12;
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO3;
|
||||
engineConfiguration->malfunctionIndicatorPin = H144_OUT_IO7;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO3;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_IO7;
|
||||
|
||||
// how come this is not denso 183?!
|
||||
engineConfiguration->map.sensor.type = MT_CUSTOM;
|
||||
|
@ -164,10 +164,10 @@ void setBoardDefaultConfiguration() {
|
|||
}
|
||||
|
||||
static Gpio OUTPUTS[] = {
|
||||
H144_LS_1,
|
||||
H144_LS_2,
|
||||
H144_LS_3,
|
||||
H144_LS_4,
|
||||
Gpio::H144_LS_1,
|
||||
Gpio::H144_LS_2,
|
||||
Gpio::H144_LS_3,
|
||||
Gpio::H144_LS_4,
|
||||
};
|
||||
|
||||
int getBoardMetaOutputsCount() {
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
- pin: auxhigh1
|
||||
# H144_OUT_IO5
|
||||
|
@ -7,8 +9,7 @@ pins:
|
|||
function: AuxHigh1
|
||||
|
||||
- pin: auxpp1
|
||||
# H144_OUT_IO11
|
||||
id: G2
|
||||
meta: H144_OUT_IO11
|
||||
class: outputs
|
||||
ts_name: AuxPP1
|
||||
function: AuxPP1
|
||||
|
@ -49,8 +50,7 @@ pins:
|
|||
type: gnda
|
||||
|
||||
- pin: A12
|
||||
# H144_LS_6
|
||||
id: F12
|
||||
meta: H144_LS_6
|
||||
class: outputs
|
||||
ts_name: A12 Idle Air Control
|
||||
function: Idle Air Control Valve
|
||||
|
@ -124,28 +124,24 @@ pins:
|
|||
function: Cam Sensor
|
||||
|
||||
- pin: A27
|
||||
# H144_IGN_4
|
||||
id: E3
|
||||
meta: H144_IGN_4
|
||||
class: outputs
|
||||
ts_name: A27 - IGN4
|
||||
function: Ignition 4
|
||||
- pin: A28
|
||||
# H144_IGN_3
|
||||
id: E4
|
||||
meta: H144_IGN_3
|
||||
class: outputs
|
||||
ts_name: A28 - IGN3
|
||||
function: Ignition 3
|
||||
|
||||
- pin: A29
|
||||
# H144_IGN_2
|
||||
id: E5
|
||||
meta: H144_IGN_2
|
||||
class: outputs
|
||||
ts_name: A29 - IGN2
|
||||
function: Ignition 2
|
||||
|
||||
- pin: A30
|
||||
# H144_IGN_1
|
||||
id: C13
|
||||
meta: H144_IGN_1
|
||||
class: outputs
|
||||
ts_name: A30 - IGN1
|
||||
function: Ignition 1
|
||||
|
@ -154,45 +150,39 @@ pins:
|
|||
function: VTC +12 supply
|
||||
|
||||
- pin: B2
|
||||
# H144_LS_4
|
||||
id: D10
|
||||
meta: H144_LS_4
|
||||
class: outputs
|
||||
type: inj
|
||||
ts_name: B2 - Injector 4
|
||||
function: Injector 4
|
||||
- pin: B3
|
||||
# H144_LS_3
|
||||
id: D11
|
||||
meta: H144_LS_3
|
||||
class: outputs
|
||||
type: inj
|
||||
ts_name: B3 - Injector 3
|
||||
function: Injector 3
|
||||
|
||||
- pin: B4
|
||||
# H144_LS_2
|
||||
id: G8
|
||||
meta: H144_LS_2
|
||||
class: outputs
|
||||
type: inj
|
||||
ts_name: B4 - Injector 2
|
||||
function: Injector 2
|
||||
|
||||
- pin: B5
|
||||
# H144_LS_1
|
||||
id: G7
|
||||
meta: H144_LS_1
|
||||
class: outputs
|
||||
ts_name: B5 - Injector 1
|
||||
function: Injector 1
|
||||
- pin: B6
|
||||
# H144_OUT_IO12
|
||||
id: A8
|
||||
meta: H144_OUT_IO12
|
||||
class: outputs
|
||||
type: ls
|
||||
ts_name: B6 Radiator Relay
|
||||
function: Radiator Relay Output
|
||||
|
||||
- pin: B7
|
||||
# H144_LS_8
|
||||
id: F14
|
||||
meta: H144_LS_8
|
||||
class: outputs
|
||||
ts_name: ___ Lockout Solenoid
|
||||
function: Lockout Solenoid
|
||||
|
@ -215,8 +205,7 @@ pins:
|
|||
function: Alternator Field
|
||||
|
||||
- pin: B15
|
||||
# H144_OUT_IO6
|
||||
id: G11
|
||||
meta: H144_OUT_IO6
|
||||
class: outputs
|
||||
ts_name: ___ VTEC/VTS Output
|
||||
# not to be confused with VTC aka VVT
|
||||
|
@ -229,29 +218,25 @@ pins:
|
|||
ts_name: ___ IAT
|
||||
function: IAT
|
||||
- pin: B18
|
||||
# H144_OUT_IO9
|
||||
id: G13
|
||||
meta: H144_OUT_IO9
|
||||
class: outputs
|
||||
ts_name: ___ Alternator Control
|
||||
function: Alternator Control
|
||||
|
||||
- pin: B21
|
||||
# H144_OUT_PWM5
|
||||
id: C9
|
||||
meta: H144_OUT_PWM5
|
||||
class: outputs
|
||||
ts_name: ___ - EVAP
|
||||
function: EVAP
|
||||
|
||||
- pin: B22
|
||||
# H144_LS_7
|
||||
id: F13
|
||||
meta: H144_LS_7
|
||||
class: outputs
|
||||
ts_name: ___ Intake Runner
|
||||
function: Intake Runner
|
||||
|
||||
- pin: B23
|
||||
# H144_OUT_PWM4
|
||||
id: C8
|
||||
meta: H144_OUT_PWM4
|
||||
class: outputs
|
||||
ts_name: ___ VTC VVT
|
||||
function: VTC VVT
|
||||
|
@ -295,21 +280,18 @@ pins:
|
|||
|
||||
|
||||
- pin: C11
|
||||
# H144_OUT_PWM7
|
||||
id: D15
|
||||
meta: H144_OUT_PWM7
|
||||
class: outputs
|
||||
ts_name: ___ Aux Low 3
|
||||
function: Aux Low 3
|
||||
|
||||
- pin: C12
|
||||
# H144_OUT_PWM6
|
||||
id: D14
|
||||
meta: H144_OUT_PWM6
|
||||
class: outputs
|
||||
function: Aux Low 2
|
||||
|
||||
- pin: C13
|
||||
# H144_OUT_PWM2
|
||||
id: C6
|
||||
meta: H144_OUT_PWM2
|
||||
class: outputs
|
||||
function: Aux Low 1
|
||||
|
||||
|
@ -354,8 +336,7 @@ pins:
|
|||
color: orange
|
||||
|
||||
- pin: E1
|
||||
# H144_OUT_IO13
|
||||
id: G6
|
||||
meta: H144_OUT_IO13
|
||||
class: outputs
|
||||
ts_name: E1 Fuel Relay
|
||||
function: Fuel Relay
|
||||
|
@ -373,8 +354,7 @@ pins:
|
|||
function: 5V Sensor Power
|
||||
|
||||
- pin: E7
|
||||
# H144_OUT_IO3
|
||||
id: G14
|
||||
meta: H144_OUT_IO3
|
||||
class: outputs
|
||||
ts_name: E7 Main Relay Control
|
||||
function: Main Relay Control
|
||||
|
|
|
@ -22,7 +22,7 @@ static void setInjectorPins() {
|
|||
engineConfiguration->clutchDownPin = Gpio::C4; // Clutch switch input
|
||||
engineConfiguration->clutchDownPinMode = PI_PULLDOWN;
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
engineConfiguration->malfunctionIndicatorPin = H144_OUT_IO8;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_IO8;
|
||||
}
|
||||
|
||||
static void setIgnitionPins() {
|
||||
|
@ -97,8 +97,8 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->fanPin = Gpio::D12; // OUT_PWM8
|
||||
engineConfiguration->mainRelayPin = Gpio::I2; // OUT_LOW3
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM1;
|
||||
engineConfiguration->alternatorControlPin = H144_OUT_PWM7;
|
||||
engineConfiguration->fan2Pin = H144_OUT_IO2;
|
||||
engineConfiguration->alternatorControlPin = Gpio::H144_OUT_PWM7;
|
||||
engineConfiguration->fan2Pin = Gpio::H144_OUT_IO2;
|
||||
|
||||
// "required" hardware is done - set some reasonable defaults
|
||||
setupDefaultSensorInputs();
|
||||
|
|
|
@ -1,7 +1,4 @@
|
|||
#
|
||||
# CONNECTOR MAPPING NEEDED
|
||||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
#
|
||||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
- pin: 1A
|
||||
|
|
|
@ -74,8 +74,8 @@ void setBoardConfigOverrides() {
|
|||
setupVbatt();
|
||||
setHellenSdCardSpi3();
|
||||
|
||||
engineConfiguration->etbIo[0].directionPin1 = H144_OUT_PWM7;
|
||||
engineConfiguration->etbIo[0].directionPin2 = H144_OUT_PWM6;
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM7;
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::H144_OUT_PWM6;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::D13; // ETB_EN out_pwm1
|
||||
engineConfiguration->etb_use_two_wires = true;
|
||||
|
||||
|
@ -103,7 +103,7 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->fuelPumpPin = Gpio::D12; // OUT_IO9 // 113 Fuel Pump Relay
|
||||
engineConfiguration->idle.solenoidPin = Gpio::Unassigned;
|
||||
// engineConfiguration->fanPin = Gpio::D12; // OUT_PWM8
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO3;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO3;
|
||||
|
||||
// "required" hardware is done - set some reasonable defaults
|
||||
setupDefaultSensorInputs();
|
||||
|
@ -133,8 +133,8 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->ignitionMode = IM_INDIVIDUAL_COILS; // IM_WASTED_SPARK
|
||||
engineConfiguration->injectionMode = IM_SEQUENTIAL;
|
||||
|
||||
engineConfiguration->luaOutputPins[0] = H144_OUT_IO4; // 104 ETB Relay
|
||||
engineConfiguration->luaOutputPins[1] = H144_OUT_PWM2; // aux LS1, upstream oxygen heaters
|
||||
engineConfiguration->luaOutputPins[0] = Gpio::H144_OUT_IO4; // 104 ETB Relay
|
||||
engineConfiguration->luaOutputPins[1] = Gpio::H144_OUT_PWM2; // aux LS1, upstream oxygen heaters
|
||||
|
||||
setPPSCalibration(0.75, 4.45, 0.43, 2.20);
|
||||
|
||||
|
|
|
@ -108,15 +108,15 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->enableSoftwareKnock = true;
|
||||
|
||||
engineConfiguration->fuelPumpPin = H144_OUT_IO3;
|
||||
engineConfiguration->fuelPumpPin = Gpio::H144_OUT_IO3;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::G4; // 47 - CEL
|
||||
engineConfiguration->tachOutputPin = H144_OUT_PWM7;
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM7;
|
||||
|
||||
// earlier revisions? engineConfiguration->idle.solenoidPin = Gpio::D14; // OUT_PWM5
|
||||
engineConfiguration->idle.solenoidPin = H144_OUT_IO4;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::H144_OUT_IO4;
|
||||
|
||||
engineConfiguration->fanPin = H144_OUT_PWM8;
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO1;
|
||||
engineConfiguration->fanPin = Gpio::H144_OUT_PWM8;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO1;
|
||||
|
||||
// engineConfiguration->injectorCompensationMode
|
||||
engineConfiguration->fuelReferencePressure = 300;
|
||||
|
@ -132,6 +132,6 @@ void setBoardDefaultConfiguration() {
|
|||
|
||||
engineConfiguration->ignitionMode = IM_INDIVIDUAL_COILS; // IM_WASTED_SPARK
|
||||
|
||||
engineConfiguration->vrThreshold[0].pin = H144_OUT_PWM6;
|
||||
engineConfiguration->vrThreshold[0].pin = Gpio::H144_OUT_PWM6;
|
||||
hellenWbo();
|
||||
}
|
||||
|
|
|
@ -85,7 +85,7 @@ void setBoardConfigOverrides() {
|
|||
|
||||
// control pins are inverted since overall ECU pinout seems to be inverted
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM3;
|
||||
engineConfiguration->etbIo[0].directionPin2 = H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_IO12;
|
||||
engineConfiguration->etbIo[0].disablePin = Gpio::Unassigned;
|
||||
engineConfiguration->etb_use_two_wires = true;
|
||||
|
@ -99,9 +99,9 @@ void setBoardConfigOverrides() {
|
|||
|
||||
if (isFirstInvocation) {
|
||||
isFirstInvocation = false;
|
||||
efiSetPadMode("ETB FIX0", H144_OUT_PWM4, PAL_MODE_INPUT_ANALOG);
|
||||
efiSetPadMode("ETB FIX1", H144_OUT_PWM5, PAL_MODE_INPUT_ANALOG);
|
||||
efiSetPadMode("ETB FIX2", Gpio::H144_OUT_IO13;, PAL_MODE_INPUT_ANALOG);
|
||||
efiSetPadMode("ETB FIX0", Gpio::H144_OUT_PWM4, PAL_MODE_INPUT_ANALOG);
|
||||
efiSetPadMode("ETB FIX1", Gpio::H144_OUT_PWM5, PAL_MODE_INPUT_ANALOG);
|
||||
efiSetPadMode("ETB FIX2", Gpio::H144_OUT_IO13, PAL_MODE_INPUT_ANALOG);
|
||||
}
|
||||
engineConfiguration->stepperDcInvertedPins = false;
|
||||
} else if (hellenBoardId == BOARD_ID_154hyundai_c || hellenBoardId == BOARD_ID_154hyundai_d) {
|
||||
|
@ -114,7 +114,7 @@ void setBoardConfigOverrides() {
|
|||
|
||||
//ETB1
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM3;
|
||||
// Disable pin
|
||||
|
@ -125,9 +125,9 @@ void setBoardConfigOverrides() {
|
|||
// wastegate DC motor
|
||||
//ETB2
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[1].controlPin = H144_OUT_PWM4;
|
||||
engineConfiguration->etbIo[1].controlPin = Gpio::H144_OUT_PWM4;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[1].directionPin1 = H144_OUT_PWM5;
|
||||
engineConfiguration->etbIo[1].directionPin1 = Gpio::H144_OUT_PWM5;
|
||||
// Disable pin
|
||||
engineConfiguration->etbIo[1].disablePin = Gpio::H144_OUT_IO13;;
|
||||
// Unused
|
||||
|
@ -149,10 +149,10 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->canTxPin = H176_CAN_TX;
|
||||
engineConfiguration->canRxPin = H176_CAN_RX;
|
||||
|
||||
engineConfiguration->fuelPumpPin = H144_OUT_IO9;
|
||||
engineConfiguration->fuelPumpPin = Gpio::H144_OUT_IO9;
|
||||
// engineConfiguration->fanPin = Gpio::D12; // OUT_PWM8
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO3; // pin: 111a
|
||||
engineConfiguration->malfunctionIndicatorPin = H144_OUT_PWM8;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO3; // pin: 111a
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_PWM8;
|
||||
|
||||
engineConfiguration->brakePedalPin = H144_IN_RES3;
|
||||
engineConfiguration->clutchUpPin = H144_IN_RES2;
|
||||
|
@ -165,10 +165,10 @@ void setBoardDefaultConfiguration() {
|
|||
}
|
||||
|
||||
static Gpio OUTPUTS[] = {
|
||||
H144_LS_1,
|
||||
H144_LS_2,
|
||||
H144_LS_3,
|
||||
H144_LS_4,
|
||||
Gpio::H144_LS_1,
|
||||
Gpio::H144_LS_2,
|
||||
Gpio::H144_LS_3,
|
||||
Gpio::H144_LS_4,
|
||||
};
|
||||
|
||||
int getBoardMetaOutputsCount() {
|
||||
|
|
|
@ -1,21 +1,18 @@
|
|||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
- pin: P66
|
||||
# LOW3 IO1
|
||||
id: D3
|
||||
meta: H144_OUT_IO1
|
||||
class: outputs
|
||||
ts_name: Aux P66
|
||||
|
||||
- pin: P67
|
||||
# LOW4 IO2
|
||||
id: A9
|
||||
meta: H144_OUT_IO2
|
||||
class: outputs
|
||||
ts_name: Aux P67
|
||||
|
||||
- pin: P68
|
||||
# LOW6 IO4
|
||||
id: G5
|
||||
meta: H144_OUT_IO4
|
||||
class: outputs
|
||||
ts_name: Aux P68
|
||||
|
||||
|
@ -100,28 +97,28 @@ pins:
|
|||
ts_name: BK2 Wastegate Position - 22
|
||||
|
||||
- pin: K25
|
||||
id: G7
|
||||
meta: H144_LS_1
|
||||
class: outputs
|
||||
ts_name: INJ_1 k25
|
||||
function: Injector 1
|
||||
type: inj
|
||||
|
||||
- pin: K26
|
||||
id: G8
|
||||
meta: H144_LS_2
|
||||
class: outputs
|
||||
ts_name: INJ_2 k26
|
||||
function: Injector 2
|
||||
type: inj
|
||||
|
||||
- pin: K27
|
||||
id: D11
|
||||
meta: H144_LS_3
|
||||
class: outputs
|
||||
ts_name: INJ_3 k27
|
||||
function: Injector 3
|
||||
type: inj
|
||||
|
||||
- pin: K28
|
||||
id: D10
|
||||
meta: H144_LS_4
|
||||
class: outputs
|
||||
ts_name: INJ_4 k28
|
||||
function: Injector 4
|
||||
|
@ -187,8 +184,7 @@ pins:
|
|||
function: Analog Ground
|
||||
|
||||
- pin: K47
|
||||
# H144_LS_7
|
||||
id: F13
|
||||
meta: H144_LS_7
|
||||
class: outputs
|
||||
ts_name: K47 BK1 Wastegate Solenoid
|
||||
function: BK1 Wastegate Solenoid
|
||||
|
@ -246,38 +242,33 @@ pins:
|
|||
type: 5v
|
||||
|
||||
- pin: K64
|
||||
# H144_OUT_IO3
|
||||
id: G14
|
||||
meta: H144_OUT_IO3
|
||||
class: outputs
|
||||
ts_name: Main Relay K64
|
||||
function: Main relay control
|
||||
type: ls
|
||||
|
||||
- pin: K65
|
||||
# H144_OUT_IO7
|
||||
id: G3
|
||||
meta: H144_OUT_IO7
|
||||
class: outputs
|
||||
ts_name: Fan Relay Low
|
||||
function: Fan relay low
|
||||
|
||||
- pin: K66
|
||||
# H144_LS_5
|
||||
id: D9
|
||||
meta: H144_LS_5
|
||||
class: outputs
|
||||
ts_name: VVT1
|
||||
function: VVT1
|
||||
|
||||
- pin: K68
|
||||
# H144_LS_6
|
||||
id: F12
|
||||
meta: H144_LS_6
|
||||
class: outputs
|
||||
ts_name: VVT2
|
||||
function: VVT2
|
||||
|
||||
|
||||
- pin: K70
|
||||
# H144_OUT_IO9
|
||||
id: G13
|
||||
meta: H144_OUT_IO9
|
||||
class: outputs
|
||||
ts_name: Fuel Pump K70
|
||||
function: Fuel Pump Relay
|
||||
|
@ -319,36 +310,32 @@ pins:
|
|||
function: Analog Ground
|
||||
|
||||
- pin: K86
|
||||
# H144_OUT_PWM7
|
||||
id: D15
|
||||
meta: H144_OUT_PWM7
|
||||
class: outputs
|
||||
ts_name: Tacho
|
||||
function: Tachometer
|
||||
|
||||
- pin: K87
|
||||
# H144_OUT_IO10
|
||||
id: G12
|
||||
meta: H144_OUT_IO10
|
||||
class: outputs
|
||||
ts_name: K87 AC Relay
|
||||
function: A/C Relay
|
||||
type: ls
|
||||
|
||||
- pin: K88
|
||||
# H144_OUT_IO8
|
||||
id: G4
|
||||
meta: H144_OUT_IO8
|
||||
class: outputs
|
||||
ts_name: Fan Relay HI
|
||||
function: Fan relay high
|
||||
|
||||
- pin: K92
|
||||
# H144_OUT_PWM8
|
||||
id: D12
|
||||
meta: H144_OUT_PWM8
|
||||
class: outputs
|
||||
ts_name: MIL
|
||||
function: Check Engine Light
|
||||
|
||||
- pin: A1
|
||||
id: E3
|
||||
meta: H144_IGN_4
|
||||
class: outputs
|
||||
ts_name: Coil 4
|
||||
function: Coil 4
|
||||
|
@ -361,7 +348,7 @@ pins:
|
|||
function: Ground
|
||||
|
||||
- pin: A16
|
||||
id: E5
|
||||
meta: H144_IGN_2
|
||||
class: outputs
|
||||
ts_name: Coil 2
|
||||
function: Coil 2
|
||||
|
@ -376,7 +363,7 @@ pins:
|
|||
|
||||
|
||||
- pin: A31
|
||||
id: C13
|
||||
meta: H144_IGN_1
|
||||
class: outputs
|
||||
ts_name: Coil 1
|
||||
function: Coil 1
|
||||
|
@ -393,7 +380,7 @@ pins:
|
|||
function: BK2 DC Wastegate Pos
|
||||
|
||||
- pin: A46
|
||||
id: E4
|
||||
meta: H144_IGN_3
|
||||
class: outputs
|
||||
ts_name: Coil 3
|
||||
function: Coil 3
|
||||
|
|
|
@ -75,8 +75,8 @@ void setBoardConfigOverrides() {
|
|||
|
||||
// NB2 still uses L6205PD
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM3; // ETB+
|
||||
engineConfiguration->etbIo[0].directionPin2 = H144_OUT_PWM4; // ETB-
|
||||
engineConfiguration->etbIo[0].controlPin = H144_OUT_PWM2; // ETB_EN
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::H144_OUT_PWM4; // ETB-
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM2; // ETB_EN
|
||||
engineConfiguration->etb_use_two_wires = true;
|
||||
|
||||
setDefaultHellenAtPullUps();
|
||||
|
|
|
@ -71,7 +71,7 @@ void setBoardConfigOverrides() {
|
|||
setupVbatt();
|
||||
|
||||
// hellen88bmw uses L6205PD
|
||||
engineConfiguration->etbIo[0].directionPin1 = H144_OUT_PWM2; // ETB+
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::H144_OUT_PWM2; // ETB+
|
||||
engineConfiguration->etbIo[0].directionPin2 = Gpio::H144_OUT_PWM3; // ETB-
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::H144_OUT_PWM1; // ETB_EN
|
||||
engineConfiguration->etb_use_two_wires = true;
|
||||
|
@ -101,10 +101,10 @@ void setBoardDefaultConfiguration() {
|
|||
setHellenCan();
|
||||
|
||||
engineConfiguration->fuelPumpPin = Gpio::D12; // OUT_IO9 // 113 Fuel Pump Relay
|
||||
engineConfiguration->idle.solenoidPin = H144_OUT_PWM5;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::H144_OUT_PWM5;
|
||||
// engineConfiguration->fanPin = Gpio::D12; // OUT_PWM8
|
||||
engineConfiguration->mainRelayPin = H144_OUT_IO3; // pin: 111a
|
||||
engineConfiguration->tachOutputPin = H144_OUT_PWM7;
|
||||
engineConfiguration->mainRelayPin = Gpio::H144_OUT_IO3; // pin: 111a
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM7;
|
||||
|
||||
// "required" hardware is done - set some reasonable defaults
|
||||
setupDefaultSensorInputs();
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
# extension header pins
|
||||
|
|
|
@ -22,7 +22,7 @@ static void setInjectorPins() {
|
|||
engineConfiguration->clutchDownPin = Gpio::C4; // Clutch switch input
|
||||
engineConfiguration->clutchDownPinMode = PI_PULLDOWN;
|
||||
engineConfiguration->launchActivationMode = CLUTCH_INPUT_LAUNCH;
|
||||
engineConfiguration->malfunctionIndicatorPin = H144_OUT_IO8;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_IO8;
|
||||
}
|
||||
|
||||
static void setIgnitionPins() {
|
||||
|
@ -55,7 +55,7 @@ static void setupDefaultSensorInputs() {
|
|||
engineConfiguration->tps1_1AdcChannel = H144_IN_TPS;
|
||||
|
||||
engineConfiguration->mafAdcChannel = EFI_ADC_10;
|
||||
engineConfiguration->map.sensor.hwChannel = Gpio::H144_IN_MAP3;
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP3;
|
||||
|
||||
engineConfiguration->afr.hwChannel = EFI_ADC_1;
|
||||
|
||||
|
@ -101,7 +101,7 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->idle.solenoidPin = Gpio::D14; // OUT_PWM5
|
||||
engineConfiguration->fanPin = Gpio::D12; // OUT_PWM8
|
||||
engineConfiguration->tachOutputPin = Gpio::H144_OUT_PWM1;
|
||||
engineConfiguration->fan2Pin = H144_OUT_IO2;
|
||||
engineConfiguration->fan2Pin = Gpio::H144_OUT_IO2;
|
||||
|
||||
// "required" hardware is done - set some reasonable defaults
|
||||
setupDefaultSensorInputs();
|
||||
|
|
|
@ -1,7 +1,4 @@
|
|||
#
|
||||
# CONNECTOR MAPPING NEEDED
|
||||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
#
|
||||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
- pin: p18_p22
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# https://github.com/rusefi/rusefi/blob/master/firmware/config/boards/hellen/hellen_meta.h
|
||||
meta: config/boards/hellen_meta.h
|
||||
|
||||
pins:
|
||||
- pin: A1
|
||||
|
|
|
@ -95,13 +95,13 @@ void detectHellenBoardType();
|
|||
#define H176_IGN_5 Gpio::E2
|
||||
|
||||
#define H144_OUT_PWM1 D13
|
||||
#define H144_OUT_PWM2 Gpio::C6
|
||||
#define H144_OUT_PWM2 C6
|
||||
#define H144_OUT_PWM3 C7
|
||||
#define H144_OUT_PWM4 Gpio::C8
|
||||
#define H144_OUT_PWM5 Gpio::C9
|
||||
#define H144_OUT_PWM6 Gpio::D14
|
||||
#define H144_OUT_PWM7 Gpio::D15
|
||||
#define H144_OUT_PWM8 Gpio::D12
|
||||
#define H144_OUT_PWM4 C8
|
||||
#define H144_OUT_PWM5 C9
|
||||
#define H144_OUT_PWM6 D14
|
||||
#define H144_OUT_PWM7 D15
|
||||
#define H144_OUT_PWM8 D12
|
||||
|
||||
|
||||
// also IO1/IO5 on rev 0.6
|
||||
|
@ -116,15 +116,15 @@ void detectHellenBoardType();
|
|||
#define H144_GP8 Gpio::E10
|
||||
#define H144_GP9 Gpio::F2
|
||||
|
||||
#define H144_OUT_IO1 Gpio::D3
|
||||
#define H144_OUT_IO2 Gpio::A9
|
||||
#define H144_OUT_IO3 Gpio::G14
|
||||
#define H144_OUT_IO4 Gpio::G5
|
||||
#define H144_OUT_IO5 Gpio::D2
|
||||
#define H144_OUT_IO1 D3
|
||||
#define H144_OUT_IO2 A9
|
||||
#define H144_OUT_IO3 G14
|
||||
#define H144_OUT_IO4 G5
|
||||
#define H144_OUT_IO5 D2
|
||||
#define H144_OUT_IO6 G11
|
||||
#define H144_OUT_IO7 Gpio::G3
|
||||
#define H144_OUT_IO8 Gpio::G4
|
||||
#define H144_OUT_IO9 Gpio::G13
|
||||
#define H144_OUT_IO7 G3
|
||||
#define H144_OUT_IO8 G4
|
||||
#define H144_OUT_IO9 G13
|
||||
#define H144_OUT_IO10 G12
|
||||
#define H144_OUT_IO11 G2
|
||||
#define H144_OUT_IO12 A8
|
||||
|
|
|
@ -10,23 +10,23 @@
|
|||
#include "proteus_meta.h"
|
||||
|
||||
static const brain_pin_e injPins[] = {
|
||||
PROTEUS_LS_1,
|
||||
PROTEUS_LS_2,
|
||||
PROTEUS_LS_3,
|
||||
PROTEUS_LS_4,
|
||||
PROTEUS_LS_5,
|
||||
PROTEUS_LS_6,
|
||||
PROTEUS_LS_7,
|
||||
PROTEUS_LS_8,
|
||||
PROTEUS_LS_9,
|
||||
PROTEUS_LS_10,
|
||||
PROTEUS_LS_11,
|
||||
PROTEUS_LS_12
|
||||
Gpio::PROTEUS_LS_1,
|
||||
Gpio::PROTEUS_LS_2,
|
||||
Gpio::PROTEUS_LS_3,
|
||||
Gpio::PROTEUS_LS_4,
|
||||
Gpio::PROTEUS_LS_5,
|
||||
Gpio::PROTEUS_LS_6,
|
||||
Gpio::PROTEUS_LS_7,
|
||||
Gpio::PROTEUS_LS_8,
|
||||
Gpio::PROTEUS_LS_9,
|
||||
Gpio::PROTEUS_LS_10,
|
||||
Gpio::PROTEUS_LS_11,
|
||||
Gpio::PROTEUS_LS_12
|
||||
};
|
||||
|
||||
static const brain_pin_e ignPins[] = {
|
||||
PROTEUS_IGN_1,
|
||||
PROTEUS_IGN_2,
|
||||
Gpio::PROTEUS_IGN_1,
|
||||
Gpio::PROTEUS_IGN_2,
|
||||
PROTEUS_IGN_3,
|
||||
PROTEUS_IGN_4,
|
||||
PROTEUS_IGN_5,
|
||||
|
@ -34,9 +34,9 @@ static const brain_pin_e ignPins[] = {
|
|||
PROTEUS_IGN_7,
|
||||
PROTEUS_IGN_8,
|
||||
PROTEUS_IGN_9,
|
||||
PROTEUS_IGN_10,
|
||||
PROTEUS_IGN_11,
|
||||
PROTEUS_IGN_12,
|
||||
Gpio::PROTEUS_IGN_10,
|
||||
Gpio::PROTEUS_IGN_11,
|
||||
Gpio::PROTEUS_IGN_12,
|
||||
};
|
||||
|
||||
static void setInjectorPins() {
|
||||
|
@ -184,9 +184,9 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->injectionMode = IM_SIMULTANEOUS;
|
||||
|
||||
#if HW_PROTEUS & EFI_PROD_CODE
|
||||
engineConfiguration->mainRelayPin = PROTEUS_LS_12;
|
||||
engineConfiguration->fanPin = PROTEUS_LS_11;
|
||||
engineConfiguration->fuelPumpPin = PROTEUS_LS_10;
|
||||
engineConfiguration->mainRelayPin = Gpio::PROTEUS_LS_12;
|
||||
engineConfiguration->fanPin = Gpio::PROTEUS_LS_11;
|
||||
engineConfiguration->fuelPumpPin = Gpio::PROTEUS_LS_10;
|
||||
#endif // HW_PROTEUS
|
||||
|
||||
// If we're running as hardware CI, borrow a few extra pins for that
|
||||
|
|
|
@ -12,40 +12,40 @@
|
|||
|
||||
#define PROTEUS_DEFAULT_AT_PULLUP 2700
|
||||
|
||||
#define PROTEUS_LS_1 Gpio::D7
|
||||
#define PROTEUS_LS_1 D7
|
||||
// pin 15/black35
|
||||
#define PROTEUS_LS_2 Gpio::G9
|
||||
#define PROTEUS_LS_2 G9
|
||||
|
||||
// pin 4/black35
|
||||
#define PROTEUS_LS_3 Gpio::G10
|
||||
#define PROTEUS_LS_3 G10
|
||||
|
||||
// pin 16/black35
|
||||
#define PROTEUS_LS_4 Gpio::G11
|
||||
#define PROTEUS_LS_4 G11
|
||||
|
||||
// pin 5/black35
|
||||
#define PROTEUS_LS_5 Gpio::G12
|
||||
#define PROTEUS_LS_5 G12
|
||||
|
||||
// pin 6/black35
|
||||
#define PROTEUS_LS_6 Gpio::G13
|
||||
#define PROTEUS_LS_6 G13
|
||||
|
||||
// pin 7/black35
|
||||
#define PROTEUS_LS_7 Gpio::G14
|
||||
#define PROTEUS_LS_8 Gpio::B4
|
||||
#define PROTEUS_LS_9 Gpio::B5
|
||||
#define PROTEUS_LS_7 G14
|
||||
#define PROTEUS_LS_8 B4
|
||||
#define PROTEUS_LS_9 B5
|
||||
|
||||
// pin 20/black35
|
||||
#define PROTEUS_LS_10 Gpio::B6
|
||||
#define PROTEUS_LS_11 Gpio::B7
|
||||
#define PROTEUS_LS_12 Gpio::B8
|
||||
#define PROTEUS_LS_10 B6
|
||||
#define PROTEUS_LS_11 B7
|
||||
#define PROTEUS_LS_12 B8
|
||||
|
||||
// pin 10/black35
|
||||
#define PROTEUS_LS_13 Gpio::B9
|
||||
#define PROTEUS_LS_13 B9
|
||||
// pin 11/black35
|
||||
#define PROTEUS_LS_14 Gpio::E0
|
||||
#define PROTEUS_LS_14 E0
|
||||
// pin 12/black35
|
||||
#define PROTEUS_LS_15 Gpio::E1
|
||||
#define PROTEUS_LS_15 E1
|
||||
// pin 23/black35
|
||||
#define PROTEUS_LS_16 Gpio::E2
|
||||
#define PROTEUS_LS_16 E2
|
||||
|
||||
|
||||
// pin 2/black35
|
||||
|
@ -59,10 +59,10 @@
|
|||
#define PROTEUS_HS_4 Gpio::D14
|
||||
|
||||
// pin 35/black35
|
||||
#define PROTEUS_IGN_1 Gpio::D4
|
||||
#define PROTEUS_IGN_1 D4
|
||||
|
||||
// pin 34/black35
|
||||
#define PROTEUS_IGN_2 Gpio::D3
|
||||
#define PROTEUS_IGN_2 D3
|
||||
|
||||
// pin 22/black35
|
||||
#define PROTEUS_IGN_3 Gpio::C9
|
||||
|
@ -72,9 +72,9 @@
|
|||
#define PROTEUS_IGN_7 Gpio::G7
|
||||
#define PROTEUS_IGN_8 Gpio::G6
|
||||
#define PROTEUS_IGN_9 Gpio::G5
|
||||
#define PROTEUS_IGN_10 Gpio::G4
|
||||
#define PROTEUS_IGN_11 Gpio::G3
|
||||
#define PROTEUS_IGN_12 Gpio::G2
|
||||
#define PROTEUS_IGN_10 G4
|
||||
#define PROTEUS_IGN_11 G3
|
||||
#define PROTEUS_IGN_12 G2
|
||||
|
||||
// Analog Temp 1 = PC4
|
||||
#define PROTEUS_IN_ANALOG_TEMP_1 EFI_ADC_14
|
||||
|
@ -143,22 +143,24 @@
|
|||
|
||||
#if HW_PROTEUS
|
||||
static Gpio PROTEUS_OUTPUTS[] = {
|
||||
PROTEUS_LS_1,
|
||||
PROTEUS_LS_2,
|
||||
PROTEUS_LS_3,
|
||||
PROTEUS_LS_4,
|
||||
PROTEUS_LS_5,
|
||||
PROTEUS_LS_6,
|
||||
PROTEUS_LS_7,
|
||||
PROTEUS_LS_8,
|
||||
PROTEUS_LS_9,
|
||||
PROTEUS_LS_10,
|
||||
PROTEUS_LS_11,
|
||||
PROTEUS_LS_12,
|
||||
PROTEUS_LS_13,
|
||||
PROTEUS_LS_14,
|
||||
PROTEUS_LS_15,
|
||||
PROTEUS_LS_16,
|
||||
Gpio::PROTEUS_LS_1,
|
||||
Gpio::PROTEUS_LS_2,
|
||||
Gpio::PROTEUS_LS_3,
|
||||
Gpio::PROTEUS_LS_4,
|
||||
Gpio::PROTEUS_LS_5,
|
||||
Gpio::PROTEUS_LS_6,
|
||||
Gpio::PROTEUS_LS_7,
|
||||
Gpio::PROTEUS_LS_8,
|
||||
Gpio::PROTEUS_LS_9,
|
||||
Gpio::PROTEUS_LS_10,
|
||||
Gpio::PROTEUS_LS_11,
|
||||
Gpio::PROTEUS_LS_12,
|
||||
Gpio::PROTEUS_LS_13,
|
||||
Gpio::PROTEUS_LS_14,
|
||||
Gpio::PROTEUS_LS_15,
|
||||
Gpio::PROTEUS_LS_16,
|
||||
Gpio::PROTEUS_IGN_1,
|
||||
Gpio::PROTEUS_IGN_2,
|
||||
};
|
||||
#endif // HW_PROTEUS
|
||||
|
||||
|
|
|
@ -271,12 +271,12 @@ void setEngineBMW_M73_Proteus() {
|
|||
engineConfiguration->clt.adcChannel = PROTEUS_IN_ANALOG_TEMP_4;
|
||||
|
||||
|
||||
engineConfiguration->starterControlPin = PROTEUS_LS_14;
|
||||
engineConfiguration->starterControlPin = Gpio::PROTEUS_LS_14;
|
||||
engineConfiguration->startStopButtonPin = PROTEUS_DIGITAL_3;
|
||||
engineConfiguration->startStopButtonMode = PI_PULLUP;
|
||||
engineConfiguration->fuelPumpPin = PROTEUS_LS_16;
|
||||
engineConfiguration->fanPin = PROTEUS_LS_15;
|
||||
engineConfiguration->mainRelayPin = PROTEUS_LS_13;
|
||||
engineConfiguration->fuelPumpPin = Gpio::PROTEUS_LS_16;
|
||||
engineConfiguration->fanPin = Gpio::PROTEUS_LS_15;
|
||||
engineConfiguration->mainRelayPin = Gpio::PROTEUS_LS_13;
|
||||
|
||||
engineConfiguration->map.sensor.hwChannel = PROTEUS_IN_ANALOG_VOLT_8; // M73 adapter board
|
||||
engineConfiguration->map.sensor.type = MT_MPX4250A;
|
||||
|
|
|
@ -491,29 +491,29 @@ void proteusBoardTest() {
|
|||
engineConfiguration->fuelPumpPin = Gpio::Unassigned;
|
||||
|
||||
#if EFI_PROD_CODE
|
||||
engineConfiguration->injectionPins[0] = PROTEUS_LS_1;
|
||||
engineConfiguration->injectionPins[1] = PROTEUS_LS_2;
|
||||
engineConfiguration->injectionPins[2] = PROTEUS_LS_3;
|
||||
engineConfiguration->injectionPins[3] = PROTEUS_LS_4;
|
||||
engineConfiguration->injectionPins[4] = PROTEUS_LS_5;
|
||||
engineConfiguration->injectionPins[5] = PROTEUS_LS_6;
|
||||
engineConfiguration->injectionPins[6] = PROTEUS_LS_9;
|
||||
engineConfiguration->injectionPins[7] = PROTEUS_LS_8;
|
||||
engineConfiguration->injectionPins[8] = PROTEUS_LS_11;
|
||||
engineConfiguration->injectionPins[9] = PROTEUS_LS_10;
|
||||
engineConfiguration->injectionPins[10] = PROTEUS_LS_12;
|
||||
engineConfiguration->injectionPins[11] = PROTEUS_LS_13;
|
||||
engineConfiguration->injectionPins[0] = Gpio::PROTEUS_LS_1;
|
||||
engineConfiguration->injectionPins[1] = Gpio::PROTEUS_LS_2;
|
||||
engineConfiguration->injectionPins[2] = Gpio::PROTEUS_LS_3;
|
||||
engineConfiguration->injectionPins[3] = Gpio::PROTEUS_LS_4;
|
||||
engineConfiguration->injectionPins[4] = Gpio::PROTEUS_LS_5;
|
||||
engineConfiguration->injectionPins[5] = Gpio::PROTEUS_LS_6;
|
||||
engineConfiguration->injectionPins[6] = Gpio::PROTEUS_LS_9;
|
||||
engineConfiguration->injectionPins[7] = Gpio::PROTEUS_LS_8;
|
||||
engineConfiguration->injectionPins[8] = Gpio::PROTEUS_LS_11;
|
||||
engineConfiguration->injectionPins[9] = Gpio::PROTEUS_LS_10;
|
||||
engineConfiguration->injectionPins[10] = Gpio::PROTEUS_LS_12;
|
||||
engineConfiguration->injectionPins[11] = Gpio::PROTEUS_LS_13;
|
||||
|
||||
|
||||
engineConfiguration->luaOutputPins[0] = PROTEUS_LS_7;
|
||||
engineConfiguration->luaOutputPins[1] = PROTEUS_LS_14;
|
||||
engineConfiguration->luaOutputPins[2] = PROTEUS_LS_15;
|
||||
engineConfiguration->luaOutputPins[3] = PROTEUS_LS_16;
|
||||
engineConfiguration->luaOutputPins[0] = Gpio::PROTEUS_LS_7;
|
||||
engineConfiguration->luaOutputPins[1] = Gpio::PROTEUS_LS_14;
|
||||
engineConfiguration->luaOutputPins[2] = Gpio::PROTEUS_LS_15;
|
||||
engineConfiguration->luaOutputPins[3] = Gpio::PROTEUS_LS_16;
|
||||
engineConfiguration->luaOutputPins[4] = PROTEUS_HS_2;
|
||||
engineConfiguration->luaOutputPins[5] = PROTEUS_HS_4;
|
||||
|
||||
engineConfiguration->ignitionPins[0] = PROTEUS_IGN_1;
|
||||
engineConfiguration->ignitionPins[1] = PROTEUS_IGN_2;
|
||||
engineConfiguration->ignitionPins[0] = Gpio::PROTEUS_IGN_1;
|
||||
engineConfiguration->ignitionPins[1] = Gpio::PROTEUS_IGN_2;
|
||||
engineConfiguration->ignitionPins[2] = PROTEUS_IGN_4;
|
||||
engineConfiguration->ignitionPins[3] = PROTEUS_IGN_5;
|
||||
engineConfiguration->ignitionPins[4] = PROTEUS_IGN_6;
|
||||
|
@ -524,7 +524,7 @@ void proteusBoardTest() {
|
|||
engineConfiguration->ignitionPins[8] = PROTEUS_IGN_9;
|
||||
engineConfiguration->ignitionPins[9] = PROTEUS_IGN_8;
|
||||
engineConfiguration->ignitionPins[10] = PROTEUS_HS_1;
|
||||
engineConfiguration->ignitionPins[11] = PROTEUS_IGN_12;
|
||||
engineConfiguration->ignitionPins[11] = Gpio::PROTEUS_IGN_12;
|
||||
|
||||
strncpy(config->luaScript, R"(
|
||||
startPwm(0, 10, 0.5)
|
||||
|
|
|
@ -80,12 +80,12 @@ void setSbc() {
|
|||
|
||||
#if HW_PROTEUS
|
||||
// tan wire with a black trace - "HEI B", plug pin B
|
||||
ignOverride->pin = PROTEUS_IGN_12;
|
||||
ignOverride->pin = Gpio::PROTEUS_IGN_12;
|
||||
engineConfiguration->fanPin = Gpio::Unassigned;
|
||||
// reminder about D101
|
||||
engineConfiguration->injectionPins[0] = PROTEUS_LS_14; // #1
|
||||
engineConfiguration->injectionPins[0] = Gpio::PROTEUS_LS_14; // #1
|
||||
// reminder about D104
|
||||
engineConfiguration->injectionPins[3] = PROTEUS_LS_15; // #4
|
||||
engineConfiguration->injectionPins[3] = Gpio::PROTEUS_LS_15; // #4
|
||||
|
||||
// wow high side relay control
|
||||
engineConfiguration->fuelPumpPin = PROTEUS_HS_1;
|
||||
|
|
|
@ -16,7 +16,7 @@ void proteusHarley() {
|
|||
|
||||
engineConfiguration->mapCamDetectionAnglePosition = 50;
|
||||
|
||||
engineConfiguration->luaOutputPins[0] = PROTEUS_LS_12;
|
||||
engineConfiguration->luaOutputPins[0] = Gpio::PROTEUS_LS_12;
|
||||
#if HW_PROTEUS
|
||||
strncpy(config->luaScript, R"(
|
||||
outputIndex = 0
|
||||
|
|
|
@ -81,17 +81,17 @@ void setProteusHondaElement2003() {
|
|||
// offset -41
|
||||
|
||||
|
||||
engineConfiguration->injectionPins[0] = PROTEUS_LS_8;
|
||||
engineConfiguration->injectionPins[1] = PROTEUS_LS_7;
|
||||
engineConfiguration->injectionPins[2] = PROTEUS_LS_6;
|
||||
engineConfiguration->injectionPins[3] = PROTEUS_LS_5;
|
||||
engineConfiguration->injectionPins[0] = Gpio::PROTEUS_LS_8;
|
||||
engineConfiguration->injectionPins[1] = Gpio::PROTEUS_LS_7;
|
||||
engineConfiguration->injectionPins[2] = Gpio::PROTEUS_LS_6;
|
||||
engineConfiguration->injectionPins[3] = Gpio::PROTEUS_LS_5;
|
||||
|
||||
vtsControl->pin = PROTEUS_HS_1;
|
||||
engineConfiguration->vvtPins[0] = PROTEUS_HS_2;
|
||||
|
||||
engineConfiguration->malfunctionIndicatorPin = PROTEUS_LS_10;
|
||||
engineConfiguration->idle.solenoidPin = PROTEUS_LS_15;
|
||||
engineConfiguration->fanPin = PROTEUS_LS_1;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::PROTEUS_LS_10;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::PROTEUS_LS_15;
|
||||
engineConfiguration->fanPin = Gpio::PROTEUS_LS_1;
|
||||
|
||||
engineConfiguration->iat.adcChannel = PROTEUS_IN_ANALOG_TEMP_1;
|
||||
engineConfiguration->clt.adcChannel = PROTEUS_IN_ANALOG_TEMP_2;
|
||||
|
@ -99,8 +99,8 @@ void setProteusHondaElement2003() {
|
|||
engineConfiguration->map.sensor.hwChannel = PROTEUS_IN_ANALOG_VOLT_6;
|
||||
engineConfiguration->fanPin = Gpio::Unassigned;
|
||||
|
||||
engineConfiguration->mainRelayPin = PROTEUS_LS_9;
|
||||
engineConfiguration->fuelPumpPin = PROTEUS_LS_11;
|
||||
engineConfiguration->mainRelayPin = Gpio::PROTEUS_LS_9;
|
||||
engineConfiguration->fuelPumpPin = Gpio::PROTEUS_LS_11;
|
||||
|
||||
#endif // HW_PROTEUS
|
||||
}
|
||||
|
|
|
@ -84,14 +84,14 @@ void setHyundaiPb() {
|
|||
setCommonNTCSensor(&engineConfiguration->clt, PROTEUS_DEFAULT_AT_PULLUP);
|
||||
setCommonNTCSensor(&engineConfiguration->iat, PROTEUS_DEFAULT_AT_PULLUP);
|
||||
|
||||
// engineConfiguration->acRelayPin = PROTEUS_LS_6;
|
||||
// engineConfiguration->acRelayPin = Gpio::PROTEUS_LS_6;
|
||||
engineConfiguration->acSwitch = PROTEUS_DIGITAL_5;
|
||||
|
||||
engineConfiguration->fanPin = PROTEUS_LS_5;
|
||||
engineConfiguration->tachOutputPin = PROTEUS_IGN_12;
|
||||
engineConfiguration->hpfpValvePin = PROTEUS_LS_6;
|
||||
engineConfiguration->vvtPins[0] = PROTEUS_LS_15; // intake
|
||||
engineConfiguration->vvtPins[1] = PROTEUS_LS_16; // exhaust
|
||||
engineConfiguration->fanPin = Gpio::PROTEUS_LS_5;
|
||||
engineConfiguration->tachOutputPin = Gpio::PROTEUS_IGN_12;
|
||||
engineConfiguration->hpfpValvePin = Gpio::PROTEUS_LS_6;
|
||||
engineConfiguration->vvtPins[0] = Gpio::PROTEUS_LS_15; // intake
|
||||
engineConfiguration->vvtPins[1] = Gpio::PROTEUS_LS_16; // exhaust
|
||||
#endif // HW_PROTEUS
|
||||
|
||||
#if HW_PROTEUS
|
||||
|
@ -210,7 +210,7 @@ void setProteusHyundaiPb() {
|
|||
setProteusEtbIO();
|
||||
|
||||
// something something input levels are not happy for digital input pin?
|
||||
engineConfiguration->starterControlPin = PROTEUS_LS_14;
|
||||
engineConfiguration->starterControlPin = Gpio::PROTEUS_LS_14;
|
||||
engineConfiguration->startStopButtonPin = PROTEUS_IN_AV_6_DIGITAL;
|
||||
engineConfiguration->startStopButtonMode = PI_DEFAULT;
|
||||
}
|
||||
|
|
|
@ -710,7 +710,7 @@ void setMiataNB2_Proteus() {
|
|||
engineConfiguration->ignitionMode = IM_WASTED_SPARK;
|
||||
|
||||
#if EFI_PROD_CODE
|
||||
engineConfiguration->ignitionPins[0] = PROTEUS_IGN_1;
|
||||
engineConfiguration->ignitionPins[0] = Gpio::PROTEUS_IGN_1;
|
||||
engineConfiguration->ignitionPins[1] = Gpio::Unassigned;
|
||||
engineConfiguration->ignitionPins[2] = PROTEUS_IGN_3;
|
||||
engineConfiguration->ignitionPins[3] = Gpio::Unassigned;
|
||||
|
@ -719,14 +719,14 @@ void setMiataNB2_Proteus() {
|
|||
engineConfiguration->injectionMode = IM_SEQUENTIAL;
|
||||
|
||||
|
||||
engineConfiguration->injectionPins[0] = PROTEUS_LS_1; // BLU # pin 3/black35
|
||||
engineConfiguration->injectionPins[1] = PROTEUS_LS_2; // BLK
|
||||
engineConfiguration->injectionPins[2] = PROTEUS_LS_3; // GRN
|
||||
engineConfiguration->injectionPins[3] = PROTEUS_LS_4; // WHT
|
||||
engineConfiguration->injectionPins[0] = Gpio::PROTEUS_LS_1; // BLU # pin 3/black35
|
||||
engineConfiguration->injectionPins[1] = Gpio::PROTEUS_LS_2; // BLK
|
||||
engineConfiguration->injectionPins[2] = Gpio::PROTEUS_LS_3; // GRN
|
||||
engineConfiguration->injectionPins[3] = Gpio::PROTEUS_LS_4; // WHT
|
||||
|
||||
engineConfiguration->enableSoftwareKnock = true;
|
||||
|
||||
engineConfiguration->malfunctionIndicatorPin = PROTEUS_LS_10;
|
||||
engineConfiguration->malfunctionIndicatorPin = Gpio::PROTEUS_LS_10;
|
||||
|
||||
engineConfiguration->map.sensor.hwChannel = PROTEUS_IN_MAP;
|
||||
|
||||
|
@ -740,9 +740,9 @@ void setMiataNB2_Proteus() {
|
|||
engineConfiguration->clt.adcChannel = PROTEUS_IN_ANALOG_TEMP_1;
|
||||
engineConfiguration->iat.adcChannel = PROTEUS_IN_ANALOG_TEMP_3;
|
||||
|
||||
engineConfiguration->fuelPumpPin = PROTEUS_LS_6;
|
||||
engineConfiguration->fuelPumpPin = Gpio::PROTEUS_LS_6;
|
||||
|
||||
engineConfiguration->idle.solenoidPin = PROTEUS_LS_7;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::PROTEUS_LS_7;
|
||||
|
||||
|
||||
engineConfiguration->fanPin = Gpio::B7;
|
||||
|
|
|
@ -113,7 +113,7 @@ void setProteusAnalogPwmTest() {
|
|||
engineConfiguration->triggerSimulatorPins[1] = Gpio::Unassigned;
|
||||
|
||||
// The idle control pin is connected to the default TPS input, analog volt 2
|
||||
engineConfiguration->idle.solenoidPin = PROTEUS_IGN_10;
|
||||
engineConfiguration->idle.solenoidPin = Gpio::PROTEUS_IGN_10;
|
||||
|
||||
// 5893hz is coprime with the analog sample rate, 500hz, so hopefully we get less aliasing
|
||||
engineConfiguration->idle.solenoidFrequency = 5893;
|
||||
|
|
|
@ -164,16 +164,16 @@ void setProteusVwPassatB6() {
|
|||
engineConfiguration->highPressureFuel.hwChannel = PROTEUS_IN_ANALOG_VOLT_4;
|
||||
|
||||
gppwm_channel *coolantControl = &engineConfiguration->gppwm[0];
|
||||
coolantControl->pin = PROTEUS_LS_5;
|
||||
coolantControl->pin = Gpio::PROTEUS_LS_5;
|
||||
|
||||
engineConfiguration->mainRelayPin = PROTEUS_LS_6;
|
||||
engineConfiguration->mainRelayPin = Gpio::PROTEUS_LS_6;
|
||||
|
||||
gppwm_channel *lowPressureFuelPumpControl = &engineConfiguration->gppwm[1];
|
||||
lowPressureFuelPumpControl->pin = PROTEUS_LS_7;
|
||||
lowPressureFuelPumpControl->pin = Gpio::PROTEUS_LS_7;
|
||||
|
||||
//engineConfiguration->boostControlPin = PROTEUS_LS_8;
|
||||
engineConfiguration->vvtPins[0] = PROTEUS_LS_9;
|
||||
engineConfiguration->hpfpValvePin = PROTEUS_LS_15;
|
||||
//engineConfiguration->boostControlPin = Gpio::PROTEUS_LS_8;
|
||||
engineConfiguration->vvtPins[0] = Gpio::PROTEUS_LS_9;
|
||||
engineConfiguration->hpfpValvePin = Gpio::PROTEUS_LS_15;
|
||||
|
||||
setProteusEtbIO();
|
||||
|
||||
|
|
|
@ -151,8 +151,11 @@ public class PinoutLogic {
|
|||
}
|
||||
if (meta != null) {
|
||||
pinId = map.get(meta);
|
||||
if (pinId == null)
|
||||
if (pinId == null) {
|
||||
if (map.isEmpty())
|
||||
throw new IllegalStateException("Empty meta mapping");
|
||||
throw new IllegalStateException("Failing to resolve [" + meta + "]");
|
||||
}
|
||||
}
|
||||
Object pinClass = pin.get("class");
|
||||
Object pinName = pin.get("pin");
|
||||
|
|
Loading…
Reference in New Issue