Skip to content

Commit 87729a6

Browse files
committed
add spi extensions
1 parent 83d09b1 commit 87729a6

File tree

2 files changed

+173
-70
lines changed

2 files changed

+173
-70
lines changed

src/dma/macros.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,7 @@ macro_rules! peripheral_target_instance {
125125
unsafe impl TargetAddress<M2P> for spi::Spi<$peripheral, spi::Disabled, $size> {
126126
#[inline(always)]
127127
fn address(&self) -> usize {
128+
use spi::SpiAllExt;
128129
&self.inner().$txreg as *const _ as usize
129130
}
130131

@@ -136,6 +137,7 @@ macro_rules! peripheral_target_instance {
136137
unsafe impl TargetAddress<P2M> for spi::Spi<$peripheral, spi::Disabled, $size> {
137138
#[inline(always)]
138139
fn address(&self) -> usize {
140+
use spi::SpiAllExt;
139141
&self.inner().$rxreg as *const _ as usize
140142
}
141143

0 commit comments

Comments
 (0)