usart(7) usart(7)
NAME
usart, scc - serial line interfaces
DESCRIPTION
usart and scc each support two RS232 ports to which terminals or
other serial devices may be connected. These are STREAMS devices
(see streamio(7)); thus, if the line discipline module ldterm is
pushed on to the stream, each line will behave as described in
termio(7). In addition, the gls character mapping module may be
pushed on to the stream if so required (see gls(7)).
scc supports all 16 transmission speeds described in termio(7); usart
supports all the speeds except 38400 baud.
The different ports support different modem control lines;
unsupported control lines are regarded by the drivers as being
permanently asserted. The following table shows which control lines
are present on which ports:
Device Port Modem Control Lines
usart A DTR, RTS, CTS, CD, RI
B none
scc A DTR, RTS, CTS, CD
B DTR, RTS, CTS, CD, RI
The meanings of the abbreviated control line names above are as
follows; here, output menas that the line may be asserted by the
driver and input means that the state of the line may be sensed by
the driver.
DTR Data Terminal Ready output
RTS Request to Send output
CTS Clear to Send input
CD Carrier Detect input
RI Ring Indicator input
When a usart or scc file is opened, DTR and RTS are asserted. If
ONDELAY is set (see open(2)), the open will return immediately,
otherwise the open will block until CD is asserted.
Once an open of a port is complete, its default state is as follows:
9600 baud
8 data bits
1 stop bit
no parity
If a port's CD line drops and CLOCAL is not set (see termio(7)), a
message is sent to the stream head with the effect that a HANGUP
signal is sent to each process which has the related file as its
"controlling terminal". Otherwise, if the state of a control line
7/91 Page 1
usart(7) usart(7)
changes, a message is sent to the stream head with the effect that a
SIGPOLL signal will be sent to any processes that have elected to
receive it
If a port's CD line drops and CLOCAL is not set, characters written
to the file may be discarded.
The following ioctl call causes subsequent kernel console diagnostic
messages to appear on the serial line associated with fildes:
ioctl(fildes, KPUTCHAR, 1)
This can be useful if it is required to divert kernel diagnostics to
another port when, for example, a windowing application is running on
the system console.
FILES
The following table shows the default assignment of serial ports to
minor device numbers and special files:
Device Port Minor No Special File
usart A 0 /dev/term/m1
B 1 /dev/term/s1
scc A 0 /dev/term/s2
B 1 /dev/term/m2
SEE ALSO
ldterm(7), gls(7), termio(7).
Page 2 7/91