mirror of
https://github.com/embassy-rs/embassy.git
synced 2024-11-22 06:42:32 +00:00
Merge pull request #3362 from showier-drastic/main
stm32/spi: issue correct DMA word length when reading to prevent hang
This commit is contained in:
commit
b9553badb3
@ -783,7 +783,7 @@ impl<'d> Spi<'d, Async> {
|
||||
let rx_f = unsafe { self.rx_dma.as_mut().unwrap().read(rx_src, data, Default::default()) };
|
||||
|
||||
let tx_dst = self.info.regs.tx_ptr();
|
||||
let clock_byte = 0x00u8;
|
||||
let clock_byte = W::default();
|
||||
let tx_f = unsafe {
|
||||
self.tx_dma
|
||||
.as_mut()
|
||||
@ -1195,7 +1195,7 @@ trait SealedWord {
|
||||
|
||||
/// Word sizes usable for SPI.
|
||||
#[allow(private_bounds)]
|
||||
pub trait Word: word::Word + SealedWord {}
|
||||
pub trait Word: word::Word + SealedWord + Default {}
|
||||
|
||||
macro_rules! impl_word {
|
||||
($T:ty, $config:expr) => {
|
||||
|
Loading…
Reference in New Issue
Block a user