[][src]Struct stmpe1600::Stmpe1600

pub struct Stmpe1600<I2C> { /* fields omitted */ }

A struct representing the STMPE1600 device driver.

Methods

impl<I2C, E> Stmpe1600<I2C> where
    I2C: Read<Error = E> + Write<Error = E>,
    E: Debug
[src]

pub fn get(&self, pin: u8) -> Result<bool, Error<E>>[src]

Gets the current state of the specified pin.

To get the state of all the pins at once, see get_all.

pub fn get_all<I>(&self) -> Result<[bool; 16], Error<E>>[src]

Gets the current state of the all pins.

To get the state a single pin, see get.

pub fn set(&self, pin: u8, value: bool) -> Result<(), Error<E>>[src]

Sets the current state of the specified pin.

To set the state of all the pins at once, see set_all.

pub fn set_all(&self, mask: u16) -> Result<(), Error<E>>[src]

Sets the current state of the all the pins.

To set the state a single pin, see set.

pub fn get_interrupts(&self) -> Result<[bool; 16], Error<E>>[src]

Gets the pending interrupts and returns them in an array.

This function clears any pending bits from the STMPE1600, and in doing so, stops triggering the interrupt output pin.

Trait Implementations

impl<I2C: Debug> Debug for Stmpe1600<I2C>[src]

Auto Trait Implementations

impl<I2C> Send for Stmpe1600<I2C> where
    I2C: Send

impl<I2C> !Sync for Stmpe1600<I2C>

impl<I2C> Unpin for Stmpe1600<I2C> where
    I2C: Unpin

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.