Created: 05.05.2023 06:22 Last Modified: 05.05.2023 06:22
Views: 1333
Keywords: Linux, NeoPixels, Python, Raspberry Pi OS, Raspbian, Raspberry Pi
How to Use Addressable RGB LED NeoPixels on Raspberry Pi Computer
This step by step tutorial demonstrates how to use Addressable RGB LED NeoPixels (WS2812B, WS2811, SK6812, etc) on a Raspberry Pi single board computer with Raspberry Pi OS Linux distribution and Python 3 script based on Adafruit CircuitPython libraries.
The following hardware has used for the demonstration:
Raspberry Pi with 40 pin header (Raspberry Pi 4, Raspberry Pi 3, Raspberry Pi Zero, etc.)
Alternatively, you can use a breadboard with level shifter, power jack and in-line resistor between 220Ω and 470Ω on the data line for protection. Also instead of Olimex LED-ROPE-10 you can use a strip or a printed circuit board with other NeoPixel types like WS2812B, WS2812, WS2811, SK6812, etc.
Follow the steps below to setup and configure the software. Please note that sound must be disabled on Raspberry Pi OS to use PWM on GPIO18. Edit /boot/config.txt and change "dtparam=audio=on" to "dtparam=audio=off". After that reboot Raspberry Pi.