FastLED 3.9.15
Loading...
Searching...
No Matches
examples Directory Reference
+ Directory dependency graph for examples:

Directories

 AnalogOutput
 
 Animartrix
 
 AnimartrixRing
 
 Apa102
 
 Apa102HD
 
 Asio
 
 Async
 
 Audio
 
 AudioFftParity
 
 AudioInput
 
 AudioReactive
 
 AudioUrl
 
 AutoResearch
 
 BeatDetection
 
 Blink
 
 BlinkParallel
 
 Blur
 
 Blur2d
 
 BlurBenchmark
 
 Chromancer
 
 Codec
 
 ColorBoost
 
 ColorPalette
 
 ColorTemperature
 
 CompileTest
 
 Corkscrew
 
 Cylon
 
 DemoReel100
 
 Downscale
 
 EaseInOut
 
 ElPanelReactive
 
 Esp8266Uart
 
 FestivalStick
 
 Fire2012
 
 Fire2012WithPalette
 
 Fire2023
 
 FireCylinder
 
 FireMatrix
 
 FirstLight
 
 FlowField
 
 Fx
 
 HD107
 
 HSVTest
 
 Json
 
 LuminescentGrand
 
 Luminova
 
 Multiple
 
 Noise
 
 NoisePlayground
 
 NoisePlusPalette
 
 OTA
 
 Overclock
 
 Pacifica
 
 ParallelSPI
 
 PerfDisc
 
 PinMode
 
 Pintest
 
 Ports
 
 Pride2015
 
 Remote
 
 RGBCalibrate
 
 RGBSetDemo
 
 RGBW
 
 RGBWEmulated
 
 RGBWW
 
 RX
 
 Sailboat
 
 SIMD
 
 SmartMatrix
 
 SpecialDrivers
 
 Spi
 
 Test
 
 TwinkleFox
 
 UITest
 
 wasm
 
 WasmScreenCoords
 
 Wave
 
 Wave2d
 
 WS2816
 
 XYMatrix
 
 XYPath
 

Detailed Description

This document maps the example sketches, shows how to run them on different targets (Arduino/PlatformIO, Teensy, ESP32, WASM), and suggests learning paths. It mirrors the structure and tone of src/fl/README.md so you can quickly jump between concepts and runnable code.

Table of Contents


Overview and Quick Start

The examples/ directory contains runnable sketches that cover:

Typical first steps:


How to Run Examples

Arduino IDE (classic workflow)

Tips:

PlatformIO (boards and native host)

Teensy/OctoWS2811

ESP32 Special Drivers (parallel output)

WASM (browser demos + JSON UI)


Directory Map (by theme)

This list highlights commonly used examples. It is not exhaustive—browse the folders for more.

Basics and core idioms

Color, palettes, and HSV

Classic 1D effects

2D, matrices, mapping

FX engine and higher-level utilities

Audio and reactive demos

Storage, SD card, and data

Multiple strips, parallel, and high-density

ESP/Teensy/SmartMatrix specifics

WASM and UI

Larger projects and showcases


🎯 Platform-Specific Filtering with @filter

FastLED now supports flexible @filter directives in .ino sketch files for conditional compilation based on platform, memory, target, and board properties. This enables you to maintain platform-specific examples without duplicating code.

Supported Filter Syntax

One-liner format (compact, flexible):

// @filter (memory is large) and (platform is esp32s3)
// @filter (memory is huge) and (platform is esp32)
// @filter (mem is large) and (plat is esp32*)
// @filter (mem: large) and (plat: esp32)
// @filter (mem=large) and (plat=esp32)

Multi-line YAML format (explicit):

// @filter
// - require:
// - platform: esp32s3
// - memory: large
// - exclude:
// - platform: avr
// @end-filter

Filter Features

Operators:

Property shortcuts:

Logical operators: and, or

Memory tiers (ordered: low < large < huge):

Examples:

// @filter (platform is esp32*)
// @filter (memory is huge)
// @filter (memory is not low)
// @filter (target is -D__AVR__) or (board is uno)

Quick Usage Notes


Choosing an Example


Troubleshooting


Guidance for New Users

Guidance for C++ Developers


This README will evolve alongside the examples. Browse subfolders for sketch-specific notes and hardware details. For the core library map and deeper subsystems, see src/README.md and src/fl/README.md.