Struct se_rs_ial::Connection [-] [+] [src]

pub struct Connection {
    // some fields omitted
}

Methods

impl Connection

fn open(port: &str, baud_rate: BaudRate) -> Result<Connection>

Open a connection through a serial port.

Supported baud rates are: 0, 50, 75, 110, 134, 150, 200, 300, 600, 1200, 1800, 2400, 4800, 9600, 19200, 38400, 57600, 115200, 230400

fn baud_rate(&self) -> Result<BaudRate>

fn set_baud_rate(&mut self, baud_rate: BaudRate) -> Result<()>

fn byte_size(&self) -> Result<ByteSize>

fn set_byte_size(&mut self, byte_size: ByteSize) -> Result<()>

fn parity(&self) -> Result<Parity>

fn set_parity(&mut self, parity: Parity) -> Result<()>

fn stop_bits(&self) -> Result<StopBits>

fn set_stop_bits(&mut self, stop_bits: StopBits) -> Result<()>

Trait Implementations

impl Write for Connection

fn write(&mut self, buf: &[u8]) -> Result<usize>

fn flush(&mut self) -> Result<()>

fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>

fn write_fmt(&mut self, fmt: Arguments) -> Result<(), Error>

fn by_ref(&mut self) -> &mut Self

fn broadcast<W>(self, other: W) -> Broadcast<Self, W> where W: Write

impl Read for Connection

fn read(&mut self, buf: &mut [u8]) -> Result<usize>

fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize, Error>

fn read_to_string(&mut self, buf: &mut String) -> Result<usize, Error>

fn by_ref(&mut self) -> &mut Self

fn bytes(self) -> Bytes<Self>

fn chars(self) -> Chars<Self>

fn chain<R>(self, next: R) -> Chain<Self, R> where R: Read

fn take(self, limit: u64) -> Take<Self>

fn tee<W>(self, out: W) -> Tee<Self, W> where W: Write