This commit is contained in:
parent
1f07d65fb1
commit
5c3fe0e77f
|
@ -827,6 +827,8 @@ void updateTunerStudioState(TunerStudioOutputChannels *tsOutputChannels DECLARE_
|
|||
|
||||
tsOutputChannels->clutchUpState = engine->clutchUpState;
|
||||
tsOutputChannels->clutchDownState = engine->clutchDownState;
|
||||
tsOutputChannels->brakePedalState = engine->brakePedalState;
|
||||
|
||||
tsOutputChannels->tCharge = getTCharge(rpm, tps, coolant, intake PASS_ENGINE_PARAMETER);
|
||||
float timing = engine->engineState.timingAdvance;
|
||||
tsOutputChannels->ignitionAdvance = timing > 360 ? timing - 720 : timing;
|
||||
|
|
|
@ -134,7 +134,7 @@ void Engine::reset() {
|
|||
|
||||
timeOfLastKnockEvent = 0;
|
||||
fuelMs = 0;
|
||||
clutchDownState = clutchUpState = false;
|
||||
clutchDownState = clutchUpState = brakePedalState = false;
|
||||
memset(&m, 0, sizeof(m));
|
||||
|
||||
}
|
||||
|
|
|
@ -329,6 +329,7 @@ public:
|
|||
|
||||
bool clutchUpState;
|
||||
bool clutchDownState;
|
||||
bool brakePedalState;
|
||||
|
||||
bool isRunningPwmTest;
|
||||
|
||||
|
|
|
@ -210,12 +210,14 @@ static msg_t ivThread(int param) {
|
|||
|
||||
// this value is not used yet
|
||||
if (boardConfiguration->clutchDownPin != GPIO_UNASSIGNED) {
|
||||
engine->clutchDownState = palReadPad(getHwPort(boardConfiguration->clutchDownPin),
|
||||
getHwPin(boardConfiguration->clutchDownPin));
|
||||
engine->clutchDownState = efiReadPin(boardConfiguration->clutchDownPin);
|
||||
}
|
||||
if (boardConfiguration->clutchUpPin != GPIO_UNASSIGNED) {
|
||||
engine->clutchUpState = palReadPad(getHwPort(boardConfiguration->clutchUpPin),
|
||||
getHwPin(boardConfiguration->clutchUpPin));
|
||||
engine->clutchUpState = efiReadPin(boardConfiguration->clutchUpPin);
|
||||
}
|
||||
|
||||
if (engineConfiguration->brakePedalPin != GPIO_UNASSIGNED) {
|
||||
engine->brakePedalState = efiReadPin(engineConfiguration->brakePedalPin);
|
||||
}
|
||||
|
||||
finishIdleTestIfNeeded();
|
||||
|
@ -320,13 +322,20 @@ void startIdleThread(Logging*sharedLogger) {
|
|||
|
||||
// this is idle switch INPUT - sometimes there is a switch on the throttle pedal
|
||||
// this switch is not used yet
|
||||
if (boardConfiguration->clutchDownPin != GPIO_UNASSIGNED)
|
||||
if (boardConfiguration->clutchDownPin != GPIO_UNASSIGNED) {
|
||||
mySetPadMode2("clutch down switch", boardConfiguration->clutchDownPin,
|
||||
getInputMode(boardConfiguration->clutchDownPinMode));
|
||||
}
|
||||
|
||||
if (boardConfiguration->clutchUpPin != GPIO_UNASSIGNED)
|
||||
if (boardConfiguration->clutchUpPin != GPIO_UNASSIGNED) {
|
||||
mySetPadMode2("clutch up switch", boardConfiguration->clutchUpPin,
|
||||
getInputMode(boardConfiguration->clutchUpPinMode));
|
||||
}
|
||||
|
||||
if (engineConfiguration->brakePedalPin != GPIO_UNASSIGNED) {
|
||||
mySetPadMode2("brake pedal switch", engineConfiguration->brakePedalPin,
|
||||
getInputMode(engineConfiguration->brakePedalPinMode));
|
||||
}
|
||||
|
||||
addConsoleAction("idleinfo", showIdleInfo);
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ enable2ndByteCanID = false
|
|||
|
||||
; see PAGE_0_SIZE in C source code
|
||||
; CONFIG_DEFINITION_START
|
||||
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon May 15 04:47:12 EDT 2017
|
||||
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon May 15 05:04:09 EDT 2017
|
||||
|
||||
pageSize = 16376
|
||||
page = 1
|
||||
|
@ -1743,6 +1743,7 @@ cmd_call_from_pit = "w\x00\x20\x34\x56"
|
|||
field = "Vehicle Speed Input pin", vehicleSpeedSensorInputPin
|
||||
field = "clutchDownPin", clutchDownPin
|
||||
field = "clutchUpPin", clutchUpPin
|
||||
field = "brakePedalPin", brakePedalPin
|
||||
|
||||
dialog = allPins2
|
||||
field = "Tachometer output Pin", tachOutputPin
|
||||
|
@ -2403,4 +2404,5 @@ cmd_call_from_pit = "w\x00\x20\x34\x56"
|
|||
field = "Use Fuel Cut", step1fuelCutEnable
|
||||
field = "clutchDownPin", clutchDownPin
|
||||
field = "clutchUpPin", clutchUpPin
|
||||
field = "brakePedalPin", brakePedalPin
|
||||
|
||||
|
|
|
@ -1003,6 +1003,7 @@ cmd_call_from_pit = "w\x00\x20\x34\x56"
|
|||
field = "Vehicle Speed Input pin", vehicleSpeedSensorInputPin
|
||||
field = "clutchDownPin", clutchDownPin
|
||||
field = "clutchUpPin", clutchUpPin
|
||||
field = "brakePedalPin", brakePedalPin
|
||||
|
||||
dialog = allPins2
|
||||
field = "Tachometer output Pin", tachOutputPin
|
||||
|
@ -1663,4 +1664,5 @@ cmd_call_from_pit = "w\x00\x20\x34\x56"
|
|||
field = "Use Fuel Cut", step1fuelCutEnable
|
||||
field = "clutchDownPin", clutchDownPin
|
||||
field = "clutchUpPin", clutchUpPin
|
||||
field = "brakePedalPin", brakePedalPin
|
||||
|
||||
|
|
Loading…
Reference in New Issue