This PR uses marker structs to set the color order. This should save one match statement as the Color order is determined at compile time (which can be assumed as the Led ordering should not change during runtime).
Usage now would be:
use ws2812_async::{Ws2812, Grb};
let mut ws: Ws2812<_, Grb, { 12 * 18 }> = Ws2812::new(spi);
The rest of the API stays the same (except that there's no set_color_order method anymore).
Note: the Cargo.toml still references my fork of the smart-leds-trait. Let's hope the async trait will be added in the next version, so that we can reference it properly.
This PR uses marker structs to set the color order. This should save one match statement as the Color order is determined at compile time (which can be assumed as the Led ordering should not change during runtime).
Usage now would be:
The rest of the API stays the same (except that there's no
set_color_order
method anymore).Furthermore I allowed myself to also implement the preliminary async smart-leds-trait from here: https://github.com/smart-leds-rs/smart-leds-trait/pull/13
Let me know what you think!
Note: the Cargo.toml still references my fork of the
smart-leds-trait
. Let's hope the async trait will be added in the next version, so that we can reference it properly.Closes #3