switch all leds off when exiting
This commit is contained in:
parent
47d3bebbb5
commit
93d2aa427e
@ -1,4 +1,4 @@
|
|||||||
#!/usr/bin/python
|
#!/usr/bin/env python
|
||||||
|
|
||||||
import glob
|
import glob
|
||||||
import os
|
import os
|
||||||
@ -98,5 +98,8 @@ if __name__ == '__main__':
|
|||||||
try:
|
try:
|
||||||
while True:
|
while True:
|
||||||
GPIO.wait_for_edge(dummyPin, GPIO.RISING)
|
GPIO.wait_for_edge(dummyPin, GPIO.RISING)
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
print 'exiting'
|
||||||
finally:
|
finally:
|
||||||
|
setLeds(0, 0, 0)
|
||||||
GPIO.cleanup()
|
GPIO.cleanup()
|
||||||
|
Reference in New Issue
Block a user