Add relevant program core information

This commit is contained in:
Theo Arends 2022-10-04 17:52:15 +02:00
parent 3df0ed4d20
commit 5a314f72e3
3 changed files with 15 additions and 3 deletions

View File

@ -743,14 +743,14 @@ void CmndStatus(void)
}
if ((0 == payload) || (2 == payload)) {
Response_P(PSTR("{\"" D_CMND_STATUS D_STATUS2_FIRMWARE "\":{\"" D_JSON_VERSION "\":\"%s%s\",\"" D_JSON_BUILDDATETIME "\":\"%s\""
Response_P(PSTR("{\"" D_CMND_STATUS D_STATUS2_FIRMWARE "\":{\"" D_JSON_VERSION "\":\"%s%s%s\",\"" D_JSON_BUILDDATETIME "\":\"%s\""
#ifdef ESP8266
",\"" D_JSON_BOOTVERSION "\":%d"
#endif
",\"" D_JSON_COREVERSION "\":\"" ARDUINO_CORE_RELEASE "\",\"" D_JSON_SDKVERSION "\":\"%s\","
"\"CpuFrequency\":%d,\"Hardware\":\"%s\""
"%s}}"),
TasmotaGlobal.version, TasmotaGlobal.image_name, GetBuildDateAndTime().c_str()
TasmotaGlobal.version, TasmotaGlobal.image_name, GetCodeCores().c_str(), GetBuildDateAndTime().c_str()
#ifdef ESP8266
, ESP.getBootVersion()
#endif

View File

@ -116,6 +116,10 @@ String GetDeviceHardwareRevision(void) {
return GetDeviceHardware();
}
String GetCodeCores(void) {
return F("");
}
#endif
/*********************************************************************************************\
@ -933,6 +937,14 @@ String GetDeviceHardwareRevision(void) {
return result;
}
String GetCodeCores(void) {
#if defined(CORE32SOLO1)
return F("single-core");
#else
return F("");
#endif
}
/*
* ESP32 v1 and v2 needs some special patches to use PSRAM.
* Standard Tasmota 32 do not include those patches.

View File

@ -2334,7 +2334,7 @@ void HandleInformation(void)
// }2 = </th><td>
WSContentSend_P(HTTP_SCRIPT_INFO_BEGIN);
WSContentSend_P(PSTR("<table style='width:100%%'><tr><th>"));
WSContentSend_P(PSTR(D_PROGRAM_VERSION "}2%s%s"), TasmotaGlobal.version, TasmotaGlobal.image_name);
WSContentSend_P(PSTR(D_PROGRAM_VERSION "}2%s%s%s"), TasmotaGlobal.version, TasmotaGlobal.image_name, GetCodeCores().c_str());
WSContentSend_P(PSTR("}1" D_BUILD_DATE_AND_TIME "}2%s"), GetBuildDateAndTime().c_str());
WSContentSend_P(PSTR("}1" D_CORE_AND_SDK_VERSION "}2" ARDUINO_CORE_RELEASE "/%s"), ESP.getSdkVersion());
WSContentSend_P(PSTR("}1" D_UPTIME "}2%s"), GetUptime().c_str());