|
NAMEcpm - read and write CP/M® floppy disksSYNOPSIScpm [ options ] [ filename ]DESCRIPTIONCpm reads and writes files with an internal structure like a CP/M file system. By default cpm assumes that the specified file has the parameters of a standard IBM format single sided single density 8" CP/M floppy disk, i.e., 2002 records containing 128 bytes each, of which 52 are reserved for system use and 16 (2 blocks) are used by the directory (maximum 64 directory entries). These parameters may be changed by specifying the appropriate flags (see below). Thus, various double density formats may also be read and written, provided that the hardware can handle the actual format.The specified file may be a floppy disk drive (e.g., /dev/floppy on an 11/780 or /dev/rrx?b if rx02 drives are available on your system), or a standard UNIX™ file with the appropriate structure. Since it may be inconvenient (and slow) to access the device directly, in particular the console floppy on an 11/780, it is always a good idea to copy the contents of the diskette into a standard file using dd(1), e.g., dd if=/dev/floppy of=yourfile bs=128 count=2002 On most systems you have to be superuser to access the console floppy and to be able to write to rx02's. Flags:
If the -i flag is specified, the filename argument must always be present. If the specified file does not exist, a new file will be initialized. The -C, -c and -p flags are mutually exclusive. The following commands are available in interactive mode:
The commands may be abbreviated as indicated by brackets. CP/M file names are automatically converted to upper case. The copy commands refuse to overwrite any existing files. If the CP/M floppy file becomes full during a file transfer from UNIX, the file is closed and the command terminated. The data already written to the CP/M file will be saved. The copyout command assumes that CP/M text files have cr+lf as line terminators and removes carriage returns. Copyin adds a carriage return in front of each line-feed, and adds a ^Z to the end of the file. The binary copy commands provide for ``raw'' file copying, thus making it possible to copy code files to and from diskettes. Interrupts are recognized in interactive mode, and will return you to the command level. FILES/dev/floppy/dev/rrx?b /usr/new/lib/cpm.hlp SEE ALSOdd(1), rx(4v)BUGSCP/M user numbers are ignored, files written to the CP/M floppy file will always have user number 0.CP/M filename extensions containing more than 3 characters will quietly be truncated. Wildcards are not supported. Binary input/output is always handled in multiples of the physical sector size; CP/M handles it in multiples of 128 byte records. TRADEMARKSCP/M is a registered trademark of Digital Research, Inc.UNIX is a trademark of AT&T Bell Labs. HISTORYThe original program has been written in 1982 and 1983 by Helge Skrivervik at the University of California, Berkeley. It has been adapted by Joerg Wunsch (joerg_wunsch@uriah.sax.de), to make it work with double density disks, especially with those having block numbers > 255. After getting written permission by Helge Skrivervik to redistribute the program under a Berkeley-style Copyright, it has been made available with the FreeBSD distribution in 1994.AUTHORHelge Skrivervik (now [1994] helge@mellvik.no)
Visit the GSP FreeBSD Man Page Interface. |