pub struct LED_STRIP_CONFIG_DATA {
pub colors: [u32; 8],
pub target_system: u8,
pub target_component: u8,
pub mode: LedConfigMode,
pub index: u8,
pub length: u8,
pub id: u8,
}stemstudios only.Expand description
Set the colors on an LED strip. The mode field determines how the colors are set. We can: - Set all LEDs to the first color in our colors array. - Set up to 8 consecutive LEDs, starting from a given index, to colors provided in an array. - Set the LED colors to change according to the flight mode. - Turn all LEDs off (clear). Which LED strip to configure is specified by the id field. The colors field is an array of up to 8 colors, each represented as a 32-bit integer in the format 0xWWRRGGBB where WW is white, RR is the intensity of the red color channel, GG is green, and BB is blue.
ID: 52600
Fields§
§colors: [u32; 8]Array of 32-bit color values (0xWWRRGGBB).
target_system: u8System ID.
target_component: u8Component ID (Normally 134 for an LED Strip Controller).
mode: LedConfigModeHow to configure LEDs.
index: u8Set LEDs starting from this index.
length: u8The number of LEDs to set (up to 8).
id: u8Which strip to configure. UINT8_MAX for all strips.
Implementations§
Source§impl LED_STRIP_CONFIG_DATA
impl LED_STRIP_CONFIG_DATA
pub const ENCODED_LEN: usize = 38usize
pub const DEFAULT: Self
Trait Implementations§
Source§impl Clone for LED_STRIP_CONFIG_DATA
impl Clone for LED_STRIP_CONFIG_DATA
Source§fn clone(&self) -> LED_STRIP_CONFIG_DATA
fn clone(&self) -> LED_STRIP_CONFIG_DATA
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more