[][src]Enum ds::JoystickValue

pub enum JoystickValue {
    Axis {
        id: u8,
        value: f32,
    },
    Button {
        id: u8,
        pressed: bool,
    },
    POV {
        id: u8,
        angle: i16,
    },
}

Enum representing a value from a Joystick to be transmitted to the roboRIO

Variants

Axis

Represents an axis value to be sent to the roboRIO

value should range from -1.0..=1.0, or 0.0..=1.0 if the axis is a trigger

Fields of Axis

id: u8value: f32
Button

Represents a button value to be sent to the roboRIO

Fields of Button

id: u8pressed: bool
POV

Represents a POV, or D-pad value to be sent to the roboRIO

Fields of POV

id: u8angle: i16

Trait Implementations

impl Debug for JoystickValue[src]

Auto Trait Implementations

Blanket Implementations

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

impl<T> From for T[src]

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

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

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

The type returned in the event of a conversion error.

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