diff --git a/firmware/console/binary/tunerstudio_configuration.h b/firmware/console/binary/tunerstudio_configuration.h index ed39dc68fd..17e7e532b4 100644 --- a/firmware/console/binary/tunerstudio_configuration.h +++ b/firmware/console/binary/tunerstudio_configuration.h @@ -167,7 +167,9 @@ typedef struct { float oilPressure; // 280 float fuelConsumptionPerHour; // 284 float injectionOffset; // 288 - int unused3[16]; + int16_t debugIntField4; // 292 + int16_t debugIntField5; // 294 + int unused3[15]; /* see also [OutputChannels] in rusefi.input */ } TunerStudioOutputChannels; diff --git a/firmware/controllers/math/pid.cpp b/firmware/controllers/math/pid.cpp index ffcf37277c..a6ecf14535 100644 --- a/firmware/controllers/math/pid.cpp +++ b/firmware/controllers/math/pid.cpp @@ -126,6 +126,7 @@ void Pid::postState(TunerStudioOutputChannels *tsOutputChannels, int pMult) { tsOutputChannels->debugIntField1 = getP() * pMult; tsOutputChannels->debugIntField2 = getOffset(); tsOutputChannels->debugIntField3 = resetCounter; + tsOutputChannels->debugIntField4 = pid->period; } #endif diff --git a/firmware/tunerstudio/rusefi.input b/firmware/tunerstudio/rusefi.input index d800ca8883..755f08d4e0 100644 --- a/firmware/tunerstudio/rusefi.input +++ b/firmware/tunerstudio/rusefi.input @@ -260,6 +260,10 @@ fileVersion = { 20171101 } oilPressure = scalar, F32, 280, "kPa", 1, 0.0 fuelConsumptionPerHour=scalar, F32, 284, "kPa", 1, 0.0 injectionOffset = scalar, F32, 288, "deg", 1, 0; + debugIntField4 = scalar, S16, 292, "val", 1, 0.0; + debugIntField5 = scalar, S16, 294, "val", 1, 0.0; + + ; ; see TunerStudioOutputChannels struct ;