#946074 socat: cfmakeraw no longer effective on TTYs

Package:
socat
Source:
socat
Description:
multipurpose relay for bidirectional data transfer
Submitter:
"Paul \"LeoNerd\" Evans"
Date:
2019-12-03 17:51:05 UTC
Severity:
normal
#946074#5
Date:
2019-12-03 17:39:07 UTC
From:
To:
I use a wrapper script around `socat` to neaten the process of
connecting the terminal to a USB serial port:

  $ socat-serial /dev/ttyUSB0
  > socat -,cfmakeraw,escape=0x0f,icrnl /dev/ttyUSB0,cfmakeraw,b19200,cs8,parenb=0,cstopb=0

In a previous version this worked fine.

`cfmakeraw` is supposed to set the terminal into char-at-a-time mode,
sending every keypress as it happens. This does not happen any more;
instead it sends only an entire line after I press ENTER.


As a workaround I can apply

  (stty raw; socat ...)

which puts the terminal into raw mode beforehand.