from machine import Pin
from neopixel import NeoPixel
from easybutton import EasyButton
import time
btn = EasyButton(Pin(4, Pin.IN, Pin.PULL_UP))
strip = NeoPixel(Pin(2), 8)
def enable_light():
strip.fill((180, 100, 40))
strip.write()
def disable_light():
strip.fill((0, 0, 0))
strip.write()
btn.down_func = enable_light
btn.up_func = disable_light
print("OK")
while True:
time.sleep(0.05)VCC
BTN_PIN
NEOPIXEL_PIN
GND