Feature: show ESP32 flash memory size in system info
This commit is contained in:
parent
1f1227fa10
commit
4972892d9a
@ -48,6 +48,7 @@ void WebApiSysstatusClass::onSystemStatus(AsyncWebServerRequest* request)
|
|||||||
root["chiprevision"] = ESP.getChipRevision();
|
root["chiprevision"] = ESP.getChipRevision();
|
||||||
root["chipmodel"] = ESP.getChipModel();
|
root["chipmodel"] = ESP.getChipModel();
|
||||||
root["chipcores"] = ESP.getChipCores();
|
root["chipcores"] = ESP.getChipCores();
|
||||||
|
root["flashsize"] = ESP.getFlashChipSize();
|
||||||
|
|
||||||
String reason;
|
String reason;
|
||||||
reason = ResetReason::get_reset_reason_verbose(0);
|
reason = ResetReason::get_reset_reason_verbose(0);
|
||||||
|
|||||||
@ -19,6 +19,13 @@
|
|||||||
<th>{{ $t('hardwareinfo.CpuFrequency') }}</th>
|
<th>{{ $t('hardwareinfo.CpuFrequency') }}</th>
|
||||||
<td>{{ systemStatus.cpufreq }} {{ $t('hardwareinfo.Mhz') }}</td>
|
<td>{{ systemStatus.cpufreq }} {{ $t('hardwareinfo.Mhz') }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>{{ $t('hardwareinfo.FlashSize') }}</th>
|
||||||
|
<td>
|
||||||
|
{{ systemStatus.flashsize }} {{ $t('hardwareinfo.Bytes') }}
|
||||||
|
({{ systemStatus.flashsize / 1024 / 1024 }} {{ $t('hardwareinfo.MegaBytes') }})
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -202,7 +202,10 @@
|
|||||||
"ChipRevision": "Chip-Revision",
|
"ChipRevision": "Chip-Revision",
|
||||||
"ChipCores": "Chip-Kerne",
|
"ChipCores": "Chip-Kerne",
|
||||||
"CpuFrequency": "CPU-Frequenz",
|
"CpuFrequency": "CPU-Frequenz",
|
||||||
"Mhz": "MHz"
|
"Mhz": "MHz",
|
||||||
|
"FlashSize": "Flash-Speichergröße",
|
||||||
|
"Bytes": "Bytes",
|
||||||
|
"MegaBytes": "MB"
|
||||||
},
|
},
|
||||||
"memoryinfo": {
|
"memoryinfo": {
|
||||||
"MemoryInformation": "Speicherinformationen",
|
"MemoryInformation": "Speicherinformationen",
|
||||||
|
|||||||
@ -202,7 +202,10 @@
|
|||||||
"ChipRevision": "Chip Revision",
|
"ChipRevision": "Chip Revision",
|
||||||
"ChipCores": "Chip Cores",
|
"ChipCores": "Chip Cores",
|
||||||
"CpuFrequency": "CPU Frequency",
|
"CpuFrequency": "CPU Frequency",
|
||||||
"Mhz": "MHz"
|
"Mhz": "MHz",
|
||||||
|
"FlashSize": "Flash Memory Size",
|
||||||
|
"Bytes": "Bytes",
|
||||||
|
"MegaBytes": "MB"
|
||||||
},
|
},
|
||||||
"memoryinfo": {
|
"memoryinfo": {
|
||||||
"MemoryInformation": "Memory Information",
|
"MemoryInformation": "Memory Information",
|
||||||
|
|||||||
@ -202,7 +202,10 @@
|
|||||||
"ChipRevision": "Révision de la puce",
|
"ChipRevision": "Révision de la puce",
|
||||||
"ChipCores": "Nombre de cœurs",
|
"ChipCores": "Nombre de cœurs",
|
||||||
"CpuFrequency": "Fréquence du CPU",
|
"CpuFrequency": "Fréquence du CPU",
|
||||||
"Mhz": "MHz"
|
"Mhz": "MHz",
|
||||||
|
"FlashSize": "Taille de la mémoire flash",
|
||||||
|
"Bytes": "octets",
|
||||||
|
"MegaBytes": "Mo"
|
||||||
},
|
},
|
||||||
"memoryinfo": {
|
"memoryinfo": {
|
||||||
"MemoryInformation": "Informations sur la mémoire",
|
"MemoryInformation": "Informations sur la mémoire",
|
||||||
|
|||||||
@ -4,6 +4,7 @@ export interface SystemStatus {
|
|||||||
chiprevision: number;
|
chiprevision: number;
|
||||||
chipcores: number;
|
chipcores: number;
|
||||||
cpufreq: number;
|
cpufreq: number;
|
||||||
|
flashsize: number;
|
||||||
// FirmwareInfo
|
// FirmwareInfo
|
||||||
hostname: string;
|
hostname: string;
|
||||||
sdkversion: string;
|
sdkversion: string;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user