Registry / devops / fastled

fastled

JSON →
library2.0.6pypypi✓ verified 84d ago

A Python library that compiles Arduino sketches using the FastLED library to WebAssembly, enabling LED animations in the browser. Current version is 2.0.6, with a recent major version bump from 1.x to 2.x. Release cadence is irregular, with active development on GitHub.

pip install fastled
INSTALL
IMPORT
SIG · FASTLED
F
fastled
devopspythonv2.0.6
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

compile_wasm
import fastled
from fastled import compile_wasm

Compile a simple FastLED sketch to WebAssembly. The `target` parameter can be 'web' or 'cli'.

from fastled import compile_wasm sketch_code = ''' #include <FastLED.h> #define NUM_LEDS 60 #define DATA_PIN 2 CRGB leds[NUM_LEDS]; void setup() { FastLED.addLeds<WS2812, DATA_PIN, GRB>(leds, NUM_LEDS); } void loop() { fill_solid(leds, NUM_LEDS, CRGB::Red); FastLED.show(); delay(100); } ''' wasm_bytes = compile_wasm(sketch_code, target='web') print(f'Compiled WASM size: {len(wasm_bytes)} bytes')
fastled --version
Debug
Known issues
breakingMajor version 2.0.0 introduced breaking changes: the `compile_wasm` function replaces the old `FastLEDWasm` class-based API from v1.x. Old code using `from fastled.compiler import compile_wasm` will break.
fix
Update imports to `from fastled import compile_wasm` and adjust function calls accordingly.
affects: <2.0.0
gotchaThe `target` parameter must be explicitly specified when calling `compile_wasm`. Default is 'web', but omitting it may lead to unexpected output.
fix
Always pass `target='web'` or `target='cli'` to avoid ambiguity.
affects: >=2.0.0
gotchaCompilation requires a C++ compiler toolchain (e.g., Emscripten) to be installed. The library does not bundle these; missing tools lead to obscure errors.
fix
Install Emscripten SDK (emsdk) and ensure `emcc` is in PATH. See https://emscripten.org/docs/getting_started/downloads.html
affects: All
Upgrade
Version history
2.0.6latest on PyPI · released Apr 5, 2026
Audit
Dependencies

No dependency data recorded yet.

Agent activity
7 hits · last 30 days
node
6
Resources
fastled — pip install fastled · libregistry