From e7fe93141b82ce9785ed89540e09958e68ca5e88 Mon Sep 17 00:00:00 2001 From: rusEfi Date: Tue, 23 Feb 2016 17:02:17 -0500 Subject: [PATCH] auto-sync --- .../rusefi/autotune/test/FuelAutoTune2Test.java | 14 +++----------- .../com/rusefi/autotune/test/FuelAutoTuneTest.java | 8 ++++---- 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/java_console/models/src/com/rusefi/autotune/test/FuelAutoTune2Test.java b/java_console/models/src/com/rusefi/autotune/test/FuelAutoTune2Test.java index 57f7f71e37..f5e8a79631 100644 --- a/java_console/models/src/com/rusefi/autotune/test/FuelAutoTune2Test.java +++ b/java_console/models/src/com/rusefi/autotune/test/FuelAutoTune2Test.java @@ -9,6 +9,8 @@ import org.junit.Test; import java.util.ArrayList; import java.util.List; +import static com.rusefi.autotune.test.FuelAutoTuneTest.createVeTable; + /** * 2/23/2016 * (c) Andrey Belomutskiy 2013-2016 @@ -21,7 +23,7 @@ public class FuelAutoTune2Test { dataPoints.add(stDataOnline.valueOf(13, 1200, 80)); { - System.out.println("Running with one datapoint"); + System.out.println("Running with one datapoint already at target AFR"); Result r = FuelAutoTune2.INSTANCE.process(false, dataPoints, 0.1, 13, createVeTable()); FuelAutoTuneTest.printNotDefault(r.getKgbcRES(), 1); } @@ -53,14 +55,4 @@ public class FuelAutoTune2Test { // todo: validate results } - - private static float[][] createVeTable() { - float kgbcINIT[][] = new float[Fields.FUEL_LOAD_COUNT][Fields.FUEL_RPM_COUNT]; - for (int engineLoadIndex = 0; engineLoadIndex < Fields.FUEL_LOAD_COUNT; engineLoadIndex++) { - for (int rpmIndex = 0; rpmIndex < Fields.FUEL_RPM_COUNT; rpmIndex++) { - kgbcINIT[engineLoadIndex][rpmIndex] = 1; - } - } - return kgbcINIT; - } } diff --git a/java_console/models/src/com/rusefi/autotune/test/FuelAutoTuneTest.java b/java_console/models/src/com/rusefi/autotune/test/FuelAutoTuneTest.java index fe7321f4e5..8ededd20db 100644 --- a/java_console/models/src/com/rusefi/autotune/test/FuelAutoTuneTest.java +++ b/java_console/models/src/com/rusefi/autotune/test/FuelAutoTuneTest.java @@ -67,14 +67,14 @@ public class FuelAutoTuneTest { } } - private static float[][] createVeTable() { - float kgbcINIT[][] = new float[Fields.FUEL_LOAD_COUNT][Fields.FUEL_RPM_COUNT]; + static float[][] createVeTable() { + float veMap[][] = new float[Fields.FUEL_LOAD_COUNT][Fields.FUEL_RPM_COUNT]; for (int engineLoadIndex = 0; engineLoadIndex < Fields.FUEL_LOAD_COUNT; engineLoadIndex++) { for (int rpmIndex = 0; rpmIndex < Fields.FUEL_RPM_COUNT; rpmIndex++) { - kgbcINIT[engineLoadIndex][rpmIndex] = 1; + veMap[engineLoadIndex][rpmIndex] = 1; } } - return kgbcINIT; + return veMap; } }