02.07.2013 Views

A/UX® System Administrator's Reference Sections 1M, 7, and 8

A/UX® System Administrator's Reference Sections 1M, 7, and 8

A/UX® System Administrator's Reference Sections 1M, 7, and 8

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

termio(7) termio(7)<br />

NAME<br />

termio - general terminal interface<br />

DESCRIPTION<br />

This section describes both a particular file <strong>and</strong> the terminal interface.<br />

The file / dev / tty is, in each process, the control terminal associated<br />

with the process group of that process. Programs or shell<br />

sequences use it to ensure that their messages appear on the terminal,<br />

no matter how output is redirected. Also, programs that<br />

dem<strong>and</strong> an output filename will accept / dev / tty, so the terminal<br />

being used is unimportant.<br />

The asynchronous communications ports use the same general interface,<br />

no matter what their hardware. This section discusses the<br />

common features of this interface.<br />

When a terminal file is opened, it normally makes the process wait<br />

until it establishes a connection. Users' programs seldom open<br />

these files; getty(IM) opens them <strong>and</strong> they become a user's<br />

st<strong>and</strong>ard input, output, <strong>and</strong> error files. The first terminal file the<br />

process-group leader opens, which is not already associated with a<br />

process group, becomes the control terminal for that process<br />

group. The control terminal plays a special role in h<strong>and</strong>ling quit<br />

<strong>and</strong> interrupt signals, as discussed later. The control terminal is<br />

inherited by a child process during a fork(2). A process breaks<br />

this association by changing its process group (using<br />

setpgrp(2)).<br />

Tenninals associated with one of these files operate in full-duplex<br />

mode. You may type at any time, even while the terminal is printing.<br />

Characters you type are lost only when the system's character<br />

input buffers are full, which is rare, or when you have accumulated<br />

the maximum number of input characters that have not been<br />

read by some program. Currently, this limit is 256 characters.<br />

When you reach the input limit, all the saved characters are<br />

thrown away without notice.<br />

Normally, tenninal input is processed in units of lines. A line is<br />

delimited by a newline (ASCII LF) character, an end-of-file<br />

(ASCII EOn character, or an end-of-line character. This means<br />

that a program cannot read input until you have typed an entire<br />

line. Also, no matter how many characters a read(2) system call<br />

requests, a maximum of one line is returned. It is not, however,<br />

necessary to read a whole line at once; a read can request any<br />

February, 1990<br />

Revision C<br />

1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!