Last active
January 15, 2016 00:59
-
-
Save logsol/9f99edbfcdc707e4ea1c to your computer and use it in GitHub Desktop.
nextthing.co C.H.I.P blink script for the internal LED to see when it has booted
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import os | |
try: | |
toggle = False | |
while True: | |
if toggle: | |
os.system('sudo i2cset -f -y 0 0x34 0x93 0x1') | |
time.sleep(0.1) | |
else: | |
os.system('sudo i2cset -f -y 0 0x34 0x93 0x0') | |
time.sleep(10) | |
toggle = not toggle | |
except KeyboardInterrupt: | |
exit() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment