Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ cu(1C) — GL2 W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

cat(1)

ct(1C)

echo(1)

stty(1)

uucp(1C)

CU(1C)  —  Silicon Graphics

NAME

cu − call another UNIX System

SYNOPSIS

cu [−sspeed] [−lline] [−h] [−t] [−d] [−m] [−o|−e] telno | dir

DESCRIPTION

Cu calls up another UNIX system, a terminal, or possibly a non-UNIX system.  It manages an interactive conversation with possible transfers of ASCII files.  Speed gives the transmission speed (110, 150, 300, 600, 1200, 2400, 4800, 9600); 300 is the default value.  Most modems are either 300 or 1200 baud.  Directly connected lines may be set to speeds higher than 1200 baud. 

The −l value may be used to specify a device name for the communications line device to be used.  This can be used to override searching for the first available line having the right speed.  The −h option emulates local echo, supporting calls to other computer systems which expect terminals to be in half-duplex mode.  The −t option is used when dialing an ASCII terminal which has been set to auto-answer.  Appropriate mapping of carriage-returns to carriage-return-line-feed pairs is set.  The −d option cause diagnostic traces to be printed.  The −m option specifies a direct line which has modem control.  The −e (−o) option designates that even (odd) parity is to be generated for data sent to the remote.  Telno is the telephone number, with equal signs for secondary dial tone or minus signs for delays, at appropriate places.  The string dir for telno may be used for directly connected lines, and implies a null ACU.  Using dir insures that a line has been specified by the −l option. 

Cu will try each line listed in the file ­/usr/lib/uucp/L-devices until it finds an available line with appropriate attributes or runs out of entries.  After making the connection, cu runs as two processes: the transmit process reads data from the standard input and, except for lines beginning with ~ , passes it to the remote system; the receive process accepts data from the remote system and, except for lines beginning with ~ , passes it to the standard output.  Normally, an automatic DC3/DC1 protocol is used to control input from the remote so the buffer is not overrun.  Lines beginning with ~ have special meanings. 

The transmit process interprets the following:

~.  terminate the conversation. 

~!  escape to an interactive shell on the local system. 

~!cmd... run cmd on the local system (via sh −c). 

~$cmd... run cmd locally and send its output to the remote system. 

~%take from [to] copy file from (on the remote system) to file to on the local system.  If to is omitted, the from argument is used in both places. 

~%put from [to] copy file from (on local system) to file to on remote system.  If to is omitted, the from argument is used in both places. 

~~ ... send the line ~ ... to the remote system.

~%nostop turn off the DC3/DC1 input control protocol for the remainder of the session.  This is useful in case the remote system is one which does not respond properly to the DC3 and DC1 characters. 

~%break send a BREAK to the remote system.  Pressing the BREAK key has the same effect. 

~%b an abbreviation for ~%break. 

The receive process normally copies data from the remote system to its standard output.  A line from the remote that begins with ~> initiates an output diversion to a file.  The complete sequence is:

~>[>]:file
zero or more lines to be written to file
~>

Data from the remote is diverted (or appended, if >> is used) to file.  The trailing ~> terminates the diversion. 

The use of ~%put requires stty(1) and cat(1) on the remote side. It also requires that the current erase and kill characters on the remote system be identical to the current ones on the local system. Backslashes are inserted at appropriate places.

The use of ~%take requires the existence of echo(1) and cat(1) on the remote system. Also, stty tabs mode should be set on the remote system if tabs are to be copied without expansion. 

EXAMPLE

cu -s 1200 7778888

attempts to connect to the telephone line numbered "7778888" at 1200 baud rate. 

FILES

/usr/lib/uucp/L-devices
/usr/spool/uucp/LCK..(tty-device)
/dev/null

SEE ALSO

cat(1), ct(1C), echo(1), stty(1), uucp(1C). 

DIAGNOSTICS

Exit code is zero for normal exit, non-zero (various values) otherwise. 

BUGS

Cu buffers input internally. 
There is an artificial slowing of transmission by cu during the ~%put operation so that loss of data is unlikely. 

Version 2.3  —  July 04, 1985

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026