Create a new SerialPort instance. The port will be opened and set to raw mode with 9600-8N1.
Sets the baud rate of this port. Usually, the baud rate can only be set to fixed values (common values are 1200 * 2^n).
Returns a string describing this serial port. For example: "ttyS0", "COM1", "cuad0".
Tries to enumerate all serial ports. While this usually works on Windows, it's more problematic on other OS. Posix provides no way to list serial ports, and the only option is searching through "/dev".
expose superclass definition also
Throw an IOException noting the last error.
Return the name of this device.
Return a preferred size for buffering conduit I/O.
Windows-specific code.
Windows-specific code.
Allow adjustment of standard IO handles.
Return the underlying OS handle of this Conduit.
Release the underlying file. Note that an exception is not thrown on error, as doing so can induce some spaggetti into error handling. Instead, we need to change this to return a bool instead, so the caller can decide what to do.
Read a chunk of bytes from the file into the provided array. Returns the number of bytes read, or Eof where there is no further data.
Write a chunk of bytes to the file from the provided array. Returns the number of bytes written, or Eof if the output is no longer available.
Unix-specific code.
Allow adjustment of standard IO handles.
Return the underlying OS handle of this Conduit.
Release the underlying file.
Read a chunk of bytes from the file into the provided array. Returns the number of bytes read, or Eof where there is no further data.
Write a chunk of bytes to the file from the provided array. Returns the number of bytes written, or Eof if the output is no longer available.
Enables applications to use a serial port (aka COM-port, ttyS). Usage is similar to that of File: