Credits
- Much of the section "Physical Connection" is from Serial-HOWTO v.
-1.11 (1997) by Greg Hankins (with his permission). His "How Do I Set
-Up A Terminal Connected To My PC?" was incorporated into v1.00 at
-various places. v1.09 has about 25 changes (and error corrections)
-suggested by Alessandro Rubini who reviewed this HOWTO. Jeremy Jon
-Spykerman told me about using a keyboardless terminal as a console for
-a monitorless PC (using ttysnoop). In 2001 (v1.26) I fixed about 25
-typos, etc. found by Alain Cochard:
+
+Greg Hankin's Serial-HOWTO v.1.11 (1997) section "How Do I Set Up A
+Terminal Connected To My PC?" was incorporated into v1.00 at various
+places (with Greg's permission). v1.09 has about 25 changes (and
+error corrections) suggested by Alessandro Rubini who reviewed this
+terminal as a console for a monitorless PC (using ttysnoop). In 2001
+(v1.26) I fixed about 25 typos, etc. found by Alain Cochard. Numerous
+other people have made a suggestion or two or found a few typos.
+Thanks.
Future Plans: You Can Help
Please let me know of any errors in facts, opinions, logic,
@@ -177,45 +182,42 @@ spelling, grammar, clarity, links, etc. But first, if the date is
over a few months old, check to see that you have the latest version.
Please send me any info that you think belongs in this document.
-Starting with version 1.00, a first attempt was made to help people
-set up terminals without recourse to a terminal manual. Much more is
-needed in this respect. One way to solve this problem would be for
-more terminal manufacturers put their manuals on the Internet. Wyse
-has already done so. I suggest that you encourage others to do so (if
-they haven't already). The task of providing information on how to
-configure most terminals in this HOWTO is daunting. There are so many
-different terminals, but there are far fewer models than there used to
-be in the 1980,s so the task is not totally infeasible.
+In order to fully utilize all the features of a certain real terminal,
+one needs the terminal manuals that came with the terminal when it was
+new. If you don't have a manual, this HOWTO may be of some help. One
+way to solve this problem would be for more terminal manufacturers put
+their manuals on the Internet.
Please send me any surplus terminal manuals which you may have,
-especially on terminals made within the past 10 years (but I'll
+especially on terminals made within the past 15 years (but I'll
accept older ones also). Also, you might want to write up something
on a certain terminal to put in the Appendix D: Notes by Brand Name.
New Versions of this HOWTO
New versions of the Text-Terminal-HOWTO should be released every
-year or so. They will be available to browse and/or download at
-LDP mirror sites. For a list of mirror sites see: . Various formats are
-available. If you only want to quickly check the date of the latest
-version look at . The
-version your are currently reading is: v1.39, August 2006 .
+year or so. To get the latest version go to an LDP mirror sites (see:
+). To quickly check the date
+of the latest version look at . The version your are currently
+reading is: v1.40 December 2006 .
-New in Recent Versions:
- For a full revision history going back to the first version in
+For a full revision history going back to the first version in
1998 see the source file (in linuxdoc format) at and click on text.
+- v1.40 Dec. 2006 Picocom is like minicom. Devfs obsolete so removed
+ tts/1, etc. Updated pseudo terminals. More about telnet, ssh, and
+ non-serial port interfaces. IBM terminal emulation over telnet.
+ Kermit for MS does terminal emulation. Ports of minicom to Mac.
+ Fixed/removed broken links. "reset" is an alias for "tset"
- v1.39 Aug. 2006 Typo your -> you're; Termcap Manual = Termcap
Library; Fixed several broken links. Found link to mapchan program.
- v1.38 Feb. 2006 Fixed typos "the the"
- v1.37 Feb. 2006 "file-transfer" cables, typo: VT012=>VT102, url to
Text-Terminal source fixed, not revised every few months anymore,
edited key cleaning
-
- v1.36 Aug. 2004 Typo for "quit", etc. Should be ^\
-
- v1.35 Mar. 2004: Wyse 60 emulator
Related HOWTOs, etc.
@@ -251,45 +253,60 @@ suspect is true (but may not be) ends with 2 question marks: ?? If
you know for sure, let me know.
What is a Terminal ?
- A real terminal consists of a screen and keyboard that one uses to
-communicate remotely with a (host) computer. One uses it just like it
-was a personal computer but the terminal is remote from its host
+
A terminal consists of a screen and keyboard that one uses to
+communicate remotely with a (host) computer. One uses it almost like
+it was a personal computer but the terminal is remote from its host
computer (on the other side of the room or even on the other side of
the world). Programs execute on the host computer but the results
display on the terminal screen. The terminal's computational ability
-is relatively low (otherwise it would be a computer and not a
-terminal). The terminal is generally limited to the ability to
-display what is sent to it (possibly including full-screen graphics)
-and the ability to send to the host what is typed at the keyboard.
+is relatively low compared to the host computer but often the terminal
+is just a personal computer (PC) itself which has been programmed to
+behave like a terminal. It often doesn't allow the user full
+access to either the PC it runs on nor the host it is connected to.
+You'll find this type of terminal at libraries and schools. But some
+terminals permit the user to log into the host computer and provide
+access dependent on the user's status.
-A text-terminal only displays text on the screen without pictures. In
-the days of mainframes from the mid 1970's to the mid 1980's, most
-people used real text-terminals to communicate with computers. They
-typed in programs, ran programs, wrote documents, issued printing
-commands, etc. A cable connected the terminal to the computer (often
-indirectly). It was called a terminal since it was located at the
-terminal end of this cable. Some text-terminals were called "graphic"
-but the resolution was poor and the speed slow by today's standards
-due to the high cost of memory and the limited speed of the
-conventional serial port, etc.
+ What is a Text-Terminal ?
+A text-terminal is a terminal which only displays text on the
+screen without pictures. Today, it's mostly done by PCs which emulate
+the terminals of olden days.
-Today, real terminals are not as common as they once were and most
-people that use terminals use a personal computer to emulate a
-terminal. Almost everyone who uses Linux uses terminal emulation.
-Without X Window, one uses a text interface (virtual terminal). It's
-also called a command line interface. In X Window one can get one or
-more terminal windows (xterm, rxvt, or zterm). All these use software
-to emulate a real terminal.
+Real text terminals
+ In the olden days of mainframes, from the mid 1970's to the mid
+1980's, most people used real text-terminals to communicate with large
+computers. These real text-terminals were neither computers nor
+emulated text-terminals. They consisted only of a screen, keyboard,
+and only enough memory to store a screenfull or so of text (a few
+kilobytes). Users typed in programs, ran programs, wrote documents,
+issued printing commands, etc. A cable connected the terminal to the
+computer (often indirectly). It was called a terminal since it was
+located at the terminal end of this cable. Some text-terminals were
+called "graphic" but the resolution was poor and the speed slow by
+today's standards due to the high cost of memory and the limited speed
+of the conventional serial port, etc.
-A real text-terminal is different from a monitor because it's a different
-electronic setup. A text terminal is often connected to a serial port
-of the computer via a long cable. Thus, in contrast to a monitor
-which is usually located right next to the computer, a terminal may be
-quite a distance away from its host computer. For a monitor, the
-video card inside a computer stores the video image. For a terminal,
-the equivalent of this video card is built right into the terminal but
-since text terminals are often monochrome without much graphics, the
-capabilities of its "video card" are rather weak. Also, most text
+Today, real terminals are becoming rarities and most people that use
+terminals use a personal computer to emulate a terminal. Almost
+everyone who uses Linux uses terminal emulation. When you are not
+using an X Window GUI at a Linux PC, you are likely using a text
+interface (virtual terminal). It's also called a command line
+interface. In X Window one can also get one or more terminal windows
+(xterm, rxvt, or zterm). All these use software to emulate a real
+terminal.
+
+A real text-terminal is different from a monitor because the simple
+character images that get displayed on the text-terminal are stored
+right inside the terminal in it's memory. For a monitor, the complex
+images are stored in the video card of the PC and/or in the PC's
+memory itself. The text-terminal's keyboard plugs into the the
+terminal and is part of the terminal while a PC's keyboard plugs into
+the computer.
+
+For a monitor, the video images are sent by a short cable running from
+the video card to the monitor while for a text-terminal there is a
+bi-directional flow of character bytes in a long cable between the
+computer's serial port and the PC it's connected to. Most text
terminals do not have mice.
In network client-server terminology, one might think that the
@@ -297,14 +314,15 @@ terminal is the client and that the host computer is the server. The
terminal has been called a "thin client" by some. But it is not
actually a "client" nor is the host a "server". The only "service"
the host provides is to receive every letter typed at the keyboard and
-react to this just like a computer would. The terminal is like a
-window into the computer just like a monitor (and keyboard) are. You
-may have already used virtual terminals in Linux (by pressing Left
-Alt-F2, etc.). A real terminal is just like running such a virtual
-terminal but you run it on its own terminal screen instead of having
-to share the monitor screen. In contrast to using a virtual terminal
-at the console (monitor), this allows another person to sit at a
-terminal and use the computer simultaneously with others.
+react to this just like a computer would if you typed at its keyboard.
+The terminal is like a window into the computer just like a monitor
+(and keyboard) are. You may have already used virtual terminals in
+Linux (by pressing Left Alt-F2, etc.). A real terminal is just like
+running such a virtual terminal but you run it on its own terminal
+screen instead of having to share the monitor screen. In contrast to
+using a virtual terminal at the console (monitor), this allows another
+person to sit at a terminal and use the same computer simultaneously
+with others.
Types of Terminals
@@ -328,11 +346,11 @@ computer and the terminal takes place over the cable that connects
them together. This flow is in bytes (such as ASCII) where each byte
usually represents a printable character. Bytes typed at the keyboard
go to the computer and most bytes from the computer are displayed on
-the terminal screen. Special control bytes (or sequences of bytes) from the
-computer tell the terminal where to move the cursor to, what to erase,
-where to begin and end underlining and/or blinking and/or bold, etc.
-There are often hundreds of such special commands and most terminals
-can even change fonts.
+the terminal screen. Special control bytes (or sequences of bytes)
+from the computer tell the terminal where to move the cursor to, what
+to erase, where to begin and end underlining and/or blinking and/or
+bold, etc. There are often hundreds of such special commands and most
+terminals can even change fonts.
The communication uses characters (letters) encoded using a code chart
for the character set being used. Usually, the first 128 bytes out of
@@ -363,12 +381,13 @@ characters) is sent to the computer all at once. Block mode (as of
late 1998) is not supported by Linux. See section [.
-] Graphic GUI Capabilities of Text Terminals
- Many text terminals can display bit-mapped images, but not in
-color. Unfortunately, the popular image formats used on the Internet
-are not supported. The protocols for terminal graphics include:
-Tektronix Vector Graphics, ReGIS (DEC), Sixel (DEC), and NAPLPS (North
-American Presentation Level Protocol Syntax).
+ Graphic GUI Capabilities of Text Terminals
+ Many text
+terminals can display bit-mapped images, but not in color.
+Unfortunately, the popular image formats used on the Internet are not
+supported. The protocols for terminal graphics include: Tektronix
+Vector Graphics, ReGIS (DEC), Sixel (DEC), and NAPLPS (North American
+Presentation Level Protocol Syntax).
Even without bit-mapped images, ordinary text terminals can sort of
display images. One may form arrows <--- and draw boxes with |__|,
@@ -379,10 +398,11 @@ term "graphics terminal" usually means a terminal that can display bit
mapped images. However, this term is sometimes applied also to
text-only terminals since text is a limited form of graphics.
- Graphics GUI displays
- There are two basic types of graphics displays: raster and vector
-(rarely used). Raster graphics (bit-mapped) puts dots on the screen
-by horizontal scan lines drawn by an electron beam (or by activating
+ Graphics GUI displays
+ There
+are two basic types of graphics displays: raster and vector (rarely
+used). Raster graphics (bit-mapped) puts dots on the screen by
+horizontal scan lines drawn by an electron beam (or by activating
pixels or dots on a flat screen). Vector graphic displays were
intended to be used for monochrome screens that don't have any dots.
They use smart electronics to draw lines and curves with an electron
@@ -396,9 +416,9 @@ lines due to the electronic limitations but they can be translated to
raster graphics format for display (with a resulting drop in image
quality).
- Thin Clients (Terminals ?)
+ Thin Clients Terminals
- Introduction
+ Introduction
Since "thin clients" are not text terminals, this HOWTO only
provides a brief overview of them. There are other HOWTOs that cover
them in more detail. See [
+Terminal" which runs under MS servers (and software). Another type is
+the "network computer" which is supposed to be platform neutral. This
+implies they should work with both MS Windows and Linux but early
+models may not be easy to use with Linux. For Linux, the X Window
+protocol is used. See ][
-] MS Window terminals
-These are true terminals since all the computing work is done by
-a server running Windows. They are also called "Window-based
-Terminals" (WBT). These terminals (clients) are something like
-computers since they often run an embedded operating system such as
-Linux or Microsoft's CE, NT, or XP. It's often stored in flash memory
-so that it may be updated. Also, ordinary PCs can be used as clients
-(including, in some cases, Linux PCs) with the appropriate software,
-Some clients can support X Window (from a Linux server) and some can
-emulate text-terminals. Many so called "network computers" can also
-run X Window. This will be discussed in the next section.
+ MS Window terminals
+These are true terminals since all the
+computing work is done by a server running Windows. They are also
+called "Window-based Terminals" (WBT). These terminals (clients) are
+something like computers since they often run an embedded operating
+system such as Linux or Microsoft's CE, NT, or XP. It's often stored
+in flash memory so that it may be updated. Also, ordinary PCs can be
+used as clients (including, in some cases, Linux PCs) with the
+appropriate software, Some clients can support X Window (from a Linux
+server) and some can emulate text-terminals. Many so called "network
+computers" can also run X Window. This will be discussed in the next
+section.
The server for these clients usually runs MS's Terminal Services (for
Windows 2000 servers). Prior to this there was Windows NT Terminal
Server Edition (starting mid 1998 with codename "Hydra"). MS uses RDP
-(Remote Desktop Protocol) which is based on the ITU T.120 protocol.
+(Remote Desktop Protocol) which is based on the ITU T.120 protocol.
In addition, there is an optional ICA protocol (with added features)
which can inter-operate with RDP.
@@ -479,30 +500,30 @@ system.
PCs running Linux can be turned into ICA based client terminals using
"free" (in price only) proprietary ICA client software from Citrix:
-. Unfortunately, MS requires that you
-purchase a license to cover the clients, even if the clients all run
-Linux. So if you want to save money on software costs by using Linux,
-you'll have to go all-Linux and use both Linux servers and clients
-using the free X-Window protocol.
+. Unfortunately, MS requires that you purchase a
+license to cover the clients, even if the clients all run Linux. So
+if you want to save money on software costs by using Linux, you'll
+have to go all-Linux and use both Linux servers and clients using the
+free X-Window protocol.
The above is sometimes called "network computing" since the terminals
and servers connect to each other over a network (such as the common
TCP/IP based network used by both Linux and MS). Network computers
may be somewhat different as described below.
- Network computers (NCs)
-These are neither true computers nor true terminals but are
-something in-between. One type of network computer (NC's) is a
-computer with a CPU but no hard Disk. The OS it needs to run is sent
-to it over a network. NCs are full-graphics and use the services of a
-server computer. They are a little different from terminals since
-some (or most) of the programs they run may execute on their own CPU
-chip. Running a browser was supposed to be one of their primary
-functions and thus Java code applets may be sent to them for
-execution. Many NCs support X Window so that one may use a Linux
-server to support it. Such a server may be called a "Linux Terminal
-Server". IBM called their NC a "NetStation" but now calls it
+ Network computers (NCs)
+These are neither true computers
+nor true terminals but are something in-between. One type of network
+computer (NC's) is a computer with a CPU but no hard Disk. The OS it
+needs to run is sent to it over a network. NCs are full-graphics and
+use the services of a server computer. They are a little different
+from terminals since some (or most) of the programs they run may
+execute on their own CPU chip. Running a browser was supposed to be
+one of their primary functions and thus Java code applets may be sent
+to them for execution. Many NCs support X Window so that one may use
+a Linux server to support it. Such a server may be called a "Linux
+Terminal Server". IBM called their NC a "NetStation" but now calls it
"NetVista". They should work on Intranet type networks and NetVista
can run the Linux OS.
@@ -510,15 +531,16 @@ Wintel came out with a "NetPC" which, unlike the above, is almost a PC
computer. However, it has no removable disks so users can't install
their own software or obtain copies of anything.
- Thin clients and NCs under Linux
- There is a "Linux Terminal Server Project" (LTSP or ltsp) to use
-Linux as a server for diskless thin clients. They use X Window and by
-default, applications run on the server. But with additional effort,
-one can set it up so that some or all applications run on the
-"terminal". See .
+ Thin clients and NCs under Linux There is a "Linux Terminal Server
+Project" (LTSP or ltsp) to use Linux as a server for diskless thin
+clients. They use X Window and by default, applications run on the
+server. But with additional effort, one can set it up so that some or
+all applications run on the "terminal". See .
-"Terminal" in LTSP is actually a thin (or fat) client. This
-project's client can also run a telnet session and thus behave like a
+"Terminal" in LTSP is actually a thin (or fat) client. This project's
+client can also run a telnet session and thus behave like a
text-terminal. A software package named "lts" for the LTSP is
available in the major Linux distributions.
@@ -533,9 +555,8 @@ are connected to each other via a network, then a person on one
computer can run programs on another computer. Such a program sends
messages over the network so that it appears just like a program was
being run by your local computer. But such a program is actually
-being run on another computer on the network. It works also with
-X Window so that one may see GUI images generated on another
-computer.
+being run on another computer on the network. It works also with X
+Window so that one may see GUI images generated on another computer.
Linux also allows a computer to be diskless and boot over a network.
See the "Terminal Server Project" above which has special software for
@@ -568,25 +589,21 @@ X Window terminal.
There are some Linux HOWTOs for certain brands of NCs:
-
-- JavaStation-HOWTO (by Sun)
-
- NC-HOWTO (IBM NetStation)
-
- NCD mini-HOWTO (NCD-ThinSTAR)
-
- NCD-X-Terminal mini-HOWTO
-
- XDM-and-X-Terminal mini-HOWTO
-
+ - JavaStation-HOWTO (by Sun)
- NC-HOWTO (IBM
+NetStation)
- NCD mini-HOWTO (NCD-ThinSTAR)
- NCD-X-Terminal
+mini-HOWTO
- XDM-and-X-Terminal mini-HOWTO
- Hardware hookups
- There are 3 different types of hardware arrangements for thin
-clients. The first type just uses a PC computer as a thin client by
-emulating a thin client. It really isn't a thin client but it behaves
-like one. The second type looks just like a text-terminal. It just
-looks like a monitor, with a connector for a keyboard and another
-connector for a network cable. It's a dedicated thin client and can't
-be used for anything else. The third type looks like a tiny computer.
-It uses a standard PC monitor and keyboard both of which plug into a
-small box which is a "thin" computer. This box provides an interface
-between the monitor/keyboard and the network.
+ Hardware hookups
+ There are 3 different types of hardware
+arrangements for thin clients. The first type just uses a PC computer
+as a thin client by emulating a thin client. It really isn't a thin
+client but it behaves like one. The second type looks just like a
+text-terminal. It just looks like a monitor, with a connector for a
+keyboard and another connector for a network cable. It's a dedicated
+thin client and can't be used for anything else. The third type looks
+like a tiny computer. It uses a standard PC monitor and keyboard both
+of which plug into a small box which is a "thin" computer. This box
+provides an interface between the monitor/keyboard and the network.
History and the future
Promoters of NCs and related Window-Terminals projected that they
@@ -629,16 +646,16 @@ To install a terminal, first look in /etc/termcap or
terminfo.src to find an entry for it (see [). Figure out what serial port
you'll connect it to and what the tty designation is for that port
-(e.g. ttyS1 or tts/1), see ][).
-As the root user, edit ]/etc/inittab and add a getty command
-next to the other getty commands. The format of the getty command
-depends on which getty program you use. ).
+e.g. ttyS1, see [). As the
+root user, edit ]/etc/inittab and add a getty command next to
+the other getty commands. The format of the getty command depends on
+which getty program you use. ).
Then physically connect the main serial port of the terminal to the
chosen serial port of the computer with a file-transfer (null modem)
@@ -653,21 +670,21 @@ see [.
]Why Use a Terminal ?
- Intro to Why Use a Terminal
- PC's are so powerful today that just one PC can often support
-several persons using it at once, especially if they are doing
-low-load tasks such as text editing, data entry, etc. One way to do
-this is to connect a number of terminals to a single PC (or other host
-computer) by modems or direct cable connection. To do this, it's
-usually best to have a multi-user operating system such as Linux so
-that each user at a terminal can use the computer independently. This
-has been called "time sharing" but it's not good terminology today
-since "distributed" computing over a network is also a type of time
-sharing. It might be better described as "centralized" computing.
-But the central computer may be connected to the rest of the world via
-a network so that terminal users may send email, browse the Internet
-with the lynx browser, etc. So it's not exactly "centralized"
-either.
+ Intro to Why Use a Terminal
+ PC's are so powerful today
+that just one PC can often support several persons using it at once,
+especially if they are doing low-load tasks such as text editing, data
+entry, etc. One way to do this is to connect a number of terminals to
+a single PC (or other host computer) by modems or direct cable
+connection. To do this, it's usually best to have a multi-user
+operating system such as Linux so that each user at a terminal can use
+the computer independently. This has been called "time sharing" but
+it's not good terminology today since "distributed" computing over a
+network is also a type of time sharing. It might be better described
+as "centralized" computing. But the central computer may be connected
+to the rest of the world via a network so that terminal users may send
+email, browse the Internet with the lynx browser, etc. So it's not
+exactly "centralized" either.
Terminals have seldom been used with PC's because the popular
operating systems used for them (Windows, DOS, and Mac) were not
@@ -678,12 +695,12 @@ with PC's becomes more feasible. The drawback is that text terminals
are not smart enough to support the type of graphical user interface
(GUI) that many computer users today normally expect.
- Lower Hardware Costs ?
- When Computers (including PCs) were quite expensive, lower hardware
-costs was a significant advantage of using terminals. Today with
-cheap PCs, the cost savings is problematical. Here's what I wrote
-years ago when PCs were more expensive. It's still true today but of
-less significance.
+ Lower Hardware Costs ?
+ When Computers (including PCs)
+were quite expensive, lower hardware costs was a significant advantage
+of using terminals. Today with cheap PCs, the cost savings is
+problematical. Here's what I wrote years ago when PCs were more
+expensive. It's still true today but of less significance.
If several people use the same computer as the same time, there is a
reduction in the amount of hardware needed for the same level of
@@ -711,104 +728,104 @@ computer.
For a fair comparison with PC's, the terminals should have the same
capabilities as the PC monitors. Unfortunately, color graphic
terminals for Linux (X Window) with high speed communication cost
-about as much as a PC so in this case there not much (if any)
-savings in hardware costs. But for text terminals there will be some
-savings, especially if the terminals are obtained used at low cost.
+about as much as a PC so in this case there not much (if any) savings
+in hardware costs. But for text terminals there will be some savings,
+especially if the terminals are obtained used at low cost.
- Control of Software
- For centralized computing, software (and the updates to software)
-only need be installed and configured on one host computer instead of
-several. The person in charge of this computer may control and
-configure the software which is installed on it. This is advantageous
-if the person controlling the host computer does an excellent job and
-knows about the needs and preferences of the other users. Users can
-be restricted in playing games or surfing the Internet by not
-installing the software (or by otherwise restricting access to it).
-Whether or not centralized control is desirable depends on the
-situation.
+ Control of Software
+ For centralized computing, software
+(and the updates to software) only need be installed and configured on
+one host computer instead of several. The person in charge of this
+computer may control and configure the software which is installed on
+it. This is advantageous if the person controlling the host computer
+does an excellent job and knows about the needs and preferences of the
+other users. Users can be restricted in playing games or surfing the
+Internet by not installing the software (or by otherwise restricting
+access to it). Whether or not centralized control is desirable
+depends on the situation.
- Hardware Upgrades
- With terminals, the computer hardware upgrades take place on only
-one computer instead of many. This saves installation labor effort.
-While the cost of the hardware for the host computer upgrade will be
-more than that for a single PC (since the host needs more computing
-power than a PC), the cost will be significantly less than upgrading
-the hardware of a number of PC's being used instead of terminals.
+ Hardware Upgrades
+ With terminals, the computer hardware
+upgrades take place on only one computer instead of many. This saves
+installation labor effort. While the cost of the hardware for the
+host computer upgrade will be more than that for a single PC (since
+the host needs more computing power than a PC), the cost will be
+significantly less than upgrading the hardware of a number of PC's
+being used instead of terminals.
- Other Advantages of Terminals
-
-- The elimination of noise from fans and disk drives (unless
-you're using a PC to emulate a terminal).
-
- The users of the terminals can share data and files
-and send e-mail to each other. It's similar to a local network.
-
+ Other Advantages of Terminals
+ - The
+elimination of noise from fans and disk drives (unless you're using a
+PC to emulate a terminal).
- The users of the terminals can
+share data and files and send e-mail to each other. It's similar to a
+local network.
- Major Disadvantages of Terminals
-
-- Text terminals have no high-speed graphic display (or high
- resolution graphics) although they can often use graphic character
- sets to draw boxes, etc. This lack limits the software that may be
- used on it.
+
Major Disadvantages of Terminals
+ - Text
+terminals have no high-speed graphic display (or high resolution
+graphics) although they can often use graphic character sets to draw
+boxes, etc. This lack limits the software that may be used on it.
- If the host computer goes down, then no one can use the
- terminals either (unless there is a "standby" host computer to connect to).
-
+terminals either (unless there is a "standby" host computer to connect
+to).
- Are Text Terminals Obsolete ?
- Text terminals are technologically obsolete because for a slightly
-higher cost of hardware, one could build a smarter terminal (with the
-same quality of display). This wasn't always the case since around
-1980 memory cost thousands of dollars per megabyte. Today with low
-costs for memory and processors, one could turn a text terminal into a
-GUI graphic terminal for only about a 10% or 20% increase in hardware
-cost. Since a PC can emulate a terminal, almost everyone using
-computers has a terminal emulator available.
+ Are Text Terminals Obsolete ?
+ Text terminals are
+technologically obsolete because for a slightly higher cost of
+hardware, one could build a smarter terminal (with the same quality of
+display). This wasn't always the case since around 1980 memory cost
+thousands of dollars per megabyte. Today with low costs for memory
+and processors, one could turn a text terminal into a GUI graphic
+terminal for only about a 10% or 20% increase in hardware cost. Since
+a PC can emulate a terminal, almost everyone using computers has a
+terminal emulator available.
-The reasons that text terminals are not fully obsolete are:
-
+The reasons that text terminals are not fully obsolete are:
- The resolution of characters on the screen is better on
-monochrome terminals than for monitors in text mode.
-
- Many people don't need full screen graphics.
-
- Since running a text-terminal (in contrast to a GUI-graphics
-terminal) doesn't consume much of a modern PC's resources, a large
-number of terminals may be efficiently run from one PC.
-
+monochrome terminals than for monitors in text mode. - Many
+people don't need full screen graphics.
- Since running a
+text-terminal (in contrast to a GUI-graphics terminal) doesn't consume
+much of a modern PC's resources, a large number of terminals may be
+efficiently run from one PC.
Overview of How Terminals Work (in Linux)
See also section [
-] Device Names
- Each terminal is connected to a serial port on the host computer
-(often just a PC). The ports have names/numbers. The first few are: tts/0
-(or ttyS0), tts/1 (or ttyS1), tts/2 (or ttyS2) etc.
+ Device Names
+ Each terminal is
+connected to a serial port on the host computer (often just a PC).
+The ports have names/numbers. The first few are: ttyS0, ttyS1, ttyS2,
+etc.
These are represented by special files found in the /dev (device)
-directory. tts/0 (or ttyS0) corresponds to COM1 in DOS or Windows.
-tts/1 (or ttyS1) is COM2, etc. See [ for details on these and related "devices".
+directory. ttyS0) corresponds to COM1 in DOS or Windows. ttyS1) is
+COM2, etc. See ][ for
+details on these and related "devices".
-] Login/Logout
- When the host computer starts up it runs the program getty. The
-getty program runs the "login" program to log people in. See [. A "login:" prompt
-appears on the screen. People at the terminals log in (after giving
-their passwords) and then have access to the computer. When it's time
-to shut the terminal down, one normally logs out and turns the
-terminal off. See ][
-regarding restricting logins (including allowing the root user to log
-in at terminal).
+] Login/Logout
+ When the host computer starts up it runs the
+program getty. The getty program runs the "login" program to log
+people in. See [.
+A "login:" prompt appears on the screen. People at the terminals log
+in (after giving their passwords) and then have access to the
+computer. When it's time to shut the terminal down, one normally logs
+out and turns the terminal off. See ][ regarding restricting logins (including allowing the
+root user to log in at terminal).
-] Half/Full Duplex
- If one watches someone typing at a terminal, the letters one types
-simultaneously appear on the screen. A naive person might think that
-what one types is being sent directly from the keyboard to the screen
-with a copy going to the computer (half-duplex like, see next
-paragraph). What is usually going on is that what is typed at the
-keyboard is directly sent only to the host computer which in turn
-echoes back to the terminal each character it receives (called
-full-duplex). In some cases (such as passwords or terse editor
-commands) the typed letters are not echoed back.
+ Half/Full Duplex
+ If one watches
+someone typing at a terminal, the letters one types simultaneously
+appear on the screen. A naive person might think that what one types
+is being sent directly from the keyboard to the screen with a copy
+going to the computer (half-duplex like, see next paragraph). What is
+usually going on is that what is typed at the keyboard is directly
+sent only to the host computer which in turn echoes back to the
+terminal each character it receives (called full-duplex). In some
+cases (such as passwords or terse editor commands) the typed letters
+are not echoed back.
Full-duplex means that there are two (dual) one-way communication
links. Full-duplex is the norm for terminals. Half-duplex is half of
@@ -820,25 +837,27 @@ send to it) so the terminal would need to also send each character you
type directly to the terminal screen. Some terminals have a
half-duplex mode of operation which is seldom used.
- Terminal Memory
- The image on a CRT tube will fade away almost instantly unless it
-is frequently redrawn on the screen by a beam of electrons shot onto
-the face of the tube. Since text sent to a terminal needs to stay
-on the screen, the image on the screen must be stored in the memory
-chips of the terminal and the electron beam must repeatedly scan the
-screen (say 60 times per second) to maintain the image. See [ for more details.
+] Terminal Memory
+ The image on a CRT tube will fade away
+almost instantly unless it is frequently redrawn on the screen by a
+beam of electrons shot onto the face of the tube. Since text sent to
+a terminal needs to stay on the screen, the image on the screen must
+be stored in the memory chips of the terminal and the electron beam
+must repeatedly scan the screen (say 60 times per second) to maintain
+the image. See [ for more details.
-] Commands for the Terminal
- The terminal is under the control of the computer. The computer
-not only sends the terminal text to display on the screen but also
-sends the terminal commands which are acted on. These are [ (bytes) and ][. For example, the CR (carriage return)
-control code moves the cursor to the left hand edge of the screen. A
-certain escape sequence (several bytes where the first byte is the
-"escape" control code) can move the cursor to the location on the
-screen specified by parameters placed inside the escape sequence.
+] Commands for the Terminal
+ The terminal is under the
+control of the computer. The computer not only sends the terminal
+text to display on the screen but also sends the terminal commands
+which are acted on. These are [ (bytes) and ][. For
+example, the CR (carriage return) control code moves the cursor to the
+left hand edge of the screen. A certain escape sequence (several
+bytes where the first byte is the "escape" control code) can move the
+cursor to the location on the screen specified by parameters placed
+inside the escape sequence.
The ][ had only a few such
commands but modern terminals have hundreds of them. The appearance
@@ -851,19 +870,20 @@ of the screen may be erased. Various types of flow control may be
used to stop the flow of data when bytes are being sent to the
terminal faster than the terminal can handle them. There are many
more as you will see from looking over an advanced terminal manual or
-from the Internet links ][
+from the Internet links ][
-] Lack of Standardization Solved by Terminfo
- While terminals made for the US all used the same ASCII code for
-the alphabet (except for IBM terminals which used EBCDIC), they
-unfortunately did not all use the same escape sequences. This
-happened even after various ANSI (and ISO) standards were established
-since these standards were never quite advanced enough. Furthermore,
-older terminals often lacked the capabilities of newer terminals.
-This might cause problems. For example, the computer might send a
-terminal an escape sequence telling it to split the screen up into
-two windows of specified size, not realizing that the terminal was
-incapable of doing this.
+ Lack of Standardization Solved by Terminfo
+ While terminals
+made for the US all used the same ASCII code for the alphabet (except
+for IBM terminals which used EBCDIC), they unfortunately did not all
+use the same escape sequences. This happened even after various ANSI
+(and ISO) standards were established since these standards were never
+quite advanced enough. Furthermore, older terminals often lacked the
+capabilities of newer terminals. This might cause problems. For
+example, the computer might send a terminal an escape sequence telling
+it to split the screen up into two windows of specified size, not
+realizing that the terminal was incapable of doing this.
To overcome these problems a database called "termcap" (meaning
"terminal capabilities") was established. Termcap was later
@@ -880,25 +900,25 @@ certain C-Library functions. One large set of such programs (over
"ncurses" which comes with a developer's ncurses package. There is
also a NCURSES-programming-HOWTO.
- The Interface
- The environment variable TERM is the type of terminal Linux thinks
-you are using. Most application programs use this to look up the
-capabilities in the terminfo database so TERM needs to be set
-correctly. But there is more to a correct interface than the
-computer knowing about the capabilities of the terminal.
+ The Interface
+ The environment variable TERM is the type of
+terminal Linux thinks you are using. Most application programs use
+this to look up the capabilities in the terminfo database so TERM
+needs to be set correctly. But there is more to a correct interface
+than the computer knowing about the capabilities of the terminal.
For bytes to flow from the computer to the terminal the terminal must
be set to receive the bytes at the same baud rate (bits per second) as
-they are sent out from the terminal. If the terminal is set to receive at
-19,200 baud and the computer sends out characters at 9600 baud, only
-garbage (or perhaps nothing) will be seen on the screen. One selects
-the baud rate for a terminal (as well as many other features) from the
-terminals "set-up" menus at the terminal. Most terminals have a large
-number of options in their "set-up" menus (see [).
-The computer serial port has options also and these options must be
-set up in a compatible way (see ][.
+they are sent out from the terminal. If the terminal is set to
+receive at 19,200 baud and the computer sends out characters at 9600
+baud, only garbage (or perhaps nothing) will be seen on the screen.
+One selects the baud rate for a terminal (as well as many other
+features) from the terminals "set-up" menus at the terminal. Most
+terminals have a large number of options in their "set-up" menus (see
+][). The computer serial port has options also and these
+options must be set up in a compatible way (see ][.
] Emulation
@@ -954,16 +974,13 @@ should be included with kernel sources. It "describes" what each
device used for in only a word or two but doesn't tell you how to use
them.
- Serial Port Terminals
- The computer considers each serial port to be a "device". It's
-sometimes called a terminal device since at one time terminals were
-the most common use for a serial port. For each such serial port
-there is a special file in the /dev (device) directory. /dev/tts/0
-(or /dev/ttyS0) is the special file for the serial port known as COM1
-in the DOS/Windows world. The device filesystem notation: tts/0 is
-replacing the older ttyS0 notation. But the older notation will be
-often used in this howto since it is still widely used and often
-still works (using symbolic links) on the newer device filesystems.
+ Serial Port Terminals
+ The computer considers each serial
+port to be a "device". It's sometimes called a terminal device since
+at one time terminals were the most common use for a serial port. For
+each such serial port there is a special file in the /dev (device)
+directory. /dev/ttyS0) is the special file for the serial port known
+as COM1 in the DOS/Windows world.
To send text to a terminal you may redirect standard output of some
command-line command to the appropriate special file. For example
@@ -975,58 +992,52 @@ permission on /dev/ttyS1. Similarly, typing "cat my_file >
Pseudo Terminals
- Pseudo terminals are pairs of devices such as /dev/pty/m3
-and /dev/pty/s3 (or respectively /dev/ptyp3 and /dev/ttyp3 if you're
-not using the device filesystem). There is no physical device
-directly associated with either of them, not even a serial port
-connector. But if a program treats s3 (ttyp3) like it was a serial
-port, what is read and written to that port appears on the other
-member of the pair m3 (ptyp3) which another program uses to read and
-write to. Thus two programs talk to each other via this method and
-one program (on s3=ttyp3) thinks it's talking to a serial port. It's
-something like a "pipe" between m3 and s3.
+
Pseudo terminals are pairs of devices such as /dev/ptyp3 and
+/dev/ttyp3. There is no physical device directly associated with
+either of them, not even a serial port connector. But if a program
+treats ttyp3 like it was a serial port, what is read and written to
+that port appears on the other member of the pair ptyp3 which another
+program uses to read and write to. Thus two programs talk to each
+other via this method and one program on ttyp3 thinks it's talking to
+a serial port. It's something like a "pipe" between these two tty's.
-For talking to s3 (ttyp3), any program designed to talk to a serial
-port will do. But for the other program that talks to m3 (ptyp3), it
-must have been specially written to talk to m3. It's mainly
-programmers that must concern themselves with pseudo terminals and
-most users don't need to worry about them.
+For talking to ttyp3, any program designed to talk to a serial port
+will do. But for the other program that talks to ptyp3, it must have
+been specially written to talk to it. It's mainly programmers that
+must concern themselves with pseudo terminals and most users don't
+need to worry about them.
Here's an example: If someone connects via telnet to your computer
over a network (you are a telnet server), the part of the telnet
program handling this connection on your computer may wind up
-connected to the pseudo terminal m2 (ptyp2). A getty program should
-be running on the corresponding s2 (ttyp2). Getty thinks it's talking
-to a terminal. When telnet gets a character from the remote client,
-it goes thru m2 to s2 to getty which then sends back "login:" routed
-to s2, m2, your server telnet program, and then out to the network back to
-the client. Here the login program and the telnet server program talk
-to each other via a "pseudo terminal". Note that there is no pseudo
-terminal used on the client computer, just telnet. Of course the
-server allocates a pseudo terminal (on the server) for each client.
+connected to the pseudo terminal ptyp2. A getty program should be
+running on the corresponding ttyp2. Getty thinks it's talking to a
+terminal. When telnet gets a character from the remote client, it
+goes thru ptyp2 to ttyp2 to getty which then sends back "login:"
+routed via ttyp2, ptyp2, your server telnet program, and then out to
+the network back to the client. Here the login program and the telnet
+server program talk to each other via a "pseudo terminal". Note that
+there is no pseudo terminal used on the client computer, just telnet.
+Of course the server allocates a pseudo terminal (on the server) for
+each client.
In X Window, the terminal emulator program, xterm (or rxvt), uses
pseudo terminals. Ham radio programs under Linux also use them. By
using certain application software, it is possible to have 2 or more
pseudo terminals attached to the same physical serial port.
-For a pseudo terminal pair such as m3 (ptyp3) and s3 (ttyp3), the m...
-(pty...) is the master or controlling terminal and the s... (tty...)
-is the slave. The device filesystem notation makes this clear (m is
-for master, s is for slave). The slave is like a serial port so also
-think of s as standing for "serial". In the old notation, tty.. is
-like a serial port ttyS (which in olden days was just tty).
+For a pseudo terminal pair such as ptyp3 and ttyp3, the pty... is the
+master or controlling terminal and the tty... is the slave.
-Prior to the device filesystem a complex notation was used in order
-to get a large number of pseudo terminals. There are only 16 ttyp's:
-ttyp0-ttypf (f is a hexadecimal digit). To get more pairs, more
-letters such as q, r, s were used instead of p. For example the pair
-ttys8, ptys8 was a pseudo terminal pair. Later on, even more letters
-were added so as to allow even more pseudo terminals. With the device
-filesystem, we may just use, for example, /dev/pty/m57 instead of
-/dev/ttys9 for the 58th pty master. People have made the mistake of
-typing say ttys2 (which is a pseudo serial port) when they meant to
-type ttyS2 (a real serial port).
+There are only 16 ttyp's: ttyp0-ttypf (f is a hexadecimal digit). To
+get more pairs, more letters such as q, r, s are used instead of p.
+For example the pair ttys8, ptys8 is a pseudo terminal pair. Later
+on, even more letters were added so as to allow even more pseudo
+terminals. And when z was reached, they wrapped around to a. This is
+confusing but old habits are difficult to change. Today Linux allow
+say ttyp189 but it's not used. The device file system, which was
+abandoned in 2004, would have used tty/s189. Be sure not to type say
+ttys2 if you mean ttyS2 (a real serial port).
The master and slave are really the same "port" but the slave is used
by the application program and the master is used by a network program
@@ -1034,44 +1045,59 @@ by the application program and the master is used by a network program
The program using the slave port can run "as is" since it thinks it is
talking to a serial port.
-Unix98 (available on Linux) doesn't use the above but instead uses a
-"pty master" which might be, for example, /dev/ptm3. It's slave is
-automatically created as /dev/pts/3. It thus supplies a pty on demand.
+Unix98 pseudo terminals (available on Linux) is more advanced than the
+above but the basic concepts are the same (only the device names and
+methods of creating them change). It creates pseudo terminal devices
+on request so there is no need to check if the pseudo terminal you
+might want to use in in use. By opening /dev/ptmx a new pseudo
+terminal pair is created. The master doesn't show up as a device but
+is just a file descriptor number passed to the computer program that
+opened /dev/ptmx. But the slave is put into the /dev/pts directory:
+for example" /dev/pts/3.
+
The /dev/pts directory is considered to be a file system of type
devpts and appears in the lists of mounted filesystems. While the
-"file" /dev/pts/3 looks like it would be an entry in the device
-filesystem, it's really a wholly different kind of filesystem.
+"file" /dev/pts/3 looks like an entry in the now obsolete device
+filesystem, /dev/pts Is really a wholly different kind of filesystem.
-While other unix-like systems have a manual page for pseudo terminals
-(may be named "pty") Linux lacks one for the general user. But there
-is a man-page for programmers: (openpty or forkpty) which assumes that
-you already understand pseudo terminals. There is both a Linux pty
-module and a /usr/include/pty.h file.
+See the Linux manual pages "pty" and "pts" (Unix 98 style) for more
+details. For programmers there's the man-page openpty/forkpty (either
+name displays the same man-page) which assumes that you already
+understand pseudo terminals. There is a usr/include/pty.h file for
+use by programmers. In earlier versions of Linux there was a pty.o
+module, but it now seems that it's been built into the kernel. Here's
+an example of some options available when you are compiling a Linux
+2.6 kernel:
- The Controlling Terminal /dev/tty
- /dev/tty stands for the controlling terminal (if any) for the
-current process. To find out which tty's are attached to which
-processes use the "ps -a" command at the shell prompt (command line).
-Look at the "tty" column. For the shell process you're in, /dev/tty
-is the terminal you are now using. Type "tty" at the shell prompt to
-see what it is (see manual pg. tty(1)). /dev/tty is something like a
-link to the actually terminal device name with some additional
-features for C-programmers: see the manual page tty(4).
+ CONFIG_UNIX98_PTYS=y CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=256
- /dev/ttyIN "Terminals"
- N stands for an integer. One use of these in Linux is with the
-ISDN driver package: isdn4linux. The ttyIN is something like ttySN
-but it emulates a modem and can be given modem commands.
+ The Controlling Terminal /dev/tty
+ /dev/tty stands for the
+controlling terminal (if any) for the current process. To find out
+which tty's are attached to which processes use the "ps -a" command at
+the shell prompt (command line). Look at the "tty" column. For the
+shell process you're in, /dev/tty is the terminal you are now using.
+Type "tty" at the shell prompt to see what it is (see manual pg.
+tty(1)). /dev/tty is something like a link to the actually terminal
+device name with some additional features for C-programmers: see the
+manual page tty(4).
- The Console: ttyN or vc/N In Linux
-the PC monitor is usually called the console and has several device
-special files associated with it: vc/0 (tty0), vc/1 (tty1), vc/2
-(tty2), etc. When you log in you are on vc/1. To go to vc/2 (on the
-same screen) press down the 2 keys Alt(left)-F3. For vc/3 use Left
-Alt-F3, etc. These (vc/1, vc/2, vc/3, etc.) are called "virtual
-terminals". vc/0 (tty0) is just an alias for the current virtual
-terminal and it's where messages from the system are sent. Thus
-messages from the system will be seen on the console (monitor)
+ /dev/ttyIN "Terminals"
+ N stands for an integer. One use
+of these in Linux is with the ISDN driver package: isdn4linux. The
+ttyIN is something like ttySN but it emulates a modem and can be given
+modem commands.
+
+ The Console: ttyN or vc/N
+ In Linux the PC monitor is usually called the console and has
+several device special files associated with it: vc/0 (tty0), vc/1
+(tty1), vc/2 (tty2), etc. When you log in you are on vc/1. To go to
+vc/2 (on the same screen) press down the 2 keys Alt(left)-F3. For
+vc/3 use Left Alt-F3, etc. These (vc/1, vc/2, vc/3, etc.) are called
+"virtual terminals". vc/0 (tty0) is just an alias for the current
+virtual terminal and it's where messages from the system are sent.
+Thus messages from the system will be seen on the console (monitor)
regardless of which virtual terminal it is displaying.
You may log in to different virtual terminals and thus have a few
@@ -1080,52 +1106,56 @@ the system or the root user may write to /dev/vc/0 to which
/dev/console is sometimes linked. For more info on the console see
[.
-] Creating a Device with "mknod"
- The /dev directory comes supplied with many device special files.
-If you need something that's not there you may try to create it with
-the "mknod" command. See the manual page ttys(4) for how to do this
-for serial ports. To use Creating a Device with "mknod"
+
The /dev directory comes
+supplied with many device special files. If you need something that's
+not there you may try to create it with the "mknod" command. See the
+manual page ttys(4) for how to do this for serial ports. To use
+ Some Details on How Terminals Work
+ Some Details on How Terminals Work
If you know almost nothing about terminals, it's suggested that
you first read [ and also read ][.
-] Terminal Memory Details
- The terminal screen refreshes itself at perhaps 60 times per
-second from an image stored in the memory of the terminal. For a PC
-the monitor's image is stored on the video card inside the computer
-but for a terminal, the equivalent of the video card is inside the
-terminal. For a text terminal the storage of the image uses little
-memory. Instead of putting every dot (pixel) on the screen into
-memory and requiring the storage of about a quarter-million dots, a
-much more efficient method of storage is used.
+ Terminal Memory Details
+ The
+terminal screen refreshes itself at perhaps 60 times per second from
+an image stored in the memory of the terminal. For a PC the monitor's
+image is stored on the video card inside the computer but for a
+terminal, the equivalent of the video card is inside the terminal.
+For a text terminal the storage of the image uses little memory.
+Instead of putting every dot (pixel) on the screen into memory and
+requiring the storage of about a quarter-million dots, a much more
+efficient method of storage is used.
A screen-full of text may be represented inside the terminal memory by
-ASCII bytes, one for each character on the screen. An entire
-screen only takes about 2K ASCII bytes. To display these characters,
-the terminal must also know the bit-map (the shape) of each of the
-almost 100 printable ASCII characters. With a bit-map of a character
-using say 15 bytes, only about 1.5K of memory is needed for the
-bit-maps of all the ASCII characters (the font). This ASCII text and
-font memory is scanned so that the resulting image is put on the
-screen about 60 times each second. This is a form of shared memory
-where a single bit-map of a letter such as the letter e, is shared by
-all of the many letter e's which appear on a screen-full of text. Low
-memory requirements meant low costs to produce monitors in the early
-1980's when the cost of memory was several thousand times higher than
-it is today (costing then several dollars per kilobyte).
+ASCII bytes, one for each character on the screen. An entire screen
+only takes about 2K ASCII bytes. To display these characters, the
+terminal must also know the bit-map (the shape) of each of the almost
+100 printable ASCII characters. With a bit-map of a character using
+say 15 bytes, only about 1.5K of memory is needed for the bit-maps of
+all the ASCII characters (the font). This ASCII text and font memory
+is scanned so that the resulting image is put on the screen about 60
+times each second. This is a form of shared memory where a single
+bit-map of a letter such as the letter e, is shared by all of the many
+letter e's which appear on a screen-full of text. Low memory
+requirements meant low costs to produce monitors in the early 1980's
+when the cost of memory was several thousand times higher than it is
+today (costing then several dollars per kilobyte).
- Early Terminals
- The first terminals were something like remotely controlled
-typewriters which could only "display" (print on paper) the character
-stream sent to them from the computer. The earliest models were
-called [. The name "tty" is just
-an abbreviation for "Teletype". Early terminals could do a line feed
+] Early Terminals
+ The first
+terminals were something like remotely controlled typewriters which
+could only "display" (print on paper) the character stream sent to
+them from the computer. The earliest models were called [. The name "tty" is just an
+abbreviation for "Teletype". Early terminals could do a line feed
and a carriage return just like a typewriter and ring a bell when a
bell character was received. Due to the lack of significant
capabilities this was the first type of terminal to be labeled "dumb".
@@ -1133,45 +1163,47 @@ This type of terminal interface (using a terminal type called "dumb")
is sometimes used today when the computer can't figure out what kind
of a terminal it is communicating with.
-] Escape Sequences and Control Codes (intro)
- Terminals have many capabilities some of which are always present
-and some of which require commands from the computer to change or
-activate. To exercise all these capabilities under the control of the
-computer requires that special codes be established so that the
-computer can tell the terminal what to do. There are two major type
-of such codes: escape sequences and control codes (control
-characters). There are many times more escape sequences than control
-codes.
+ Escape Sequences and Control Codes (intro)
+ Terminals have
+many capabilities some of which are always present and some of which
+require commands from the computer to change or activate. To exercise
+all these capabilities under the control of the computer requires that
+special codes be established so that the computer can tell the
+terminal what to do. There are two major type of such codes: escape
+sequences and control codes (control characters). There are many
+times more escape sequences than control codes.
- Control codes
- The control codes (or control characters) consist of the first 32
-bytes of the ASCII alphabet. They include the following:
-carriage-return (cursor to far left), line-feed (cursor down one line),
-backspace, escape-character, tab, and bell. They do not normally
-show on the screen. There is usually a command which you may give to
-your terminal which will result in them being displayed when they are
-received by the terminal. It's called something like "Display Controls"
-or "Monitor". If you do this then the display may look a mess since
-escape sequences, which all start with the ESC (escape) control
-character, are no longer executed. Words which should appear at the
-top or bottom of the screen will show up in other locations. The
-escape sequences to reposition the cursor display on the screen but
-the cursor doesn't move to where the escape sequence says.
+ Control codes
+ The control
+codes (or control characters) consist of the first 32 bytes of the
+ASCII alphabet. They include the following: carriage-return (cursor
+to far left), line-feed (cursor down one line), backspace,
+escape-character, tab, and bell. They do not normally show on the
+screen. There is usually a command which you may give to your
+terminal which will result in them being displayed when they are
+received by the terminal. It's called something like "Display
+Controls" or "Monitor". If you do this then the display may look a
+mess since escape sequences, which all start with the ESC (escape)
+control character, are no longer executed. Words which should appear
+at the top or bottom of the screen will show up in other locations.
+The escape sequences to reposition the cursor display on the screen
+but the cursor doesn't move to where the escape sequence says.
- Escape sequences
- Since there are not nearly enough control codes to do everything
-(and for some reason, not all of them are utilized) many escape
-sequences are used. They consist of the "escape" (ESC) control
-character followed by a sequence of ordinary characters. Upon
-receiving an escape character, the terminal examines the characters
-following it so that it may interpret the sequence and carry out the
-intended command from the computer. Once it recognizes the end of a
-valid sequence, further characters received just display on the screen
-(unless they are control codes or more escape sequences). Some escape
-sequences may take parameters (or arguments) such as the coordinates
-on the screen to move the cursor to. The parameters become a part of
-the escape sequence. An [ is on the web for some terminals, but it's terse.
+] Escape sequences
+ Since there are not
+nearly enough control codes to do everything (and for some reason, not
+all of them are utilized) many escape sequences are used. They
+consist of the "escape" (ESC) control character followed by a sequence
+of ordinary characters. Upon receiving an escape character, the
+terminal examines the characters following it so that it may interpret
+the sequence and carry out the intended command from the computer.
+Once it recognizes the end of a valid sequence, further characters
+received just display on the screen (unless they are control codes or
+more escape sequences). Some escape sequences may take parameters (or
+arguments) such as the coordinates on the screen to move the cursor
+to. The parameters become a part of the escape sequence. An [ is on the web for some
+terminals, but it's terse.
A list of the escape sequences for your terminal should be in the
"programmers manual" for the terminal. Except for very old terminals,
@@ -1190,12 +1222,13 @@ does not list all of the escape sequences which the terminal has
available for use, but fortunately, the most important ones are
usually there.
-] Display Attributes & Magic Cookies
- Terminals have various methods of generating character attributes
-such as bold, reverse-video, underlining, etc. There should be
-no need for the user to worry about how this is done, except that
-it creates problems for some old terminals and there is sometimes an
-option for this in the set-up menu of newer terminals.
+ Display Attributes & Magic Cookies Terminals have various methods of
+generating character attributes such as bold, reverse-video,
+underlining, etc. There should be no need for the user to worry about
+how this is done, except that it creates problems for some old
+terminals and there is sometimes an option for this in the set-up menu
+of newer terminals.
The magic cookie method is obsolete. It's the simplest (and worst)
method of defining attributes: Use a certain byte for the start of an
@@ -1213,13 +1246,13 @@ by PC video cards (for text) for the common PC monitor.
Special Features of Some Terminals
- Color
- While the common monochrome terminal is not a color terminal it
-may have a fixed "color" display other than white such as green or
-amber. All terminals have black (electron beam turned off = zero
-brightness). A real color terminal can change the color of the text
-and background to many different colors while a monochrome terminal
-can only change the brightness of a fixed color.
+ Color
+ While the common monochrome terminal is not a color
+terminal it may have a fixed "color" display other than white such as
+green or amber. All terminals have black (electron beam turned off =
+zero brightness). A real color terminal can change the color of the
+text and background to many different colors while a monochrome
+terminal can only change the brightness of a fixed color.
However, changing the brightness, etc. gives a lot of possibilities.
For example, a black and white (monochrome) terminal can have white,
@@ -1227,49 +1260,49 @@ grey, and black by varying the brightness. Some words can be black on
a light grey background while other are highlighted by black on white.
In addition there is white on black, underlining, and blinking.
-Color works like the color on a computer monitor or TV screen.
-The CRT has three colors of dots on it with each color controlled by
-its own electron beam (3 beams). Monochrome has inherently better
+Color works like the color on a computer monitor or TV screen. The
+CRT has three colors of dots on it with each color controlled by its
+own electron beam (3 beams). Monochrome has inherently better
resolution since it doesn't depend on dots permanently fixed on the
screen. For text terminals the only use of color is to differentiate
text and this advantage is not always worth the cost of worse
resolution. Thus monochrome may be better since it also costs less.
- Multiple Sessions
- For dual sessions the terminal has two serial ports of equal
-status. Each port is connected to a serial port on a different
-computer. Thus one may log in to two different computers with each
-session displaying in a split-screen window. Alternatively, each
-session may run full-screen with a "hot" key (or the like) to switch
-between sessions. One could also connect to two different serial
-ports on the same computer and log in twice (similar to "virtual
-terminals" at the console). The program "screen" will make any
-ordinary terminal (single session) connected to a single computer run
-two or more "sessions".
+ Multiple Sessions
+ For dual sessions the terminal has two
+serial ports of equal status. Each port is connected to a serial port
+on a different computer. Thus one may log in to two different
+computers with each session displaying in a split-screen window.
+Alternatively, each session may run full-screen with a "hot" key (or
+the like) to switch between sessions. One could also connect to two
+different serial ports on the same computer and log in twice (similar
+to "virtual terminals" at the console). The program "screen" will
+make any ordinary terminal (single session) connected to a single
+computer run two or more "sessions".
- Printer/Auxiliary Port
- Many terminals have a connector on the rear for such a port. It
-may be labeled as "Aux" or "Printer", etc. Some printer ports are for
-parallel printers while others are for serial printers. If a printer
-is connected to the printer or auxiliary port, then pressing certain
-keys will print the screen. One may also have everything that
-displays on the screen go also to the printer. If the port is an
-auxiliary port, one may connect this to another computer and almost
-have dual sessions as above. However, the video memory inside the
-terminal may not retain both sessions so you may need to refresh the
-screen when switching to the other session. There will likely not be
-a hot key either but possibly a programmable function key may be
-programmed to do this. There exists various key combinations and
-escape sequences for controlling such a port. See [.
+] Printer/Auxiliary Port
+ Many terminals have a connector on
+the rear for such a port. It may be labeled as "Aux" or "Printer",
+etc. Some printer ports are for parallel printers while others are
+for serial printers. If a printer is connected to the printer or
+auxiliary port, then pressing certain keys will print the screen. One
+may also have everything that displays on the screen go also to the
+printer. If the port is an auxiliary port, one may connect this to
+another computer and almost have dual sessions as above. However, the
+video memory inside the terminal may not retain both sessions so you
+may need to refresh the screen when switching to the other session.
+There will likely not be a hot key either but possibly a programmable
+function key may be programmed to do this. There exists various key
+combinations and escape sequences for controlling such a port. See
+[.
There is a program called ] .
-It's also included in the Debian distribution of Linux. . It's also
+included in the Debian distribution of Linux. Pages
- Many terminals permit the storage of more than one page in their
-video memory. Sometimes the page size is the same as the screen, but
-sometimes it is larger so that scrolling will reveal unseen parts of a
-page. So when one looks at a screen, there may be hidden text on the
-same page above or below the display. In addition, if there is more
-than just one page, there may be hidden text on these other pages.
-One use for pages is on terminals that support dual sessions. Each
-session may have its own page and one may switch back and forth
-between them.
+ Pages
+ Many terminals permit the
+storage of more than one page in their video memory. Sometimes the
+page size is the same as the screen, but sometimes it is larger so
+that scrolling will reveal unseen parts of a page. So when one looks
+at a screen, there may be hidden text on the same page above or below
+the display. In addition, if there is more than just one page, there
+may be hidden text on these other pages. One use for pages is on
+terminals that support dual sessions. Each session may have its own
+page and one may switch back and forth between them.
Even if you only have a one-page-terminal with the page sized equal to
what is displayed on the screen, you will still see other pages of a
@@ -1311,10 +1344,10 @@ page-like window for each running program.
A character-set is normally represented by a list (or table or
chart) of characters along with the byte code assigned to each
character. The codes for a byte range from 0 to 255 (00 to FF in
-hexadecimal). In MS-DOS, character-set tables are called "code-pages".
-You should examine such a table if you're not familiar with them.
-They are sometimes included in printer and terminal manuals but also
-are found on the Internet.
+hexadecimal). In MS-DOS, character-set tables are called
+"code-pages". You should examine such a table if you're not familiar
+with them. They are sometimes included in printer and terminal
+manuals but also are found on the Internet.
Many character sets include letters from foreign languages. But they
may also include special characters used to draw boxes and other
@@ -1345,46 +1378,43 @@ KOI8-R is more commonly used for Russian than IS0-8859-5. Unicode is
a very large character-set where each character is represented by 2
bytes instead on just one byte.
-More info re character-sets are:
+More info re character-sets are:
-- Manual pages: charsets, iso_8859-l or latin1 (covers 8859
- series), ascii
+
- Manual pages: charsets, iso_8859-l or latin1 (covers 8859 series), ascii
- HOWTO's for various languages (often written in that language).
-
More than just iso8859. Extensive.