This commit is contained in:
2021-08-22 21:46:31 +02:00
parent 72b67feb25
commit ac26fc6bdd
17 changed files with 3293 additions and 8 deletions

View File

@@ -141,8 +141,11 @@ int TimeoutSerial::readChar(int delay)
timeout = posix_time::seconds(delay);
try {
result = read(1);
return static_cast<int>(result[0]);
std::cerr << std::hex << (uint8_t
)result[0] << endl;
return static_cast<u_int8_t>(result[0]);
} catch (boost::system::system_error& e) {
cerr << "EOF" << endl;
return -1;
}
}