40 115200, { 110, 300, 600, 1200, 2400, 4800, 9600, 14400, 19200, 38400, 57600, 115200,
41 230400, 460800, 921600, 1000000, 1152000, 1500000, 2000000,
42 2500000, 3000000, 3500000, 4000000 }, ParamCateg);
46 "8N1", boost::regex(
"^[5-8][NEO][12]$"), ParamCateg);
58 "avoid blocking when writing messages to serial-over-USB port and the host is "
59 "not listening to it. Note that even when drop is false, we will still drop "
60 "data after repeated attempts to send it, and will report an error (as opposed to "
61 "silently dropping when drop is true).",
69 "CRLF is for 0x0d 0x0a [\\r\\n]; Zero is for 0x00 [\\0]; Sloppy accepts any of "
70 "CR, LF, CRLF, 0xd0 (issued by some keyboards instead of Return), and Zero as input "
71 "and issues CRLF in outputs.",
72 LineStyle::Sloppy, LineStyle_Values, ParamCateg);
79 TerminalMode::Plain, TerminalMode_Values, ParamCateg);
86 public Parameter<serial::devname, serial::baudrate, serial::format, serial::flowsoft,
87 serial::flowhard, serial::drop, serial::linestyle, serial::mode>
98 void setBlocking(
bool blocking, std::chrono::milliseconds
const & timeout);
101 void toggleDTR(std::chrono::milliseconds
const & dur);
108 bool readSome(std::string & str)
override;
112 void writeString(std::string
const & str)
override;
117 void fileGet(std::string
const & abspath);
122 void filePut(std::string
const & abspath);
137 void writeInternal(
void const * buffer,
const int nbytes,
bool nodrop =
false);
139 termios itsSavedState;
140 std::string itsPartialString;
142 int itsWriteOverflowCounter;
144 std::atomic<int> itsErrno;
145 std::future<void> itsOpenFut;