pub struct Spi2Builder {
pub base: SpiBase<SPI2>,
pub sck: PB13,
pub mosi: PB15,
pub miso: PB14,
}Expand description
spi2 builder
Fields§
§base: SpiBase<SPI2>spi device
sck: PB13sck pin
mosi: PB15mosi pin
miso: PB14miso pin
Implementations§
Source§impl Spi2Builder
custom method
impl Spi2Builder
custom method
Sourcepub fn build(self, tx_dma: DMA1_CH5, rx_dma: DMA1_CH4) -> Spi<'static, Async>
pub fn build(self, tx_dma: DMA1_CH5, rx_dma: DMA1_CH4) -> Spi<'static, Async>
Create a new SPI driver.
more see Spi::<Async>::new
Sourcepub fn build_blocking(self) -> Spi<'static, Blocking>
pub fn build_blocking(self) -> Spi<'static, Blocking>
Create a new blocking SPI driver.
more see Spi::<Blocking>::new_blocking
Auto Trait Implementations§
impl Freeze for Spi2Builder
impl RefUnwindSafe for Spi2Builder
impl Send for Spi2Builder
impl Sync for Spi2Builder
impl Unpin for Spi2Builder
impl UnwindSafe for Spi2Builder
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