Lark’s Forge

Design • Build • Create

← Electronics Lab Adafruit KB2040

3D Printed LED Panel Light

Soft, diffused white light from a single GRBW NeoPixel and an Adafruit KB2040.

KB2040NeoPixel GRBWCircuitPythonLighting
3D Printed LED Panel Light
Downloads

Code

Printable parts

STL files coming soon.

Docs

Overview

A compact panel light: one GRBW NeoPixel, driven by an Adafruit KB2040 running CircuitPython, sits in a 3D printed housing behind a diffuser. Using the NeoPixel's dedicated white channel gives a clean, pure white glow - great for desk accent lighting or lighting a piece of art.

  • Single GRBW NeoPixel - bright, pure white from the W channel
  • Designed to fit a 3D printed panel housing
  • Colour and brightness are one line each to change

Parts

  • Adafruit KB2040 — RP2040 microcontroller
  • NeoPixel GRBW LED (1 pixel)
  • 3D printed panel housing
  • Diffuser panel or frosted acrylic cover — optional

Wiring

NeoPixel to KB2040

FromToNotes
KB2040 D5NeoPixel Data Incontrol signal
KB2040 3VNeoPixel VCCpower
KB2040 GNDNeoPixel GNDground
  • Power the NeoPixel from 3V or 5V depending on your LED's specifications.

Directions

  1. Install CircuitPython on the KB2040.
  2. Copy neopixel.mpy from the Adafruit CircuitPython Library Bundle into CIRCUITPY/lib/.
  3. Copy code.py to the root of the CIRCUITPY drive.
  4. Wire the NeoPixel as shown in the table.
  5. Print the panel housing, fit the electronics and the diffuser, and plug in USB power.

Libraries

Copy these from the Adafruit CircuitPython Library Bundle into CIRCUITPY/lib/.

  • neopixel.mpy

Make it yours

  • BRIGHTNESS = 1.0 - overall brightness (0.0 to 1.0)
  • pixels[0] = (0, 0, 0, 255) - the colour as (R, G, B, W); this is pure white

Code

code.py Download

The copy here has a stray Markdown line (```python) removed from the top of the GitHub version so it runs as-is.

import board
import neopixel
import time

# Configuration
NUM_PIXELS = 1
PIXEL_PIN = board.D5
BRIGHTNESS = 1.0

pixels = neopixel.NeoPixel(
    PIXEL_PIN,
    NUM_PIXELS,
    brightness=BRIGHTNESS,
    auto_write=False,
    pixel_order=neopixel.GRBW
)

# Turn off any previous color
pixels.fill((0, 0, 0, 0))

# Set light to pure white using the W channel
pixels[0] = (0, 0, 0, 255)

pixels.show()

Credits & licence

Released under the MIT License — Copyright (c) 2025 Lark216. Free to use, modify and share.