added Function to WebUI to measure Pulses
This commit is contained in:
@@ -260,6 +260,12 @@ String processor(const String &var)
|
||||
if (var == "GIT_REV")
|
||||
return String(constants.GitHash);
|
||||
|
||||
if (var == "MEASURED_PULSES")
|
||||
return String(globals.measuredPulses);
|
||||
|
||||
if (var == "MEASURE_BTN")
|
||||
return String(globals.measurementActive == true ? "Stop" : "Start");
|
||||
|
||||
if (var == "PLACEHOLDER")
|
||||
return "placeholder";
|
||||
|
||||
@@ -396,6 +402,12 @@ void WebserverPOST_Callback(AsyncWebServerRequest *request)
|
||||
globals.requestEEAction = EE_CFG_SAVE;
|
||||
}
|
||||
// end: POST Form LED SEttings
|
||||
// begin: POST Form Measure Pulses
|
||||
if (p->name() == "measurereset")
|
||||
globals.measuredPulses = 0;
|
||||
if (p->name() == "measurestartstop")
|
||||
globals.measurementActive = !globals.measurementActive;
|
||||
// end: POST Form Measure Pulses
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user