From eed17d276f4bdc3936f5b6bdd4565d8bd232e8bc Mon Sep 17 00:00:00 2001 From: bdc Date: Wed, 1 Nov 1995 01:12:42 +0000 Subject: [PATCH] finalized tty-consts.scm baud format --- scsh/aix/tty-consts.scm | 37 +++++--------------------- scsh/bsd/tty-consts.scm | 53 +++++++------------------------------ scsh/irix/tty-consts.scm | 38 +++++--------------------- scsh/linux/tty-consts.scm | 37 +++++--------------------- scsh/next/tty-consts.scm | 42 +++++++---------------------- scsh/solaris/tty-consts.scm | 35 +++++------------------- scsh/sunos/tty-consts.scm | 37 +++++--------------------- 7 files changed, 54 insertions(+), 225 deletions(-) diff --git a/scsh/aix/tty-consts.scm b/scsh/aix/tty-consts.scm index c999f82..036607c 100644 --- a/scsh/aix/tty-consts.scm +++ b/scsh/aix/tty-consts.scm @@ -182,37 +182,14 @@ ;;; SVR4 (define ttyl/case-map #x4) ; xcase: canonical upper/lower presentation -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 8) -(define baud/1200 9) -(define baud/1800 10) -(define baud/2400 11) -(define baud/4800 12) -(define baud/9600 13) -(define baud/19200 14) -(define baud/38400 15) -(define baud/exta 14) ;non-standard -(define baud/extb 15) ;non-standard - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (9600) (19200 exta) - (38400 extb))) +;;; Vector of (speed . code) pairs. +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400) (14 . exta) (15 . extb))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/bsd/tty-consts.scm b/scsh/bsd/tty-consts.scm index b9c0d05..9c8b6b5 100644 --- a/scsh/bsd/tty-consts.scm +++ b/scsh/bsd/tty-consts.scm @@ -181,50 +181,17 @@ ;;; SVR4 (define ttyl/case-map #f) ; xcase: canonical upper/lower presentation -;;; Baud Rates -(define baud/0 0) -(define baud/50 50) -(define baud/75 75) -(define baud/110 110) -(define baud/134 134) -(define baud/150 150) -(define baud/200 200) -(define baud/300 300) -(define baud/600 600) -(define baud/1200 1200) -(define baud/1800 1800) -(define baud/2400 2400) -(define baud/4800 4800) -(define baud/9600 9600) -(define baud/19200 19200) -(define baud/38400 38400) -(define baud/exta 19200) ;non-standard -(define baud/extb 38400) ;non-standard +;;; Vector of (speed . code) pairs. -;; non-standard: -(define baud/7200 7200) -(define baud/14400 14400) -(define baud/28800 28800) -(define baud/57600 57600) -(define baud/76800 76800) -(define baud/115200 115200) -(define baud/230400 230400) - - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - - - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (7200) (9600) - (14400) (19200 exta) (28800) - (38400 extb) (57600) (76800) - (115200) (230400))) +(define baud-rates '#((0 . 0) (50 . 50) (75 . 75) + (110 . 110) (134 . 134) (150 . 150) + (200 . 200) (300 . 300) (600 . 600) + (1200 . 1200) (1800 . 1800) (2400 . 2400) + (4800 . 4800) (7200 . 7200) (9600 . 9600) + (14400 . 14400) (19200 . 19200) (28800 . 28800) + (38400 . 38400) (19200 . exta) (38400 . extb) + (57600 . 57600) (76800 . 76800) (115200 . 115200) + (230400 . 230400))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/irix/tty-consts.scm b/scsh/irix/tty-consts.scm index 57ae481..95a323a 100644 --- a/scsh/irix/tty-consts.scm +++ b/scsh/irix/tty-consts.scm @@ -182,38 +182,14 @@ ;;; SVR4 (define ttyl/case-map #o4) ; xcase: canonical upper/lower presentation +;;; Vector of (speed . code) pairs. -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 #o10) -(define baud/1200 #o11) -(define baud/1800 #o12) -(define baud/2400 #o13) -(define baud/4800 #o14) -(define baud/9600 #o15) -(define baud/19200 #o16) -(define baud/38400 #o17) -(define baud/exta #o16) ; Non-standard -(define baud/extb #o17) ; Non-standard - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (9600) (19200 exta) - (38400 extb))) - +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400) (14 . exta) (15 . extb))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/linux/tty-consts.scm b/scsh/linux/tty-consts.scm index 5012861..2e2796e 100644 --- a/scsh/linux/tty-consts.scm +++ b/scsh/linux/tty-consts.scm @@ -181,37 +181,14 @@ ;;; SVR4 (define ttyl/case-map #o4) ; xcase: canonical upper/lower presentation -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 8) -(define baud/1200 9) -(define baud/1800 10) -(define baud/2400 11) -(define baud/4800 12) -(define baud/9600 13) -(define baud/19200 14) -(define baud/38400 15) -(define baud/exta 14) ;non-standard -(define baud/extb 15) ;non-standard - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (9600) (19200 exta) - (38400 extb))) +;;; Vector of (speed . code) pairs. +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400) (14 . exta) (15 . extb))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/next/tty-consts.scm b/scsh/next/tty-consts.scm index 5c78ab9..7628eef 100644 --- a/scsh/next/tty-consts.scm +++ b/scsh/next/tty-consts.scm @@ -212,40 +212,16 @@ ;;; NOTE: xlcase and xeucbksp are in the NeXT , but don't appear ;;; in the tty(4) or termios(4) man pages. Where are they documented? +;;; Vector of (speed . code) pairs. -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 8) -(define baud/1200 9) -(define baud/1800 10) -(define baud/2400 11) -(define baud/4800 12) -(define baud/9600 13) -(define baud/19200 14) -(define baud/38400 15) -(define baud/exta baud/19200) ; Non-standard -(define baud/extb baud/38400) ; Non-standard -(define baud/14400 16) ; Non-standard -(define baud/28800 17) ; Non-standard -(define baud/43200 18) ; Non-standard -(define baud/57600 19) ; Non-standard - - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) (110) (134) (150) - (200) (300) (600) (1200) (1800) (2400) - (4800) (9600) (19200 exta) (38400 extb) - (14400) (28800) (43200) (57600))) +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400) (14 . exta) (15 . extb) + (16 . 14400) (17 . 28800) (18 . 43200) + (19 . 57600))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/solaris/tty-consts.scm b/scsh/solaris/tty-consts.scm index 6927262..7a83431 100644 --- a/scsh/solaris/tty-consts.scm +++ b/scsh/solaris/tty-consts.scm @@ -181,35 +181,14 @@ ;;; SVR4 (define ttyl/case-map #o4) ; xcase: canonical upper/lower presentation -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 8) -(define baud/1200 9) -(define baud/1800 10) -(define baud/2400 11) -(define baud/4800 12) -(define baud/9600 13) -(define baud/19200 14) -(define baud/38400 15) - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (9600) (19200) - (38400))) +;;; Vector of (speed . code) pairs. +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/scsh/sunos/tty-consts.scm b/scsh/sunos/tty-consts.scm index dd90b32..16ada56 100644 --- a/scsh/sunos/tty-consts.scm +++ b/scsh/sunos/tty-consts.scm @@ -183,37 +183,14 @@ ;;; SVR4 (define ttyl/case-map #x4) ; xcase: canonical upper/lower presentation -;;; Baud Rates -(define baud/0 0) -(define baud/50 1) -(define baud/75 2) -(define baud/110 3) -(define baud/134 4) -(define baud/150 5) -(define baud/200 6) -(define baud/300 7) -(define baud/600 8) -(define baud/1200 9) -(define baud/1800 10) -(define baud/2400 11) -(define baud/4800 12) -(define baud/9600 13) -(define baud/19200 14) -(define baud/38400 15) -(define baud/exta 14) ;non-standard -(define baud/extb 15) ;non-standard - -;;; Rather cheesy mechanism here. -;;; Vector of lists because some OS's define EXTA and EXTB to be -;;; the same code as 19.2k and 38.4k baud. - -(define baud-rates '#((0) (50) (75) - (110) (134) (150) - (200) (300) (600) - (1200) (1800) (2400) - (4800) (9600) (19200 exta) - (38400 extb))) +;;; Vector of (speed . code) pairs. +(define baud-rates '#((0 . 0) (1 . 50) (2 . 75) + (3 . 110) (4 . 134) (5 . 150) + (6 . 200) (7 . 300) (8 . 600) + (9 . 1200) (10 . 1800) (11 . 2400) + (12 . 4800) (13 . 9600) (14 . 19200) + (15 . 38400) (14 . exta) (15 . extb))) ;;; tcflush() constants ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;