diff --git a/Software/src/debugger.cpp b/Software/src/debugger.cpp index a3d0518..7f56d22 100644 --- a/Software/src/debugger.cpp +++ b/Software/src/debugger.cpp @@ -30,6 +30,7 @@ void Debug_ShowDTCs(); void Debug_dumpGlobals(); void Debug_printHelp(); void Debug_Purge(); +void Debug_refillTank(); const char *uint32_to_binary_string(uint32_t num); /** @@ -318,7 +319,8 @@ static const std::map &getCmdMap() int code = tokens[0].toInt(); MaintainDTC((DTCNum_t)code, true, millis()); } - }} + }}, + {"tank_refill", [](const String &) { Debug_refillTank(); }}, }; return cmdMap; } @@ -542,6 +544,13 @@ void Debug_Purge() Debug_pushMessage("Purging 10 pulses\n"); } +void Debug_refillTank() +{ + PersistenceData.tankRemain_microL = LubeConfig.tankCapacity_ml * 1000; + globals.requestEEAction = EE_PDS_SAVE; + Debug_pushMessage("Setting Tank to 100%\n"); +} + /** * @brief Convert a uint32_t value to a binary string with nibbles separated by a space. *