[][src]Struct rs_ws281x::ChannelBuilder

pub struct ChannelBuilder(pub ws2811_channel_t);

A struct used to build a channel configuration for a ControllerBuilder.

Implementations

impl ChannelBuilder[src]

pub fn new() -> Self[src]

Creates a new ChannelBuilder

pub fn pin(&mut self, value: i32) -> &mut Self[src]

Sets the GPIO pin used by this channel

pub fn count(&mut self, value: i32) -> &mut Self[src]

Sets the number of LEDs attached to this channel

pub fn strip_type(&mut self, value: StripType) -> &mut Self[src]

Sets the strip type of this channel

pub fn invert(&mut self, value: bool) -> &mut Self[src]

Sets the invert flag on the channel

pub fn brightness(&mut self, value: u8) -> &mut Self[src]

Sets the brightness of this channel

pub fn wshift(&mut self, value: u8) -> &mut Self[src]

Sets the white shift of this channel

pub fn rshift(&mut self, value: u8) -> &mut Self[src]

Sets the red shift of this channel

pub fn gshift(&mut self, value: u8) -> &mut Self[src]

Sets the green shift of this channel

pub fn bshift(&mut self, value: u8) -> &mut Self[src]

Sets the blue shift of this channel

pub fn build(&mut self) -> ws2811_channel_t[src]

Return the built channel.

Trait Implementations

impl Debug for ChannelBuilder[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.