only: part of knock logging
This commit is contained in:
parent
d7527eb774
commit
85db1cf0dc
|
@ -66,7 +66,6 @@ int16_t rpmAcceleration;dRPM;"RPM acceleration",1, 0, 0, 5, 2
|
|||
uint16_t autoscale baroPressure;;"kPa",{1/@@PACK_MULT_PRESSURE@@}, 0, 0, 0, 1
|
||||
|
||||
uint16_t autoscale lambdaValue;@@GAUGE_NAME_LAMBDA@@;"",{1/@@PACK_MULT_LAMBDA@@}, 0, 0, 0, 3
|
||||
uint8_t autoscale knockRetard;@@GAUGE_NAME_KNOCK_RETARD@@;"deg",{1/10}, 0, 0, 0, 1
|
||||
|
||||
uint16_t autoscale VBatt;@@GAUGE_NAME_VBAT@@;"V",{1/@@PACK_MULT_VOLTAGE@@}, 0, 0, 0, 2
|
||||
|
||||
|
@ -109,8 +108,6 @@ int16_t rpmAcceleration;dRPM;"RPM acceleration",1, 0, 0, 5, 2
|
|||
int16_t autoscale TPS2Value;@@GAUGE_NAME_TPS2@@;"%",{1/@@PACK_MULT_PERCENT@@}, 0, 0, 0, 2
|
||||
uint16_t tuneCrc16;@@GAUGE_NAME_TUNE_CRC16@@;"crc16", 1, 0, 0, 0, 0
|
||||
|
||||
float knockLevel;@@GAUGE_NAME_KNOCK_LEVEL@@;"Volts", 1, 0, 0, 0, 2
|
||||
|
||||
! integration magic: TS requires exact 'seconds' name
|
||||
uint32_t seconds;@@GAUGE_NAME_UPTIME@@;"sec", 1, 0, 0, 0, 0
|
||||
uint32_t engineMode;Engine Mode;"em", 1, 0, 0, 0, 0
|
||||
|
@ -137,10 +134,6 @@ int16_t rpmAcceleration;dRPM;"RPM acceleration",1, 0, 0, 5, 2
|
|||
int16_t autoscale wastegatePositionSensor;@@GAUGE_NAME_WG_POSITION@@;"%",{1/@@PACK_MULT_PERCENT@@}, 0, 0, 0, 2
|
||||
int16_t autoscale highFuelPressure;@@GAUGE_NAME_FUEL_PRESSURE_HIGH@@;"bar",{1/@@PACK_MULT_HIGH_PRESSURE@@}, 0, 0, 0, 0
|
||||
|
||||
! todo: this not needed in light of TS_SIGNATURE but rusEFI console still uses it. Need to migrate
|
||||
! rusEFI console from TS_FILE_VERSION to TS_SIGNATURE :(
|
||||
uint32_t tsConfigVersion;;"", 1, 0, 0, 0, 0
|
||||
|
||||
|
||||
! These two fields indicate to TS that we'd like to set a particular field to a particular value
|
||||
! We use a maintainConstantValue in TS for each field we'd like to set, like this:
|
||||
|
@ -156,6 +149,10 @@ int16_t rpmAcceleration;dRPM;"RPM acceleration",1, 0, 0, 5, 2
|
|||
uint8_t calibrationMode;;"", 1, 0, 0, 0, 0
|
||||
uint8_t idleTargetPosition;Idle: Stepper target position;"", 1, 0, 0, 0, 0
|
||||
|
||||
! todo: this not needed in light of TS_SIGNATURE but rusEFI console still uses it. Need to migrate
|
||||
! rusEFI console from TS_FILE_VERSION to TS_SIGNATURE :(
|
||||
uint32_t tsConfigVersion;;"", 1, 0, 0, 0, 0
|
||||
|
||||
! Errors
|
||||
uint32_t totalTriggerErrorCounter;@@GAUGE_NAME_TRG_ERR@@;"counter",1, 0, 0, 0, 0
|
||||
uint32_t orderingErrorCounter;;"",1, 0, 0, 0, 0
|
||||
|
|
|
@ -723,7 +723,7 @@ void canDashboardHaltech(CanCycle cycle) {
|
|||
{
|
||||
CanTxMessage msg(CanCategory::NBC, 0x36A, 4);
|
||||
/* Knock Level 1 */
|
||||
tmp = (engine->outputChannels.knockLevel * 100);
|
||||
tmp = (engine->module<KnockController>()->m_knockLevel * 100);
|
||||
msg[0] = (tmp >> 8);
|
||||
msg[1] = (tmp & 0x00ff);
|
||||
/* Knock Level 2 */
|
||||
|
|
|
@ -91,7 +91,7 @@ static void populateFrame(ms1515& msg)
|
|||
/* TODO */
|
||||
msg.sensor1 = 0;
|
||||
msg.sensor2 = 0;
|
||||
msg.knk_rtd = engine->outputChannels.knockLevel;
|
||||
msg.knk_rtd = engine->module<KnockController>()->m_knockLevel;
|
||||
msg.unused = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -60,7 +60,7 @@ bool KnockControllerBase::onKnockSenseCompleted(uint8_t cylinderNumber, float db
|
|||
engine->outputChannels.knock[cylinderNumber] = roundf(cylPeak);
|
||||
|
||||
// Pass through all-cylinders peak detector
|
||||
engine->outputChannels.knockLevel = allCylinderPeakDetector.detect(dbv, lastKnockTime);
|
||||
m_knockLevel = allCylinderPeakDetector.detect(dbv, lastKnockTime);
|
||||
|
||||
// If this was a knock, count it!
|
||||
if (isKnock) {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
struct_no_prefix knock_controller_s
|
||||
angle_t m_knockRetard;Knock Degrees retarded\nlarger number = more retard
|
||||
float m_knockThreshold;Knock Retard Threshold
|
||||
uint32_t m_knockCount;Knock Count
|
||||
float m_knockLevel;@@GAUGE_NAME_KNOCK_LEVEL@@;"Volts", 1, 0, 0, 0, 2
|
||||
angle_t m_knockRetard;@@GAUGE_NAME_KNOCK_RETARD@@;"deg",1,0,0,0,1
|
||||
float m_knockThreshold;Knock: Threshold
|
||||
uint32_t m_knockCount;@@GAUGE_NAME_KNOCK_COUNTER@@;"",1, 0, 0, 0, 0
|
||||
float m_maximumRetard
|
||||
end_struct
|
||||
|
|
Loading…
Reference in New Issue