BufferedUart initialization

This change modifies UART initialization throughout Embassy to take pins
before interrupts.

Related to #1304.
This commit is contained in:
Michael Gomez
2025-03-19 20:44:16 -07:00
parent a44abaf7e4
commit f1feedf190
24 changed files with 40 additions and 34 deletions

View File

@@ -30,9 +30,9 @@ async fn main(_spawner: Spawner) {
p.PPI_CH0.reborrow(),
p.PPI_CH1.reborrow(),
p.PPI_GROUP0.reborrow(),
irqs!(UART0_BUFFERED),
peri!(p, PIN_A).reborrow(),
peri!(p, PIN_B).reborrow(),
irqs!(UART0_BUFFERED),
config.clone(),
&mut rx_buffer,
&mut tx_buffer,

View File

@@ -28,9 +28,9 @@ async fn main(_spawner: Spawner) {
p.PPI_CH0,
p.PPI_CH1,
p.PPI_GROUP0,
irqs!(UART0_BUFFERED),
peri!(p, PIN_A),
peri!(p, PIN_B),
irqs!(UART0_BUFFERED),
config.clone(),
&mut rx_buffer,
&mut tx_buffer,

View File

@@ -28,8 +28,8 @@ async fn main(_spawner: Spawner) {
let mut tx = BufferedUarteTx::new(
peri!(p, UART1).reborrow(),
irqs!(UART1_BUFFERED),
peri!(p, PIN_A).reborrow(),
irqs!(UART1_BUFFERED),
config.clone(),
&mut tx_buffer,
);

View File

@@ -22,9 +22,9 @@ async fn main(_spawner: Spawner) {
let uarte = Uarte::new(
peri!(p, UART0).reborrow(),
irqs!(UART0),
peri!(p, PIN_A).reborrow(),
peri!(p, PIN_B).reborrow(),
irqs!(UART0),
config.clone(),
);
let (mut tx, mut rx) = uarte.split();