changed pwm setters and httpserver call

This commit is contained in:
2021-07-19 11:29:51 +02:00
parent 42a927e383
commit ad21d73fbb
3 changed files with 190 additions and 207 deletions
+12 -2
View File
@@ -42,9 +42,19 @@ void HTTPServer::start_apps() {
if (args()) {
for (int i = 0; i < args() - 1; i++) {
Serial.printf("%s=%s\n", argName(i).c_str(), arg(i).c_str());
if (argName(i).equals("range_idl_pwm")) {
treppe->set_idle_prozent(arg(i).toInt());
if (argName(i).equals("range_act_pwm")) {
treppe->set_active_pwm(arg(i).toInt(), VORGABE_PROZENT);
}
else if (argName(i).equals("range_idl_pwm")) {
treppe->set_idle_pwm_max(arg(i).toInt(), VORGABE_PROZENT);
}
else if (argName(i).equals("range_tim_sta")) {
}
else if (argName(i).equals("range_tim_on")) {
}
}
}
send(200, "text/plain", "accepted");