Crate smart_leds
source ·Expand description
Smart Leds
Smart leds is a collection of crates to use smart leds on embedded devices with rust.
Examples of smart leds include the popular WS2812 (also called Neopixel), APA102 (DotStar) and other leds, which can be individually adressed.
Other driver crates implement these indivdual interfaces and should be used in tandem with this crate. This crate provides various convenience utilities for end users.
Other crates should depended on the smart-leds-trait crate, which (should) experience less breaking changes
Modules
Structs
- An iterator that provides brightness reduction
- An iterator that provides gamma correction. Makes the colour distribution non-linear, to match your eyes’ perception In other words, makes orange look orange. If using in combination with a brightness reduction, apply the gamma correction first, then the brightness reduction ie: brightness(gamma(data.iter().cloned()), 32)
- The RGB pixel
- The RGBA pixel
Traits
- A trait that smart led drivers implement
Functions
- Pass your iterator into this function to get reduced brightness
- Pass your iterator into this function to get corrected gamma
Type Aliases
- 8-bit RGB
- 16-bit RGB in machine’s native endian
- The RGBW Pixel