home *** CD-ROM | disk | FTP | other *** search
- ;
- ECHO.COM
-
- Size (recs) CRC Version Author/Latest Issue Disk
- ECHO.3OM 1k (8) 6C5F 1.4 Gene Pizzetta 10/91 Z3COM6
- ECHO.4OM 2k (12) BF64 1.4 Gene Pizzetta 10/91 Z3COM6
- ECHO.COM 1k (8) 8A06 1.4 Gene Pizzetta 10/91 Z3COM6
-
- 1- Usage 2- Printer Output 3- Configuration 4- Notes 5- Examples of Use
-
- ECHO allows text entered at the command line to be typed to the screen
- without the operating system acting on it. This is useful for displaying
- messages from aliases and between commands of a multiple command line.
-
- ECHO also provides a convenient way of sending escape sequences to the CRT
- or printer. ECHO uses direct BIOS calls without any character translation,
- except as noted below. Virtually any ASCII character can be sent because
- several escape sequences allow sending characters that cannot ordinarily be
- entered on the command line. Vs 1.0 (3/22/84) by R. Conn. Recent versions
- based on Carson Wilson's Z34RCP.
- :1
- Syntax ECHO {text}
-
- If no text is given, no characters are echoed. (Except that when printer
- output is selected, a CR,LF pair is sent at the end of the line).
-
- Text may contain the following escape sequences:
-
- %P Send following characters to printer.
- %C Send following characters to console. (This is usually the default,
- but ECHO can be configured to default to printer output.)
- %> Send following characters in lower-case.
- %< Send following characters in upper-case. (This is usually the
- default, but ECHO can be configured to default to lower-case.)
- ^c Send character c as a control character. For example, "^Z" sends a
- control-Z and "^@" sends a null.
- %D Send a delete (rubout) character.
- %S Send a semi-colon character. Since it acts as the ZCPR command sep-
- arator, an actual semi-colon cannot be included in the text string.
- %^ Send a caret character.
- %% Send a percent character.
- Usage - 2/2
-
- If two slashes are the first two non-space characters on the command line,
- a usage message will be displayed. You can begin the text display with two
- slashes by merely preceding them with the per-cent sign escape character:
- ECHO %// THIS LINE BEGINS WITH TWO SLASHES
-
- A semi-colon on the command line signals the end of a command to the
- command processor, so ECHO's text string cannot contain one. Use "%S"
- instead; it will be replaced with a semi-colon on output.
-
- If the "%" escape character is followed by "C", "P", "D", "S", "<", or ">",
- the appropriate action will be taken, otherwise the following character will
- merely be echoed as is.
- :2
- Printer Output
-
- Printer output varies slightly from console output.
-
- If a form feed is sent during printer output ("^L"), ECHO will send a
- carriage return and line feed first, then the form feed character.
-
- If a text string ends while ECHO is in printer output mode, a final
- carriage return and linefeed will be added to the string. (In console mode a
- carriage return and line feed is sent by the CPR instead.) If you would
- rather not have a CR/LF pair sent to the printer, put the console output
- escape sequence ("%C") at the end of the string. For instance, to reset an
- Epson printer without spacing the paper up a line:
-
- ECHO %P^[@^M%C
-
- This sequence sends ESC and "@", followed by a carriage return ("^M"), but not
- a final carriage return/line feed because output is redirected to the console.
- :3
- Configuration
-
- Although no configuration is necessary, two defaults can be changed using
- ZCNFG and the ECHOnn.CFG configuration file. If you do not change the name of
- the CFG file, ZCNFG will always be able to find it, even if you change the
- name of ECHO.
-
- Normally ECHO defaults to sending upper-case characters, but ZCNFG can be
- used to set the default to lower-case. Also, output normally defaults to the
- console, but ECHO can be configured to default to the printer.
- :4
- ECHO Notes - 1/2
-
- a. Vs 1.4 updates (10/10/91, Gene Pizzetta):
- - ECHO was sometimes exhibiting strange behavior under BYE, which Howard
- Goldstein diagnosed as a stack problem. The stack size has been
- increased.
- - Also, now uses ZSLIB GCOMNAM instead of Z3LIB PRTNAME so correct disk
- name prints on usage screen even with GO command.
- - Some code tweeking saved a few bytes.
-
- b. Vs 1.3 updates (11/25/90, Gene Pizzetta):
- - Fixed a bug that could cause a crash under certain circumstances if no
- text string was given on the command line.
- - Added %D escape sequence that sends a DEL (RUB) character, the only
- character ECHO could not send.
- - Converted code to Zilog.
- ECHO Notes - 2/2
-
- c. Vs 1.2 updates (10/21/90, Gene Pizzetta):
- - I got tired of my aliases not working whenever I got rid of my RCP for
- more memory. So I decided to make the transient ECHO compatible with
- Carson Wilson's Z34RCP. Code mostly his, modified as necessary.
- - The dollar sign ($) for printer output no longer works.
- - One additional escape sequence has been added: %S sends a semi-colon
- to printer or screen; there was no other way to send one.
- - Now properly requires *two* slashes for the help message.
- - Added type-3 safety header.
- - Added type-4 version.
- - Configurable with ZCNFG.
-
- d. Vs 1.1 updates (09/22/87, Cameron Cotrill):
- - Code from RCPECHO in z33 applied to ECHO10, resulting in a type 3
- transient echo that knows case.
- :5
- Examples of Use
-
- a. ECHO hello, world
-
- - sends text "HELLO, WORLD" to console
-
- b. ECHO Assembling;m80 =$1;^E
- if input;echo Linking;l80 /P:100,$1,A:SYSLIB/S,$1/N,/E;fi
-
- - a single multiple command line will print the informative messages
- "ASSEMBLING" and "LINKING" during the respective commands
-
- c. ECHO ^Z
-
- - clears CRT screen (on terminal where ^Z clears the screen)
-
- d. ECHO $^L
-
- - form feeds printer (assuming printer responds to form feed char)