ttydefs(4) ttydefs(4)
NAME
ttydefs - file contains terminal line settings information for
ttymon
DESCRIPTION
/etc/ttydefs is an administrative file that contains
information used by ttymon to set up the speed and terminal
settings for a TTY port.
The ttydefs file contains sets of flag entries, which indicate
input, output, control, and other settings (see stty). These
settings are stated in five fields, delimited by colons (:)
and flag entries within each field are delimited by spaces, as
in the example.
The fields comprising each line of ttydefs include:
ttylabel Typically, the baud rate for the terminal line,
used as a string to conduct a search for an
acceptable port. ttymon tries to match this
string against the TTY port's ttylabel field in
the port monitor administrative file. ttylabel
usually describes the speed at which the
terminal is supposed to run, for example, 1200.
initial-flags The termio settings to be applied during the
initial phase of login to set and/or unset the
modes to be used on that line. See the Usage
Section below for the original settings
referenced by initial-flags. initial-flags
settings may be used by the system
administrator, for example, to specify what the
default erase and kill characters will be.
initial-flags must be specified in the syntax
recognized by the stty command. Settings to be
turned on have no prefix or are preceded by a
plus sign (+); settings to be turned off are
preceded by a minus sign (-).
final-flags The termio settings used for final-flags are
applied over the initial-flags settings. This
is done by ttymon after a connection request
has been accepted and immediately prior to
invoking a port's service. final-flags must be
specified in the same format as initial-flags,
that is, in the syntax recognized by stty.
Copyright 1994 Novell, Inc. Page 1
ttydefs(4) ttydefs(4)
autobaud If this field contains the character `A',
autobaud will be enabled. Otherwise (if the
field is blank), autobaud is not enabled.
ttymon determines what line speed to set the
TTY port to by analyzing the carriage returns
entered. The hunt sequence indicated in
ttydefs with the nextlabel entry is used for
baud rate determination unless autobaud is
enabled.
nextlabel If the user indicates that the current terminal
setting is not appropriate by sending a BREAK,
ttymon searches for a ttydefs entry whose
ttylabel field matches the nextlabel field. If
a match is found, ttymon uses that field as its
ttylabel field. A series of speeds is often
linked together in this way into a closed set
called a hunt sequence. For example, 4800 may
be linked to 1200, which in turn is linked to
2400, which is finally linked to 4800.
USAGE
The settings provided via ttydefs allow for management of
terminal settings through the various phases of service
start-up.
Original Settings
The initial-flags settings are applied to the following
original values:
Input Modes ignpar istrip icrnl ixon
Control Modes cs7 cread parenb b9600
Output Modes opost onclr
Local Modes isig icanon echo echoe echok
Default Settings
If you use sane to indicate that the ttymon settings in the
port monitor administrative file be used, the following
settings will serve as the values for initial-flags.
Control Modes cs7 parenb cread -parodd -clocal
Copyright 1994 Novell, Inc. Page 2
ttydefs(4) ttydefs(4)
Input Modes brkin tignpar istrip icrnl ixon
-ignbrk -parmrk -inpck -inlcr
-igncr -iuclc -ixoff
Local Modes isig icanon echo echoe -xcase
-echoe -echonl -noflsh -stflush
stwrap -stappl
Output Modes opost onlcr -olcuc -ocrnl -onocr
-onlret -ofill -ofdel -ndly -crdly
-tabdly -bsdly -vtdly -ffdly
Specific values may be restated following the use of sane, as
in the example, to modify these defaults.
Examples
The following is an example of a no-parity 9600-baud entry.
--------------------------------------------------------------------
9600np:9600 ignbrk -parenb:9600 sane ixany tab3 hupcl erase ^h::4800
--------------------------------------------------------------------
ttylabel: 9600np
initial flags: 9600 ignbrk -parenb
final flags: 9600 sane ixany tab3 hupcl erase ^h
autobaud: no
nextlabel: 4800
The example calls for initial-flags to be applied to the
original settings stated above. As a result, the following
flags will be in effect for the initial phase:
Input Modes ignpar istrip icrnl ixon ignbrk
Control Modes cs7 cread b9600
Output Modes opost onclr
Local Modes isig icanon echo echoe echok
(Note that an Input Mode setting of ignbrk is turned on and a
Control Mode setting of parenb is turned off as a result of
the initial-flags settings in the example.)
Also in the example, final-flags uses sane. This results in
applying the default values for sane, listed above. The
settings for final-flags that follow sane (ixany, tab3, and so
Copyright 1994 Novell, Inc. Page 3
ttydefs(4) ttydefs(4)
on) are then applied over the sane defaults.
REFERENCES
stty(1), sttydefs(1M), termio(7), ttymon(1M)
Copyright 1994 Novell, Inc. Page 4