aboutsummaryrefslogtreecommitdiff
path: root/embassy-rp/src/pio_programs
diff options
context:
space:
mode:
authoreden barby <>2025-03-01 17:23:04 +1000
committereden barby <>2025-03-01 17:23:04 +1000
commit24941212e8130cddef974aab865bce4c7e294c33 (patch)
tree27ce11477749d8af3e0f02a002363541449fcaa4 /embassy-rp/src/pio_programs
parent17301c00e986c5b8536435ea31ebf5aaf13aed17 (diff)
Added access to the byte swap flag for RP2*** chips for the PIO state machine DMA calls.
Diffstat (limited to 'embassy-rp/src/pio_programs')
-rw-r--r--embassy-rp/src/pio_programs/hd44780.rs4
-rw-r--r--embassy-rp/src/pio_programs/i2s.rs2
-rw-r--r--embassy-rp/src/pio_programs/ws2812.rs2
3 files changed, 4 insertions, 4 deletions
diff --git a/embassy-rp/src/pio_programs/hd44780.rs b/embassy-rp/src/pio_programs/hd44780.rs
index 70129318b..6997b91f3 100644
--- a/embassy-rp/src/pio_programs/hd44780.rs
+++ b/embassy-rp/src/pio_programs/hd44780.rs
@@ -173,7 +173,7 @@ impl<'l, P: Instance, const S: usize> PioHD44780<'l, P, S> {
173 sm.set_enable(true); 173 sm.set_enable(true);
174 174
175 // display on and cursor on and blinking, reset display 175 // display on and cursor on and blinking, reset display
176 sm.tx().dma_push(dma.reborrow(), &[0x81u8, 0x0f, 1]).await; 176 sm.tx().dma_push(dma.reborrow(), &[0x81u8, 0x0f, 1], false).await;
177 177
178 Self { 178 Self {
179 dma: dma.map_into(), 179 dma: dma.map_into(),
@@ -198,6 +198,6 @@ impl<'l, P: Instance, const S: usize> PioHD44780<'l, P, S> {
198 // set cursor to 1:15 198 // set cursor to 1:15
199 self.buf[38..].copy_from_slice(&[0x80, 0xcf]); 199 self.buf[38..].copy_from_slice(&[0x80, 0xcf]);
200 200
201 self.sm.tx().dma_push(self.dma.reborrow(), &self.buf).await; 201 self.sm.tx().dma_push(self.dma.reborrow(), &self.buf, false).await;
202 } 202 }
203} 203}
diff --git a/embassy-rp/src/pio_programs/i2s.rs b/embassy-rp/src/pio_programs/i2s.rs
index a7b4f46a6..17e321405 100644
--- a/embassy-rp/src/pio_programs/i2s.rs
+++ b/embassy-rp/src/pio_programs/i2s.rs
@@ -90,6 +90,6 @@ impl<'a, P: Instance, const S: usize> PioI2sOut<'a, P, S> {
90 90
91 /// Return an in-prograss dma transfer future. Awaiting it will guarentee a complete transfer. 91 /// Return an in-prograss dma transfer future. Awaiting it will guarentee a complete transfer.
92 pub fn write<'b>(&'b mut self, buff: &'b [u32]) -> Transfer<'b, AnyChannel> { 92 pub fn write<'b>(&'b mut self, buff: &'b [u32]) -> Transfer<'b, AnyChannel> {
93 self.sm.tx().dma_push(self.dma.reborrow(), buff) 93 self.sm.tx().dma_push(self.dma.reborrow(), buff, false)
94 } 94 }
95} 95}
diff --git a/embassy-rp/src/pio_programs/ws2812.rs b/embassy-rp/src/pio_programs/ws2812.rs
index 875f0209f..2462a64e6 100644
--- a/embassy-rp/src/pio_programs/ws2812.rs
+++ b/embassy-rp/src/pio_programs/ws2812.rs
@@ -111,7 +111,7 @@ impl<'d, P: Instance, const S: usize, const N: usize> PioWs2812<'d, P, S, N> {
111 } 111 }
112 112
113 // DMA transfer 113 // DMA transfer
114 self.sm.tx().dma_push(self.dma.reborrow(), &words).await; 114 self.sm.tx().dma_push(self.dma.reborrow(), &words, false).await;
115 115
116 Timer::after_micros(55).await; 116 Timer::after_micros(55).await;
117 } 117 }