Added neopixel rainbow example

This commit is contained in:
David Thurstenson 2022-10-09 22:30:46 -05:00
parent 58e5c94d8a
commit 7097136a57
1 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
import time
import board
import digitalio
import neopixel
from adafruit_led_animation.animation.rainbow import Rainbow
pixel_pin = board.GP28
num_pixels = 1
brightness = 0.2
pixels = neopixel.NeoPixel(pixel_pin, num_pixels, brightness=brightness, auto_write=False)
rainbow = Rainbow(pixels, 0.01, period=10)
while True:
rainbow.animate()