From 3806945d7400cce065f6866d46f6f067acb219f2 Mon Sep 17 00:00:00 2001 From: Merlin Raschtuttis Date: Sun, 11 Feb 2018 22:14:05 +0000 Subject: [PATCH] =?UTF-8?q?L=C3=A4uft=20wider?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nohup.out | 329 +++++++++++++++++++++++++++++++++++++++++++++++++ power_mqtt1.py | 32 ++--- 2 files changed, 346 insertions(+), 15 deletions(-) create mode 100644 nohup.out diff --git a/nohup.out b/nohup.out new file mode 100644 index 0000000..43fa8f3 --- /dev/null +++ b/nohup.out @@ -0,0 +1,329 @@ +Connected +Subscribed OK +Received on topic: foobar/oben/licht Message: b'2' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'7' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'99' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'1' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'' +No valid value +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' +Received on topic: foobar/oben/licht Message: b'8' \ No newline at end of file diff --git a/power_mqtt1.py b/power_mqtt1.py index 1bb3f04..e2008af 100755 --- a/power_mqtt1.py +++ b/power_mqtt1.py @@ -85,7 +85,7 @@ def switch(i,speed=0.5): time.sleep(speed) off(i) -commands = { "flur" : 0, "baellebad" : 1, "lounge-front": 2, "lounge-back" : 3,"baellebad-ein" : 4, "lounge-ein" : 5, "cantina-ein" : 6, "zentral-aus" : 7, "flur-strobo": 9, "cantina" : 8} +commands = { "flur" : 0, "baellebad" : 1, "lounge-front": 2, "lounge-back" : 3,"baellebad-ein" : 4, "lounge-ein" : 5, "cantina-ein" : 6, "zentral-aus" : 7, "flur-strobo": 100, "cantina" : 8, "cantina-strobo": 99} def msgs(inp): c = inp.decode("utf-8") @@ -97,16 +97,16 @@ def msgs(inp): except ValueError: print ( "No valid value") return - if (msg == 9): - for i in range(1000): - switch(0, speed=0.05) - time.sleep(0.06) - elif (msg == 99): - for i in range(50): - switch(8, speed=0.05) - time.sleep(0.06) - else: - switch(msg) + #if (msg == 9): + # for i in range(1000): + # switch(0, speed=0.05) + # time.sleep(0.06) + #elif (msg == 99): + # for i in range(50): + # switch(8, speed=0.05) + # time.sleep(0.06) + #else: + switch(msg) else: cmds = c.split(",") @@ -121,10 +121,12 @@ def msgs(inp): except ValueError: return switch(command,speed = 3*arg/100+0.7 ) - if ( command == 9 ): - for i in range(arg): - switch(0, speed=0.05) - time.sleep(0.06) + if ( command == 100 or command == 99 ): + if arg < 100: + for i in range(arg): + switch((100-command)*8, speed=0.05) + time.sleep(0.06) + else: try: