pub struct AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,{ /* private fields */ }Implementations§
Source§impl<'d> AsyncUartTxDriver<'d, UartTxDriver<'d>>
impl<'d> AsyncUartTxDriver<'d, UartTxDriver<'d>>
pub fn new<UART>(
uart: UART,
tx: impl OutputPin + 'd,
cts: Option<impl InputPin + 'd>,
rts: Option<impl OutputPin + 'd>,
config: &Config,
) -> Result<AsyncUartTxDriver<'d, UartTxDriver<'d>>, EspError>where
UART: Uart + 'd,
Source§impl<'d, T> AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
impl<'d, T> AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
pub fn wrap(driver: T) -> Result<AsyncUartTxDriver<'d, T>, EspError>
pub fn wrap_custom( driver: T, priority: Option<u8>, pin_to_core: Option<Core>, ) -> Result<AsyncUartTxDriver<'d, T>, EspError>
pub fn driver(&self) -> &UartTxDriver<'d>
pub fn driver_mut(&mut self) -> &mut UartTxDriver<'d>
pub async fn write(&self, bytes: &[u8]) -> Result<usize, EspError>
pub async fn wait_done(&self) -> Result<(), EspError>
Trait Implementations§
Source§impl<'d, T> Drop for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
impl<'d, T> Drop for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
Source§impl<'d, T> ErrorType for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
impl<'d, T> ErrorType for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
Source§type Error = EspIOError
type Error = EspIOError
Error type of all the IO operations on this type.
Source§impl<'d, T> Write for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
impl<'d, T> Write for AsyncUartTxDriver<'d, T>where
T: BorrowMut<UartTxDriver<'d>>,
Source§async fn write(
&mut self,
buf: &[u8],
) -> Result<usize, <AsyncUartTxDriver<'d, T> as ErrorType>::Error>
async fn write( &mut self, buf: &[u8], ) -> Result<usize, <AsyncUartTxDriver<'d, T> as ErrorType>::Error>
Write a buffer into this writer, returning how many bytes were written. Read more