Skip to content

Commit

Permalink
Merge pull request #13 from pimoroni/defer-setup
Browse files Browse the repository at this point in the history
Defer setup to avoid module import-time side-effects
  • Loading branch information
Gadgetoid committed Feb 13, 2018
2 parents 5e32c9f + 3dee415 commit 4be639a
Show file tree
Hide file tree
Showing 2 changed files with 219 additions and 110 deletions.
21 changes: 21 additions & 0 deletions examples/lights.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env python

import time
import signal

import automationhat

automationhat.enable_auto_lights(False)

automationhat.light.on()

for analog in automationhat.analog:
analog.light.on()

for output in automationhat.output:
output.light.on()

for input in automationhat.input:
input.light.on()

signal.pause()

0 comments on commit 4be639a

Please sign in to comment.