SerialDevice

Type Alias SerialDevice 

Source
pub type SerialDevice = SerialWrapper<EventFdTrigger, SerialEventsWrapper, Stdin>;
Expand description

Type for representing a serial device.

Aliased Type§

pub struct SerialDevice {
    pub serial: Serial<EventFdTrigger, SerialEventsWrapper, SerialOut>,
    pub input: Option<Stdin>,
}

Fields§

§serial: Serial<EventFdTrigger, SerialEventsWrapper, SerialOut>

Serial device object.

§input: Option<Stdin>

Input to the serial device (needs to be readable).

Implementations§

Source§

impl SerialDevice

Source

pub fn new( serial_in: Option<Stdin>, serial_out: SerialOut, ) -> Result<Self, Error>