From 59ccc45f280e05a9d2a0ece2bb1e01debadb2f7e Mon Sep 17 00:00:00 2001 From: Dario Nieuwenhuis Date: Wed, 14 Apr 2021 16:01:43 +0200 Subject: Remove pin from Uart --- embassy-traits/src/uart.rs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'embassy-traits/src') diff --git a/embassy-traits/src/uart.rs b/embassy-traits/src/uart.rs index 5676e3fca..9e76306b0 100644 --- a/embassy-traits/src/uart.rs +++ b/embassy-traits/src/uart.rs @@ -13,7 +13,7 @@ pub trait Read { where Self: 'a; - fn read<'a>(self: Pin<&'a mut Self>, buf: &'a mut [u8]) -> Self::ReadFuture<'a>; + fn read<'a>(&'a mut self, buf: &'a mut [u8]) -> Self::ReadFuture<'a>; } pub trait ReadUntilIdle { @@ -23,10 +23,7 @@ pub trait ReadUntilIdle { /// Receive into the buffer until the buffer is full or the line is idle after some bytes are received /// Return the number of bytes received - fn read_until_idle<'a>( - self: Pin<&'a mut Self>, - buf: &'a mut [u8], - ) -> Self::ReadUntilIdleFuture<'a>; + fn read_until_idle<'a>(&'a mut self, buf: &'a mut [u8]) -> Self::ReadUntilIdleFuture<'a>; } pub trait Write { @@ -34,5 +31,5 @@ pub trait Write { where Self: 'a; - fn write<'a>(self: Pin<&'a mut Self>, buf: &'a [u8]) -> Self::WriteFuture<'a>; + fn write<'a>(&'a mut self, buf: &'a [u8]) -> Self::WriteFuture<'a>; } -- cgit