Trait cortex_m::prelude::_embedded_hal_serial_Write

pub trait _embedded_hal_serial_Write<Word> {
    type Error;

    // Required methods
    fn write(&mut self, word: Word) -> Result<(), Error<Self::Error>>;
    fn flush(&mut self) -> Result<(), Error<Self::Error>>;
}
Expand description

Write half of a serial interface

Required Associated Types§

type Error

Write error

Required Methods§

fn write(&mut self, word: Word) -> Result<(), Error<Self::Error>>

Writes a single word to the serial interface

fn flush(&mut self) -> Result<(), Error<Self::Error>>

Ensures that none of the previously written words are still buffered

Trait Implementations§

§

impl<Word, Error> Write for dyn Write<Word, Error = Error>
where Word: From<u8>,

§

fn write_str(&mut self, s: &str) -> Result<(), Error>

Writes a string slice into this writer, returning whether the write succeeded. Read more
1.1.0 · source§

fn write_char(&mut self, c: char) -> Result<(), Error>

Writes a char into this writer, returning whether the write succeeded. Read more
1.0.0 · source§

fn write_fmt(&mut self, args: Arguments<'_>) -> Result<(), Error>

Glue for usage of the write! macro with implementors of this trait. Read more

Implementors§