I am using screen to communicate with arduino over serial port, i start screen like this:
screen /dev/ttyACM0 115200
then I try to send a command but every key I press on the keyboard get sent straight away, how to make it wait until I press Enter
key before sending input to arduino?
Here's my serial device /dev/ttyACM0
settings:
$ sudo ssty -F /dev/ttyACM0 -a
speed 115200 baud; rows 0; columns 0; line = 0;
intr = ^C; quit = ^\; erase = ^?; kill = ^H; eof = ^D; eol = <undef>;
eol2 = <undef>; swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R;
werase = ^W; lnext = ^V; discard = ^O; min = 100; time = 2;
-parenb -parodd -cmspar cs8 -hupcl -cstopb cread clocal -crtscts
-ignbrk brkint ignpar -parmrk -inpck -istrip -inlcr -igncr -icrnl ixon -ixoff
-iuclc -ixany -imaxbel -iutf8
-opost -olcuc -ocrnl -onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
-isig -icanon iexten -echo echoe echok -echonl -noflsh -xcase -tostop -echoprt
echoctl echoke -flusho -extproc
My .screenrc
file is empty.
-icanon
indicates canonical (line-based) processing is disabled, so one thing to try would be usingstty
to flip that (thescreen
docs I have don't list a direct means to change that). – thrig Nov 10 '16 at 21:13sudo stty -F /dev/ttyACM0 icanon
but nothing changed. – razzak Nov 10 '16 at 21:20ttyACM0
? (Other options to consider includeminicom
or on OpenBSDcu
is maintained.) – thrig Nov 10 '16 at 21:38