pub struct InOutPin<T>where
T: AnyPin,{ /* private fields */ }Expand description
A wrapper AnyPin<Function = FunctionSioOutput> emulating open-drain function.
This wrapper implements both InputPin and OutputPin, to simulate an open-drain pin as needed for example by the wire protocol the DHT11 sensor speaks.
https://how2electronics.com/interfacing-dht11-temperature-humidity-sensor-with-raspberry-pi-pico/
Implementations§
Trait Implementations§
Source§impl<I> OutputPin for InOutPin<I>where
I: AnyPin,
impl<I> OutputPin for InOutPin<I>where
I: AnyPin,
Auto Trait Implementations§
impl<T> Freeze for InOutPin<T>
impl<T> RefUnwindSafe for InOutPin<T>
impl<T> Send for InOutPin<T>
impl<T> Sync for InOutPin<T>
impl<T> Unpin for InOutPin<T>
impl<T> UnwindSafe for InOutPin<T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<Choices> CoproductSubsetter<CNil, HNil> for Choices
impl<Choices> CoproductSubsetter<CNil, HNil> for Choices
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more