home *** CD-ROM | disk | FTP | other *** search
- *****************************************************************
- THIS ARTICLE IS BEING PRESENTED THROUGH THE PIP ONLINE CP/M
- MAGAZINE OF THE NATIONAL CP/M ROUNDTABLE ON GENIE. copyright (c)
- 1989 BY BILL JULIANI. ALL RIGHTS RESERVED. PERMISSION IS HEREBY
- GRANTED TO NON-PROFIT ORGANIZATIONS ONLY TO REPRINT THIS ARTICLE
- OR PASS IT ALONG ELECTRONICALLY AS LONG AS PROPER CREDIT IS GIVEN
- TO BOTH THE AUTHOR AND GENIE.
- *****************************************************************
-
- PIP tutorial by Dale Ray (D.RAY1)
-
- PIP: Peripheral Interchange Program
-
- PIP is one of the most powerful utilities in your CP/M library.
- Normally you use it to simply copy files from one drive to
- another. But PIP can do much more than that. PIP can interchange
- data between your other computer peripherals too. In CP/M each
- peripheral has a name that the computer recognizes it by. For
- example:
-
- LST = PRINTER
-
- CON = CONSOLE (monitor & keyboard)
-
- These devices can be specified in the PIP command instead of a
- disk drive.
-
- EXAMPLE:
-
- A>PIP LST:=A:FILE.TYP
-
- The above command will cause FILE.TYP to be read from the disk in
- drive A and outputted to the printer. If you had specified CON:
- instead it would be printed on your monitor.
-
- OPTIONS:
-
- PIP has many options for altering a file as it is transferred
- between peripherals. These can be used to reformat a file as it
- is duplicated or printed. You will use these options most
- frequently with text files. The options are used by placing them
- in brackets [] at the end of the command string. DO NOT put a
- space before the first bracket. Where there is an [n] after the
- option it means that you can enter a number there to further
- control the options function.
-
- Dn ... Delete Characters. This will truncate a file that is too
- wide to display. All characters that are beyond (n) will be cut
- off.
-
- E .... Echo Characters. all copying is echoed to the screen. Use
- this to view a file while it is being transferred.
-
- F .... Form Feeds removed. Takes all form feed commands out of
- the file.
-
- L .... Lowercase Only. Converts all uppercase characters to
- lowercase.
-
- N .... Number Lines. Numbers the lines of the file. Used most to
- create a program file from a text file, allowing you to enter
- your program with a text editor.
-
- N2 ... Number Lines. Same as above but it puts leading zeros
- before the numbers (001) and a tab after the number.
-
- Pn ... Page Form-Feeds added. Think of this as page length. It
- adds a form feed after the number of lines you specify. Default
- is 60. Keeps you from printing over the perfs.
-
- Qphrase[control]Z... Quit copying at phrase specified. After the
- Q enter the phrase you want the computer to look for then hold
- down the control key and press Z. When your phrase is reached
- copying will be stopped.
-
- Sphrase[control]Z... Start copying at phrase specified. Same
- syntax as above. Use Q and S together to copy a specified section
- of the file.
-
- Tn ... Tab Spaces. Each TAB encountered in the text will cause
- the specified number of spaces to be printed.
-
- U .... Uppercase only. Converts all lowercase to uppercase
- characters.
-
- V ... Verify copy. Causes the system to check the copy against
- the original for errors.
-
- As you can see there is a lot you can do with PIP to reformat
- text files. Experiment to see what you can do.
-
- OTHER USES:
-
- Another use for PIP in handling text files is the ability to join
- files together. To do this simply list the source files separated
- by a comma. EX.:
-
- A>PIP BOOK=CHAPTER1,CHAPTER2,CHAPTER3
-
- This would create a file called book by copying the three
- specified source files into one larger file.
-
- You can also use PIP to transfer files from one user area to
- another. The syntax looks like this:
-
- A>PIP NEWFILE.TYP=OLDFILE.TYP[Gn]
-
- This would GET the file OLDFILE.TYP from the user area specified
- by the n and copy it to the current user area.
- TYP[Gn]
-
- This would GET the file OLDFILE.TYP from the user area specified
- by the n and copy it to the cur