mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 00:09:51 +03:00
remove NTP status
This commit is contained in:
@@ -683,15 +683,7 @@ void System::heartbeat_json(JsonObject output) {
|
||||
|
||||
output["uptime"] = uuid::log::format_timestamp_ms(uuid::get_uptime_ms(), 3);
|
||||
output["uptime_sec"] = uuid::get_uptime_sec();
|
||||
bool value_b = ntp_connected();
|
||||
if (EMSESP::system_.bool_format() == BOOL_FORMAT_TRUEFALSE) {
|
||||
output["ntp_status"] = value_b;
|
||||
} else if (EMSESP::system_.bool_format() == BOOL_FORMAT_10) {
|
||||
output["ntp_status"] = value_b ? 1 : 0;
|
||||
} else {
|
||||
char s[12];
|
||||
output["ntp_status"] = Helpers::render_boolean(s, value_b);
|
||||
}
|
||||
|
||||
output["rxreceived"] = EMSESP::rxservice_.telegram_count();
|
||||
output["rxfails"] = EMSESP::rxservice_.telegram_error_count();
|
||||
output["txreads"] = EMSESP::txservice_.telegram_read_count();
|
||||
@@ -724,6 +716,7 @@ void System::heartbeat_json(JsonObject output) {
|
||||
int8_t rssi = WiFi.RSSI();
|
||||
output["rssi"] = rssi;
|
||||
output["wifistrength"] = wifi_quality(rssi);
|
||||
output["wificonnects"] = EMSESP::esp8266React.getWifiConnects();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@@ -1504,9 +1497,10 @@ bool System::command_info(const char * value, const int8_t id, JsonObject output
|
||||
// node["IPv6 address"] = uuid::printable_to_string(ETH.localIPv6());
|
||||
// }
|
||||
} else if (WiFi.status() == WL_CONNECTED) {
|
||||
node["network"] = "WiFi";
|
||||
node["hostname"] = WiFi.getHostname();
|
||||
node["RSSI"] = WiFi.RSSI();
|
||||
node["network"] = "WiFi";
|
||||
node["hostname"] = WiFi.getHostname();
|
||||
node["RSSI"] = WiFi.RSSI();
|
||||
node["WIFIConnects"] = EMSESP::esp8266React.getWifiConnects();
|
||||
// node["MAC"] = WiFi.macAddress();
|
||||
// node["IPv4 address"] = uuid::printable_to_string(WiFi.localIP()) + "/" + uuid::printable_to_string(WiFi.subnetMask());
|
||||
// node["IPv4 gateway"] = uuid::printable_to_string(WiFi.gatewayIP());
|
||||
@@ -1535,6 +1529,7 @@ bool System::command_info(const char * value, const int8_t id, JsonObject output
|
||||
node["CORSOrigin"] = settings.CORSOrigin;
|
||||
}
|
||||
});
|
||||
|
||||
#ifndef EMSESP_STANDALONE
|
||||
EMSESP::esp8266React.getAPSettingsService()->read([&](const APSettings & settings) {
|
||||
const char * pM[] = {"always", "disconnected", "never"};
|
||||
|
||||
Reference in New Issue
Block a user