We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 94931fe commit ca6ac5fCopy full SHA for ca6ac5f
boot.py
@@ -314,17 +314,18 @@ def pause():
314
case 1:
315
command = 2
316
def middle():
317
- global command, start
+ global start
318
start = time.time()
319
- command = -1
320
321
def shutdown():
322
- global start
+ global start, command
323
end = time.time()
324
if(end-start>2):
325
lcd.clear()
326
lcd.message="Goodbye"
327
check_call(['sudo', 'poweroff'])
+ else:
328
+ command = -1
329
330
Button_up.when_pressed = pause
331
Button_left.when_pressed = back
0 commit comments