diff options
| author | Ulf Lilleengen <[email protected]> | 2025-04-05 05:36:27 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-04-05 05:36:27 +0000 |
| commit | b1179c5090a945d8b15919c99144f157e11d4654 (patch) | |
| tree | b8a819be5f368460c46b59dd258e31385d9cf734 /embassy-rp | |
| parent | 61b77624219eac1b5e74bdeeb64f5c38df997a93 (diff) | |
| parent | f1feedf19031d0c007628569add51ff89ae08447 (diff) | |
Merge pull request #3983 from mgomez0/topic/buffered-uart-take-pins-before-interrupts
BufferedUart initialization
Diffstat (limited to 'embassy-rp')
| -rw-r--r-- | embassy-rp/CHANGELOG.md | 1 | ||||
| -rw-r--r-- | embassy-rp/src/uart/buffered.rs | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/embassy-rp/CHANGELOG.md b/embassy-rp/CHANGELOG.md index 8ad3b0b76..7ac0a47cb 100644 --- a/embassy-rp/CHANGELOG.md +++ b/embassy-rp/CHANGELOG.md | |||
| @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 | |||
| 16 | - rp235x: add ImageDef features. ([#3890](https://github.com/embassy-rs/embassy/pull/3890)) | 16 | - rp235x: add ImageDef features. ([#3890](https://github.com/embassy-rs/embassy/pull/3890)) |
| 17 | - doc: Fix "the the" ([#3903](https://github.com/embassy-rs/embassy/pull/3903)) | 17 | - doc: Fix "the the" ([#3903](https://github.com/embassy-rs/embassy/pull/3903)) |
| 18 | - pio: Add access to DMA engine byte swapping ([#3935](https://github.com/embassy-rs/embassy/pull/3935)) | 18 | - pio: Add access to DMA engine byte swapping ([#3935](https://github.com/embassy-rs/embassy/pull/3935)) |
| 19 | - Modify BufferedUart initialization to take pins before interrupts ([#3983](https://github.com/embassy-rs/embassy/pull/3983)) | ||
| 19 | 20 | ||
| 20 | ## 0.3.1 - 2025-02-06 | 21 | ## 0.3.1 - 2025-02-06 |
| 21 | 22 | ||
diff --git a/embassy-rp/src/uart/buffered.rs b/embassy-rp/src/uart/buffered.rs index 5b5159d22..da18138b5 100644 --- a/embassy-rp/src/uart/buffered.rs +++ b/embassy-rp/src/uart/buffered.rs | |||
| @@ -91,9 +91,9 @@ impl<'d, T: Instance> BufferedUart<'d, T> { | |||
| 91 | /// Create a buffered UART instance. | 91 | /// Create a buffered UART instance. |
| 92 | pub fn new( | 92 | pub fn new( |
| 93 | _uart: Peri<'d, T>, | 93 | _uart: Peri<'d, T>, |
| 94 | irq: impl Binding<T::Interrupt, BufferedInterruptHandler<T>>, | ||
| 95 | tx: Peri<'d, impl TxPin<T>>, | 94 | tx: Peri<'d, impl TxPin<T>>, |
| 96 | rx: Peri<'d, impl RxPin<T>>, | 95 | rx: Peri<'d, impl RxPin<T>>, |
| 96 | irq: impl Binding<T::Interrupt, BufferedInterruptHandler<T>>, | ||
| 97 | tx_buffer: &'d mut [u8], | 97 | tx_buffer: &'d mut [u8], |
| 98 | rx_buffer: &'d mut [u8], | 98 | rx_buffer: &'d mut [u8], |
| 99 | config: Config, | 99 | config: Config, |
| @@ -110,11 +110,11 @@ impl<'d, T: Instance> BufferedUart<'d, T> { | |||
| 110 | /// Create a buffered UART instance with flow control. | 110 | /// Create a buffered UART instance with flow control. |
| 111 | pub fn new_with_rtscts( | 111 | pub fn new_with_rtscts( |
| 112 | _uart: Peri<'d, T>, | 112 | _uart: Peri<'d, T>, |
| 113 | irq: impl Binding<T::Interrupt, BufferedInterruptHandler<T>>, | ||
| 114 | tx: Peri<'d, impl TxPin<T>>, | 113 | tx: Peri<'d, impl TxPin<T>>, |
| 115 | rx: Peri<'d, impl RxPin<T>>, | 114 | rx: Peri<'d, impl RxPin<T>>, |
| 116 | rts: Peri<'d, impl RtsPin<T>>, | 115 | rts: Peri<'d, impl RtsPin<T>>, |
| 117 | cts: Peri<'d, impl CtsPin<T>>, | 116 | cts: Peri<'d, impl CtsPin<T>>, |
| 117 | irq: impl Binding<T::Interrupt, BufferedInterruptHandler<T>>, | ||
| 118 | tx_buffer: &'d mut [u8], | 118 | tx_buffer: &'d mut [u8], |
| 119 | rx_buffer: &'d mut [u8], | 119 | rx_buffer: &'d mut [u8], |
| 120 | config: Config, | 120 | config: Config, |
