|
|
1.1 root 1: .\" Copyright (c) 1986, 1990 The Regents of the University of California.
2: .\" All rights reserved.
3: .\"
4: .\" Redistribution and use in source and binary forms are permitted provided
5: .\" that: (1) source distributions retain this entire copyright notice and
6: .\" comment, and (2) distributions including binaries display the following
7: .\" acknowledgement: ``This product includes software developed by the
8: .\" University of California, Berkeley and its contributors'' in the
9: .\" documentation or other materials provided with the distribution and in
10: .\" all advertising materials mentioning features or use of this software.
11: .\" Neither the name of the University nor the names of its contributors may
12: .\" be used to endorse or promote products derived from this software without
13: .\" specific prior written permission.
14: .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
15: .\" WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
16: .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
17: .\"
18: .\" @(#)tn3270.1 4.3 (Berkeley) 6/11/90
19: .\"
20: .Dd June 11, 1990
21: .Dt TN3270 1
22: .Os BSD 4.3
23: .Sh NAME
24: .Nm tn3270
25: .Nd full-screen remote login to IBM VM/CMS
26: .Sh SYNOPSIS
27: .Nm tn3270
28: .Op Fl d
29: .Op Fl n Ar filename
30: .Op Fl t Ar commandname
31: .Op Ar sysname Op port
32: .Sh DESCRIPTION
33: .Nm Tn3270
34: permits a full-screen, full-duplex connection
35: from a UNIX
36: machine
37: to an IBM (or compatible) machine.
38: .Nm Tn3270
39: gives the appearance of being logged in
40: to the remote machine
41: from an IBM 3270 terminal.
42: Of course, you must have an account on the machine
43: to which you connect in order to log in.
44: .Nm Tn3270
45: looks to the user in many respects
46: like the Yale ASCII Terminal Communication System II.
47: .Nm Tn3270
48: is actually a modification of the Arpanet TELNET user interface (see
49: .Xr telnet 1 )
50: which will, in certain circumstances, interpret and generate
51: raw 3270 control streams.
52: .Pp
53: The flags to
54: .Nm tn3270
55: are as follows:
56: .Tw Fl
57: .Tp Fl d
58: Turn on socket-level tracing (for super-user only)
59: .Ct Fl n
60: .Ar filename
61: .Cx
62: Specify a file to receive network trace data
63: output (from commands "toggle netdata" and
64: "toggle options", see
65: .Xr telnet 1 ) ;
66: the default is for output
67: to be directed to the standard error file.
68: .Ct Fl t
69: .Ar commandname
70: .Cx
71: Specify a UNIX
72: command to process IBM 4994 style transparent mode
73: data received from the remote IBM machine.
74: .Tp Ar sysname
75: The name of the remote system. If the remote name
76: is NOT specified, the user will be prompted for a
77: command (see below).
78: .Tp Ar port
79: The port to connect to on the remote system.
80: Normally,
81: .Nm tn3270
82: attempts to connect to the
83: standard TELNET port (port
84: 23) on the remote machine.
85: .Tp
86: .Pp
87: When
88: .Nm tn3270
89: first connects to the remote system, it will negotiate to go into
90: 3270 mode.
91: Part of this negotiation involves telling the remote system what model
92: 3270 it is emulating.
93: In all cases,
94: .Nm tn3270
95: emulates a 3278 terminal.
96: To decide which specific model,
97: .Nm tn3270
98: looks at the number of lines and columns on the actual terminal (as
99: defined in the
100: .Ev TERM
101: environment variable; see
102: .Xr termcap 5 ) .
103: The terminal (or window in which
104: .Nm tn3270
105: is running, on multiple
106: window systems) must have at least 80 columns and 24 lines, or
107: .Nm tn3270
108: will not go into emulation mode.
109: If the terminal does have at least 80 columns and at least 24 lines,
110: the following table describes the emulation:
111: .Pp
112: .ne 7v
113: .Ds C
114: .Cw (rows*columns)
115: .Cl minimum_size emulated
116: .Cl (rows*columns) terminal
117: .Cl -------------- ------------
118: .Cl 27*132 3278 model 5
119: .Cl 43*80 3278 model 4
120: .Cl 32*80 3278 model 3
121: .Cl 24*80 3278 model 2.
122: .Cw
123: .De
124: .Pp
125: .Pp
126: Emulation of the 3270 terminal is done in the UNIX
127: process.
128: This emulation involves mapping
129: 3270-style commands from the host
130: into appropriate sequences to control the user's terminal screen.
131: .Nm Tn3270
132: uses
133: .Xr curses 3
134: and the
135: .Pa /usr/share/misc/termcap
136: file to do this.
137: The emulation also involves simulating the special 3270 keyboard keys
138: (program function keys, etc.)
139: by mapping sequences of keystrokes
140: from the ASCII keyboard into appropriate 3270 control strings.
141: This mapping is terminal dependent and is specified
142: in a description file,
143: .Pa /usr/share/misc/map3270 ,
144: (see
145: .Xr map3270 5 )
146: or in an environment variable
147: .Ev MAP3270
148: (and, if necessary,
149: .Ev MAP3270A ,
150: .Ev MAP3270B ,
151: and so on - see
152: .Xr mset 1 ) .
153: Any special function keys on the ASCII keyboard are used whenever possible.
154: If an entry for the user's terminal
155: is not found,
156: .Nm tn3270
157: looks for an entry for the terminal type
158: .Em unknown .
159: If this is not found,
160: .Nm tn3270
161: uses a default keyboard mapping
162: (see
163: .Xr map3270 5 ) .
164: .Pp
165: The first character of each special keyboard mapping sequence
166: is either an ASCII escape (ESC),
167: a control character, or an ASCII delete (DEL).
168: If the user types an unrecognized function key sequence,
169: .Nm tn3270
170: sends an ASCII bell (BEL), or a visual bell if
171: defined in the user's termcap entry, to the user's terminal
172: and nothing is sent to the IBM host.
173: .Pp
174: If
175: .Nm tn3270
176: is invoked without specifying a remote host system name,
177: it enters local command mode,
178: indicated by the prompt
179: .Dq Li tn3270>\ .
180: In this mode,
181: .Nm tn3270
182: accepts and executes
183: all the commands of
184: .Xr telnet 1 ,
185: plus one additional command:
186: .Pp
187: .Tw Ar
188: .Tp Ic transcom
189: Specify UNIX
190: command for IBM 4994 style transparent mode processing.
191: .Tp
192: .Pp
193: .Nm Tn3270
194: command mode may also be entered, after connecting to a host, by typing
195: a special escape sequence.
196: If
197: .Nm tn3270
198: has succeeded in negotiating 3270 mode with the remote host, the
199: escape sequence will be as defined by the map3270 (see
200: .Xr map3270 5 )
201: entry for the user's terminal type
202: (typically control-C);
203: otherwise the escape sequence will initially be set to the
204: single character
205: .Sq Li \&^]
206: (control right square bracket).
207: .Pp
208: While in command mode, any host login session is still alive
209: but temporarily suspended.
210: The host login session may be resumed by entering an empty line
211: (press the
212: .Li RETURN
213: key)
214: in response to the command prompt.
215: A session may be terminated by logging off the foreign host,
216: or by typing ``quit'' or ``close'' while in local command mode.
217: .Sh FILES
218: .Dw /usr/share/misc/termcap
219: .Di L
220: .Dp Pa /usr/share/misc/termcap
221: .br
222: .Dp Pa /usr/share/misc/map3270
223: .Dp
224: .Sh AUTHOR
225: Greg Minshall
226: .Sh NOTES
227: The IBM 4994 style transparent mode command is invoked when
228: .Nm tn3270
229: receives IBM 4994 style transparent output from the remote host.
230: Output and input pipes are created for communication between the two
231: processes.
232: The pipes are closed when a 3270 clear command is received from the remote
233: hosts, signalling the end of transparent mode output.
234: Transparent mode is necessary for sending ASCII control characters over the
235: 3270 terminal connection; ASCII graphics terminal support is accomplished this
236: way.
237: Developers of
238: .Ic transcom
239: commands should note that the
240: .Ic transcom
241: stdin pipe end will be in CBREAK mode, with ECHO and CRMOD turned off.
242: .Sh ENVIRONMENT
243: .Nm Tn3270
244: checks the following environment variables:
245: .Ev TERM ,
246: .Ev MAP3270 ,
247: .Ev MAP3270[A...] .
248: Information on these can be found in
249: .Xr mset 1 .
250: .Nm Tn3270
251: also checks
252: .Ev SHELL ,
253: .Ev KEYBD
254: and
255: .Ev API3270 .
256: .Sh SEE ALSO
257: .Xr mset 1 ,
258: .Xr telnet 1 ,
259: .Xr curses 3 ,
260: .Xr termcap 3 ,
261: .Xr termcap 5 ,
262: .Xr map3270 5 ,
263: .br
264: .Em Yale ASCII Terminal Communication
265: .Em System II Program Description/Operator's Manual
266: .Pq IBM SB30-1911
267: .Sh HISTORY
268: .Nm
269: appeared in 4.3 BSD.
270: .Sh BUGS
271: Tn3270 is slow and uses system resources prodigiously.
272: .Pp
273: Not all 3270 functions are supported,
274: nor all Yale enhancements.
275: .Pp
276: Error conditions (attempting to enter data in a protected field, for
277: example) should cause a message to be sent to the user's terminal
278: instead of just ringing a bell.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.