2 .\" Copyright 1989 AT&T Copyright (c) 1997 Sun Microsystems, Inc. All Rights Reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH STTYDEFS 1M "Sep 14, 1992"
8 sttydefs \- maintain line settings and hunt sequences for TTY ports
12 \fB/usr/sbin/sttydefs\fR \fB-a\fR \fIttylabel\fR [\fB-b\fR] [\fB-f\fR \fIfinal-flags\fR]
13 [\fB-i\fR \fIinitial-flags\fR] [\fB-n\fR \fInextlabel\fR]
18 \fB/usr/sbin/sttydefs\fR \fB-l\fR [\fIttylabel\fR]
23 \fB/usr/sbin/sttydefs\fR \fB-r\fR \fIttylabel\fR
29 \fBsttydefs\fR is an administrative command that maintains the line settings
30 and hunt sequences for the system's TTY ports by making entries in, and
31 deleting entries from the \fB/etc/ttydefs\fR file.
34 \fBsttydefs\fR with a \fB-a\fR or \fB-r\fR option may be invoked only by the
35 super-user. \fBsttydefs\fR with \fB-l\fR may be invoked by any user on the
40 The following options are supported:
44 \fB\fB-a\fR \fIttylabel\fR\fR
47 Add a record to the \fBttydefs\fR file, using \fIttylabel\fR as its label. The
48 following describes the effect of the \fB-b\fR, \fB-n\fR, \fB-i\fR, or \fB-f\fR
49 options when used in conjunction with the \fB-a\fR option:
58 Enable autobaud. Autobaud allows the system to set the line speed of a given
59 TTY port to the line speed of the device connected to the port without the
66 \fB\fB-f\fR \fIfinal-flags\fR\fR
69 Specify the value to be used in the \fIfinal-flags\fR field in
70 \fB/etc/ttydefs\fR. \fIfinal-flags\fR must be in a format recognized by the
71 \fBstty\fR command. \fIfinal-flags\fR are the \fBtermio\fR(7I) settings used by
72 \fBttymon\fR after receiving a successful connection request and immediately
73 before invoking the service on the port. If this option is not specified,
74 \fBsttydefs\fR will set \fIfinal-flags\fR equal to the \fBtermio\fR(7I) flags
75 \fB9600\fR and \fBsane\fR.
81 \fB\fB-i\fR \fIinitial-flags\fR\fR
84 Specify the value to be used in the \fIinitial-flags\fR field in
85 \fB/etc/ttydefs\fR. \fIinitial-flags\fR must be in a format recognized by the
86 \fBstty\fR command. These flags are used by \fBttymon\fR when searching for the
87 correct baud rate. They are set prior to writing the prompt. If this option is
88 not specified, \fBsttydefs\fR will set \fIinitial-flags\fR equal to the
89 \fBtermio\fR(7I) flag \fB9600\fR.
95 \fB\fB-n\fR \fInextlabel\fR\fR
98 Specify the value to be used in the \fInextlabel\fR field in
99 \fB/etc/ttydefs\fR. If this option is not specified, \fBsttydefs\fR will set
100 \fInextlabel\fR equal to \fIttylabel\fR.
106 \fB\fB-l\fR[\fIttylabel\fR]\fR
109 If a \fIttylabel\fR is specified, \fBsttydefs\fR displays the record from
110 \fB/etc/ttydefs\fR whose TTY label matches the specified \fIttylabel\fR. If no
111 \fIttylabel\fR is specified, \fBsttydefs\fR displays the entire contents of
112 \fB/etc/ttydefs\fR. \fBsttydefs\fR verifies that each entry it displays is
113 correct and that the entry's \fInextlabel\fR field references an existing
119 \fB\fB-r\fR \fIttylabel\fR\fR
122 Remove any record in the \fBttydefs\fR file that has \fIttylabel\fR as its
129 If successful, \fBsttydefs\fR will exit with a status of \fB0\fR.
130 \fBsttydefs\fR \fB-l\fR will generate the requested information and send it to
134 \fBExample 1 \fRA sample of \fBsttydefs\fR command.
137 The following command lists all the entries in the \fBttydefs\fR file and
138 prints an error message for each invalid entry that is detected.
143 example# \fBsttydefs\fR \fB-l\fR
150 The following shows a command that requests information for a single label and
156 example# \fBsttydefs\fR \fB-l\fR 9600
157 ------------------------------------------------------------------
158 9600:9600 hupcl erase ^h:9600 sane ixany tab3 hupcl erase ^h::4800
159 ------------------------------------------------------------------
161 initial flags: 9600 hupcl erase ^h
162 final flags: 9600 sane ixany tab3 hupcl erase ^h
171 The following sequence of commands will add the labels \fB1200\fR, \fB2400\fR,
172 \fB4800\fR, and \fB9600\fR and put them in a circular list:
177 sttydefs \fB-a\fR 1200 \fB-n\fR 2400 \fB-i\fR 1200 \fB-f\fR "1200 sane"
178 sttydefs \fB-a\fR 2400 \fB-n\fR 4800 \fB-i\fR 2400 \fB-f\fR "2400 sane"
179 sttydefs \fB-a\fR 4800 \fB-n\fR 9600 \fB-i\fR 4800 \fB-f\fR "4800 sane"
180 sttydefs \fB-a\fR 9600 \fB-n\fR 1200 \fB-i\fR 9600 \fB-f\fR "9600 sane"
192 \fBattributes\fR(5), \fBtermio\fR(7I)