[][src]Struct hx711::Hx711

pub struct Hx711<IN, OUT> { /* fields omitted */ }

HX711 driver

Methods

impl<IN, OUT> Hx711<IN, OUT> where
    IN: InputPin,
    OUT: OutputPin
[src]

pub fn new(dout: IN, pd_sck: OUT) -> Self[src]

Creates a new driver from Input and Outut pins

pub fn set_mode(&mut self, mode: Mode)[src]

Set the mode (channel and gain).

pub fn reset(&mut self)[src]

Reset the chip. Mode is Channel A Gain 128 after reset.

pub fn retrieve(&mut self) -> Result<i32, !>[src]

Retrieve the latest conversion value if available

Auto Trait Implementations

impl<IN, OUT> Send for Hx711<IN, OUT> where
    IN: Send,
    OUT: Send

impl<IN, OUT> Sync for Hx711<IN, OUT> where
    IN: Sync,
    OUT: Sync

Blanket Implementations

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, 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, U> Into for T where
    U: From<T>, 
[src]

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

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

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