some debugging

This commit is contained in:
Marcel Peterkau 2022-08-24 23:08:57 +02:00
parent 4f5fdb7af4
commit e12971b971
2 changed files with 21 additions and 3 deletions

View File

@ -77,6 +77,7 @@ void RemoteDebug_CheckEEPOM();
void RemoteDebug_dumpConfig();
void RemoteDebug_dumpPersistance();
void RemoteDebug_ShowDTCs();
void RemoteDebug_dumpGlobals();
#endif
#ifdef FEATURE_ENABLE_WIFI_CLIENT
@ -287,9 +288,11 @@ void processCmdRemoteDebug()
else if (lastCmd == "dumpPDS")
RemoteDebug_dumpPersistance();
else if (lastCmd == "saveEE")
globals.requestEEAction == EE_ALL_SAVE;
globals.requestEEAction = EE_ALL_SAVE;
else if (lastCmd == "showdtc")
RemoteDebug_ShowDTCs();
else if (lastCmd == "dumpGlobals")
RemoteDebug_dumpGlobals();
}
void RemoteDebug_formatCFG()
@ -350,6 +353,20 @@ void RemoteDebug_dumpConfig()
debugA("checksum: 0x%08X", LubeConfig.checksum);
}
void RemoteDebug_dumpGlobals()
{
debugA("systemStatus: %d", globals.systemStatus);
debugA("resumeStatus: %d", globals.resumeStatus);
debugA("systemStatustxt: %s", globals.systemStatustxt);
debugA("purgePulses: %d", globals.purgePulses);
debugA("requestEEAction: %d", globals.requestEEAction);
debugA("DeviceName: %s", globals.DeviceName);
debugA("FlashVersion: %s", globals.FlashVersion);
debugA("eePersistanceAdress: %d", globals.eePersistanceAdress);
debugA("TankPercentage: %d", globals.TankPercentage);
debugA("hasDTC: %d", globals.hasDTC);
}
void RemoteDebug_dumpPersistance()
{
debugA("writeCycleCounter: %d", PersistenceData.writeCycleCounter);

View File

@ -9,4 +9,5 @@ const char helpCmd[] = "sysinfo - System Info\r\n"
"dumpCFG - print Config struct\r\n"
"dumpPDS - print PersistanceStruct\r\n"
"saveEE - save EE-Data\r\n"
"showdtc - Show all DTCs\r\n";
"showdtc - Show all DTCs\r\n"
"dumpGlobals - print globals\r\n";