]> sigrok.org Git - libsigrok.git/commitdiff
sr: turn off canonical mode and echo ion serial ports by default
authorBert Vermeulen <redacted>
Sun, 16 Sep 2012 12:07:21 +0000 (14:07 +0200)
committerBert Vermeulen <redacted>
Tue, 25 Sep 2012 17:53:05 +0000 (19:53 +0200)
hardware/common/serial.c

index 51934ed859114dcaf16f673521eee4a0c07c8f73..0be403af9b87e3a456bd94647382d3a36c1d6dc0 100644 (file)
@@ -316,6 +316,9 @@ SR_PRIV int serial_set_params(int fd, int baudrate, int bits, int parity,
                return SR_ERR;
        }
 
+       /* Some default parameters */
+       term.c_lflag &= ~(ICANON | ECHO);
+
        if (tcsetattr(fd, TCSADRAIN, &term) < 0)
                return SR_ERR;
 #endif