only: extracting mock commands

This commit is contained in:
rusefillc 2023-07-29 08:01:37 -04:00
parent 786caca2ac
commit 26762ba6a2
3 changed files with 4 additions and 9 deletions

View File

@ -1813,6 +1813,9 @@ uint16_t[4] lambdaMaxDeviationRpmBins;;"RPM", 1, 0, 0, 18000, 0
end_struct
#define CMD_SET_SENSOR_MOCK "set_sensor_mock"
#define CMD_RESET_SENSOR_MOCKS "reset_sensor_mocks"
! Pedal Position Sensor
#define MOCK_PPS_POSITION_COMMAND "mock_pps_position"
#define MOCK_PPS_VOLTAGE_COMMAND "mock_pps_voltage"

View File

@ -61,7 +61,7 @@ public class DetachedSensor {
private Sensor sensor;
@org.jetbrains.annotations.NotNull
private final UIContext uiContext;
private int width;
private final int width;
public DetachedSensor(UIContext uiContext, Sensor sensor, int width) {
this.uiContext = uiContext;

View File

@ -119,18 +119,10 @@ public class SensorGauge {
}
public static Radial createRadial(String title, String units, double maxValue, double minValue) {
// final Section[] SECTIONS =
// {
// new Section(0, to, Color.red)
// };
Radial radial1 = new Radial();
// radial1.setSections(SECTIONS);
radial1.setTitle(title);
radial1.setUnitString(units);
//radial1.setTrackStop(to);
radial1.setMinValue(minValue);
if (minValue == maxValue) {
// a bit of a hack to survive not great input data