Struct idasen::Idasen[][src]

pub struct Idasen<T> where
    T: Device
{ pub mac_addr: BDAddr, // some fields omitted }

Fields

mac_addr: BDAddr

Implementations

impl<T: Device> Idasen<T>[src]

pub fn new(desk: T) -> Result<Self, Error>[src]

Instantiate the struct. Requires Device instance.

pub fn up(&self) -> Result<()>[src]

Move desk up.

pub fn down(&self) -> Result<()>[src]

Lower the desk’s position.

pub fn stop(&self) -> Result<()>[src]

Stop desk from moving.

pub fn move_to(&self, target_position: u16) -> Result<(), Error>[src]

Move desk to a desired position. The precision is decent, usually less than 1mm off.

pub fn move_to_with_progress(&self, target_position: u16) -> Result<(), Error>[src]

pub fn position(&self) -> Result<u16, Error>[src]

Return the desk height in tenth millimeters (1m = 10000)

Auto Trait Implementations

impl<T> RefUnwindSafe for Idasen<T> where
    T: RefUnwindSafe

impl<T> Send for Idasen<T>

impl<T> Sync for Idasen<T>

impl<T> Unpin for Idasen<T> where
    T: Unpin

impl<T> UnwindSafe for Idasen<T> where
    T: UnwindSafe

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.