Struct imxrt_hal::lpi2c::Disabled

source ·
pub struct Disabled<'a, const N: u8> { /* private fields */ }
Expand description

A temporarily disabled LPI2C peripheral.

This handle lets you modify LPI2C settings that require a disabled peripheral.

Implementations§

source§

impl<'a, const N: u8> Disabled<'a, N>

source

pub fn set_timings(&mut self, timings: &Timing)

Modify LPI2C timing parameters.

This call only affects parameters used in standard, fast, and fast+ modes. There is no support for switching into high-speed mode.

source

pub fn set_watermark(&mut self, direction: Direction, watermark: u8) -> u8

Set the watermark level for a given direction.

Returns the watermark level committed to the hardware. This may be different than the supplied watermark, since it’s limited by the hardware.

When direction == Direction::Rx, the receive data flag is set whenever the number of words in the receive FIFO is greater than watermark.

When direction == Direction::Tx, the transmit data flag is set whenever the the number of words in the transmit FIFO is less than, or equal, to watermark.

Trait Implementations§

source§

impl<const N: u8> Drop for Disabled<'_, N>

source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

§

impl<'a, const N: u8> !RefUnwindSafe for Disabled<'a, N>

§

impl<'a, const N: u8> Send for Disabled<'a, N>

§

impl<'a, const N: u8> !Sync for Disabled<'a, N>

§

impl<'a, const N: u8> Unpin for Disabled<'a, N>

§

impl<'a, const N: u8> !UnwindSafe for Disabled<'a, N>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.