Struct rainbow_hat_rs::lights::Lights[][src]

pub struct Lights {
    pub red: Light,
    pub green: Light,
    pub blue: Light,
}
Expand description

Set of lights on the board.

Fields

red: Light

Red light.

green: Light

Green light.

blue: Light

Blue light.

Implementations

Creates a the set of Lights.

Set the state for all the lights.

Arguments

  • state - State of the lights: true for on, false for Off.

Set the state for each light.

Arguments

  • r - State of the red light: true for on, false for Off.
  • g - State of the green light: true for on, false for Off.
  • b - State of the blue light: true for on, false for Off.

Enbles simulation mode.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.