1 Copyright (c) 1999 Massachusetts Institute of Technology
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2 of the License, or (at
6 your option) any later version.
8 This program is distributed in the hope that it will be useful, but
9 WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 General Public License for more details.
13 You should have received a copy of the GNU General Public License
14 along with this program; if not, write to the Free Software
15 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16 ------------------------------
20 This file attempts to maintain up-to-date documentation on all
21 the TTY variables. Those wonderful souls who update this information
22 in anyway (additions, deletions, corrections) should describe their
23 modifications in a brief note to INFO-ITS so that interested parties
24 can correct their copies or conceptions without needing to print or read
25 the entire file again. For example:
27 :MAIL INFO-ITS I added documentation on the FOO variable to TTYVAR.^C
28 ----------------------------------------------------------------------
30 For a more complete description of TTY handling see the file
31 .INFO.;ITS TTY. This file exists primarily to facilitate lookup via
32 the DOC program. Use :DOC TTYVAR <name> to read the documentation
33 of a specific variable.
35 The system calls for reading and setting TTY variables are:
36 CNSGET, CNSSET, OPEN, RCPOS, RFNAME, RSSIZE, SCML, SCPOS, STYGET,
37 TTYGET, TTYSET, and TTYVAR.
41 Bit names begin with %Tx where x specifies which variable. Byte
42 pointer names begin with $Tx. Here is a list of the prefixs in use
43 and where they're found:
48 %TD output buffers (these are characters, not bits)
51 %TI IOCHNM (for input channels)
52 %TJ IOCHNM (for output channels)
53 %TN TCTYP (these are codes, not bits)
61 HEIGHT: Screen Height (per-TTY)
63 HEIGHT contains the number of lines on the screen. For printing
64 terminals it is usually some large number.
66 This variable can be read with the CNSGET, RSSIZE, and TTYVAR system
67 calls and set with the CNSSET and TTYVAR system calls.
69 IDLTIM: Idle Time (per-TTY)
71 IDLTIM contains the length of time since the last input character
72 character was typed on the TTY, in 30'ths of a second.
74 This variable can be read with the TTYVAR system call.
76 IOCHNM: I/O channel bits (per-channel)
78 Some of the control bits set first time options and some are per-channel.
79 Those which are per-channel are marked below with a *. The standard names
80 for these bits are also given.
82 Control bits on input:
83 2.6 * %TIECH Read even if char needs pi echoing
84 2.5 * %TIPEK Don't remove char from buffer (peek)
85 2.3 * %TIACT Don't wait for activation char
86 2.2 * %TIINT Read even if char is an interrupt
87 char and hasn't interrupted yet.
88 2.1 * %TINWT Do not wait for input. If no input is
89 available, return -1 in unit mode, or
90 return a partially filled block in block mode.
91 1.9 * %TIFUL Use the full TV character set if possible.
92 In this mode, characters have this form:
94 2.2 Obsolete. Used to be Shift lock.
95 2.1 %TXSUP Super. Used to be Shift.
98 1.7-1.1 %TXASC Ascii part of character.
99 Of course, for non-TV's only %TXASC
101 1.6 Set up 3 line echo area (like SCML of 3).
102 1.4 "DDT" mode. Initially clear the %TGPIE and
103 %TGMPE bits for carriage return, line feed,
104 and tab, thus causing them not to echo.
105 1.3 Image mode. Initially clear the %TGPIE
106 and %TGMPE bits for all characters.
107 1.2 0 = unit mode, 1 = block mode. In block mode,
108 ^C causes a block mode end of file.
111 Control bits on output:
113 2.6 * %TJECH Echo mode output.
114 2.5 * %TJCTN Don't do line continuation.
115 2.4 * %TJSTP Channel is hung in **MORE**.
116 Unusual in that the system modifies this bit.
117 2.3 * %TJDIS Recognize ^P cursor codes.
118 2.2 * %TJSIO Super-image output. No padding
119 or cursor control is performed.
120 2.1 * %TJMOR Do not do **MORE** processing.
121 1.9 * %TJPP2 Output in the echo area if it exists.
122 1.6 Same as 2.2 - turns on %TJSIO.
123 1.5 Same as 2.3 - turns on %TJDIS.
124 1.4 Turns on %TJECH, %TJPP2, %TJMOR.
125 1.3 Image mode. Initially set %TGIMG bits
127 1.2 0 = unit mode, 1 = block mode. In block mode
128 output all ^C's are ignored.
131 The I/O channel word for a TTY channel can be read with RFNAME. It
132 is set by the OPEN call.
134 ISPEED: Input Speed (per-TTY)
136 ISPEED is the input speed of the terminal. It refers to the input
137 speed code stored in the TTYTYP variable. However, it is not a speed
138 code, but rather the speed in bits per second. Also, you are allowed to
139 set the ISPEED variable, while you are not allowed to set the whole TTYTYP
142 This variable can be read and set with the TTYVAR system call.
144 OSPEED: Output Speed (per-TTY)
146 OSPEED is the output speed of the terminal. It refers to the output
147 speed code stored in the TTYTYP variable. However, it is not a speed
148 code, but rather the speed in bits per second. Also, you are allowed to
149 set the OSPEED variable, while you are not allowed to set the whole TTYTYP
152 This variable can be read and set with the TTYVAR system call.
154 TCTYP: Terminal type code (per-TTY)
156 0 %TNPRT Printing terminal.
157 1 %TNDP Good Datapoint.
158 2 %TNODP Bad Datapoint ("loser").
163 7 %TNSFW Software terminal (accepts internal
164 ITS display codes, such as live in
165 internal terminal output buffers;
166 see ITS TTY for details).
168 11 %TNESC Display using ASCII standard display codes.
170 13 %TNRAY Teleray 1061
171 14 %TNHDS Concept 100
173 16 %TNAAA Ann Arbor Ambassador
175 This variable can be read with the CNSGET and TTYVAR system calls
176 and set with the CNSSET and TTYVAR system calls.
178 TTYCOM: Com-link bits (per-TTY)
180 4.9 Communicate mode.
181 4.8 %TCLFT Local feed through (my job sees his typing).
182 4.7 %TCRFT Remote feed through (his job sees my typing).
183 4.6 %TCICO Input comm override (my job sees my typing).
184 4.5 %TCOCO Output comm override (I see my job's typing).
185 4.4 %TCRFS Refuse comm messages.
186 4.3 %TCQRY Query me if comm attempted to me.
187 4.2 %TCMTR The tty's motor is off, and must be
188 turned on before next output.
189 (Currently only Terminets get turned off.)
190 4.1 %TCECH The last output to this tty was PI echo.
191 3.9 %TCINP Someone waited for input since last home-up.
192 3.8 %TCDET Console's tree detached by top level interrupt.
193 3.7 %TCDNG Type bell (input buffer full).
194 3.6 %TCCBK Reading uname or tty number after ^_K.
195 3.5 %TCCBS Reading uname or tty number after ^_S.
196 3.4 %TCFPD First part of an output code sequence is done.
197 3.3 %TCTPN Type ^_N on leaving comm (unless user types it).
198 3.2 %TCPAD 0 => padding necessary on datapoint.
199 3.1 %TCHNG Done flag seems to be fried - time out quickly.
200 2.9-1.1 -1 if not in comm mode; otherwise number of
201 next tty in circular list of those in comm mode
204 Only the %TCICO, %TCOCO, %TCRFS, %TCQRY, %TCMTR, and %TCINP bits may
207 This variable can be read with the CNSGET and TTYVAR system calls
208 and set with the CNSSET and TTYVAR system calls.
210 TTYOPT: TTY capability and option bits (per-TTY)
212 4.8 %TOALT Standardize altmodes.
213 4.7 %TOCLC Convert lower case input to upper case.
214 4.6 %TOERS This tty can selectively erase.
215 4.5 %TOHDX This tty is half-duplex.
216 4.4 %TOMVB This tty can backspace directly.
217 4.3 %TOSAI This tty handles SAIL characters.
218 4.2 %TOSA1 Used to initialize %TSSAI for new jobs.
219 4.1 %TOOVR This tty can overprint correctly.
220 3.9 %TOMVU This tty can move its cursor upward.
221 3.8 %TOMOR Used to initialize %TSMOR for new jobs.
222 3.7 %TOROL Used to initialize %TSROL for new jobs.
223 3.6 %TORAW Don't optimize cursor motion.
224 3.5 %TOLWR This tty has a lower case keyboard.
225 3.4 %TOFCI This tty's keyboard has the full TV character set.
226 3.3 %TOIML This tty acts like an IMLAC.
227 3.2 %TOLID This tty can insert/delete lines.
228 3.1 %TOCID This tty can insert/delete characters.
229 2.9-2.7 $TPPLF How to pad line feeds:
231 1 Two pad chars (Memorex, 2741).
233 2.6-2.4 $TPPCR How to pad carriage returns:
234 0 Don't. 4 Execuport.
238 For a Datapoint, number of pad chars before
239 each string of cursor motion commands.
240 For a Terminet, 0=no padding, 1,2,3,4,5
241 correspond to 10,15,30,60,120 cps.
242 2.3-2.1 $TPPTB How to pad tabs:
244 <n> Use <n-1> pad chars.
248 2 use VT52-style absolute positioning.
249 1.9 %TPMTA Treat bit 1.8 of input characters as the meta bit.
250 this is for terminals such as Telerays which have Edit keys.
251 1.8 %TPPRN interchange ( with [, and ) with ], on input.
252 1.7 %TPTEL Treat CRLF input as CR for TELNET protocol.
253 1.6 %TPCBS The ^\ intelligent terminal protocol is enabled.
254 1.5 %TP11T PDP-11 TV. Reflects %TY11T.
255 1.4 %TPORS Output reset really does something.
256 1.3 %TPRSC This tty can do region scrolling.
257 1.2 %TPIBC Oddball 2741-like tty. ;no longer defined
258 1.1 %TPIBM It really is a 2741. ;no longer defined
260 This variable can be read with the CNSGET and TTYVAR system calls
261 and set with the CNSSET and TTYVAR system calls.
263 TTYROL: Scroll count (per-TTY)
265 TTYROL contains the number of lines the TTY moves up when it scrolls.
266 Scrolling occurs when a LF is sent while the cursor is on the last line.
268 This variable can be read and set with the TTYVAR system call.
272 4.9 %TACFM Tty does not need a console free message
273 eventually (hasn't been in use since
275 4.8 %TAC.Z Tty is being ^Z'd. Shouldn't be on with
276 %TACFM. If %TACFM and %TAC.Z are both 0,
277 the tty is being freed and a console free
279 4.7 %TANJS This ^Z is being flushed because no job
280 slots are available. If set, %TAC.Z
281 will be 1 and %TACFM will be 0.
282 4.6-4.3 %TANEC Number of following chars to inhibit echo and ints for.
283 This is used for the arg chars that follow Top-E,
286 This variable can be read with the STYGET system call.
288 TTYST1: Activation and Echo control word 1 (per-job)
290 This variable contains six groups of six bits.
291 Each group is as follows:
292 1.6 %TGMPE Echo at main program level (when IOT'ed).
293 1.5 %TGPIE Echo at interrupt level (when typed).
294 1.4 %TGIMG Echo in image mode.
295 1.3 %TGSPC Special hack: convert lower case to upper.
296 1.2 %TGACT Activation character.
297 1.1 %TGINT Interrupt character.
299 The character groups are:
300 4.9-4.4 ^@-^F ^K ^L ^N-^R ^T-^Z ^\-^_
301 4.3-3.7 Upper and lower case letters.
303 2.9-2.4 ! " # $ % & ' , . : ; ? @ \ ` | ~
304 2.3-1.7 + * - / = ^ _
305 1.6-1.1 < > ( ) [ ] { }
307 This variable can be read with the TTYGET system call and set
308 with the TTYSET system call.
310 TTYST2: Activation and Echo control word 2 (per-job)
312 This variable contains six more groups of six bits.
313 Each group is as follows:
314 1.6 %TGMPE Echo at main program level (when IOT'ed).
315 1.5 %TGPIE Echo at interrupt level (when typed).
316 1.4 %TGIMG Echo in image mode.
317 1.3 %TGSPC Special hack: convert lower case to upper.
318 1.2 %TGACT Activation character.
319 1.1 %TGINT Interrupt character.
321 The character groups are:
323 4.3-3.7 ^I ^J (tab, linefeed)
325 2.9-2.4 ^M (carriage return)
327 1.6-1.1 space, ^H (backspace)
329 This variable can be read with the TTYGET system call and set
330 with the TTYSET system call.
332 TTYSTS: TTY option bits (per-job)
334 4.9 %TSFRE Free console (not in use).
335 4.8 %TSCLE ^L should echo as "^L" (normally
336 clears screen on displays).
337 4.7 %TSHDX Same as %TOHDX. Vestigial.
338 4.6 %TSFCO Use full 12-bit TV char set for output
339 and echoing; echo META as BETA; echo
341 4.5 %TSALT Do not standardize altmodes.
342 4.4 %TSROL Scroll mode.
343 4.3 %TSSAI Echo and ascii output use SAIL
345 4.2 %TSACT Next input IOT shouldn't wait
346 for an activation character.
347 4.1 %TSNEA Don't echo in echo area; echo in M.P. Area.
348 3.9 %TSINT Next input character should
349 interrupt even if it ordinarily
350 would not (%TGINT = 0).
351 3.8 %TSMOR Inhibit **MORE** processing.
352 3.7 %TSATY Set whenever an .ATTY executed by
353 some superior returns the tty to
355 3.4 %TSNOE Defer echoing.
356 3.3 %TSLCZ Last character typed was ^Z.
357 This bit causes .ATTY's to fail.
358 3.2 %TSSII Super-image input. The special
359 actions of ^Z and ^_ are suppressed.
360 3.1 %TSCNS This is a console, not a device.
361 2.9-1.1 The user index of the job which controls
362 the tty, or -1 if the tty is free.
364 %TSFRE, %TSHDX, %TSLCZ, %TSCNS, and the RH may not be altered.
366 This variable can be read with the TTYGET system call and set
367 with the TTYSET system call.
369 TTYTYP: Semi-permanent stuff (per-TTY)
371 This variable may not be set, just read (but see ISPEED and OSPEED).
373 4.9 %TTLCL Local tty (i.e. right near the PDP-10).
374 4.8 %TT340 Near the 340 or a 340 slave.
375 4.7 %TT3HP High priority for grabbing 340.
376 4.3 %TTPAR Tty needs a parity bit generated by software.
377 4.2 %TTDDI Don't ding bell on excess input.
378 4.1 %TTIBM Datel (2741) line.
379 3.8-3.5 $TTISP Input speed code:
380 0 = unknown 6 = 1800 baud 13 = 40K baud
381 1 = 600 baud 7 = 2400 baud 14 = 50K baud
382 2 = 110 baud 10 = 4800 baud 15 = 80K baud
383 3 = 150 baud 11 = 9600 baud 16 unused
384 4 = 300 baud 12 = 25K baud 17 unused
386 3.4-3.1 $TTOSP Output speed code, as above.
387 2.9 %TYDPK Datapoint controller line.
388 2.8 %TYSTY Alter ego to a STY.
389 2.7 %TYNVA Nova tty (requiescat in pace).
390 2.6 %TYMTY Morton controller line.
391 2.5 %TYDIL Dial-up line.
392 2.4 %TY11T PDP-11 TV tty.
394 2.2 %TYOTY KA-10 console tty.
395 2.1 %TYETY DTE-20 tty.
396 1.9 %TYNTY TK-10 tty.
397 1.8 %TYMDM Dial-up line with modem control.
398 1.7 %TYKST KS-10 console tty.
399 1.6 %TYDZT DZ-11 tty on a KS-10.
400 1.5 %TYRLM ROLM data switch tty.
402 This variable can be read with the CNSGET and TTYVAR system calls.
404 WIDTH: Screen width (per-TTY)
406 WIDTH contains the no. of usable print positions on a line for the
407 TTY. It is usually one or two less than the actual no. of columns to allow
408 room for a "!" in the last column to indicate typeout being continued on
409 the next line (two columns are required when the terminal loses by
410 automatically performing a CRLF operation when a character is output to
413 This variable can be read with the CNSGET, RSSIZE and TTYVAR system
414 calls and set with the CNSSET and TTYVAR system calls.