added keyboardinterrupt publish

Signed-off-by: Ebbe Baß <ebbe@ping-mee.de>
master
Ebbe Baß 2022-07-02 00:51:29 +02:00
parent ca90f36f07
commit 60e942431c
1 changed files with 1 additions and 0 deletions

View File

@ -223,6 +223,7 @@ if __name__ == '__main__':
time.sleep(1) time.sleep(1)
except KeyboardInterrupt: except KeyboardInterrupt:
client.publish("server-rack-led/power", "False")
client.loop_stop() client.loop_stop()
setColor(strip, Color(0,0,0)) setColor(strip, Color(0,0,0))
GPIO.cleanup() GPIO.cleanup()