Struct I2cMapping

Source
pub struct I2cMapping<SDA, SCL>(/* private fields */);

Trait Implementations§

Source§

impl<SDA: Clone, SCL: Clone> Clone for I2cMapping<SDA, SCL>

Source§

fn clone(&self) -> I2cMapping<SDA, SCL>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<SDA: Debug, SCL: Debug> Debug for I2cMapping<SDA, SCL>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl I2cBusMapping<Pin<P0_26<Input<Floating>>>, Pin<P0_27<Input<Floating>>>> for I2cMapping<Pin<P0_26<Input<Floating>>>, Pin<P0_27<Input<Floating>>>>

Source§

type Error = Error

The common error type for I²C operations. Read more
Source§

type Bus = I2c

The I²C bus that will be produced once initialization based off of this mapping succeeds.
Source§

fn poll_initialize( self: Pin<&mut Self>, cx: &mut Context<'_>, sda: &mut Pin<P0_26<Input<Floating>>>, scl: &mut Pin<P0_27<Input<Floating>>>, ) -> Poll<Result<Self::Bus, Self::Error>>
where Self: Sized,

Polls the initialization operation to completion.
Source§

impl<SDA: Copy, SCL: Copy> Copy for I2cMapping<SDA, SCL>

Auto Trait Implementations§

§

impl<SDA, SCL> Freeze for I2cMapping<SDA, SCL>
where SDA: Freeze, SCL: Freeze,

§

impl<SDA, SCL> RefUnwindSafe for I2cMapping<SDA, SCL>
where SDA: RefUnwindSafe, SCL: RefUnwindSafe,

§

impl<SDA, SCL> Send for I2cMapping<SDA, SCL>
where SDA: Send, SCL: Send,

§

impl<SDA, SCL> Sync for I2cMapping<SDA, SCL>
where SDA: Sync, SCL: Sync,

§

impl<SDA, SCL> Unpin for I2cMapping<SDA, SCL>
where SDA: Unpin, SCL: Unpin,

§

impl<SDA, SCL> UnwindSafe for I2cMapping<SDA, SCL>
where SDA: UnwindSafe, SCL: UnwindSafe,

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<A, SDA, SCL> I2cBusMappingExt<SDA, SCL> for A
where A: I2cBusMapping<SDA, SCL>, SDA: Unpin, SCL: Unpin,

Source§

fn initialize(self, sda: SDA, scl: SCL) -> Initialize<Self, SDA, SCL>
where Self: Sized + Unpin,

Initializes a new I²C bus based off of the two provided SDA (data) and SCL (clock) pins.
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> Same for T

Source§

type Output = T

Should always be Self
Source§

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

Source§

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>,

Source§

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.
Source§

impl<A> WriteExt for A
where A: WriteExt,

Source§

fn write<'a>(&'a mut self, bytes: &'a [u8]) -> Write<'a, Self>
where Self: Unpin,

Source§

fn write_all<'a>(&'a mut self, bytes: &'a [u8]) -> WriteAll<'a, Self>
where Self: Unpin,

Source§

fn shutdown(&mut self) -> Shutdown<'_, Self>
where Self: Unpin,