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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
switch = DigitalInOut(board.D3) | |
switch.direction = Direction.INPUT | |
switch.pull = Pull.UP | |
pixel_pin = board.D2 |
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 board | |
import neopixel | |
pixel_pin = board.D2 #the ring data is connected to this pin | |
num_pixels = 16 #number of leds pixels on the ring | |
pixels = neopixel.NeoPixel(pixel_pin, num_pixels, brightness=0.3, auto_write=False) | |
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 board | |
import neopixel | |
import time | |
pixel_pin = board.D2 #the ring data is connected to this pin | |
num_pixels = 16 #number of leds pixels on the ring | |
pixels = neopixel.NeoPixel(pixel_pin, num_pixels, brightness=0.3, auto_write=False) | |
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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
import touchio | |
touch_pad = board.A0 # the ~1 pin | |
high_threshold = 4059 | |
low_threshold = 3500 |
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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
import touchio | |
touch_pad = board.A0 # the ~1 pin | |
high_threshold = 4059 | |
low_threshold = 3500 |
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 board | |
import touchio | |
import digitalio | |
touch_pad = board.A0 | |
high_threshold = 4059 | |
low_threshold = 2500 | |
touch = touchio.TouchIn(touch_pad) |
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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
import touchio | |
touch_pad = board.A0 # the ~1 pin | |
high_threshold = 4059 | |
low_threshold = 2500 |
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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
pixel_pin = board.D2 | |
num_pixels = 12 | |
switch = DigitalInOut(board.D3) | |
switch.direction = Direction.INPUT |
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 board | |
import neopixel | |
from digitalio import DigitalInOut, Direction, Pull | |
import touchio | |
touch_pad = board.A0 # the ~1 pin | |
high_threshold = 4059 | |
low_threshold = 3400 |
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
# Write your code here :-) | |
import time | |
import board | |
import neopixel | |
pixel_pin = board.D2 | |
num_pixels = 12 | |
pixels = neopixel.NeoPixel(pixel_pin, num_pixels, brightness=0.7, auto_write=False) |