π’ TurtlPass Firmware v3.1.0 β Universal LED Framework & 130-Board Support
π Overview
TurtlPass v3.1.0 delivers a major upgrade to the embedded LED system with a fully modular driver architecture and broad hardware compatibility.
This release unifies LED control across all supported RP2040 and RP2350 boards β from the Pico family to custom carrier designs β while maintaining smooth animations, low power usage, and easy extensibility.
β¨ New in v3.1.0
π§© Complete LED Driver Suite
TurtlPass now includes five fully implemented and interchangeable LED drivers:
| Driver | Purpose |
|---|---|
AnalogLedDriver |
Basic single-pin brightness control |
Cyw43LedDriver |
Onboard Wi-Fi status LED |
Rgb3PinLedDriver |
Standard 3-pin RGB LED via PWM |
FastLedDriver |
Addressable LED strip (WS2812/NeoPixel) |
NullLedDriver |
No-op driver for headless / non-LED devices |
Each driver conforms to the unified ILedDriver interface, ensuring drop-in replacement and consistent behavior across hardware variants.
π‘ Universal LED Manager
-
Centralized control via the updated
LedManagerclass. -
Unified color table shared by all drivers β nine vivid presets (
Green,Yellow,Red,Blue,White,Violet,Orange,Aqua,Pink). -
Intelligent brightness mapping for smoother fades and realistic pulsing.
-
Modular state machine supporting:
LED_ONLED_OFFLED_BLINKINGLED_PULSINGLED_FADE_OUT_ONCELED_FADE_OUT_LOOP
βοΈ Architecture & Refactor Highlights
- Separation of Concerns:
LedManagerhandles logic; each driver handles hardware. - Removed Duplication:
Color constants now exist only inLedManager. - Refactored Brightness Handling:
Exponential mapping and unified PWM scaling yield smoother transitions. - Simplified Integration:
Drivers auto-register via the shared interface for easy runtime selection.
π§ RP2040 / RP2350 Board Support
Full validation and LED compatibility for 130 boards, including:
- Raspberry Pi Pico, Pico W, Pico 2, Pico 2 W
- Adafruit Feather RP2040 / ItsyBitsy / QT Py
- Seeed XIAO RP2040 / W
- SparkFun Thing Plus RP2040
- Waveshare RP2040 series
- Pimoroni PicoSystem / Tiny2040 / Galactic Unicorn / Plasma2040
- Custom boards built on the RP2350 MCU
- and many more community variants
Boards are now auto-detected, selecting the correct LED driver at runtime.
π§° Developer Notes
-
New API Contract:
All drivers must implement:void begin(); void setColor(uint8_t r, uint8_t g, uint8_t b); void setBrightness(uint8_t brightness); void show();
-
Optional Interface Extension:
Drivers may optionally provide board-specific setup (e.g., Wi-Fi LED binding forCyw43LedDriver). -
Native Testing:
- Native unit tests validate all LED states without hardware, ensuring correct timing, color, and brightness behavior.
- Contract testing verifies full compliance of all
ILedDriverimplementations.