[−][src]Struct lis2dh12::Int
Interrupt setting and status
Implementations
impl<'a, REG, I2C, E> Int<'a, REG, I2C> where
REG: IntRegs,
I2C: WriteRead<Error = E> + Write<Error = E>,
E: Debug,
[src]
REG: IntRegs,
I2C: WriteRead<Error = E> + Write<Error = E>,
E: Debug,
pub fn disable(&mut self) -> Result<(), Error<E>>
[src]
Disable interrupt,
INTx_CFG
clean all bits
pub fn set_mode(&mut self, mode: Aoi6d) -> Result<(), Error<E>>
[src]
AOI-6D Interrupt mode,
INTx_CFG
: AOI
, 6D
pub fn enable_high(
&mut self,
(x, y, z): (bool, bool, bool)
) -> Result<(), Error<E>>
[src]
&mut self,
(x, y, z): (bool, bool, bool)
) -> Result<(), Error<E>>
X,Y,Z high event enable,
INTx_CFG
: XHIE
, YHIE
, ZHIE
pub fn enable_low(
&mut self,
(x, y, z): (bool, bool, bool)
) -> Result<(), Error<E>>
[src]
&mut self,
(x, y, z): (bool, bool, bool)
) -> Result<(), Error<E>>
X,Y,Z low event enable,
INTx_CFG
: XLIE
, YLIE
, ZLIE
pub fn get_src(
&mut self
) -> Result<Option<((bool, bool), (bool, bool), (bool, bool))>, Error<E>>
[src]
&mut self
) -> Result<Option<((bool, bool), (bool, bool), (bool, bool))>, Error<E>>
Source,
INTx_SRC
decoded as ((XH
, XL
), (YH
, YL
), (ZH
, ZL
))
pub fn set_ths(&mut self, ths: u8) -> Result<(), Error<E>>
[src]
Threshold,
INTx_THS
: THS
pub fn set_thsf(&mut self, ths: f32) -> Result<(), Error<E>>
[src]
Threshold as f32,
INTx_THS
: THS
pub fn set_duration(&mut self, d: u8) -> Result<(), Error<E>>
[src]
Duration,
INTx_DURATION
: D
Auto Trait Implementations
impl<'a, REG, I2C> RefUnwindSafe for Int<'a, REG, I2C> where
I2C: RefUnwindSafe,
REG: RefUnwindSafe,
I2C: RefUnwindSafe,
REG: RefUnwindSafe,
impl<'a, REG, I2C> Send for Int<'a, REG, I2C> where
I2C: Send,
REG: Send,
I2C: Send,
REG: Send,
impl<'a, REG, I2C> Sync for Int<'a, REG, I2C> where
I2C: Sync,
REG: Sync,
I2C: Sync,
REG: Sync,
impl<'a, REG, I2C> Unpin for Int<'a, REG, I2C> where
REG: Unpin,
REG: Unpin,
impl<'a, REG, I2C> !UnwindSafe for Int<'a, REG, I2C>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,