From 350d1c6ee4cdabdc81b3708ca2a67b57af41fa0e Mon Sep 17 00:00:00 2001 From: rusEfi Date: Thu, 4 Sep 2014 17:02:56 -0500 Subject: [PATCH] auto-sync --- firmware/console/status_loop.cpp | 2 +- firmware/controllers/algo/enum_strings.cpp | 15 +++++++++++++++ firmware/controllers/algo/enum_strings.h | 1 + firmware/rusefi.cpp | 2 +- 4 files changed, 18 insertions(+), 2 deletions(-) diff --git a/firmware/console/status_loop.cpp b/firmware/console/status_loop.cpp index f5afb753fe..49bee53c94 100644 --- a/firmware/console/status_loop.cpp +++ b/firmware/console/status_loop.cpp @@ -307,7 +307,7 @@ void updateDevConsoleState(void) { static void showFuelMap2(float rpm, float engineLoad) { float baseFuel = getBaseTableFuel((int) rpm, engineLoad); - scheduleMsg(&logger2, "algo=%d", engineConfiguration->algorithm); + scheduleMsg(&logger2, "algo=%s", algorithmToString(engineConfiguration->algorithm)); float iatCorrection = getIatCorrection(getIntakeAirTemperature()); float cltCorrection = getCltCorrection(getCoolantTemperature()); float injectorLag = getInjectorLag(getVBatt()); diff --git a/firmware/controllers/algo/enum_strings.cpp b/firmware/controllers/algo/enum_strings.cpp index 393db29898..a7d36b92eb 100644 --- a/firmware/controllers/algo/enum_strings.cpp +++ b/firmware/controllers/algo/enum_strings.cpp @@ -82,3 +82,18 @@ const char * pinModeToString(pin_output_mode_e mode) { return "unexpected"; } } + +const char * algorithmToString(engine_load_mode_e mode) { + switch(mode) { + case LM_TPS: + return "Alpha-N"; + case LM_MAF: + return "Maf"; + case LM_MAP: + return "pMap"; + case LM_SPEED_DENSITY: + return "SD"; + default: + return "unexpected"; + } +} diff --git a/firmware/controllers/algo/enum_strings.h b/firmware/controllers/algo/enum_strings.h index 5e52694cfd..237f2e527e 100644 --- a/firmware/controllers/algo/enum_strings.h +++ b/firmware/controllers/algo/enum_strings.h @@ -12,5 +12,6 @@ const char* getConfigurationName(engine_type_e engineType); const char * pinModeToString(pin_output_mode_e mode); +const char * algorithmToString(engine_load_mode_e mode); #endif /* ENUM_STRINGS_H_ */ diff --git a/firmware/rusefi.cpp b/firmware/rusefi.cpp index 76e7e34708..ba901b69a9 100644 --- a/firmware/rusefi.cpp +++ b/firmware/rusefi.cpp @@ -229,5 +229,5 @@ void firmwareError(const char *fmt, ...) { } int getRusEfiVersion(void) { - return 20140903; + return 20140904; }