From aa71e1bb4837f7e24ae83e0b94b52c155ba3ba60 Mon Sep 17 00:00:00 2001 From: Guillaume Dott Date: Tue, 14 Nov 2017 00:28:12 +0100 Subject: [PATCH] Add poweroff command --- photoboite.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/photoboite.py b/photoboite.py index 48d96b5..0c8a4f7 100755 --- a/photoboite.py +++ b/photoboite.py @@ -155,7 +155,7 @@ class PowerButton(Button): self.timestamp = time.time() if self.count >= 5: - print('POWEROFF') + os.system('sudo poweroff') class CaptureButton(Button): countdown = 3