Raspberry Pi Pico practice problem · Raspberry Pi Pico
Colour the stick
MediumBudget $14MicroPython
A WS2812B stick with 8 LEDs has its data input on GP18, powered from 5 V (VBUS). Use the frozen neopixel module to set every pixel to red (255, 0, 0).
import neopixel
from machine import Pin
strip = neopixel.NeoPixel(Pin(18), 8)
The stick's data line is 3.3 V on a short wire, which the WS2812B accepts. Power the LEDs from 5 V, not from 3V3.