Back

Understanding disk images for the CP/M emulation:

All disk images for the CP/M emulation are located under the directory ~/z80pack-x.y/cpmsim/disks. The following table shows the CP/M disk drives and the used image files on the UNIX host:

Disk type CP/M disk UNIX filename
8" IBM SD drive a: ~/z80pack-x.y/cpmsim/disks/drivea.cpm
8" IBM SD drive b: ~/z80pack-x.y/cpmsim/disks/driveb.cpm
8" IBM SD drive c: ~/z80pack-x.y/cpmsim/disks/drivec.cpm
8" IBM SD drive d: ~/z80pack-x.y/cpmsim/disks/drived.cpm
4MB harddisk drive i: ~/z80pack-x.y/cpmsim/disks/drivei.cpm
4MB harddisk drive j: ~/z80pack-x.y/cpmsim/disks/drivej.cpm
512MB harddisk drive p: ~/z80pack-x.y/cpmsim/disks/drivep.cpm

The 512MB harddisk is supported by CP/M3 and MP/M 2 only, CP/M 2 can't access harddisks of this size, the limit are 8MB drives. Also a 512MB disk image isn't included, you can format one your self with the format program described below.

The files drivea.cpm and driveb.cpm are used for the DRI and UCSD p-System OS's and always are hard linked to the disk images under ~/z80pack-x.y/cpmsim/disks/library. The shell scripts to start the emulation with one of the boots disks first unlink this both files, and then link the images from the library directory to this files! If you wish to use your own disks a: and b: place the images under library directory and write similar shell scripts to boot your own disks.

The dives c: and d: are reserved for your own work, also future releases of z80pack won't touch them. However, there will be additional disk images for download sometime, and those also might need disk c: and/or disk d. So it is a good idea to keep copies of your own disks images elsewhere, so that they can't be removed. The directory ~/z80pack-x.y/cpmsim/disks/backups would be an acceptable place for this, no software distributed with or for z80pack will touch this directory.

The harddisk image (mounted on drive i:) comes filled with lots of CP/M software. This software has been placed in various user areas to avoid a huge mess, because the CP/M DRI OS's don't support directory structures. The following table shows the contents:

User area Contents
User 0 Assemblers, linkers, debuggers and various tools frequently used
User 1 DRI PLI compiler version 1.3
User 2 Aztec C compiler version 1.06D
User 3 DRI Pascal MT+ version 5.6.1
User 8 Various games: the Zork adventures, Sargon chess, Ladder, ...

All executable programs in user area 0 have the SYS attribute set. Under CP/M 3 and MP/M 2 you can execute the programs from other user areas with i:program, because this OS's honor the SYS attribute for files in user area 0 appropriate. CP/M 2 doesn't support this, which makes it uncomfortable to use user areas under this OS.

The link command to mount this disk as drive I: for CP/M is:

	ln disks/library/hd-tools.dsk disks/drivei.cpm

The image file for drive a: always must be available before you start the CP/M emulation (if not used with options -l or -x), the builtin bootloader tries to boot an OS from this disk image. If the file is not accessable the simulation will abort with an error message. All other drives are optional, if the files aren't in place and you try to access the disk under CP/M you'll get the usual BDOS error message, type CTRL-C to abort the disk access.

The program format in directory ~/z80pack-x.y/cpmsim is used to format empty disk images. It can be used for disks a-d, i-j and p. It knows about the required format for this disk images. Up to release 1.14 it would just format disks, even if the file exist. Beginning with release 1.15 it won't overwrite existing files, remove the file to format a fresh one.

No disklabels, timestamps or passwords are activated or used on the disk images included with z80pack. CP/M 2 doesn't support them and the implementation differences between CP/M 3 and MP/M 2 are enough to make a mess. If you want to use this features build your own disks and make sure to use them with the OS, which was used to activate the features before.

Now all that said again in simple words:
~/z80pack-x.y/cpmsim/disks includes the disk images the CP/M emulation uses as drives.
~/z80pack-x.y/cpmsim/disks/library includes your collection of disk images with whatever software you wish to use. Files in here are linked to the drives in the disks directory above.
~/z80pack-x.y/cpmsim/disks/backups contains backups of your disk library. This directory won't be touched by anything that comes with z80pack. Use it frequently.

Back