|
Manipulate disk images
by Christian Groessler
Using disk images for the M20, you may want to access and manipulate PCOS files contained in them. To download the source of m20floppy, click here. This software is under the GNU GPL, Version 2, June 1991.
Installing on Linux/x86:
type make
some files will be compiled, generating a executable called m20
Installing on other systems:
edit Makefile and type make
I've tried it on Solaris/x86 and it worked, for other systems your
mileage may vary.
This version worked on disk images only, to access real M20 floppies
you'll need Linux or NetBSD.
The DOS version supports only 40track/360K floppy drives. It does not
work with 1.2M drives.
Using the m20 command
If you start m20 w/o arguments it will print a short usage overview:
usage: m20 image_file option
option can be one of
ls - list files on image
lsl - verbosely list files on image
cat - show file from image
get - get file from image
mget - get multiple files from image
put - put file onto image
mput - put multiple files onto image
rm - delete file on image
new - create a new empty image
version - display program version
Short description of the options:
- ls: display contents of image (file names). Only the file names
are listed, one in each line, for easy use with the mget
option.
e.g.
m20 m20disk.img ls | xargs m20 m20disk.img mget
- lsl: display contents of image (file names) in a format similar to
the PCOS vl command.
e.g.
m20 m20disk.img lsl
- cat: print contents of (ascii) file from image
e.g.
m20 m20disk.img cat file.txt
- get: get a file from the image (i.e. copy to host file system),
optionally renaming it
e.g.
m20 m20disk.img get PCOS.SAV
(this will copy the PCOS.SAV file from the image to a
PCOS.SAV file on the host file system)
or
m20 m20disk.img get PCOS.SAV newname.bin
(this will copy the PCOS.SAV file from the image to a
newname.bin file on the host file system)
- mget: get multiple files from the image (i.e. copy to host file
system)
e.g.
m20 m20disk.img get PCOS.SAV file1 file2
(this will copy the PCOS.SAV, file1, and file2 files
from the image to a files with the same name on the
host file system)
- put: put host file onto image, optionally renaming it
e.g.
m20 m20disk.img put runz.batz
(this will copy the file runz.batz onto the image)
or
m20 m20disk.img put runz.batz newname.bin
(this will copy the file runz.batz onto the image and
name it newname.bin there)
- mput: put host files onto image
e.g.
m20 m20disk.img put runz.batz file1 file2
(this will copy the files runz.batz, file1, and file2
onto the image)
- rm: remove files from image
e.g.
m20 m20disk.img rm basic.cmd file1 file2
(this will delete the files basic.cmd, file1, and
file2 from the image)
- new: create a fresh empty image (format disk)
e.g.
m20 newimage.img new
(you will have to populate the image with the put
command)
What else?
Nothing I know of. If you have comments/suggestions/etc., please
contact me here. You may need to change the mail address.
Olivetti is a registered trademark of Telecom Italia.
This site is not related to Olivetti nor to Telecom Italia. The material presented is meant for personal use only and is shared in a "fair use" spirit. If you own the copyright of some of the stuff presented here and you think it should be removed, please contact the webmaster.
|
Updates
|