SERIAL++ library: simple serial port access

◆ mode7E1()

void serialport::SerialPort::mode7E1 ( ) const

set 7 data bits, even parity, 1 stop bit

Definition at line 133 of file serialport.cc.

References Mfd.

134  {
135  struct termios options;
136  ::tcgetattr(Mfd, &options);
137  options.c_cflag |= PARENB;
138  options.c_cflag &= ~PARODD;
139  options.c_cflag &= ~CSTOPB;
140  options.c_cflag &= ~CSIZE;
141  options.c_cflag |= CS7;
142  ::tcsetattr(Mfd, TCSANOW, &options);
143  } // void SerialPort::mode7E1() const
int Mfd
file descriptor to this port
Definition: serialport.h:90