Struct embedded_hal::spi::blocking::ExclusiveDevice
source · [−]pub struct ExclusiveDevice<BUS, CS> { /* private fields */ }
Expand description
Implementations
sourceimpl<BUS, CS> ExclusiveDevice<BUS, CS>
impl<BUS, CS> ExclusiveDevice<BUS, CS>
Trait Implementations
sourceimpl<BUS, CS> ErrorType for ExclusiveDevice<BUS, CS> where
BUS: ErrorType,
CS: OutputPin,
impl<BUS, CS> ErrorType for ExclusiveDevice<BUS, CS> where
BUS: ErrorType,
CS: OutputPin,
sourceimpl<BUS, CS> SpiDevice for ExclusiveDevice<BUS, CS> where
BUS: SpiBusFlush,
CS: OutputPin,
impl<BUS, CS> SpiDevice for ExclusiveDevice<BUS, CS> where
BUS: SpiBusFlush,
CS: OutputPin,
type Bus = BUS
type Bus = BUS
SPI Bus type for this device.
sourcefn transaction<R>(
&mut self,
f: impl FnOnce(&mut Self::Bus) -> Result<R, <Self::Bus as ErrorType>::Error>
) -> Result<R, Self::Error>
fn transaction<R>(
&mut self,
f: impl FnOnce(&mut Self::Bus) -> Result<R, <Self::Bus as ErrorType>::Error>
) -> Result<R, Self::Error>
Perform a transaction against the device. Read more
sourcefn write<Word>(&mut self, buf: &[Word]) -> Result<(), Self::Error> where
Self::Bus: SpiBusWrite<Word>,
Word: Copy,
fn write<Word>(&mut self, buf: &[Word]) -> Result<(), Self::Error> where
Self::Bus: SpiBusWrite<Word>,
Word: Copy,
Do a write within a transaction. Read more
sourcefn read<Word>(&mut self, buf: &mut [Word]) -> Result<(), Self::Error> where
Self::Bus: SpiBusRead<Word>,
Word: Copy,
fn read<Word>(&mut self, buf: &mut [Word]) -> Result<(), Self::Error> where
Self::Bus: SpiBusRead<Word>,
Word: Copy,
Do a read within a transaction. Read more
sourcefn transfer<Word>(
&mut self,
read: &mut [Word],
write: &[Word]
) -> Result<(), Self::Error> where
Self::Bus: SpiBus<Word>,
Word: Copy,
fn transfer<Word>(
&mut self,
read: &mut [Word],
write: &[Word]
) -> Result<(), Self::Error> where
Self::Bus: SpiBus<Word>,
Word: Copy,
Do a transfer within a transaction. Read more
sourcefn transfer_in_place<Word>(
&mut self,
buf: &mut [Word]
) -> Result<(), Self::Error> where
Self::Bus: SpiBus<Word>,
Word: Copy,
fn transfer_in_place<Word>(
&mut self,
buf: &mut [Word]
) -> Result<(), Self::Error> where
Self::Bus: SpiBus<Word>,
Word: Copy,
Do an in-place transfer within a transaction. Read more
Auto Trait Implementations
impl<BUS, CS> RefUnwindSafe for ExclusiveDevice<BUS, CS> where
BUS: RefUnwindSafe,
CS: RefUnwindSafe,
impl<BUS, CS> Send for ExclusiveDevice<BUS, CS> where
BUS: Send,
CS: Send,
impl<BUS, CS> Sync for ExclusiveDevice<BUS, CS> where
BUS: Sync,
CS: Sync,
impl<BUS, CS> Unpin for ExclusiveDevice<BUS, CS> where
BUS: Unpin,
CS: Unpin,
impl<BUS, CS> UnwindSafe for ExclusiveDevice<BUS, CS> where
BUS: UnwindSafe,
CS: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more