Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ioctl(2)

termio(4V)

STTY(1V)  —  USER COMMANDS

NAME

stty − set the options for a terminal, System V

SYNOPSIS

/usr/5bin/stty [ −a ] [ −g ] [ option ] ...

SYSTEM V DESCRIPTION

Note:Optional Software (System V Option).  Refer to Installing UNIX on the Sun Workstation for information on how to install this command. 

There are two distinct versions of stty: /bin/stty and /usr/5bin/stty.  This manual page describes the latter version. 

/usr/5bin/stty sets certain terminal I/O options for the device that is the current standard input.  Without arguments, it reports the settings of certain terminal options. 

Detailed information about the modes listed in the first five groups below may be found in termio(4V). In the current implementation, the values of certain values cannot be altered, and certain combinations of values are not supported.  These restrictions are given in termio(4V). Note that many combinations of options make no sense, but no sanity checking is performed.

OPTIONS

−a Report all of the option settings. 

−g Report current settings in a form that can be used as an argument to another stty command. 

Control Modes

[−]parenb Enable parity generation and detection.  With a −, disable parity checking. 

[−]parodd
Select odd parity. With a −, select even parity. 

cs7 cs8 Select character size. 

0 Hang up phone line immediately. 

50 75 110 134 150 200 300 600 1200 1800 2400 4800 9600 exta extb
Set terminal baud rate to the number given, if possible. (All speeds are not supported by all hardware interfaces.)

[−]hupcl Hang up connection on last close.  With a −, do not hang up connection. 

[−]hup Same as hupcl. 

[−]cstopb Use two stop bits per character.  With a −, use one stop bit per character. 

[−]cread Enable the receiver.  With a − , disable the receiver. 

[−]clocal Assume a line without modem control.  With a −, assume a line with modem control. 

Input Modes

[−]ignbrk Ignore break on input.  With a −, do not ignore a break on input. 

[−]brkint Signal INTR on break.  With a −, do not signal. 

[−]ignpar Ignore parity errors.  With a −, do not ignore parity errors. 

[−]parmrk
Mark parity errors With a −, do not mark parity errors (always clear). 

[−]inpck Enable input parity checking.  With a −, disable input parity checking. 

[−]istrip Strip input characters to seven bits.  With a −, do not strip input characters. 

[−]inlcr Map NL to CR on input (always clear).  With a −, do not map on input (always clear). 

[−]igncr Ignore CR on input.  With a −, do not ignore CR on input (always clear). 

[−]icrnl Map CR to NL on input.  With a −, do not map. 

[−]iuclc Map upper-case alphabetics to lower case on input.  With a −, do not map. 

[−]ixon Enable START/STOP output control.  With a −, disable output control.  When enabled, output is stopped by sending an ASCII DC3 and started by sending an ASCII DC1. 

[−]ixany Allow any character to restart output.  With a −, only restart with DC1. 

[−]ixoff Request that the system send (not send) START/STOP characters when the input queue is nearly empty/full.  With a −, request that the system not send START/STOP characters. 

Output Modes

[−]opost Post-process output.  With a −, do not post-process output; ignore all other output modes. 

[−]olcuc Map lower-case alphabetics to upper case on output.  With a −, do not map. 

[−]onlcr Map NL to CR-NL on output.  With a −, do not map. 

[−]ocrnl Map CR to NL on output.  With a −, do not map. 

[−]onocr Do not place CRs at column zero.  With a −, do place CRs at column zero (always clear). 

[−]onlret On the terminal NL performs the CR function.  With a −, NL does not perform the CR function. 

[−]ofill Use fill characters for delays.  With a −, use timing for delays (always clear). 

[−]ofdel Fill characters are DELs.  With a −, fill characters are NULs (always clear). 

cr0 cr1 cr2 cr3
Select style of delay for carriage returns.

nl0 nl1 Select style of delay for line-feeds. 

tab0 tab1 tab2 tab3
Select style of delay for horizontal tabs.

bs0 bs1 Select style of delay for backspaces. 

ff0 ff1 Select style of delay for form-feeds. 

vt0 vt1 Select style of delay for vertical tabs. 

Local Modes

[−]isig Enable the checking of characters against the special control characters INTR and QUIT.  With a −, disable this checking. 

[−]icanon Enable canonical input (ERASE and KILL processing).  With a −, disable canonical input. 

[−]xcase Canonical upper/lower-case presentation.  With a −, do not process cases. 

[−]echo Echo back every character typed.  With a −, do not echo back. 

[−]echoe Echo ERASE character as a sequence of backspace-space-backspace.  With a −, do not echo ERASE character. 

[−]echok Echo NL after KILL character.  With a −, do not echo NL after KILL (always set). 

lfkc the same as echok; obsolete. 

[−]echonl Echo NL.  With a −, do not echo (always clear). 

[−]noflsh Disable flush after INTR or QUIT.  With a −, enable flush. 

Control Assignments

control-character c
Set control-character to c, where control-character is one of erase, kill, intr, quit, eof, eol, min ,or time (min and time are used with −icanon) If c is preceded by an (escaped from the shell) caret (^), then the value used is the corresponding CTRL character (e.g., “^d” is a CTRL-d); “^?” is interpreted as DEL and “^−” is interpreted as undefined. 

line i Set line discipline to i (0 < i < 127 ). 

Combination Modes

cooked
Process ERASE, KILL, INTR, QUIT, SWTCH, EOT, and perform output post-processing. 

evenp or parity
Enable parenb and cs7. 

oddp Enable parenb, cs7, and parodd. 

−parity, −evenp, or −oddp
Disable parenb, and set cs8. 

[−]raw Enable raw input and output.  With a −, disable raw I/O.  In raw mode, there is no ERASE, KILL, INTR, QUIT, SWTCH, EOT, or output post-processing. 

[−]nl Unset icrnl, onlcr.  With a −, set them.  In addition −nl unsets inlcr, igncr, ocrnl, and onlret. 

[−]lcase Set xcase, iuclc, and olcuc.  With a −, unset them. 

[−]LCASE Same as lcase (−lcase). 

[−]tabs

tabs3 Preserve TABs when printing. With a −, or with tabs3, expand TABs to spaces. 

ek Reset ERASE and KILL characters back to normal: # and @. 

sane Reset all modes to some reasonable values. 

term set all modes suitable for the terminal type term, where term is one of tty33, tty37, vt05, tn300, ti700, or tek. 

SEE ALSO

ioctl(2), termio(4V)

Sun Release 3.2  —  Last change: 18 July 1986

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026