13 #include <QApplication>
14 #include <QMessageBox>
16 #include <QtSerialPort/QSerialPort>
17 #include <QtSerialPort/QSerialPortInfo>
28 QSerialPort::SerialPortError sperror)
29 : runtime_error(desc.toStdString())
39 QSerialPort::SerialPortError sperror)
40 : runtime_error(desc.toStdString())
71 case QSerialPort::NoError:
73 case QSerialPort::DeviceNotFoundError:
74 return "No such device";
75 case QSerialPort::PermissionError:
76 return "Permission Denied: Possibly already opened by another process";
77 case QSerialPort::OpenError:
78 return "Device already opened";
79 case QSerialPort::ParityError:
80 return "Hardware detected a parity error";
81 case QSerialPort::FramingError:
82 return "Framing Error";
83 case QSerialPort::BreakConditionError:
84 return "Break Condition Error";
85 case QSerialPort::WriteError:
86 return "I/O Error occurred while writing the data";
87 case QSerialPort::ReadError:
88 return "I/O Error occurred while reading the data";
89 case QSerialPort::ResourceError:
90 return "I/O error: resource unavailable";
91 case QSerialPort::UnsupportedOperationError:
92 return "Unsupported operation error";
93 case QSerialPort::UnknownError:
94 return "Unsupported operation error";
96 return "Unknown error";