mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 07:49:52 +03:00
add is_system to analog sensor so internal sensors cannot be removed
This commit is contained in:
@@ -143,6 +143,7 @@ void WebDataService::sensor_data(AsyncWebServerRequest * request) {
|
||||
obj["o"] = sensor.offset();
|
||||
obj["f"] = sensor.factor();
|
||||
obj["t"] = sensor.type();
|
||||
obj["s"] = sensor.is_system();
|
||||
|
||||
if (sensor.type() != AnalogSensor::AnalogType::NOTUSED) {
|
||||
obj["v"] = Helpers::transformNumFloat(sensor.value()); // is optional and is a float
|
||||
|
||||
Reference in New Issue
Block a user