wc: wiatrak sterowany przez HTTP

Ma wgrany firmware, w ktorym akurat nie dziala MQTT.
Dotychczas sterowałem przez curla w cronie, ale przeciez
openhab ma bindingi http.
This commit is contained in:
2020-11-26 07:10:58 +01:00
parent 6faa34220e
commit db500eefa1
2 changed files with 10 additions and 8 deletions

View File

@@ -26,25 +26,26 @@ end
rule "Wyłączaj wiatrak na noc"
when
Time cron "0 0 22 * * ?"
Time cron "0 58 21 * * ?"
then
/* logInfo("Vacancy", "state {}", sHolidayVacancy.state)
logInfo("Vacancy", "state {}", sHolidayVacancy.state)
if (sHolidayVacancy.state == ON) {
return;
}
*/
sSONOFF07.sendCommand(OFF)
end
rule "Włączaj wiatrak rano "
when
Time cron "0 30 6 * * ?"
Time cron "0 30 6 ? * MON-FRI" or
Time cron "0 30 9 ? * SAT-SUN"
then
/* logInfo("Vacancy", "state {}", sHolidayVacancy.state)
logInfo("Vacancy", "state {}", sHolidayVacancy.state)
if (sHolidayVacancy.state == ON) {
return;
}
*/
sSONOFF07.sendCommand(ON)
end