diff --git a/Cargo.toml b/Cargo.toml index a391e178..cc60ed04 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -147,6 +147,10 @@ required-features = ["fmc", "rm0399"] name = "qspi" required-features = ["xspi", "rm0433"] +[[example]] +name = "qspi_mdma" +required-features = ["xspi", "rm0433"] + [[example]] name = "octospi" required-features = ["xspi", "rm0468"] diff --git a/examples/qspi_mdma.rs b/examples/qspi_mdma.rs index 9633cf51..f06e1271 100644 --- a/examples/qspi_mdma.rs +++ b/examples/qspi_mdma.rs @@ -13,7 +13,7 @@ mod utilities; use core::mem; use cortex_m_rt::entry; -use stm32h7xx_hal::{pac, prelude::*, qspi, qspi::QspiMode}; +use stm32h7xx_hal::{pac, prelude::*, xspi, xspi::QspiMode}; use stm32h7xx_hal::dma::{ mdma::{ @@ -57,7 +57,7 @@ fn main() -> ! { info!("stm32h7xx-hal example - QSPI with MDMA"); info!(""); - let config: qspi::Config = 1.mhz().into(); + let config: xspi::Config = 1.mhz().into(); // Threshold when half full let config = config.fifo_threshold(16); diff --git a/src/dma/mdma.rs b/src/dma/mdma.rs index efa3525a..720d7ea0 100644 --- a/src/dma/mdma.rs +++ b/src/dma/mdma.rs @@ -1250,8 +1250,8 @@ peripheral_target_address!( (pac::QUADSPI, dr, u32, P2M), (pac::QUADSPI, dr, u32, M2P), ); -#[cfg(all(feature = "quadspi", any(feature = "rm0433", feature = "rm0399")))] +#[cfg(all(feature = "xspi", any(feature = "rm0433", feature = "rm0399")))] peripheral_target_address!( - (INNER: crate::qspi::Qspi, dr, u32, P2M), - (INNER: crate::qspi::Qspi, dr, u32, M2P), + (INNER: crate::xspi::Qspi, dr, u32, P2M), + (INNER: crate::xspi::Qspi, dr, u32, M2P), );