2024-10-01 14:16:12 +08:00
|
|
|
#ifndef _SYSTEM_INFO_H_
|
|
|
|
|
#define _SYSTEM_INFO_H_
|
|
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
|
|
2024-10-03 06:39:22 +08:00
|
|
|
#include <esp_err.h>
|
|
|
|
|
#include <freertos/FreeRTOS.h>
|
2024-10-01 14:16:12 +08:00
|
|
|
|
|
|
|
|
class SystemInfo {
|
|
|
|
|
public:
|
|
|
|
|
static size_t GetFlashSize();
|
|
|
|
|
static size_t GetMinimumFreeHeapSize();
|
|
|
|
|
static size_t GetFreeHeapSize();
|
|
|
|
|
static std::string GetMacAddress();
|
|
|
|
|
static std::string GetChipModelName();
|
2025-09-16 05:00:02 +08:00
|
|
|
static std::string GetUserAgent();
|
2025-05-26 14:30:44 +08:00
|
|
|
static esp_err_t PrintTaskCpuUsage(TickType_t xTicksToWait);
|
|
|
|
|
static void PrintTaskList();
|
|
|
|
|
static void PrintHeapStats();
|
2024-10-01 14:16:12 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif // _SYSTEM_INFO_H_
|