SerialPort
braboar
braboar at gmail.com
Thu Sep 20 10:51:52 UTC 2018
I am going to play with serial port read/write, so I fetched
serial-port. After that, I wrote simple program:
auto port_name = "/dev/ttyUSB1";
auto reader = new SerialPort(port_name);
reader.dataBits(DataBits.data8);
reader.stopBits(StopBits.one);
reader.parity(Parity.none);
reader.speed(BaudRate.BR_230400);
string[] income;
reader.read(income);
and the result is
> serial.device.TimeoutException
Can anybody give me a guide of using serial port?
And one more question: how to outline code blocks? ''' or ---
can't help me.
More information about the Digitalmars-d-learn
mailing list