diff options
Diffstat (limited to 'embassy-nrf/src/qspi.rs')
| -rw-r--r-- | embassy-nrf/src/qspi.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/embassy-nrf/src/qspi.rs b/embassy-nrf/src/qspi.rs index 3f48568b3..baefc7967 100644 --- a/embassy-nrf/src/qspi.rs +++ b/embassy-nrf/src/qspi.rs | |||
| @@ -12,12 +12,12 @@ use embassy_hal_common::{into_ref, PeripheralRef}; | |||
| 12 | use embedded_storage::nor_flash::{ErrorType, NorFlash, NorFlashError, NorFlashErrorKind, ReadNorFlash}; | 12 | use embedded_storage::nor_flash::{ErrorType, NorFlash, NorFlashError, NorFlashErrorKind, ReadNorFlash}; |
| 13 | 13 | ||
| 14 | use crate::gpio::{self, Pin as GpioPin}; | 14 | use crate::gpio::{self, Pin as GpioPin}; |
| 15 | use crate::interrupt::{self, Interrupt}; | 15 | use crate::interrupt::typelevel::Interrupt; |
| 16 | pub use crate::pac::qspi::ifconfig0::{ | 16 | pub use crate::pac::qspi::ifconfig0::{ |
| 17 | ADDRMODE_A as AddressMode, PPSIZE_A as WritePageSize, READOC_A as ReadOpcode, WRITEOC_A as WriteOpcode, | 17 | ADDRMODE_A as AddressMode, PPSIZE_A as WritePageSize, READOC_A as ReadOpcode, WRITEOC_A as WriteOpcode, |
| 18 | }; | 18 | }; |
| 19 | pub use crate::pac::qspi::ifconfig1::SPIMODE_A as SpiMode; | 19 | pub use crate::pac::qspi::ifconfig1::SPIMODE_A as SpiMode; |
| 20 | use crate::Peripheral; | 20 | use crate::{interrupt, Peripheral}; |
| 21 | 21 | ||
| 22 | /// Deep power-down config. | 22 | /// Deep power-down config. |
| 23 | pub struct DeepPowerDownConfig { | 23 | pub struct DeepPowerDownConfig { |
| @@ -120,7 +120,7 @@ pub struct InterruptHandler<T: Instance> { | |||
| 120 | _phantom: PhantomData<T>, | 120 | _phantom: PhantomData<T>, |
| 121 | } | 121 | } |
| 122 | 122 | ||
| 123 | impl<T: Instance> interrupt::Handler<T::Interrupt> for InterruptHandler<T> { | 123 | impl<T: Instance> interrupt::typelevel::Handler<T::Interrupt> for InterruptHandler<T> { |
| 124 | unsafe fn on_interrupt() { | 124 | unsafe fn on_interrupt() { |
| 125 | let r = T::regs(); | 125 | let r = T::regs(); |
| 126 | let s = T::state(); | 126 | let s = T::state(); |
| @@ -143,7 +143,7 @@ impl<'d, T: Instance> Qspi<'d, T> { | |||
| 143 | /// Create a new QSPI driver. | 143 | /// Create a new QSPI driver. |
| 144 | pub fn new( | 144 | pub fn new( |
| 145 | qspi: impl Peripheral<P = T> + 'd, | 145 | qspi: impl Peripheral<P = T> + 'd, |
| 146 | _irq: impl interrupt::Binding<T::Interrupt, InterruptHandler<T>> + 'd, | 146 | _irq: impl interrupt::typelevel::Binding<T::Interrupt, InterruptHandler<T>> + 'd, |
| 147 | sck: impl Peripheral<P = impl GpioPin> + 'd, | 147 | sck: impl Peripheral<P = impl GpioPin> + 'd, |
| 148 | csn: impl Peripheral<P = impl GpioPin> + 'd, | 148 | csn: impl Peripheral<P = impl GpioPin> + 'd, |
| 149 | io0: impl Peripheral<P = impl GpioPin> + 'd, | 149 | io0: impl Peripheral<P = impl GpioPin> + 'd, |
| @@ -644,7 +644,7 @@ pub(crate) mod sealed { | |||
| 644 | /// QSPI peripheral instance. | 644 | /// QSPI peripheral instance. |
| 645 | pub trait Instance: Peripheral<P = Self> + sealed::Instance + 'static + Send { | 645 | pub trait Instance: Peripheral<P = Self> + sealed::Instance + 'static + Send { |
| 646 | /// Interrupt for this peripheral. | 646 | /// Interrupt for this peripheral. |
| 647 | type Interrupt: Interrupt; | 647 | type Interrupt: interrupt::typelevel::Interrupt; |
| 648 | } | 648 | } |
| 649 | 649 | ||
| 650 | macro_rules! impl_qspi { | 650 | macro_rules! impl_qspi { |
| @@ -659,7 +659,7 @@ macro_rules! impl_qspi { | |||
| 659 | } | 659 | } |
| 660 | } | 660 | } |
| 661 | impl crate::qspi::Instance for peripherals::$type { | 661 | impl crate::qspi::Instance for peripherals::$type { |
| 662 | type Interrupt = crate::interrupt::$irq; | 662 | type Interrupt = crate::interrupt::typelevel::$irq; |
| 663 | } | 663 | } |
| 664 | }; | 664 | }; |
| 665 | } | 665 | } |
