parent
fcc77166fe
commit
1e9ca2f90a
|
@ -27,6 +27,7 @@
|
|||
#include "pch.h"
|
||||
#include "status_loop.h"
|
||||
#include "hip9011_logic.h"
|
||||
#include "electronic_throttle.h"
|
||||
|
||||
#if EFI_LOGIC_ANALYZER
|
||||
#include "logic_analyzer.h"
|
||||
|
@ -644,6 +645,26 @@ void updateTunerStudioState() {
|
|||
|
||||
float rpm = Sensor::get(SensorType::Rpm).value_or(0);
|
||||
|
||||
|
||||
static Timer blinkIndicatorsTimer;
|
||||
constexpr float blinkHalfPeriod = 0.3;
|
||||
bool isBlinkPhase = blinkIndicatorsTimer.hasElapsedSec(blinkHalfPeriod);
|
||||
#if EFI_ELECTRONIC_THROTTLE_BODY
|
||||
blinkEtbErrorCodes(isBlinkPhase);
|
||||
#endif // EFI_ELECTRONIC_THROTTLE_BODY
|
||||
if (isBlinkPhase) {
|
||||
engine->outputChannels.sparkCutReasonBlinker = 0;
|
||||
engine->outputChannels.fuelCutReasonBlinker = 0;
|
||||
|
||||
if (blinkIndicatorsTimer.hasElapsedSec(2 * blinkHalfPeriod)) {
|
||||
blinkIndicatorsTimer.reset();
|
||||
}
|
||||
} else {
|
||||
engine->outputChannels.sparkCutReasonBlinker = engine->outputChannels.sparkCutReason;
|
||||
engine->outputChannels.fuelCutReasonBlinker = engine->outputChannels.fuelCutReason;
|
||||
}
|
||||
|
||||
|
||||
#if EFI_PROD_CODE
|
||||
executorStatistics();
|
||||
#endif /* EFI_PROD_CODE */
|
||||
|
|
|
@ -762,6 +762,12 @@ static EtbImpl<EtbController2> etb2(throttle2TrimTable);
|
|||
static_assert(ETB_COUNT == 2);
|
||||
static EtbController* etbControllers[] = { &etb1, &etb2 };
|
||||
|
||||
void blinkEtbErrorCodes(bool blinkPhase) {
|
||||
for (int i = 0;i<ETB_COUNT;i++) {
|
||||
etbControllers[i]->etbErrorCodeBlinker = blinkPhase ? 0 : etbControllers[i]->etbErrorCode;
|
||||
}
|
||||
}
|
||||
|
||||
#if !EFI_UNIT_TEST
|
||||
|
||||
struct DcThread final : public PeriodicController<512> {
|
||||
|
|
|
@ -19,6 +19,8 @@ void setEtbWastegatePosition(percent_t pos);
|
|||
void setEtbLuaAdjustment(percent_t adjustment);
|
||||
void setHitachiEtbCalibration();
|
||||
|
||||
void blinkEtbErrorCodes(bool blinkPhase);
|
||||
|
||||
// same plug as 18919 AM810 but have different calibrations
|
||||
void setToyota89281_33010_pedal_position_sensor();
|
||||
|
||||
|
|
|
@ -1837,9 +1837,9 @@ gaugeCategory = GPPWM Outputs
|
|||
indicator = { isWarnNow }, "No warnings", "Warning", white, black, yellow, black
|
||||
indicator = { checkEngine }, "No Check Engine", "Check Engine", white, black, red, black
|
||||
indicator = { isTriggerError}, "Trigger OK", "Trigger ERR", white, black, red, black
|
||||
indicator = { fuelCutReason != 0 }, "Injection OK", { Fuel cut: bitStringValue(fuelIgnCutCodeList, fuelCutReason)}, white, black, yellow, black
|
||||
indicator = { sparkCutReason != 0 }, "Ignition OK", { Ign cut: bitStringValue(fuelIgnCutCodeList, sparkCutReason)}, white, black, yellow, black
|
||||
indicator = { etbErrorCode0 != 0 }, "ETB OK", { ETB: bitStringValue(etbCutCodeList, etbErrorCode0)}, white, black, yellow, black
|
||||
indicator = { fuelCutReasonBlinker != 0 }, "Injection OK", { Fuel cut: bitStringValue(fuelIgnCutCodeList, fuelCutReason)}, white, black, yellow, black
|
||||
indicator = { sparkCutReasonBlinker != 0 }, "Ignition OK", { Ign cut: bitStringValue(fuelIgnCutCodeList, sparkCutReason)}, white, black, yellow, black
|
||||
indicator = { etbErrorCodeBlinker0 != 0 }, "ETB OK", { ETB: bitStringValue(etbCutCodeList, etbErrorCode0)}, white, black, yellow, black
|
||||
|
||||
; minor info
|
||||
indicator = { isFanOn }, "Fan off", "Fan on", white, black, green, black
|
||||
|
|
Loading…
Reference in New Issue