diff --git a/java_console/autotest/src/com/rusefi/proteus/ProteusAnalogTest.java b/java_console/autotest/src/com/rusefi/proteus/ProteusAnalogTest.java index e2bdbba729..f2ac8a457f 100644 --- a/java_console/autotest/src/com/rusefi/proteus/ProteusAnalogTest.java +++ b/java_console/autotest/src/com/rusefi/proteus/ProteusAnalogTest.java @@ -58,4 +58,16 @@ public class ProteusAnalogTest extends RusefiTestBase { // 100% duty -> failed TPS (voltage too high) setIdlePositionAndAssertTps(98, 0); } + + void assertSensorValue(Sensor sensor, double expected) { + double actual = SensorCentral.getInstance().getValue(sensor); + assertEquals(expected, actual, 0.5); + } + + @Test + public void testUnconnectedInputs() { + // CLT/IAT inputs should float at ~5 volts + assertSensorValue(Sensor.rawClt, 5.0); + assertSensorValue(Sensor.rawIat, 5.0); + } } diff --git a/java_console/models/src/main/java/com/rusefi/core/Sensor.java b/java_console/models/src/main/java/com/rusefi/core/Sensor.java index 7acde965cd..e588c24557 100644 --- a/java_console/models/src/main/java/com/rusefi/core/Sensor.java +++ b/java_console/models/src/main/java/com/rusefi/core/Sensor.java @@ -118,6 +118,10 @@ public enum Sensor { tuneCrc16("tune crc16", SensorCategory.STATUS, FieldType.UINT16, 244, 0, 5), + // Raw sensors + rawClt("raw CLT", SensorCategory.SENSOR_INPUTS, FieldType.INT16, 238, 1.0 / PACK_MULT_VOLTAGE, 0, 5, "volts"), + rawIat("raw IAT", SensorCategory.SENSOR_INPUTS, FieldType.INT16, 240, 1.0 / PACK_MULT_VOLTAGE, 0, 5, "volts"), + // Synthetic (console only) channels ETB_CONTROL_QUALITY("ETB metric", SensorCategory.SNIFFING, "", 100), ;