Something something Automatic Compression Release #3442
This commit is contained in:
parent
fcf0d68849
commit
e8aebc313a
|
@ -94,6 +94,7 @@ public:
|
||||||
AcState acState;
|
AcState acState;
|
||||||
bool enableOverdwellProtection = true;
|
bool enableOverdwellProtection = true;
|
||||||
bool isPwmEnabled = true;
|
bool isPwmEnabled = true;
|
||||||
|
// todo: remove this once all usages are using 'm_lastEventTimer'
|
||||||
int triggerActivityMs = -99 * 1000;
|
int triggerActivityMs = -99 * 1000;
|
||||||
|
|
||||||
const char *prevOutputName = nullptr;
|
const char *prevOutputName = nullptr;
|
||||||
|
|
|
@ -531,7 +531,7 @@ void configureRusefiLuaHooks(lua_State* l) {
|
||||||
Engine *engine = engineForLuaUnitTests;
|
Engine *engine = engineForLuaUnitTests;
|
||||||
EXPAND_Engine;
|
EXPAND_Engine;
|
||||||
#endif
|
#endif
|
||||||
int result = currentTimeMillis() - engine->triggerActivityMs;
|
int result = engine->triggerCentral.m_lastEventTimer.getElapsedUs() / 1000;
|
||||||
lua_pushnumber(l, result);
|
lua_pushnumber(l, result);
|
||||||
return 1;
|
return 1;
|
||||||
});
|
});
|
||||||
|
|
|
@ -86,10 +86,10 @@ public:
|
||||||
|
|
||||||
TriggerFormDetails triggerFormDetails;
|
TriggerFormDetails triggerFormDetails;
|
||||||
|
|
||||||
private:
|
|
||||||
// Keep track of the last time we got a valid trigger event
|
// Keep track of the last time we got a valid trigger event
|
||||||
Timer m_lastEventTimer;
|
Timer m_lastEventTimer;
|
||||||
|
|
||||||
|
private:
|
||||||
// Keep track of the last time we saw the sync tooth go by (trigger index 0)
|
// Keep track of the last time we saw the sync tooth go by (trigger index 0)
|
||||||
Timer m_virtualZeroTimer;
|
Timer m_virtualZeroTimer;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue