This commit is contained in:
Kattni Rembor 2018-08-03 14:43:30 -04:00
parent 85d7628b53
commit 2a4e814575
2 changed files with 4 additions and 1 deletions

View file

@ -23,6 +23,7 @@ deploy:
install:
- pip install pylint circuitpython-build-tools Sphinx sphinx-rtd-theme
- pip install --force-reinstall pylint==1.9.2
script:
- pylint adafruit_circuitplayground/*.py

View file

@ -3,10 +3,10 @@
import time
from adafruit_circuitplayground.express import cpx
# The number of pixels in the strip
numpix = 10
def wheel(pos):
# Input a value 0 to 255 to get a color value.
# The colours are a transition r - g - b - back to r.
@ -20,6 +20,7 @@ def wheel(pos):
pos -= 170
return (0, int(pos*3), int(255 - pos*3))
def rainbow_cycle(wait):
for j in range(255):
for i in range(cpx.pixels.n):
@ -28,6 +29,7 @@ def rainbow_cycle(wait):
cpx.pixels.show()
time.sleep(wait)
cpx.pixels.auto_write = False
cpx.pixels.brightness = 0.3
while True: