projects
/
libs
/
core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c750a22
)
Tell the TTY driver to not mess with serial port data
author
Mikko Rasa
<tdb@tdb.fi>
Thu, 26 Jul 2012 19:15:28 +0000
(22:15 +0300)
committer
Mikko Rasa
<tdb@tdb.fi>
Thu, 26 Jul 2012 19:30:18 +0000
(22:30 +0300)
source/io/serial.cpp
patch
|
blob
|
history
diff --git
a/source/io/serial.cpp
b/source/io/serial.cpp
index 2ed11ae9fddd900b4ab695a2acc05770deaf5e18..26ef92ed9015ae4f04aa1f96670a38f27dfcacfc 100644
(file)
--- a/
source/io/serial.cpp
+++ b/
source/io/serial.cpp
@@
-181,8
+181,11
@@
Serial::Serial(const string &descr):
termios t;
tcgetattr(*handle, &t);
- t.c_lflag &= ~(ECHO|ICANON);
- t.c_oflag &= ~OPOST;
+ t.c_iflag &= ~(ISTRIP|INLCR|IGNCR|ICRNL|IXON);
+ t.c_lflag &= ~(ECHO|ICANON|ISIG|IEXTEN);
+ t.c_oflag &= ~(OPOST|OCRNL|ONOCR|ONLRET);
+ t.c_cc[VMIN] = 1;
+ t.c_cc[VTIME] = 0;
tcsetattr(*handle, TCSADRAIN, &t);
#endif