diff --git a/WiFiManager.cpp b/WiFiManager.cpp index 0a4af8a..a81be36 100644 --- a/WiFiManager.cpp +++ b/WiFiManager.cpp @@ -2007,6 +2007,7 @@ void WiFiManager::handleInfo() { F("memsmeter"), F("lastreset"), F("temp"), + // F("hall"), F("wifihead"), F("conx"), F("stassid"), @@ -2249,8 +2250,10 @@ String WiFiManager::getInfoData(String id){ p = FPSTR(HTTP_INFO_temp); p.replace(FPSTR(T_1),(String)temperatureRead()); p.replace(FPSTR(T_2),(String)((temperatureRead()+32)*1.8)); - // p.replace(FPSTR(T_3),(String)hallRead()); - // p.replace(FPSTR(T_3),"NA"); // removed hall sensor as reads can cause issues with adcs + } + else if(id==F("hall")){ + p = FPSTR(HTTP_INFO_hall); + p.replace(FPSTR(T_1),(String)hallRead()); // hall sensor reads can cause issues with adcs } #endif else if(id==F("aboutver")){ diff --git a/WiFiManager.h b/WiFiManager.h index 641b989..36fe039 100644 --- a/WiFiManager.h +++ b/WiFiManager.h @@ -163,19 +163,26 @@ // #pragma message "ESP_ARDUINO_VERSION_MAJOR = " WM_STRING(ESP_ARDUINO_VERSION_MAJOR) // #pragma message "ESP_ARDUINO_VERSION_MINOR = " WM_STRING(ESP_ARDUINO_VERSION_MINOR) // #pragma message "ESP_ARDUINO_VERSION_PATCH = " WM_STRING(ESP_ARDUINO_VERSION_PATCH) + #ifdef ESP_ARDUINO_VERSION_MAJOR #define VER_ARDUINO_STR WM_STRING(ESP_ARDUINO_VERSION_MAJOR) "." WM_STRING(ESP_ARDUINO_VERSION_MINOR) "." WM_STRING(ESP_ARDUINO_VERSION_PATCH) + #else + #define VER_ARDUINO_STR "Unknown" + #endif #else #include // #pragma message "ESP_ARDUINO_VERSION_GIT = " WM_STRING(ARDUINO_ESP32_GIT_VER)// 0x46d5afb1 // #pragma message "ESP_ARDUINO_VERSION_DESC = " WM_STRING(ARDUINO_ESP32_GIT_DESC) // 1.0.6 // #pragma message "ESP_ARDUINO_VERSION_REL = " WM_STRING(ARDUINO_ESP32_RELEASE) //"1_0_6" + #ifdef ESP_ARDUINO_VERSION_MAJOR #define VER_ARDUINO_STR WM_STRING(ESP_ARDUINO_VERSION_MAJOR) "." WM_STRING(ESP_ARDUINO_VERSION_MINOR) "." WM_STRING(ESP_ARDUINO_VERSION_PATCH) + #else + #define VER_ARDUINO_STR "Unknown" + #endif #endif #else #define VER_ARDUINO_STR "Unknown" #endif - // #pragma message "VER_IDF_STR = " WM_STRING(VER_IDF_STR) // #pragma message "VER_ARDUINO_STR = " WM_STRING(VER_ARDUINO_STR) diff --git a/wm_strings_en.h b/wm_strings_en.h index 2c014bf..73ba6c1 100644 --- a/wm_strings_en.h +++ b/wm_strings_en.h @@ -181,7 +181,8 @@ const char HTTP_JS[] PROGMEM = const char HTTP_INFO_lastreset[] PROGMEM = "
Last reset reason
CPU0: {1}
CPU1: {2}
"; const char HTTP_INFO_aphost[] PROGMEM = "
Access point hostname
{1}
"; const char HTTP_INFO_psrsize[] PROGMEM = "
PSRAM Size
{1} bytes
"; - const char HTTP_INFO_temp[] PROGMEM = "
Temperature
{1} C° / {2} F°
Hall
{3}
"; + const char HTTP_INFO_temp[] PROGMEM = "
Temperature
{1} C° / {2} F°
"; + const char HTTP_INFO_hall[] PROGMEM = "
Hall
{1}
"; #else const char HTTP_INFO_esphead[] PROGMEM = "

esp8266


"; const char HTTP_INFO_fchipid[] PROGMEM = "
Flash chip ID
{1}
";