pub struct Qspi<'d, T: Instance, M: PeriMode> { /* private fields */ }
Expand description
QSPI driver.
Implementations§
Source§impl<'d, T: Instance, M: PeriMode> Qspi<'d, T, M>
impl<'d, T: Instance, M: PeriMode> Qspi<'d, T, M>
Sourcepub fn command(&mut self, transaction: TransferConfig)
pub fn command(&mut self, transaction: TransferConfig)
Do a QSPI command.
Sourcepub fn blocking_read(&mut self, buf: &mut [u8], transaction: TransferConfig)
pub fn blocking_read(&mut self, buf: &mut [u8], transaction: TransferConfig)
Blocking read data.
Sourcepub fn blocking_write(&mut self, buf: &[u8], transaction: TransferConfig)
pub fn blocking_write(&mut self, buf: &[u8], transaction: TransferConfig)
Blocking write data.
Source§impl<'d, T: Instance> Qspi<'d, T, Blocking>
impl<'d, T: Instance> Qspi<'d, T, Blocking>
Sourcepub fn new_blocking_bank1(
peri: impl Peripheral<P = T> + 'd,
d0: impl Peripheral<P = impl BK1D0Pin<T>> + 'd,
d1: impl Peripheral<P = impl BK1D1Pin<T>> + 'd,
d2: impl Peripheral<P = impl BK1D2Pin<T>> + 'd,
d3: impl Peripheral<P = impl BK1D3Pin<T>> + 'd,
sck: impl Peripheral<P = impl SckPin<T>> + 'd,
nss: impl Peripheral<P = impl BK1NSSPin<T>> + 'd,
config: Config,
) -> Self
pub fn new_blocking_bank1( peri: impl Peripheral<P = T> + 'd, d0: impl Peripheral<P = impl BK1D0Pin<T>> + 'd, d1: impl Peripheral<P = impl BK1D1Pin<T>> + 'd, d2: impl Peripheral<P = impl BK1D2Pin<T>> + 'd, d3: impl Peripheral<P = impl BK1D3Pin<T>> + 'd, sck: impl Peripheral<P = impl SckPin<T>> + 'd, nss: impl Peripheral<P = impl BK1NSSPin<T>> + 'd, config: Config, ) -> Self
Create a new QSPI driver for bank 1, in blocking mode.
Sourcepub fn new_blocking_bank2(
peri: impl Peripheral<P = T> + 'd,
d0: impl Peripheral<P = impl BK2D0Pin<T>> + 'd,
d1: impl Peripheral<P = impl BK2D1Pin<T>> + 'd,
d2: impl Peripheral<P = impl BK2D2Pin<T>> + 'd,
d3: impl Peripheral<P = impl BK2D3Pin<T>> + 'd,
sck: impl Peripheral<P = impl SckPin<T>> + 'd,
nss: impl Peripheral<P = impl BK2NSSPin<T>> + 'd,
config: Config,
) -> Self
pub fn new_blocking_bank2( peri: impl Peripheral<P = T> + 'd, d0: impl Peripheral<P = impl BK2D0Pin<T>> + 'd, d1: impl Peripheral<P = impl BK2D1Pin<T>> + 'd, d2: impl Peripheral<P = impl BK2D2Pin<T>> + 'd, d3: impl Peripheral<P = impl BK2D3Pin<T>> + 'd, sck: impl Peripheral<P = impl SckPin<T>> + 'd, nss: impl Peripheral<P = impl BK2NSSPin<T>> + 'd, config: Config, ) -> Self
Create a new QSPI driver for bank 2, in blocking mode.
Source§impl<'d, T: Instance> Qspi<'d, T, Async>
impl<'d, T: Instance> Qspi<'d, T, Async>
Sourcepub fn new_bank1(
peri: impl Peripheral<P = T> + 'd,
d0: impl Peripheral<P = impl BK1D0Pin<T>> + 'd,
d1: impl Peripheral<P = impl BK1D1Pin<T>> + 'd,
d2: impl Peripheral<P = impl BK1D2Pin<T>> + 'd,
d3: impl Peripheral<P = impl BK1D3Pin<T>> + 'd,
sck: impl Peripheral<P = impl SckPin<T>> + 'd,
nss: impl Peripheral<P = impl BK1NSSPin<T>> + 'd,
dma: impl Peripheral<P = impl QuadDma<T>> + 'd,
config: Config,
) -> Self
pub fn new_bank1( peri: impl Peripheral<P = T> + 'd, d0: impl Peripheral<P = impl BK1D0Pin<T>> + 'd, d1: impl Peripheral<P = impl BK1D1Pin<T>> + 'd, d2: impl Peripheral<P = impl BK1D2Pin<T>> + 'd, d3: impl Peripheral<P = impl BK1D3Pin<T>> + 'd, sck: impl Peripheral<P = impl SckPin<T>> + 'd, nss: impl Peripheral<P = impl BK1NSSPin<T>> + 'd, dma: impl Peripheral<P = impl QuadDma<T>> + 'd, config: Config, ) -> Self
Create a new QSPI driver for bank 1.
Sourcepub fn new_bank2(
peri: impl Peripheral<P = T> + 'd,
d0: impl Peripheral<P = impl BK2D0Pin<T>> + 'd,
d1: impl Peripheral<P = impl BK2D1Pin<T>> + 'd,
d2: impl Peripheral<P = impl BK2D2Pin<T>> + 'd,
d3: impl Peripheral<P = impl BK2D3Pin<T>> + 'd,
sck: impl Peripheral<P = impl SckPin<T>> + 'd,
nss: impl Peripheral<P = impl BK2NSSPin<T>> + 'd,
dma: impl Peripheral<P = impl QuadDma<T>> + 'd,
config: Config,
) -> Self
pub fn new_bank2( peri: impl Peripheral<P = T> + 'd, d0: impl Peripheral<P = impl BK2D0Pin<T>> + 'd, d1: impl Peripheral<P = impl BK2D1Pin<T>> + 'd, d2: impl Peripheral<P = impl BK2D2Pin<T>> + 'd, d3: impl Peripheral<P = impl BK2D3Pin<T>> + 'd, sck: impl Peripheral<P = impl SckPin<T>> + 'd, nss: impl Peripheral<P = impl BK2NSSPin<T>> + 'd, dma: impl Peripheral<P = impl QuadDma<T>> + 'd, config: Config, ) -> Self
Create a new QSPI driver for bank 2.
Sourcepub fn blocking_read_dma(&mut self, buf: &mut [u8], transaction: TransferConfig)
pub fn blocking_read_dma(&mut self, buf: &mut [u8], transaction: TransferConfig)
Blocking read data, using DMA.
Sourcepub async fn read_dma(&mut self, buf: &mut [u8], transaction: TransferConfig)
pub async fn read_dma(&mut self, buf: &mut [u8], transaction: TransferConfig)
Async read data, using DMA.
Sourcepub fn blocking_write_dma(&mut self, buf: &[u8], transaction: TransferConfig)
pub fn blocking_write_dma(&mut self, buf: &[u8], transaction: TransferConfig)
Blocking write data, using DMA.
Sourcepub async fn write_dma(&mut self, buf: &[u8], transaction: TransferConfig)
pub async fn write_dma(&mut self, buf: &[u8], transaction: TransferConfig)
Async write data, using DMA.
Auto Trait Implementations§
impl<'d, T, M> Freeze for Qspi<'d, T, M>where
T: Freeze,
impl<'d, T, M> RefUnwindSafe for Qspi<'d, T, M>where
T: RefUnwindSafe,
M: RefUnwindSafe,
impl<'d, T, M> Send for Qspi<'d, T, M>
impl<'d, T, M> Sync for Qspi<'d, T, M>
impl<'d, T, M> Unpin for Qspi<'d, T, M>
impl<'d, T, M> !UnwindSafe for Qspi<'d, T, M>
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