From a3b81ec5089fbd974fff0f711c093c2033b1615a Mon Sep 17 00:00:00 2001 From: realraum Date: Mon, 11 May 2009 18:04:54 +0000 Subject: [PATCH] firmware: reset with manual keys door_daemon: updated status side --- door_daemon.py | 4 ++-- firmware/tuer.pde | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/door_daemon.py b/door_daemon.py index 7453238..60d0cb2 100755 --- a/door_daemon.py +++ b/door_daemon.py @@ -14,8 +14,8 @@ logging.basicConfig(level=logging.INFO,filename='/var/log/tuer.log',format="%(as class StatusDisplay(): def __init__(self): - self.url_open = 'https://www.realraum.at/cgi/status.cgi?pass=jako16&set=%3Chtml%3E%3Cbody%20bgcolor=%22lime%22%3E%3Ch3%3E%3Ccenter%3ETuer%20ist%20Offen%3C/center%3E%3C/h3%3E%3C/body%3E%3C/html%3E'; - self.url_closed = 'https://www.realraum.at/cgi/status.cgi?pass=jako16&set=%3Chtml%3E%3Cbody%20bgcolor=%22red%22%3E%3Ch3%3E%3Ccenter%3ETuer%20ist%20Geschlossen%3C/center%3E%3C/h3%3E%3C/body%3E%3C/html%3E'; + self.url_open = 'https://www.realraum.at/cgi/status.cgi?pass=jako16&set=%3Chtml%3E%3Cbody%20bgcolor=%22lime%22%3E%3Ccenter%3E%3Cb%3ET%26uuml%3Br%20ist%20Offen%3C/b%3E%3C/center%3E%3C/body%3E%3C/html%3E' + self.url_closed = 'https://www.realraum.at/cgi/status.cgi?pass=jako16&set=%3Chtml%3E%3Cbody%20bgcolor=%22red%22%3E%3Cb%3E%3Ccenter%3ET%26uuml%3Br%20ist%20Geschlossen%3C/center%3E%3C/b%3E%3C/body%3E%3C/html%3E' self.last_status_set="" #object.__init__(self) diff --git a/firmware/tuer.pde b/firmware/tuer.pde index d2c7a09..6c966a2 100644 --- a/firmware/tuer.pde +++ b/firmware/tuer.pde @@ -571,11 +571,11 @@ void loop() else Serial.println("Error: unknown command"); } - if(manual_open() && !is_opened() && current_state == IDLE) { + if(manual_open() && !is_opened() && (current_state == IDLE || current_state == ERROR)) { Serial.println("open forced manually"); start_open(); } - if(manual_close() && !is_closed() && current_state == IDLE) { + if(manual_close() && !is_closed() && (current_state == IDLE || current_state == ERROR)) { Serial.println("close forced manually"); start_close(); } -- 1.7.10.4