aboutsummaryrefslogtreecommitdiff
path: root/embassy-rp/src/uart
diff options
context:
space:
mode:
authorkalkyl <[email protected]>2022-12-22 23:03:05 +0100
committerkalkyl <[email protected]>2022-12-22 23:03:05 +0100
commitaa92ce6dc71cf176eb6e99632fda72c875d071e6 (patch)
tree634476ce53ba0c86b005515984eb5ec9c83d2a95 /embassy-rp/src/uart
parent1bd6c954c23b16041b382243a844a53727f6cc9c (diff)
embassy-rp: Add split() to BufferedUart
Diffstat (limited to 'embassy-rp/src/uart')
-rw-r--r--embassy-rp/src/uart/buffered.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/embassy-rp/src/uart/buffered.rs b/embassy-rp/src/uart/buffered.rs
index 32029f81e..e89970d11 100644
--- a/embassy-rp/src/uart/buffered.rs
+++ b/embassy-rp/src/uart/buffered.rs
@@ -126,6 +126,13 @@ impl<'d, T: Instance> BufferedUart<'d, T> {
126 126
127 Self { phantom: PhantomData } 127 Self { phantom: PhantomData }
128 } 128 }
129
130 pub fn split(&mut self) -> (BufferedUartRx<'d, T>, BufferedUartTx<'d, T>) {
131 (
132 BufferedUartRx { phantom: PhantomData },
133 BufferedUartTx { phantom: PhantomData },
134 )
135 }
129} 136}
130 137
131impl<'d, T: Instance> BufferedUartRx<'d, T> { 138impl<'d, T: Instance> BufferedUartRx<'d, T> {