Creating a boot disk for rare CP/M computers - 8" & 5.25"

General discussion forum - for all that doesn't fit in any other category.
Post Reply
DazBit
Posts: 2
Joined: Tue Mar 20, 2012 4:49 am

Creating a boot disk for rare CP/M computers - 8" & 5.25"

Post by DazBit »

Hi,

This is my first post on the HxC forum. I am interested in buying a HxC floppy emulator to use on some rare old CP/M computers, including a HH Tiger (twin 5.25" floppy drives, double sided, double density) and a Plessey Telecoms PC80 (twin 8" drives, double sided, double density). The disk drives and floppies are getting old so I want to preserve these disks for the future and share disk images with others users of these machines. Please can somebody help me with the following questions:


1. Can I copy the CP/M boot (system) disk to the HxC and boot my computers from it?

2. Can I use the HxC to create a 'disk image' that I can share with other users of these computers?

3. Do I need the USB version or the SD card version of the HxC to do this, or will either be OK?

4. Some others posts have mentioned the number of tracks, sectors, data rates, skew tables, etc. Do I need to provide this information, and where do I find it?


If the HxC will do the job I will buy one straight away. I will probably need help with this project though. I'm good with electronics, but I don't know anything (yet) about floppy disk drives. If somebody can help me, I will be very happy to share everything I learn with the community.

Thanks,
Daz.

pulkomandy
Posts: 132
Joined: Sun Mar 20, 2011 6:55 pm

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by pulkomandy »

If your floppy drives are Shugart compatible (or close enough to it), there should not be too much problems.
The HxC behaves mostly like a floppy, so booting from it is possible. The main constraints are :
* No formatting support on the SD version. This means you have to keep a "blank", formatted floppy image and copy it when you need to create a new floppy.
* There may be some problems with mixing FM and MFM sectors, but I think this is being worked on.

The disk images are in the hfe format, this can be shared, or converted to more usual file formats when such formats exists.
The USB version stores the data directly to a modern computer, the SD version is more standalone. The USB version is useful if you want to move files a lot back and forth with a modern computer (when doing cross-development for example)

You need the following information to create your own floppy images :
* Number of tracks
* Number of sides
* Number of sectors in each track, and how much are FM/MFM
* bitrate of the drive
* spin speed of the drive
The skew table is usually not needed, it just makes things faster.

To find this data you need to check your drive, floppy controller and filesystem software user manuals. In CP/M times the format was specific to each combination of these, so they were given out in the manual to help you exchange data with other people.

Jeff
Site Admin
Posts: 8092
Joined: Fri Oct 20, 2006 12:12 am
Location: Paris
Contact:

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by Jeff »

pulkomandy wrote: * There may be some problems with mixing FM and MFM sectors, but I think this is being worked on.
in fact i already have a firmware supporting this. But for the moment this only for people asking it . ;)

Additionnal and prefered way to create an HFE file for "not yet tested" host : use the floppy dump/read tool. : This can be done "right now" (i mean : without having the hxc).
Additionnal way : use a KryoFlux.

pulkomandy
Posts: 132
Joined: Sun Mar 20, 2011 6:55 pm

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by pulkomandy »

The dump/read tool needs a 5.25" or 8" drive connected to a PC in this case - not a current setup in these modern times...
(but it should be possible anyway ?)

DazBit
Posts: 2
Joined: Tue Mar 20, 2012 4:49 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by DazBit »

Thanks Pulkomandy and Jeff for your help.

I don't think the floppy dump option would be for me because connecting an old 8" or 5.25" disk drive to my modern PC motherboard is beyond my ability! I have an old DOS PC from the early 90's that has a 5.25" drive, but I don't know if it still works.

As for the KryoFlux, I spent an hour looking in to it but I don't know enough to decide if the KryoFlux is more suitable for me. Because I have some other old computers like the BBC Micro and Amiga I think I'll go with the HxC, and I'd be happy if I could just use the HxC to backup my HH Tiger and Plessey PC80 CP/M disks in the HFE format.

Could you help me out with a few more questions?:

1. How do I know if my 8" or 5.25" drive is a Shugart (or Shugart compatible) drive? As far as I know, the 8" drives on the Plessey PC80 use a 50 pin ribbon cable, and the 5.25" drives on the HH Tiger use 34 way ribbon cables.

2. So, if I buy the HxC SD card version: Once I've created a boot disk image on the SD card, do I just backup the HFE file from the SD card to my PC? And then I can give the HFE image to other HxC users who have a HH Tiger or Plessey PC80 computer?

3. Can I use the HxC SD for multiple computers (BBC Micro, Amiga, CP/M computers), and have a separate directory on the SD card for each type of computer? (I suppose I'd need a different ribbon cable for each system)

Thanks,
Darren.

pulkomandy
Posts: 132
Joined: Sun Mar 20, 2011 6:55 pm

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by pulkomandy »

2 - yes, this will work fine.
3 - there are some jumpers and a configuration file on the SD card, so you may not even need to change the cable.

1 - As I said, best solution is to check the original docmentation for the hardware, if you can find it. You will need a special cable for the 8" drive (50 to 34 pin) at least, I don't know more about it...

ldkraemer
Posts: 51
Joined: Thu Feb 28, 2013 3:47 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by ldkraemer »

DazBit,
Before you start trying to copy the CP/M System Disk, Please make sure you have a SPARE 8" Floppy to work from.
Your OLD 8" Floppys are likely to not have enough Lubrication in the Floppy Sleeve to allow the Media to turn freely,
and by trying to read them one more time, you are likely to scrub off the Oxide Media. I've CONJURED up a totally
unapproved method of lubricating my old 5 1/4" floppies so I can read them without scrubbing off the Oxide media.

WARNING - UNAPPROVED METHOD:

One CAUTION here is that if your floppy disks are 25+ years old as mine were, the Oxide coating on most of the floppies is ready
to fail, and you may ruin them by trying to read them. (You may find that a tiny bit of alcohol placed on a cotton swab will totally
remove all the Oxide coating from the platter making then unreadable, so DON'T try Alcohol, WD40, or Silicone as a cleaner or lubricant for your floppies.) Also, the inner lining of the old floppies have lost their lubricating ability by becoming dry over the years, and this causes DRAG on the heads as the platter tries to spin so the read heads can recover the data.

I chose use a lubricant from KANO LABS in Nashville, Tennessee USA called Aerosol SiliKroil to lubricate my floppies. I was able to
recover about 85% of the disks using this TOTALLY UNAPPROVED method. I ruined the first 4-5 disks by trying to read them.
A costly ERROR!

http://www.kanolabs.com

SiliKroil is an Industrial Penetrating Lubricant that works wonders, and doesn't remove the Oxide coating as Alcohol and Silicone does.
Alcohol can be used to clean the floppy drives read heads as usual. You can make a SAMPLE purchase and select ONLY Silikroil,
giving you 3 Cans to work with. A Lifetime supply.

#1.
Your 8" Floppy's have a 50 Pin Connector as shown here:
http://old.pinouts.ru/Storage/
http://old.pinouts.ru/Storage/8InchDisk_pinout.shtml

You should check your CP/M System Schematics to VERIFY exactly what wiring was used on your Controller to Drive Interface.
You will also need to make a 50 Pin to 34 Pin Cable to be able to interface your 8" Drive to an IBM type Computer to read the
Disk into the HxC System's software.

If your CP/M System still Boots, and you have Lubricated the Floppy's, you can use the SYSGEN command to copy the System
Disk in A: to B: with:
sysgen A: B:

And then use the copy for all your work, protecting the Original. That should get you a copy of the CP/M System ready to read
into the HxC's Software.

Larry
Last edited by ldkraemer on Thu Feb 28, 2013 6:21 pm, edited 1 time in total.

ldkraemer
Posts: 51
Joined: Thu Feb 28, 2013 3:47 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by ldkraemer »

DazBit,
When you have your CP/M system booting, and functional you can use a lot of the system commands along with additional CP/M software to find the information for your system's CP/M Disk definition. ie. CPMADDR, DPB, PROBE, SKEW, and ANADISK which is DOS software.

I've written several Disk Definitions, and supplied those to the folks at SYDEX for their 22DISK program. 22DISK allows a IBM type Computer to read CP/M disks, and allows you to run those files (now with a .CPM extension) in their 22NICE Emulator.

The following is my NEW Disk Definition Document:

Some Helpful Hints on Developing a Disk Definition from Scratch

If possible, run programs on the CP/M system to help get the necessary information for building a new definition. The following files may be transferred by RS-232C if a Terminal Program is available.

1. CPMADR.COM - Finds addresses used by the CP/M system.

2. DPB.COM - Finds Disk Parameter Block information.
DPB.BAS - Same, but runs under MBASIC.

3. PROBE.COM - Probes CP/M System and Drive for information.
Note: The previous four programs may not locate and
display accurate information for some CP/M systems.

4. SKEW.COM - Finds disk SKEW information.

5. Execute the following "STAT" commands on system in question.
Note: "Control P" will allow a hardcopy of the information.

STAT DEV: - Displays current DEVICE information.
STAT VAL: - Displays current STATUS information.
STAT USR: - Displays current USR information.
STAT A*.* $S - Displays detailed file information.
STAT DSK: - Gives some detailed disk information for logged drive.
STAT A: DSK: - Gives some detailed disk information for A:.
STAT B: DSK: - Gives some detailed disk information for B:.

If you have a functional CP/M system, you can use DDT to find the Disk Parameter Block and the
information is stored there for each drive.

1. Log the drive you wish to locate the DPB data for. I will use A; for this example
2. Run DDT and enter the code below:
DDT
-f0100,0200,00
-A0100
0100 mvi c,1f
0102 call 5
0105 rst 7
0106 <Carriage Return>
-d0100
0100 0e1fcd0500FF
-g0100
*105
-x
The contents of register HL is the address of Drive A: DPB. If you display that address (mine was
F5E3) you will see F5E3: 2400040F0154007F00C00020000200.

RPT = 0024 = The number of 128 byte records per track.
BSH = 04 = The block shift count.
BLM = 0F = The block mask.
EXM = 01 = The extent mask.
DSM = 0054 = Disk storage maximum (the largest block number).
DRM = 007F = Directory maximum (the largest directory entry).
DAB = 000C= Directory Allocation Block AL0: = 00 & AL1: = 0C
CKS = 00020 = Directory check size.
OFF = 0002 = Track offset (number of reserved tracks).

SPT: Number of sectors per track. May differ from RPT if physical sectors are other than
128 bytes in size.

SSZ: Sector size code:
0 = 128 bytes per sector
1 = 256 bytes per sector
2 = 512 bytes per sector
3 = 1024 bytes per sector

NTK: Number of tracks (35, 40, 77, or 80). The number of tracks can be determined by formatting
a Floppy, or with Anadisk. Anadisk will also tell you the sector size and SKEW.

Quite frequently, the only information available when developing a definition for 22DISK is a
diskette with a few files and nothing more.

Here's a guide on what to do if you'd like to try working up a definition yourself:

1. Get a copy of Sydex's ANADISK. This utility will furnish far more information than will any
other program. A typical disk definition follows:

BEGIN AMP4 Ampro - DSDD 96 tpi 5.25"
DENSITY MFM,LOW
CYLINDERS 80 SIDES 2 SECTORS 5,1024 SKEW 2
SIDE1 0 17,18,19,20,21
SIDE2 1 17,18,19,20,21
ORDER SIDES
BSH 4 BLM 15 EXM 0 DSM 394 DRM 255 AL0 0F0H AL1 0 OFS 2
END


New definitions require the following information:

DENSITY xx,xx
CYLINDERS xx
SIDES xx
SECTORS x,xxxx
SKEW x
SIDE1 0 x,x1,x2,x3, , ,xn
SIDE2 x x,x1,x2,x3, , ,xn
ORDER x
BSH x
BLM x
EXM x
DSM x
DRM x
AL0 x
AL1 x
OFS x (or SOFS x)
COMPLEMENT (unlikely)

2. Run ANADISK on the diskette in SECTOR EDIT mode with the display set for "HEX".
Note that the interleave (or SKEW) is given, as well as the number, size and addresses of
sectors. You now have data for: DENSITY, CYLINDERS, SIDES, SKEW SIDE1 and SIDE2.

3. Locate the directory on the diskette. Almost invariably, it starts on the first sector of a track.
If for some reason it can't be found on the first sector of a track, try using the SEARCH feature
to find a "FILE" name that exists on the disk. The number of tracks or sectors up the point
where the directory begins will give the figure for OFS or SOFS. The directory stands out
because it shows file names every 32 bytes, or every other line on the ANADISK display.

Directory was located at Cylinder 0, Side 0, Sector 2:

0000 00 32 32 44 49 53 4b 20 20 44 4f 43 00 00 00 80 .22DISK DOC....
0010 02 00 03 00 04 00 05 00 06 00 07 00 08 00 09 00 ................
0020 00 32 32 44 49 53 4b 20 20 44 4f 43 01 00 00 80 .22DISK DOC....
0030 0a 00 0b 00 0c 00 0d 00 0e 00 0f 00 10 00 11 00 ................
0040 00 32 32 44 49 53 4b 20 20 44 4f 43 02 00 00 80 .22DISK DOC....
0050 12 00 13 00 14 00 15 00 16 00 17 00 18 00 19 00 ................
0060 00 32 32 44 49 53 4b 20 20 44 4f 43 03 00 00 80 .22DISK DOC....
0070 1a 00 1b 00 1c 00 1d 00 1e 00 1f 00 20 00 21 00 ............ .!.
0080 00 32 32 44 49 53 4b 20 20 44 4f 43 04 00 00 08 .22DISK DOC....
0090 22 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 "...............
00a0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00b0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00c0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00d0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00e0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00f0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0100 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0110 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0120 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0130 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0140 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0150 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0160 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0170 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0180 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0190 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01a0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01b0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01c0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01d0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01e0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01f0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................

Fig 1

Directory continues on Cylinder 0, Side 0, Sector 3:

0000 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0010 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0020 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0030 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0040 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0050 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0060 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0070 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0080 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0090 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00a0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00b0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00c0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00d0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00e0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
00f0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0100 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0110 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0120 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0130 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0140 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0150 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0160 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0170 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0180 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
0190 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01a0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01b0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01c0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01d0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01e0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................
01f0 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 e5 ................

Fig 2

4. Examine the first directory entry. The second 16 bytes (the second line of the entry) gives a list
of allocation unit numbers (AUN) belonging to the file. The first one of these will tell how many
allocation units have been reserved to hold the directory. Thus, if the first allocation byte is 02,
two allocation units have been allocated to the directory. Another thing to note is whether the
allocation unit number appears to be an 8 bit or 16 bit quantity. For example, if an entry has the
following form:

00 50 49 50 20 20 20 20 20 43 4F 4D 00 00 00 10 .PIP COM....
04 00 05 00 06 00 00 00 00 00 00 00 00 00 00 00 ................

the allocation unit designators are 4, 5 and 6 and are 16 bit quantities. On the other hand, the
following item:

00 50 49 50 20 20 20 20 20 43 4F 4D 00 00 00 10 .PIP COM....
04 05 06 00 00 00 00 00 00 00 00 00 00 00 00 00 ................

shows the same allocation units, but as 8 bit quantities. If 16 bit quantities are involved, more
than 255 allocation nits are defined for the diskette, if an 8 bit quantity, less than 256 units.
This serves as a check for later computations. In any case, the first allocation number of the
first directory entry gives the number of bits to be set in AL0 and AL1.

Allocation Unit Number (AUN)
02 AL0 11000000B Al1 0
04 AL0 11110000B Al1 0


The following information shows a detailed breakdown of all the information in the the first and
second directory entries.

00 - Valid file (E5 for Erased File)
32 32 44 49 53 4b 20 20 44 4f 43 - File name 22DISK DOC (11 bytes)
00 - Extent (used for large files)
00 - S1 (Digital Research Reserved)
00 - S2 (Digital Research Reserved)
80 - Number of records in this extent
02 00 03 00 04 00 05 00 06 00 07 00 08 00 09 00 - allocation units

Note: 02 is the first AUN.

00 - (Continuation of above file)
32 32 44 49 53 4b 20 20 44 4f 43 - File name 22DISK DOC (11 bytes)
01 - Extent (used for large files)
00 - S1 (Digital Research Reserved)
00 - S2 (Digital Research Reserved)
80 - Number of records used
0a 00 0b 00 0c 00 0d 00 0e 00 0f 00 10 00 11 00 - allocation units

Note: Unused allocation units will be 00.


5. Starting with the first directory sector, advance the sector (and track, if necessary) until you
find the data belonging to the first file. Unused directory entries are almost always filled out
with a pattern of E5's. The number of sectors dedicated to the directory will give an indication
of both the number of directory entries and the allocation unit size.


First Program located at Cylinder 0, Side 1, Sector 2:
NOTE: (This was the 9th sector displayed, so 8 are reserved for directory)

0000 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 20 20 20 20 ............
0010 20 20 53 79 64 65 78 0d 0a 0d 0a 0d 0a 0d 0a 0d Sydex.........
0020 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d ................
0030 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 20 ...............
0040 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0050 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0060 20 20 20 20 20 32 32 44 49 53 4b 0d 0a 0d 0a 0d 22DISK.....
0070 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
0080 20 20 20 20 20 41 20 43 50 2f 4d 2d 74 6f 2d 44 A CP/M-to-D
0090 4f 53 20 44 69 73 6b 65 74 74 65 20 49 6e 74 65 OS Diskette Inte
00a0 72 63 68 61 6e 67 65 20 55 74 69 6c 69 74 79 0d rchange Utility.
00b0 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d ................
00c0 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d ................
00d0 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 20 ...............
00e0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
00f0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0100 20 20 20 20 20 20 20 20 20 20 20 20 20 53 79 64 Syd
0110 65 78 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 ex..
0120 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0130 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0140 20 20 31 35 33 20 4e 6f 72 74 68 20 4d 75 72 70 153 North Murp
0150 68 79 20 41 76 65 2e 0d 0a 20 20 20 20 20 20 20 hy Ave...
0160 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0170 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0180 20 20 20 20 20 20 20 53 75 6e 6e 79 76 61 6c 65 Sunnyvale
0190 2c 20 43 41 20 20 39 34 30 38 36 0d 0a 20 20 20 , CA 94086..
01a0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
01b0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
01c0 20 20 20 20 20 20 20 20 20 20 20 28 34 30 38 29 (408)
01d0 20 37 33 39 2d 34 38 36 36 0d 0a 0d 0a 0d 0a 0d 739-4866.......
01e0 0a 0c 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a 0d 0a ................
01f0 0d 0a 0d 0a 0d 0a 0d 0a 20 20 20 20 20 20 20 20 ........

Fig 3


Suppose that a our hypothetical diskette shows 8 sectors of 512 bytes allocated to the directory.
Since a directory entry is 32 bytes long, the number of directory entries possible for this format is:

16 entries/sector X 8 sectors = 128 entries total
or
((Sector Size in Bytes/32) X Sectors to DIR) -1 = DRM


Thus, DRM is one less than this or 127. Since we know that these 8 sectors represent 2 allocation
units or 4,096 bytes, the Allocation Unit Size (AUS) is:

4,096 / 2 = 2,048 bytes
or
((Sector Size in Bytes) X Sectors to DIR) / AUN = AUS

Given this, we can use the following table to compute the values for BSH and BLM:


+------------+---------+----------+
| Unit Size | BSH | BLM |
+------------+---------+----------+
| 1,024 | 3 | 7 | +----------+
| 2,048 | 4 | 15 | ------+ This one |
| 4,096 | 5 | 31 | +----------+
| 8,192 | 6 | 63 |
| 16,384 | 7 | 127 |
+------------+---------+----------+


7. We still need a value for EXM and DSM. DSM is simply the total number of allocation units
on the diskette, not counting the system OFS area. Let's assume that our diskette has an offset
of 2 tracks and is single-sided with 40 cylinders with 8 sectors per track. The value of DSM
is then:

((40 cylinders X 1 side) - 2 tracks) X 8 sectors X 512 bytes) =
155,648 bytes / 2,048 = 76 Allocation units, total

To get EXM, we then use the following table:

+------------+-----------+-----------+
| Unit Size | DSM < 256 | DSM > 255 |
+------------+-----------+-----------+
| 1,024 | 0 | na |
| 2,048 | 1 | 0 |
| 4,096 | 3 | 1 |
| 8,192 | 7 | 3 |
| 16,384 | 15 | 7 |
+------------+-----------+-----------+


8. That's almost the complete picture, but for the SIDE1 and SIDE2 sector ordering. This is the
hardest to determine of any of the parameters. Find a readable text file on the diskette and
piece the text back together by observing how words break across sector boundaries. After a
bit, a pattern in the ordering will become apparent, such as:

1, 3, 5, 7, 2, 4, 6, 8

9. The ORDER value can be determined on double-sided diskettes by observing whether file
data appears to move from one track to the next on the same side (CYLINDERS), or appears to
go from one side to the other and then advance to the next cylinder (SIDES).

10. COMPLEMENT is rare. Generally, if a diskette appears to be formatted with values of 1A
instead of E5, the data on the diskette is complemented.

11. Last resort for information will require a memory dump from F200 hex through FFFF to
provide all the DBP information as hex bytes. It will be necessary to dig through 3584 (E00)
bytes of data to locate the DPB information. Most systems follow the layout shown below.


(Hex values starting in memory at Fxxx)
RPT: (word) total # of logical 128-byte sectors/track
BSH: (byte) data allocation block shift factor,
determined by data block allocation size
1k=3 2k=4 4k=5 8k=6 16k=7
BLM: (byte) data allocation block mask (2**[BSH-1])
1k=7 2k=15 4k=31 8k=63 16k=127
EXM: (byte) extent mask, determined by the data block
allocation size and the number of disk blocks
1k=0 2k=1 4k=3 8k=7 16k=15 if DSM < 256
1k=n 2k=0 4k=1 8k=3 16k=7 if DSM > 256
DSM: (word) disk size in blocks-1; determines the total
storage capacity of the disk size
DRM: (word) directory size-1; determines the total number
directory entries that can be stored on this
drive. DRM: = ((# dir entries) / 4) -1
AL0: (byte) alloc0 (1100 0000) 2 blocks/dir
(1000 0000) 1 block/dir
AL1: (byte) alloc1 (0000 0000)
Note that AL0: and AL1: are taken together
as a single sixteen-bit mask for the number
of blocks of directory allocation.
(1100 0000 0000 0000) 2 blocks/dir
(1000 0000 0000 0000) 1 block/dir
CKS: (word) directory check vector size
fixed media: CKS = 0
removable media: CKS = (DRM + 1)/4
OFF/SOFF: (word) # of reserved system tracks or sectors (offset)
at the beginning of the (logical) disk.
Usually the directory begins at the first
sector of the track defined by this number.

By formatting a disk the number of tracks can be determined, which will give the first byte to
look for. The SPT will be followed by 00 and the value for BSH and BLM will be the third and
fourth bytes.

BSH and BLM will be one of the following Hex values:

BSH 3 or 4 or 5 or 6 or 7
BLM 7 or 0F or 1F or 3F or 7F

The above information should be fairly easily to locate.

That should get you the information you need for your Question #4. And if you have that Definition, you can add it to the
SYDEX 22DISK Software allowing you to read your 8" Floppy's on an IBM typr Computer.


The current SYDEX Disk Definitions include:

The following disk types are supported by the registered version of 22DISK:
===========================================================================
Generic CP/M - SSSD 8"
ABC-80 - SSDD 48 tpi 5.25"
A. B. Dick Magna III - DSDD 48 tpi 5.25"
Actrix (Access Matrix) - SSDD 48 tpi 5.25"
Actrix (Access Matrix) - DSDD 48 tpi 5.25"
Action Computer Ent. Alloy 66 - SSHD 8"
Adler Textriter - SSDD 48 tpi 5.25"
Advanced Digital Super 6 - SSDD 48 tpi 5.25"
Advanced Digital Super 6 - DSDD 48 tpi 5.25"
Advanced Digital Super 6 - DSDD 96 tpi 5.25"
Advanced Digital Super 8 - DSDD 8"
Advanced Digital TurboDOS 312K - DSDD 48 tpi 5.25"
Advanced Digital TurboDOS 366K - DSDD 48 tpi 5.25"
Advanced Controls - DSDD 96 tpi 5.25"
Allen-Bradley Advisor+ - DSDD 3.5"
Altos - SSSD 8"
Altos - DSSD 8"
Altos - SSDD 8"
Altos - DSDD 8"
Altos Series 5 - DSDD 96 tpi 5.25"
Amada Horizon CNC - DSDD 3.5"
Amigo - SSDD 48 tpi 5.25"
Amigo - DSDD 48 tpi 5.25"
Ampro - SSDD 48 tpi 5.25"
Ampro - DSDD 48 tpi 5.25"
Ampro - SSDD 96 tpi 5.25"
Ampro - DSDD 96 tpi 5.25"
Ampro - SSDD 3.5"
Ampro - DSDD 3.5"
Amstrad PCW 8256 - DSDD 96 tpi 5.25"
Amstrad CPC464 - SSDD 48 tpi 5.25"
Amstrad CPC464 - SSDD 96 tpi 5.25"
Amstrad PCW 8512 - SSDD 48 tpi 5.25"
Amstrad PCW 8512 - DSDD 48 tpi 5.25"
Amstrad PCW 8512 - DSDD 96 tpi 5.25"
Amstrad CPC 6128 - DSDD 48 tpi 5.25"
Amstrad CPC 6128 - DSDD 96 tpi 5.25"
Amstrad CPC 6128 Side 1 - SSDD 3.5"
Amstrad CPC 6128 Side 2 - SSDD 3.5"
Amstrad PCW w/DU49, Moonstone XFORMAT - DSDD 3.5"
Amstrad CPC 6128 Vortex - DSDD 3.5"/96 tpi 5.25"
Amstrad PCW 9256, 9512 Disckit - DSDD 3.5"
Archive I - SSDD 96 tpi 5.25"
Archive II & III - DSDD 96 tpi 5.25"
Arisia - SSDD 48 tpi 5.25"
Associate - DSDD 48 tpi 5.25"
Aster CT-80 - DSDD 96 tpi 5.25"
ATR-8000 - SSDD 48 tpi 5.25"
ATR-8000 - DSDD 48 tpi 5.25"
ATT-7700 - DSDD 3.5"
Avatar - DSDD 48 tpi 5.25"
Barudan - DSDD 3.5"
Beehive - DSDD 48 tpi 5.25"
Beehive Microbee - DSDD 48 tpi 5.25"
Beehive Microbee - SSDD 3.5"
Computer Bell - DSDD 48 tpi 5.25"
Big Board (512 bytes/sector) - SSDD 8"
Big Board (512 bytes/sector) - DSDD 8"
Big Board 1024 bytes/sector - SSDD 8"
Bitelex - SSDD 48 tpi 5.25"
BMC IF800 Model 20 - DSDD 48 tpi 5.25"
Bondwell 12 - SSDD 48 tpi 5.25"
Bondwell 14 - DSDD 48 tpi 5.25"
Bondwell 2 - SSDD 3.5"
BOSS TurboDOS - DSDD 8"
BTI Systems - DSDD 48 tpi
Burr-Brown - DSDD 48 tpi 5.25"
Cal-PC - DSDD 48 tpi 5.25"
Cashcom 100 - DSDD 96 tpi 5.25"
Casio FP-1100/FP-1020 - DSDD 48 tpi 5.25"
Commodore Business Machines 1581 drive - DSDD 3.5"
CCS (256 bytes/sector) - DSDD 48 tpi 5.25"
CCS (512 bytes/sector) - DSDD 48 tpi 5.25"
CCS (1024 bytes/sector) - DSDD 48 tpi 5.25"
CCS 8 - DSDD 8"
CDI-5000 - DSDD 48 tpi 5.25"
COLEX 850 - SSDD 96 tpi 5.25"
COLEX 850 - DSDD 96 tpi 5.25"
CMC Supersystem 2 - DSDD 96 tpi 5.25"
Coin - DSDD 96 tpi 5.25"
Coleco ADAM, 40 track - SSDD 48 tpi 5.25"
Coleco ADAM, 254K - DSDD 48 tpi 5.25"
Coleco ADAM, 320K - DSDD 48 tpi 5.25"
Coleco ADAM, 720K - DSDD 3.5"
Coleco ADAM, 360K - DSDD 48 tpi 5.25"
Coleco ADAM, E&T PROM 720K - DSDD 3.5"
Coleco ADAM, 720K - DSDD 3.5"
Coleco ADAM, 1.44M - DSHD 3.5"
Coleco Adam TDOS - DSDD 5.25"
Columbia Commander 964 - DSDD 48 tpi 5.25"
Columbia 1600 - DSDD 96 tpi 5.25"
Compis - DSDD 96 tpi 5.25"
Compugraphic MCS-5 - SSDD 48 tpi 5.25"
Compustar Model 30 - DSDD 48 tpi 5.25"
Compustar 30, Super IOS - DSDD 48 tpi 5.25"
Compupro (Viasyn) 1,024 bytes/sector - DSDD 96 tpi 5.25"
Compupro (Viasyn) 8/16 1,024 bytes/sector - SSDD 8"
Compupro (Viasyn) 8/16 1,024 bytes/sector - DSDD 8"
Compupro (Viasyn) 512 bytes/sector - SSDD 8"
Compupro (Viasyn) 256 bytes/sector - SSDD 8"
Compupro (Viasyn) - DSSD 8"
Compupro (Viasyn) 512 bytes/sector - DSHD 8"
Compupro (Viasyn) 256 bytes/sector - DSHD 8"
Cromemco CDOS - SSSD 48 tpi 5.25"
Cromemco CDOS - DSSD 48 tpi 5.25"
Cromemco CDOS - SSDD 48 tpi 5.25"
Cromemco CDOS - DSDD 48 tpi 5.25"
Cromemco CDOS - DSDD 8"
Cromemco CP/M - SSDD 48 tpi 5.25"
Cromemco CP/M - DSDD 48 tpi 5.25"
C/WP Cortex - SSDD 48 tpi 5.25"
Cykey - DSDD 48 tpi 5.25"
Datavue DV80 - DSDD 48 tpi 5.25"
Datavue DV80 - DSDD 96 tpi 5.25"
Davidge - DSDD 96 tpi 5.25"
DEC DECMate II - SSDD 96 tpi 5.25"
DEC Rainbow - SSDD 96 tpi 5.25"
DEC VT-180 - SSDD 48 tpi 5.25"
Dictaphone 6000 CP/M - DSDD 96 tpi 5.25"
Dictaphone 6000 CP/M - DSDD 96 tpi 5.25"
Digilog 2500 - DSDD 48 tpi 5.25"
Digilog 1500 - DSDD 96 tpi 5.25"
Digitech 500 series - SSDD 3.5"
Digitech 500 series - DSDD 3.5"
Dimension 68000 - DSDD 48 tpi 5.25"
Direct 1025 - DSDD 48 tpi 5.25"
Direct 1025 - DSDD 96 tpi 5.25"
Discovery - DSDD 96 tpi 5.25"
Domino - DSDD 96 tpi 5.25"
Duet CP/M - DSDD 96tpi 5.25"
Eagle I, II - SSDD 96 tpi 5.25"
Eagle III, IV, V - DSDD 96 tpi 5.25"
Electroglas/Xynetics - DSDD 48 tpi 5.25"
Electroglas/Xynetics - DSDD 3.5"
Epson QX-10 - DSDD 48 tpi 5.25"
Epson QX-10 (256 bytes/sector) - DSDD 48 tpi 5.25"
Epson PX-10/8 - DSDD 3.5"
Epson QX-16 640K - DSDD 3.5"
Epson QX-16 - DSDD 96 tpi 5.25"
Ericsson DTC - SSDD 96 tpi 5.25"
Ericsson DTC - DSDD 96 tpi 5.25"
Ericsson Step One - DSDD 96 tpi 5.25"
Esprit DBS 16 - DSDD 96 tpi 5.25"
Estimation Inc. EST101 - DSDD 96 tpi 5.25"
Everett/Charles Kryterion 165 - DSDD 8"
Eureka A4 - DSDD 3.5"
Exidy Sorcerer - SSDD 48 tpi 5.25"
EXO - SSDD 8"
EXO - DSDD 8"
Facit DTC 6500/6503 - SSDD 96 tpi 5.25"
Facit DTC - DSDD 96 tpi 5.25"
Facit CP/M - SSDD 48 tpi 5.25"
F & G Cable Tester - DSDD 3.5"
Florida Graphics - DSDD 96 tpi 5.25"
Formula 1 - DSDD 48 tpi 5.25"
Fujitsu Micro 16 - DSDD 48 tpi 5.25"
Fujitsu Micro 8 - DSDD 48 tpi 5.25"
Future FX-20 - DSDD 96 tpi 5.25"
Gemini Galaxy - 5.25" DSDD 96 tpi
Globe 101 - 5.25" DSDD 96 tpi
Gnat System 10 - DSDD 48 tpi 5.25"
Graco OM-5000 - DSHD 5.25"
Hagiwara HPU 801 CP/M 68K - DSDD 3.5" Special
Hazeltine - DSDD 96 tpi 5.25"
Hollister, Inc. Hazel - SSHD 8"
HCL System 2 - DSDD 96 tpi 5.25"
Heath H89, Magnolia CP/M - SSDD 48 tpi 5.25"
Heath H89, Magnolia CP/M - DSDD 48 tpi 5.25"
Heath H89, Magnolia CP/M - DSDD 96 tpi 5.25"
Heurikon MLZ-91A - DSDD 96 tpi 5.25"
Hewlett-Packard HP 86, 87, 120, 125 - DSDD 48 tpi 5.25"
Hewlett Packard HP 125 - SSSD 8"
Hewlett Packard HP 125 - SSDD 3.5"
Hitachi HPC-6000 CP/M 68K - DSHD 1.2M 3.5"
Hitachi R-1500 CP/M 68K - DSHD 1.2M 5.25"
Strippit Houdaille Fab/V - DSDD 48 tpi 5.25"
IBM PC, CP/M-86 - SSDD 48 tpi 5.25"
IBM PC, CP/M-86 - DSDD 48 tpi 5.25"
IBS Ultraframe Turbo DOS - DSDD 5.25" 96 tpi
ICL DRS 20 - DSDD 5.25" 96 tpi
ICL DRS 300 - DSDD 5.25" 96 tpi
ICL Model 35/36 - DSDD 5.25" 96 tpi
IMS 5000 - SSDD 48 tpi 5.25"
IMS 5000 TurboDOS - DSDD 96 tpi 5.25"
IMS 5000 TurboDOS - SSDD 8"
IMS 5000 CP/M - DSDD 96 tpi 5.25"
IMS IP-120 - SSDD 8"
Intel iPDS 100 - DSDD 96 tpi 5.25"
Intuit - SSDD 48 tpi 5.25"
Insight Enterprises - DSDD 48 tpi 5.25"
Ithaca Intersystems - SSDD 96 tpi 5.25"
Ithaca Intersystems - SSDD 8"
Ithaca Intersystems - DSDD 8"
ITT 3030 - DSDD 48 tpi 5.25"
ITT 3030 - DSDD 96 tpi 5.25"
JC Information Systems TurboDOS - DSDD 96tpi 5.25"
Jet-80 - DSDD 48 tpi 5.25"
Jet-80 - DSDD 96 tpi 5.25"
Jonos - SSDD 3.5"
Kaypro II/2 - SSDD 48 tpi 5.25"
Kaypro 2X/4/10 - DSDD 48 tpi 5.25"
Kaypro 2X/4/10 (Alternate) - DSDD 48 tpi 5.25"
Kaypro, Pro-8 ROM - DSDD 96 tpi 5.25"
Kaypro Advent TurboROM - DSDD 48 tpi 5.25"
Kaypro Advent TurboROM - SSDD 48 tpi 5.25"
Kaypro Advent TurboROM - DSDD 96 tpi 5.25"
Kontron - DSDD 8"
Kontron/Zeiss - DSDD 96 tpi 5.25"
Kontron Transient Recorder- DSDD 96 tpi 5.25" & 3.5"
Lanier LTD READ-ONLY - DSDD 96 tpi 5.25"
Lexoriter - SSDD 48 tpi 5.25"
Lexoriter - DSDD 48 tpi 5.25"
Lobo Max-80 (256 bytes/sector) - SSDD 48 tpi 5.25"
Lobo Max-80 (256) - DSDD 48 tpi 5.25"
Lobo Max-80 (512 bytes/sector) - DSDD 48 tpi 5.25"
Lobo Max-80 (512 bytes/sector) - DSDD 96 tpi 5.25"
Lobo CP/M 2.2 - SSHD 8"
LNW 2 - SSDD 48 tpi 5.25"
Macsym 150 - SSDD 96 tpi 5.25"
Magic - DSDD 48 tpi 5.25"
MAI Basic Four - DSDD 96 tpi 5.25"
Marconi Midata 510 - DSDD 3.5"
MC CP/M DSDD 96 tpi 5.25"/3.5"
Memotech MaxBP #0A Format - DSDD 3.5"
Memotech FDX/MTX #03 Format - DSDD 48 tpi 5.25"
Memotech MTX #09 Format - DSDD 48 tpi 5.25"
Micron Quark - DSDD 48 tpi 5.25"
Micro Source M6000 - DSDD 48 tpi 5.25"
Michels and Kleberhoff CP/M 3 - DSDD 96 tpi 5.25"
Michels and Kleberhoff CP/M 3 - DSDD 48 tpi 5.25"
Mitsubishi PLC - DSDD 3.5"
Micromint SB180 Native 1 - DSDD 48 tpi 5.25"
Micromint SB180 Native 2 - DSDD 96 tpi 5.25"
Micromint SB180 Native 3 - SSDD 48 tpi 5.25"
Micromint SB180 Native 4 - SSDD 96 tpi 5.25"
Micromint SB180 - SSDD 3.5"
Micromint SB180 - DSDD 3.5"
MicroMint SB180 - DSDD 48 tpi 5.25"
Molecular Series 9 - DSDD 48 tpi 5.25"
Molecular/Durango Poppy 54 - DSDD 96 tpi 5.25"
Molecular - SSDD 8"
Monroe 8800 Series - SSDD 96 tpi 5.25"
Monroe System 2000 - DSDD 96 tpi 5.25"
Morrow MD2 - SSDD 48 tpi 5.25"
Morrow MD3, 5, 11, 16, 34 - DSDD 48 tpi 5.25"
Morrow 8 (512 bytes/sector) - SSDD 8"
Morrow 8 (1024 bytes/sector) - SSDD 8"
Morrow 8 (1024 bytes/sector) - DSDD 8"
Morrow TurboDOS - DSDD 48 tpi 5.25"
Morrow MD3...CP/M Plus - DSDD 48 tpi 5.25"
MOS 80 - DSDD 8"
MUPD/MDISK, Side I - SSSD 96 tpi 5.25
MUPD/MDISK, Side II - SSSD 96 tpi 5.25
MSD Systems PSC-1 POS - DSDD 5.25" 96 tpi
NCHQ System II - SSSD 48tpi 5.25
NCR Decision Mate V - DSDD 48 tpi 5.25"
NCR FirstStep - DSDD 96 tpi 5.25"
NDR - DSDD 96 tpi 5.25"/3.5"
NEC PC-8801A, 256 bytes/sector - DSDD 8"
NEC PC-8801A, 512 bytes/sector - DSDD 8"
NEC PC-8801A, 1024 bytes/sector - DSDD 8"
NEC PC-8001A - SSDD 48 tpi 5.25"
NEC PC-8001B - DSDD 48 tpi 5.25"
NEC PC-8801A 256 bytes/sector - DSDD 48 tpi 5.25"
NEC PC 8801A 512 bytes/sector - DSDD 48 tpi 5.25"
NEC PC 8801A 1024 bytes/sector - DSDD 48 tpi 5.25"
NEC PC 8500/8431A, Starlet - DSDD 3.5"
NEC Bungo - DSDD 3.5"
NEC APC CP/M-86 - DSHD 8"
New Brain - SSDD 96 tpi 5.25"
Niat - DSDD 96 tpi 5.25"
Nixdorf 8810/30 - DSDD 96 tpi 5.25"
Norsonic 830/836 - DSDD 3.5"
Numeridex 7000 - DSDD 8"
Octagon 8/16 - SSDD 8"
OEM Screen Typist - SSDD 3.5"
OKI IF800 Model 20 - DSDD 48 tpi 5.25"
Olivetti ETV300 - SSDD 48 tpi 5.25"
Olivetti M20 - DSDD 48 tpi 5.25"
Olivetti 250, CWP1 - SSDD 3.5"
Olivetti CWP1 - DSDD 3.5"
Olivetti ETV 1010, CP/M 86 - DSDD 48 tpi 5.25"
Olympia EX-100 - DSDD 48 tpi 5.25"
Olympia ETX II - SSDD 48 tpi 5.25"
Olympia Olytext 20 - DSDD 3.5"
Olympia People - DSDD 96tpi 5.25"
Osborne 1 - SSSD 48 tpi 5.25"
Osborne 1 - SSDD 48 tpi 5.25"
Osborne Executive - SSDD 48 tpi 5.25"
Osborne G2 System - DSDD 48 tpi 5.25"
Osborne G2 System - DSDD 96 tpi 5.25"
Osborne 1 + Osmosis - DSDD 96 tpi 5.25"
Osborne Nuevo - DSDD 48 tpi 5.25"
Osborne Vixen - DSDD 48 tpi 5.25"
Osborne Executive w/Z3 - DSDD 96 tpi 5.25"
Osborne Executive Dig. Arts - DSDD 48 tpi 5.25"
Osborne Nuevo 2.1 - DSDD 96 tpi 5.25"
OSM Zeus 4 - DSDD 96 tpi 5.25"
Otrona Attache - DSDD 48 tpi 5.25"
Otrona Attache - DSDD 96 tpi 5.25"
Panasonic KX-E828 - DSDD 48 tpi 5.25"
Potter & Brumfield - SSSD 48 tpi 5.25"
Perf. Bus. Mach. PBM-1000 - DSDD 96 tpi 5.25"
Pegasus Data Logger - DSDD 48 tpi 5.25"
People's World Computer - SSDD 48 tpi 5.25"
People's World Computer Boot Disk - SSDD 48 tpi 5.25"
Pericom - DSDD 96 tpi 5.25"
Philips PC-2010 - SSDD 48 tpi 5.25"
Philips PC-2012 - DSDD 96 tpi 5.25"
Philips PC-3000 - 3004 - SSDD 96 tpi 5.25"
Physical Acoutstics - DSDD 48 tpi 5.25"
Pied Piper - DSDD 96 tpi 5.25"
PMC Micromate - DSDD 48 tpi 5.25"
Prince Digico - DSDD 96 tpi 5.25"
Proglas 770K - DSDD 96 tpi 5.25"
Pulsar LBB - SSHD 8"
QDP-500 - DSHD 5.25" 96 tpi
Quay - DSDD 5.25" 48 tpi
Remanco "Back of the House" - DSDD 96 tpi 5.25"
Royal Alphatronic - DSDD 48 tpi 5.25"
Sage IV - DSDD 48 tpi 5.25"
Sage IV - DSDD 96 tpi 5.25"
Sanyo MBC-1000, 1100, 1150 - DSDD 48 tpi 5.25"
Sanyo MBC-1160, 1250, 4050 - DSDD 96 tpi 5.25"
Sanyo MBC-2000 - SSDD 96 tpi 5.25"
Sanyo MBC-3000 - DSDD 8"
Sanco 8001 - DSDD 48 tpi 5.25"
Schneider CPC 6128 Side 1 - DSDD 5.25"
Schneider CPC 6128 Side 2 - DSDD 5.25"
S.D. Systems 40 track - SSDD 3.5"
S.D. Systems 80 track - DSDD 3.5"
Seequa Chameleon - SSDD 48 tpi 5.25"
Seequa Chameleon - DSDD 48 tpi 5.25"
Seiko - DSDD 96 tpi 5.25"
SemiDisk DT42 - DSDD 48 tpi 5.25"
SemiDisk DT42 - DSDD 96 tpi 5.25"
SemiDisk DT42 - DSHD 96 tpi 5.25"
Sharp MZ-80 - DSDD 48 tpi 5.25"
Sharp MZ-80B - DSDD 48 tpi 5.25"
Sharp 3500/5500 - DSDD 48 tpi 5.25"
Sharp 5600 - DSDD 96 tpi 5.25"
Sharp MZ 3541 - DSDD 48 tpi 5.25"
Shelton SIG/NET 2 - SSDD 48 tpi 5.25"
Shelton SIG/NET 2 - DSDD 48 tpi 5.25"
Shelton SIG/NET 2 - DSDD 96 tpi 5.25"
Siemens PG-685 DSDD 96 tpi 5.25"
Siemens PG-675 DSDD 48 tpi 5.25"
Siemens PG-635 - DSDD 3.5"
Siemens PG-3101A - DSDD 5.25" 48 tpi
Smart Aleck - SSDD 5.25" 48 tpi
Sorbus TurboDOS - 5.25" DSHD (or 8" DSDD)
Sony SMC-70 - SSDD 3.5"
Spectravideo 318/328 - SSDD 48 tpi 5.25"
Spectravideo SV-328 - DSDD 48 tpi 5.25"
Sperry UTS 30, UTS 5000 - DSDD 96 tpi 5.25"
Spectravideo - SSDD 48 tpi 5.25"
Spectravideo - DSDD 48 tpi 5.25"
Spectravideo - DSDD 48 tpi 5.25"
Spectravideo - SSDD 3.5"
Superbrain JR - SSDD 48 tpi 5.25"
Superbrain 40 track - SSDD 48 tpi 5.25"
Superbrain QD - DSDD 48 tpi 5.25"
Superbrain II - DSDD 96 tpi 5.25"
Superbrain - SSDD 48 tpi 5.25"
System Group 2800 - DSDD 8"
Systel 2 - SSDD 48 tpi 5.25"
Systel 3 - DSDD 48 tpi 5.25"
Tarbell - DSDD 8"
Tatung TPC2000 - DSDD 96 tpi 5.25"
Techron TEF 10 - DSDD 96 tpi 5.25"
Techron TEF 12 - DSHD 96 tpi 5.25"
Tektronix 4170 - DSDD 48 tpi 5.25"
Teletek - SSDD 8"
Teletek Systemaster - DSDD 48 tpi 5.25"
Teletek Systemaster - DSDD 96 tpi 5.25"
TeleVideo 800-series, TPC-1 CP/M - DSDD 48 tpi 5.25"
TeleVideo 1603 - DSDD 96 tpi 5.25"
TeleVideo 806 TurboDOS - DSDD 48 tpi 5.25"
TeleVideo 800-series, TurboDOS - DSDD 48 tpi 5.25"
Telcom 6.2 CP/M - DSDD 3.5"
TI Professional, CP/M-86 - SSDD 48 tpi 5.25"
TIKI-100, 200K - SSDD 48 tpi 5.25"
TIKI-100, 400K - DSDD 48 tpi 5.25"
Timex/Sinclair 2068+AERCO FD-68 RP/M - DSDD 48 tpi 5.25"
Tokyo Electron 80W - 3.5" DSHD
Toshiba T100, T200 - DSDD 48 tpi 5.25"
Toshiba 300 - DSDD 96 tpi 5.25"
Toshiba T-250 - DSHD 8"
Transtec - SSDD 96 tpi 5.25"
TRS-80 Model 1, Omikron CP/M - SSSD 48 tpi 5.25"
TRS-80 Model 1, Bigmem CP/M - SSDD 8"
TRS-80 Model 1, Color Power II - SSDD 48 tpi 5.25"
TRS-80 Lifeboat CP/M (256 bytes/sector) - SSDD 8"
TRS-80, Lifeboat CP/M (1024 bytes/sector) - SSDD 8"
TRS-80, Pickles & Trout CP/M - SSDD 8"
TRS-80, Holmes CP/M - DSDD 48 tpi 5.25"
TRS-80, MM CP/M - SSDD 48 tpi 5.25"
TRS-80 Model 4, 4P; MT CP/M - SSDD 48 tpi 5.25"
TRS-80 Model 4, 4P; MT CP/M - DSDD 48 tpi 5.25"
TRS-80 Model 4, 4P - SSDD 48 tpi 5.25"
TRS-80 Model 3 - Hurricane CP/M - SSDD 48 tpi 5.25"
TRS-80 Model 4P - Montezuma 800K - DSDD 96 tpi 5.25"
TRS-80 II/12/16 Aton CP/M - SSHD 8"
TRS-80 II/12/16 Aton CP/M - DSHD 8"
TRS-80 II/12/16 Pickles & Trout - DSHD 8"
U-Micro 1000 - DSDD 96 tpi 5.25"
Varian Spectra AA/20, DS-15 - 5.25" DSDD
Vector 4 - DSDD 96 tpi 5.25"
Visual 1050 - SSDD 96 tpi 5.25"
Wangwriter - DSDD 48 tpi 5.25"
Wave Mate Bullet - SSDD 48 tpi 5.25"
Wave Mate Bullet - DSDD 96 tpi 5.25"
Wave Mate Bullet - DSDD 48 tpi 5.25"
Wave Mate Bullet - SSHD 8"
Xerox (512 byte/sector) - DSDD 48 tpi 5.25"
Xerox 820 - SSSD 48 tpi 5.25"
Xerox 820 II - SSDD 48 tpi 5.25"
Xerox 820-II, 16/8 - DSDD 48 tpi 5.25"
Xerox 16/8 - SSDD 8"
Xerox 16/8 - DSDD 8"
XEROX 16/8 - DSDD 48 tpi 5.25"
Xerox 820, S/W Publishers DD - SSDD 48 tpi 5.25"
Xerox 3700 Laser Printer - DSDD 48 tpi 5.25"
Xerox 1800 - DSDD 96 tpi 3.5"/5.25"
Xerox 16/8, 820 II - SSDD 48 tpi 5.25"
Xerox 16/8 - SSDD 48 tpi 5.25"
Xerox 16/8 Special - SSDD 48 tpi 5.25"
Xerox 16/8, 820-II - DSDD 48 tpi 5.25"
Xerox 16/8 Special - DSDD 48 tpi 5.25"
Xor 5 - DSDD 48 tpi 5.25"
XYZ - DSDD 48 tpi 5.25"
Zeiss Video Analysis System - DSDD 96 tpi 5.25"
Zenith Z-37 Disk - SSSD 48 tpi 5.25"
Zenith Z-37 Disk - DSDD 96 tpi 5.25"
Zenith Z89, Heath H89 - DSDD 48 tpi 5.25"
Zenith Z89, Heath H89 - DSDD 96 tpi 5.25"
Zenith Z90 - SSDD 48 tpi 5.25"
Zenith Z90 - DSDD 48 tpi 5.25"
Zenith Z-100 - SSDD 48 tpi 5.25"
Zenith Z-100 - DSDD 48 tpi 5.25"
Zenith Z-100 - SSSD 8"
Zenith Z-100 - SSDD 8"
Zenith Z-37 Disk - DSDD 96 (Half drive) 5.25"
Zenith/Heath H-89 Extended Density - DSDD 48 tpi 5.25"
Zenith Z-100, Heath H-47 Extended Density - DSDD 8"
Zenith Z-100, Heath H-47 - DSDD 8"
Zenith Z-37 - SSDD 48 tpi 5.25"
Zenith Z-37 ED - DSDD 96 tpi 5.25"
Zenith/Heath H89/H90 Magnolia 7736 - SSHD 8"
Zorba - DSDD 48 tpi 5.25"
Zorba - DSDD 96 tpi 5.25"

If your CP/M system isn't in the list I also have several European Definition files that aren't REGISTERED with SYDEX, but I'm sure they still function. If your system is in the list, and you identify it, I can give you the specifics of your 8" Drive information.
So, look over the list carefully. Let me know......

Larry
Last edited by ldkraemer on Thu Feb 28, 2013 6:34 pm, edited 1 time in total.

ldkraemer
Posts: 51
Joined: Thu Feb 28, 2013 3:47 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by ldkraemer »

DazBit,
Here is a bit of information I found on the WEB, about a 50 Pin Connector cable to 34 Pin.

Exerpted from the "CP/M FAQ", available via any Web search. This
was exerpted Dec 20th 2006, check the most recent version. - Herb Johnson

Q14: Can I read my 8" disks with my PC?

A: (John Baker, Tom Sullivan)

With a program called 22disk, and an adaptor board that you can
make, you can read those disks on your PC. All it takes is
rearranging some of the lines on the 34 pin cable, and wiring them
to the 50 pin cable, and you're in business.

The interface on 8" drives and 5 1/4" drives are essentially the
same. The 34 lines on a typical 5 1/4" controller are sufficient to
control most 8" disk drives using soft-sectored disks. Here, is a
diagram for a basic conversion cable to allow connection of an 8"
drive to an IBM-compatible, AT-style (high density) controller.

8" disk drive
PC-AT style controller Based on Shugart SA-851

Grnd. Sig. Sig. Name Sig Name Sig Grnd
1 2 Double/High Density ->>
>>- Write Current Switch/ 2 1
Active Read Compensation
User Customizable I/O pins 4 3
" " " " 6 5
33 34 **Ready ---------------<<------------ True Ready 8 7
<<-------------#Two Sided 10 9
33 34 **Disk Change ---------<<----------- Disk Change 12 11
31 32 Side 1 Select ------->>-----------#Side Select 14 13
3 4 In Use/Open --------->>---------------- In Use 16 15
15 16 *Motor On ------------>>------------- Head Load 18 17
7 8 Index ---------------<<----------------- Index 20 19
33 34 **Ready ---------------<<----------------- Ready 22 21
<<---------------##Sector 24 23
9 10 Drive Select 0 ------>>-------- Drive Select 1 26 25
11 12 Drive Select 1 ------>>-------- Drive Select 2 28 27
13 14 Drive Select 2 ------>>-------- Drive Select 3 30 29
5 6 Drive Select 3 ------>>-------- Drive Select 4 32 31
17 18 Direction Select ---->>------ Direction Select 34 33
19 20 Step ---------------->>------------------ Step 36 35
21 22 Write Data ---------->>------------ Write Data 38 37
23 24 Write Gate ---------->>------------ Write Gate 40 39
25 26 Track 00 ------------<<-------------- Track 00 42 41
27 28 Write Protect -------<<--------- Write Protect 44 43
29 30 Read Data -----------<<------------- Read Data 46 45
<<------##Separation Data 48 47
<<-----##Separation Clock 50 49

This diagram also works in the other direction--that is, to attach
high-density 5 1/4" drives to an 8" controller.

Notes:

* - It seems to be a logical substitution since the vast majority of
8" drives have continuously running spindles and instead of
MOTOR ON require a HEAD LOAD signal. Also, a controller sends
MOTOR ON before a DRIVE SELECT.

**- Most 5 1/4" disk drives do not provide a READY signal but send a
DISK CHANGE signal on line 34 of the interface. An 8" drive has
provisions for both signals. Likewise, most AT-style
controllers expect a DISK CHANGE signal on line 34, so lines 33
and 34 should be connected to lines 11 and 12 of the 8" disk
connector. Also, some 8" drives provide a TRUE_READY signal
which is more useful than the standard READY.

# - Unused on single sided drives (SA-800/801).

##- Used only on hard-sector configured drives (SA-801/851).

Some 5 1/4" disk drives have the option of providing _either_ DISK
CHANGE _or_ READY on line 34 (in particular, the TEAC FD55R
series). Some 8" disk controllers do not care about the DISK CHANGE
signal, but must have the READY signal. If you are attaching a
high-density 5 1/4" drive to an 8" controller, you may get away with
making the drive always ready by shorting lines 21 and 22, but this
may cause a few re-tries when switching sides. If your drive offers
a READY signal that your controller can deal with, by all means use
it.

The MOTOR ON/HEADLOAD dilemma may also have an alternate solution if
you are connecting 5 1/4" drives to an 8" controller. Some 5 1/4"
drives permit motor turn-on by means other than the MOTOR ON
signal. For example, the TEAC FD55R series of drives may be
configured to turn the motor on based on the state of the IN USE
light. The IN USE light can, in turn, be set to turn on only on
drive select. Thus selecting the drive automatically turns on the
motor and neither a MOTOR ON or IN USE signal need be present.

Another way to handle 8 inch drives on a PC is with a Microsolutions
Compaticard IV, if you can find one. (MicroSolutions no longer
offers this product.) It has the necessary software support to
properly handle 8 inch drives, and in both SSSD and DSDD. This
controller can be set up as both a primary controller, or as a
secondary. It can support 4 drives, of any type, including 2.8 meg.
It supports two MSDOS 8 inch formats, SSSD (about 250k) and DSDD
(1.2 meg). It works perfectly with 22disk, and can read and write
almost any 8 inch CP/M format.

REF:
http://www.retrotechnology.com/herbs_st ... howto.html

Larry

ldkraemer
Posts: 51
Joined: Thu Feb 28, 2013 3:47 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by ldkraemer »

DazBit,
Here is a CP/M Reference Guide that I had saved. You might be interested if you haven't used CP/M much.

JUST BE SURE TO DO A "CNTL C" ANY TIME YOU REMOVE AND INSERT A FLOPPY, to REFRESH the System's Drive Information.



CP/M ver 1.4 & 2.x Programmer's Reference Guide
========================================================


BUILT-IN COMMANDS
=================

DIR Display file directory, current drive
DIR d: Display file directory, designated drive
DIR filename.typ Search for file name, current drive
DIR *.typ Display all files of named type, curr drive
DIR filename.* Display all types of designated filename
DIR x????.* Display all filenames 5 characters long and
starting with letter x

TYPE filename.typ Display ASCII file, current drive
TYPE d:filename.typ Display ASCII file, designated drive

ERA filename.typ Erase named file, current drive
ERA *.* Erase all files, curr drv, ver 2.x curr user
ERA *.typ Erase all files, current drive
ERA d:filename.typ Erase named file, designated drive
ERA filename.* Erase all types of named file, current drive

REN nuname.typ=olname.typ Rename file, current drive
REN d:nuname.typ=olname.typ Rename file, designated drive

SAVE n filename.typ Save as named file, current drive
SAVE n d:filename.typ Save as named file, designated drive
n pages (page = 256 bytes) starting at 100H

d: Switch to designated drive, making it current drive
V 1.4: A-D V 2.x: A-P

USER n Change user area (n=0 to 15) (ver 2.x)



TRANSIENT COMMANDS
==================

DDT Initiate Dynamic Debugging Tool
DDT filename.typ Initiate DDT and load named file

ASM filename Assemble named ASM file on current drive
ASM d:filename Assemble named ASM file on designated drive
ASM filename.abc Assemble named ASM file:
a = source file drive
b = HEX file destination drive (Z=skip)
c = PRN file destination drive (X=console,Z=skip)

LOAD filename Make COM file from named HEX file on current drive
LOAD d:filename Make COM file from named HEX file on design. drive

DUMP filename.typ Display file in hex, current drive
DUMP d:filename.typ Display file in hex, designated drive

MOVCPM Relocate and execute (max) KByte CP/M system
MOVCPM n Relocate and execute n KByte CP/M system
MOVCPM n * Create relocated image in RAM of n Kbyte
CP/M system, ready for SYSGEN or SAVE
MOVCPM * * Create relocated image in RAM of (max) Kbyte
CP/M system, ready for SYSGEN or SAVE

SYSGEN Initiate SYStem GENerate program

SUBMIT filename parameters Execute SUB file using optional parameter(s)

XSUB Execute eXtended SUBmit program (V2.x)

ED filename.typ Execute EDitor to create or edit named file
ED d:filename.typ Execute EDitor to create or edit named file

STAT Display STATus (R/W or R/O) \/ current drive
STAT d: and available disk space /\ design. drive
STAT DEV: Display DEVice assignments
STAT VAL: Display VALid device assignments
STAT DSK: Display DISK characteristics (V2.x)
STAT USR: Display current USeR areas (V2.x)
STAT filename.typ $S Display size of file (V2.x)
STAT fiename.typ Display file characteristics, current drive
STAT d:filename.typ Display file characteristics, designated drive
STAT d:=R/O Change designated drive to Read-Only
STAT filename.typ $R/O Change named file to Read-Only (V2.x)
STAT filename.typ $R/W Change named file to Read-Write (V2.x)
STAT filename.COM $SYS Change named file to System file (V2.x)
STAT filename.COM $DIR Change named file to Directory file (V2.x)
STAT gd:=pd: Change general device (CON:,LST:,PUN:,RDR:)
assignment of physical device (IOBYTE)


PIP
===

Commands
--------

PIP Initiate Peripheral Interchange Program
*d:=s:filename.typ Copy named file from source drive to dest drive
*d:nuname.*=s:olname.typ Copy & rename from source drive to dest drive
PIP d:=s:filename.typ Initiate PIP and copy named file
PIP d:=s:*.* from source drive \/ all files
PIP d:=s:filename.* to || all named files
PIP d:=s:*.typ destination drive /\ all files named type
PIP LST:=filename.typ Send named file to list device
PIP PUN:=filename.typ Send named file to punch device
PIP CON:=filename.typ Send named file to console device
PIP filename.typ=RDR: Copy data from reader device to named file

*nuname.typ=aname.typ,bname.typ,cname.typ ASCII copy & concatenate
*nuname.typ=aname.typ,bname.typ ASCII copy & concatenate
*nuname.typ=aname.typ[X],bname.typ[X] binary copy & concatenate

PIP LST:=aname.typ,bname.typ Send files in sequence to list device
PIP LST:=s:aname.typ,s:bname.typ Send files in sequence to list device

PIP allows access to any logical and physical devices defined in the
CP/M system. Logical devices: CON: RDR: PUN: LST:
Physical devices: TTY: CRT: PTR: UR1: UR2: PTP: UP1: UP2: LPT: UL1:

Special PIP devices (locations 109H to 1FFH are not used in the PIP
image and can be replaced by used drivers using DDT)
NUL: Send 40 NUL's (ASCII 00H) to the device
(can be issued at the end of punched output)
EOF: Send a CP/M EOF (ASCII Ctrl-Z=1AH) to dest device
(sent automatically at end of ASCII transfers thru PIP)
INP: Special PIP input source which can be patched into PIP:
PIP gets input from here by calling 103H, with data
returned at 109H)
OUT: Special PIP output destination which can be patched into PIP:
PIP calls 106H with data to be output in C for each char.
PRN: Same as LST: except that tabbs are expanded to every 8th
column, lines are numbered, and page ejects are inserted
every 60 lines with an initial eject (same as PIP options [t8np])


Parameters
----------

example *filename.typ=RDR:

- read data block until ^S (ctrl-S) character
[Dn] - delete characters past column n
[E] - echo all copy operations to console
[F] - remove form feeds
[Gn] - get file from user area n (V2.x)
[H] - check for proper HEX format
- same as H plus ignores ":00"
[L] - change all upper case characters to lower case
[N] - add line numbers without leading zeros
[N2] - same as N plus leading zeros and a TAB after number
[O] - object file transfer; ignore end-of-file (Ctrl-Z)
[P] - insert form feed every 60 lines
[Pn] - insert form feed every n lines
[Qstring^Z] - Quit copying after string is found
[R] - read SYS file (V2.x)
[Sstring^Z] - Start copying when string is found
[Tn] - expand tab space to every n columns
- change all lower case characters to upper case
[V] - verify copied data (destination must be disk file)
[W] - delete R/O files at destination (V2.x)
[X] - copy non-ACII files
[Z] - zero parity bit (hi bit) on all characters in file



Keywords
--------

CON: CONsole device (defined in BIOS)
EOF: send End-of-File (ASCII ^Z) to device
INP: INPut source (pathced in PIP)
LST: LiST device (defined in BIOS)
NUL: send 40 NUL's to device
OUT: OUTput destination (pathced in PIP)
PRN: same as LST:; tabs every 8th char, number lines & page
ejects every 60 lines with initial eject
PUN: PUNch device (defined in BIOS)
RDR: ReaDeR device (defined in BIOS)



COMMAND CONTROL CHARACTERS
==========================

Control char ASCII code Function

C 03h Reboot - CP/M warm boot
E 05h Start new line
H 08h Backspace and delete (V2.x)
I 09h Tab 8 columns
J 0Ah Line feed
M 0Dh Carriage return
P 10h Printer on/Printer off
R 12h Retype current line
S 13h Stop display outout (any char except ^C restarts)
U 15h Delete line
X 18h Same as Û (V1.4)
Z 1Ah End of console input (ED & PIP)
delete/rubout 7Fh Delete and display character (tape only)



ASM
===

Conventions
-----------

line# label operation operant ;comment

labels followed by colon 1-16 alphanumeric characters
symbol (eq. EQU) no colon first must be alpha, ? or .
labels are case insensitive (treated as uppercase)
$ is insignificant and can be inserted
anywhere for readability


Assembly Program Format (space separates fields)

[line#] label: opcode oerand(s) ;comment

Constants
A number of digits with a suffix:
B binary
O or Q octal
D decimal (default)
H hexadecimal

Reserved words in operand fields

The names of the 8080 registers are reserved, and produce the
following values if encountered in the operand field:

A 7
B 0
C 1
D 2
E 3
H 4
L 5
M 6
SP 6
PSW 6

Mnemonics for machine instructions are reserved and evaluate to
their internal codes. Instructions which require operands will
get zeroes in their operand fields, e.g. MOV will produce 40H

The symbol $ in the operand field evaulates to the address of
the next instruction to generate, not including the instruction
within the current logical line

String constants are delimieted by an apostrophe ('), and a
double apostrophe ('') will produce one apostrophe


Operators (unsigned)

a+b a added to b
a-b difference between a and b
+b 0+b (unary addition)
-b 0-b (unary subtraction)
a*b a multiplied by b
a/b a divided by b (integer)
a MOD b remainder after a/b
NOT b complement all b-bits
a AND b bit-by-bit AND of a and b
a OR b bit-by-bit OR of a and b
a XOR b bit-by-bit XOR of a and b
a SHL b shift a left b bits, end off, zero fill
a SHR b shift a right b bits, end off, zero fill


Hierarcy of operations

highest: * / MOD SHL SHR
- +
NOT
AND
OR XOR



Pseudo-ops

ORG const Set program or data origin (Default=0)
END start End program, optional address where excution begins

EQU const Define symbol value (may not be changed)
SET const Define symbol value (may be changed later)

IF const Assemble block conditionally until ENDIF
ENDIF Terminate conditionala ssembly block

DS const Define storage sace for later use
DB byte[,byte...] Define bytes as numeric or ASCII constants
DW word[,word...] Define words (two bytes)

const=constant (true if bit 0 is 1, otherwise false)


Error codes
-----------

D Data error (element cannot be placed in data area)
E Expression error (ill-formed expression)
L Label error
N Not implemented
O Overflow (expression too complicated to compute)
P Phase error (label has different values on each pass)
R register error (specified value not compatible with op code)
U Undefined label (label does not exist)
V Vaue error (operand improper)

Fatal errors
------------

NO SOURCE FILE PRESENT
NO DIRECTORY SPACE
SOURCE FILE NAME ERROR
SOURCE FILE READ ERROR
OUTPUT FILE WRITE ERROR
CANNOT CLOSE FILE


FILE TYPES
==========

ASC ASCII text file, usually Basic source
ASM ASseMbly langaige file (source for ASM program)
BAK BAcKup copy file (created by editor)
BAS BASic source program file, usually tokenized
COM COMmand file (transient exeuctable program)
DAT DATa file
DOC DOCument file
FOR FORtran source program file
INT INTermediate Basic program file (executable)
HEX HEXadecimal format file (for LOAD program)
LIB Library file used by macro assembler
PLI PL/I source file
PRN PRiNt file (source and object produced by ASM)
REL RELocatable file
SAV System file (V2.x)
SUB SUBmit text file executed by SUBMIT program
SYM SID symbol file
TEX TEXt formatter source file
XRF Cross reference file
$$$ Temporary file

Filename - 8 characters maximum
Filetype - 3 characters maximum

Invalid filename and filetype characters
< > . , ; : = ? [ ]



DDT COMMANDS
============

DDT
DDT filename.HEX
DDT filename.COM

A sad Assemble symbolic code; start at sad

D Dump RAM to console from cad, 16 lines
D sad Dump RAM to console from sad, 16 lines
D sad,ead Dump RAM to console from sad thru ead

F sad,ead,const Fill RAM from sad thru ead with const

G Start program exec. at saved PC
G sad Start program exec. at sad
G sad,bp1 Start program exec. at sad and stop at bp1
G sad,bp1,bp2 Start program exec. at sad and stop at bp1 or bp2
G,bp1,bp2 Start program exec. at cad and stop at bp1 or bp2
G0 Jump to 0000H ==> exits DDT (equivalent to Ctrl-C)

H a,b Display hex a+b and a-b

I filename Set up FCB at 5CH for user code
I filename.typ Set up FCB at 5CH for R-command (HEX or COM file)

L Disassemble RAM from cad, 12 lines
L sad Disassemble RAM from sad, 12 lines
L sad,ead Disassemble RAM from sad thru ead

M sad,ead,nad Move RAM block from sad thru ead to nad

R Read file specified by I command to RAM
R offset at normal address + optional offset
The R command requires a previos I command
There is no W (write file) command, instead
exit DDT (by G0 or Ctrl-C) and then use SAVE

S sad Examine and optionally alter RAM, byte by byte,
starting at sad

T Trace: execute 1 instruction with register dump
T n Trace: Execute n instructions with register dump

U Untrace: same as T except that intermediate
U n steps are not displayed

X Examine register or flags, display format:
CfZfMfEfIf A=bb B=dddd D=dddd H=dddd S=dddd P=dddd inst
Xr Examine/change registers or flags
C Carry flag (0/1)
Z Zero flag (0/1)
M Sign flag (0/1)
E Parity flag (0/1)
I Aux Carry flag (0/1)
A Accumulator (0-FF)
B BC reg pair (0-FFFF)
D DE reg pair (0-FFFF)
H HL reg pair (0-FFFF)
S Stack Pointer (0-FFFF)
P Program Counter (0-FFFF)


cad = current address
nad = new address
sad = start address
ead = end address

? = error, can mean:
file cannot be opened
checksum error in HEX file
assembler(disassembler overlayed




ED COMMANDS
===========

nA Append n lines to buffer (n=0 - use haf of buffer)
B Move pointer to beginning of file
-B Move pointer to end of file
nC Move pointer forward n characters
nD Delete n characters forward
E End edit, close file, return to CP/M
nFs Find n'th occurence of string 's'
H End edit, move pointer to beginning of file
I Insert text at pointer until ^Z typed
Is Insert string at pointer
nK Kill n lines starting at pointer
nL Move pointer n lines
nMx Execute command string 'x' n times
nNs Global F-command - until end of file
O Abort ED, start over with original file
nP List next n pages of 23 lines (n=0 - current page)
Q Quit without changing input file
Rfn Read fn.LIB into buffer at current pointer
nSx^Zy Substitute string 'y for next n forward occurrences of string 'x'
nT Type n lines
U Change lower case to upper case (next entry)
V Enable internal line number generation
nW Write n lines to output file, start at beginning of buffer
nX Write next n lines to file 'X$$$$$$$.LIB'
nZ Pause n/2 seconds (2 MHz)
n Move forward n lines
<CR> Move forward one line and type one line
- Move backward
n:x Move to n line number and perform 'x' command
:mx Perform command 'x' from current line to line m
n::mx Move to n line number and perform command 'x' from
current line to line m

note: "-" valid on all positioning and display commands
for backward movement (e.g. -nC)




HOW TO OPEN UP A NEW USER AREA
==============================

Enter PIP wait for the * prompt. Hit Return to go back to exit PIP.
Now, enter the user area, say USER 1. Type SAVE 28 PIP.COM and hit
Return (SAVE 30 PIP.COM in CP/M 3).

Now, PIP.COM is in your new user area, and you can copy any file
into your area from area 0 by typing PIP A:=<ufn>[G0] and Return.



PATCHING THE CCP TO PERFORM ONE COMMAND AT EVERY WARM BOOT
==========================================================

The CCP stars with the instructions:

JMP CCPSTART ; Start the console processor
JMP CCPCLEAR ; Clear the initial command
DB 127 ; Maximum command length
CL: DB 0 ; Current command length
DB ' ' ; 8 spaces
DB ' ' ; 8 more spaces
DB 'COPYRIGHT... ; Copyright notice

Starting at CL, patch in the command, e.g.:

CL: DB 3 ; Current command length
DB 'DIR',0 ; DIR command, NUL terminated
DB ' ' ; 4 spaces
DB ' ' ; 8 more spaces
DB 'COPYRIGHT... ; Copyright notice

and add this to the CCP image on the system tracks of your disk
(using MOVCPM, DDT and SYSTEM on most CP/M systems, or DDT amd
CPM56K.COM or CPM60K.COM on Apple CP/M). Now, after every warm boot
the CCP will execute this command (in this example a 'DIR' command)



BDOS FUNCTION CALLS
===================



Function no Value passed to BDOS Value returned in
in C reg in DE (or E) regs A or HL regs

Dec Hex

0 00 System reset -- --
1 01 Console read -- A = char
2 02 Console write E = char --
3 03 Reader read -- A = char
4 04 Punch write E = char --
5 05 List write E = char --
6 06 Direct console I/O E = FFh (input) A = char
(V2.x) E = char (output) --
7 07 Get IOBYTE -- A = IOBYTE
8 08 Set IOBYTE E = IOBYTE --
9 09 Print string DE = string addr --
string terminated by $, tabs are expanded as in func 2
10 0A Read console buffer DE = buffer addr A = #chars in buffer
buffer: 1st byte = bufsize, 2nd byte = chars input
11 0B Get console status -- A = 00(not rdy)/FF(rdy)
12 0C Lift head (V1.x) -- --
Get version (V2.x) -- HL = version no
H: 0=CP/M, 1=MP/M
L: 0=v1.4
20H-22H=v2.x
13 0D Reset disk** -- --
14 0E Select disk E = drive no --
0=A, 1=B, ...0FH=P
15 0F Open file DE = FCB addr A = dir code
16 10 Close file DE = FCB addr A = dir code
17 11 Search for first DE = FCB addr A = dir code
18 12 Search for next -- A = dir code
19 13 Delete file DE = FCB addr A = dir code
20 14 Read sequential DE = FCB addr A = ret code
21 15 Write sequential DE = FCB addr A = ret code
22 16 Create file DE = FCB addr A = dir code
23 17 Rename file DE = old FCB addr A = dir code
24 18 Get login vector -- (V1.4) HL = drive code
25 19 Get disk no -- A = curr disk no
(0-15 for A-P)
26 1A Set DMA addr DE = DMA addr --
27 1B Get alloc vector -- HL = ava
28 1C Write protect disk -- --
29 1D Get R/O vector -- HL = R/O vect
30 1E Set file attrib DE = FCB addr A = dir code
31 1F Get addr disk params -- HL = dpba
32 20 Set user code E = user code --
32 20 Get user code E = FFh A = curr user code
33 21 Read random DE = ext. FCB addr A = ret code ***
34 22 Write random DE = ext. FCB addr A = ret code ***
35 23 Compute file size DE = ext. FCB addr A = ret code
36 24 Set random record DE = ext. FCB addr A = ret code
37 25 Reset drive DE = drive vector A = 0
38 26 (unused) -- --
39 27 (unused) -- --
40 28 Write random DE = FCB addr A = ret code ***
with zero fill


dir code: directory code:
0FFH=failed (e.g. file not found, directory full)
0,1,2,3 = success: offset into current DMA buffer, which
contains a directory sector, where the FCB can be found

ret code: return code -- 0=success, non-zero=failed


* V1.4 none
** V1.4 initializes system and selects A: drive
*** ret codes:
00 - no error
01 - reading unwritten data
03 - cannot close current extent
04 - seek to unwritten extent
05 - directory overflow (write only)
06 - seek past physical end of disk

char = ASCII character
addr = address
dir = directory code
cdn = current drive number (A=0, B=1, etc)
dpba = disk parameter block address in CBIOS


Function 9: string is terminated with '$'

Function 10: Console buffer: 1st byte = max # chars in buffer (input)
2nd byte = actual # chars in buffer (output)
remaining bytes = buffer

Function 12: CP/M version number: H=00 CP/M, H=01 MP/M
L=00 ver prior to 2.0
L=20,21,22... subsequent versions

Function 13: Resets DMS address to BOOT+0080h

Function 23: renames file in first 16 bytes of FCB to name in second
16 bytes in FCB

Function 24: Returns a 16-bit value in HL - a 16-bit bit map where
the lowest bit represents A: and the highest bit P:
If the bit is set, that drive is present in the CP/M system

Function 29: Returns a similar bit map as func 24, except that a set
bit marks a drive which is Read/Only.

Function 33,34: the rn (Random Record No) must be set in the FCB prior to call

Function 35: fills in the file size in rn. If followed by a random write,
the file will be extended in length. Not that the "file size"
merely is the last record # - "hole" in sparse files are not
accounted for

Function 36: same as function 35 except that the current random record
position is stored in rn in FCB.

Function 37: this function is buggy - avoid using it





IOBYTE (0003H)
==============

Device LST: PUN: RDR: CON:
Bit position 7 6 5 4 3 2 1 0

Dec Binary

0 00 TTY: TTY: TTY: TTY:
1 01 CRT: PTP: PTR: CRT:
2 02 LPT: UP1: UR1: BAT:
3 03 UL1: UP2: UR2: UC1:

TTY: TeleTYpe
CRT: Cathode Ray Tube type terminal
BAT: BATch process (RDR=inut, LST=output)
UC1: User defined Console
LPT: Line Printer
UL1: User defined List device
PTR: Paper Tape Reader
UR1: User defined Reader device 1
UR2: User defined Reader device 2
PTP: Paper Tape Punch
UP1: User defined Punch device 1
UP2: User defined Punch device 2



LOGIN BYTE (0004H)
==================

low nibble = current drive (0=A, 1=B, etc)
high nibble = current user (V2.x only)



BIOS ENTRY POINTS
=================

Hex Vector Function Value Value
addr name passed returned

4A00H+b BOOT Cold start entry point - C=0
4A03H+b WBOOT Warm start entry point - C=drv no
4A06H+b CONST Check for console ready - A=const
4A09H+b CONIN Read from console - A=char
4A0CH+b CONOUT Write to console C=char -
4A0FH+b LIST Write to list device C=char -
4A12H+b PUNCH Write to punch device C=char -
4A15H+b READER Read from reader device - A=char
4A18H+b HOME Move head to track 0 - -
4A1BH+b SELDSK Select drive C=drv no HL=dph*, HL=0 for error
4A1EH+b SETTRK Set track number BC=trk no -
4A21H+b SETSEC Set sector number BC=sec no -
4A24H+b SETDMA Set DMA address BC=DMA -
4A27H+b READ Read selected sector - A=dskst
4A2AH+b WRITE Write selected sector - A=dskst
4A2DH+b* LOSTST Get list status - A=lstst
4A30H+b* SECTRAN Sector translate BC=lsecno HL=physec
DE=smap

BOOT: gets control after the cold start loader
Basic system initalization
Send sign-on message
Set IOBYTE
Set the WBOOT parameters
Jump to CCP at its entry point (at its first address 3400H+b)

WBOOT: gets control after Ctrl-C or JP 0000 or CPU reset
Reload CP/M CCP and BDOS
Setup JMP WBOOT at 0000H-0002H (JMP 4A03H+b)
Set inital value of IOBYTE at 0003H
Set 0004H hi nibble = current user no, lo nibble = current drive no
Setup JMP BDOS at 0005H-0007H (JMP 3C06H+b)
Set C=current drive, then branch to CCP at 3400H+b


const = console status: 00=idle, FF=data avail

dph = disk parameter/header address

dskst = disk status: 00=OK, 01=error

lstst = list status: 00=busy, FF=ready

lsecno = logical sector number \
physec = physical sector number | (standard skew factor = 6)
smap = sector interlace map address /

char = 7-bit ASCII char with parity bit (=hi bit) zero

drv no = drive number: 0=A, 1=B, etc, max 15=P
trk no = track number (0-76 std CP/M floppy, 0-65535 non-standard)
sec no = sector number (1-25 std CP/M floppy, 1-65535 non-standard)
DMA = DMA address (default 0080H)

* = not used in V1.4
** = contents of location 0002Hz



FILE CONTROL BLOCK (FCB)
========================

Byte Function
offset

0 dr Drive code (0=current, 1=A, 2=B, ...., 16=P)
1-8 f1-f8 File name, hi but = 0
9-11 t1-t3 File type + status (hi bits)
t1: 1=R/O t2: 1=SYS t3: 1=archived
12 ex Current extent number
13 s1 reserved (V1.4: not used)
14 s2 =0 on BDOS call to Open/Make/Search (v1.4: always 0)
16 rc extent record count: 0-127
16-31 d0-dn Disk map
32 cr Current record for R/W
33-35 rn Random record number, 0-65535, overflow into 3rd byte


MEMORY ALLOCATION
=================

V1.4: b = memsize-16K
0000 - 00FF System scratch area
0100 - 28FF+b TPA (Transient Program Area) - COM file area
2900+b - 30FF+b CCP - Console COmmand Processor
3100+b - 3DFF+b BDOS
3E00+b - 3FFF+b CBIOS

V2.2: b = memsize-20K
0000 - 00FF System scratch area
0100 - 33FF+b TPA (Transient Program Area) - COM file area
3400+b - 3BFF+b CCP - Console COmmand Processor
3C00+b - 49FF+b BDOS
4A00+b - 4FFF+b CBIOS


System scratch area, "page zero":

00 - 02 Jump to BIOS warm start entry point
03 IOBYTE
04 Login byte: Login drive number, current user number
05 - 07 Jump to BDOS
08 - 37 Reserved; interrupt vectors & future use
38 - 3A RST7 - used by DDT and SID programs, contains JMP into DDT/SID
3B - 3F Reserved for interrupt vector
40 - 4F Scratch area for CBIOS; unused by distribution version of CP/M
50 - 5B Not used, reserved
5C - 7C Default FCB (File Control Block) area
7D - 7F Optional Default Random Record Position (V2.x)
80 - FF Default DMA buffer area (128 bytes) for disk I/O
Also filled with CCP commandline at the start of a program



CP/M STANDARD DISK FORMAT (8" SSSD)
===================================

Media: 8" soft-sectored floppy-disk single density (IBM 3740 standard)
Tracks: 77, numbered 0 thru 76
Sectors/track: 26 (numbered 1 thru 26)
Bytes/sector: 128 data bytes (one logical record)
Storage/disk: 256256 bytes (77*26*128)
File size: any number of sectors from zero to capacity of disk
Extent: 1 kBytes - 8 sectors (smallest file space allocated)
Skew: 6 sectors standard (space between consecutive physical sectors
on track):
1-7-13-19-25-5-11-17-23-3-9-15-21-2-8-14-20-26-6-12-18-24-4-10-16-22

System: Track 0 & 1 (optional)
Track 0 sector 1: boot loader
Track 0 sectors 2-26: CCP & BDOS
Track 1 sectors 1-17: CCP & BDOS
Track 1 sectors 18-26: CBIOS

Directory: Track 2:
16 sectors typical
32 bytes/entry
64 entries typical
extents 0 and 1

User file area: Remaining sectors on Track 2 and 3 to 76, extents 2
and above

A Standard CP/M 8" SSSD floppy contains:

Track# Sector# Page# Mem address CP/M module name

00 01 (boot addr) Cold start loader

00 02 00 3400H+b CCP
00 03 . 3480H+b CCP
00 04 01 3500H+b CCP
00 05 . 3580H+b CCP
00 06 02 3600H+b CCP
00 07 . 3680H+b CCP
00 08 03 3700H+b CCP
00 09 . 3780H+b CCP
00 10 04 3800H+b CCP
00 11 . 3880H+b CCP
00 12 05 3900H+b CCP
00 13 . 3980H+b CCP
00 14 06 3A00H+b CCP
00 15 . 3A80H+b CCP
00 16 07 3B00H+b CCP
00 17 . 3B80H+b CCP

00 18 08 3C00H+b BDOS
00 19 . 3C80H+b BDOS
00 20 09 3D00H+b BDOS
00 21 . 3D80H+b BDOS
00 22 10 3E00H+b BDOS
00 23 . 3E80H+b BDOS
00 24 11 3F00H+b BDOS
00 25 . 3F80H+b BDOS
00 26 12 4000H+b BDOS
01 01 . 4080H+b BDOS
01 02 13 4100H+b BDOS
01 03 . 4180H+b BDOS
01 04 14 4200H+b BDOS
01 05 . 4280H+b BDOS
01 06 15 4300H+b BDOS
01 07 . 4380H+b BDOS
01 08 16 4400H+b BDOS
01 09 . 4480H+b BDOS
01 10 17 4500H+b BDOS
01 11 . 4580H+b BDOS
01 12 18 4600H+b BDOS
01 13 . 4680H+b BDOS
01 14 19 4700H+b BDOS
01 15 . 4780H+b BDOS
01 16 20 4800H+b BDOS
01 17 . 4880H+b BDOS
01 18 21 4900H+b BDOS
01 19 . 4980H+b BDOS

01 20 22 4A00H+b BIOS
01 21 . 4A80H+b BIOS
01 22 23 4B00H+b BIOS
01 23 . 4B80H+b BIOS
01 24 24 4C00H+b BIOS
01 25 . 4C80H+b BIOS
01 26 25 4D00H+b BIOS

02 01-08 Directory block 1
02 09-16 Directory block 2
02 17-26 Data
03-76 01-26 Data




DISK PARAMETER TABLES
=====================

Each disk drive has an associated 16-byte (8-word) DPH - Disk Parameter
Header, containing:

Offset Contents
------ --------
00H XLT Addr of logical-to-physical sector translation vector
or 0000H of no translation (i.e. they are the same)
Disk drives with identical sector skew factors
share the same table
02H 0000H \
04H 0000H | Scratchpad values for use within BDOS
06H 0000H / (initial value unimportant)
08H DIRBUF Addr of scratchpad 128-byte directory buffer.
All DPH's share the same DIRBUF.
0AH DPB Addr of Disk Parameter Block for this drive
0CH CSV Addr of scratchpad area used for software check for
changed disks. Each DPH has its own CSV.
0EH ALV Addr of scratchpad area used for disk storage
allocation information. Each DPH has its own ALV.

If the system has n disk drives, the n DPH's are arranged one after
another, from drive 0 to drive n-1, starting at DPBASE:

DPBASE:
+--------+------+------+------+--------+--------+--------+--------+
00 | XLT 00 | 0000 | 0000 | 0000 | DIRBUF | DPB 00 | CSV 00 | ALV 00 |
+--------+------+------+------+--------+--------+--------+--------+
01 | XLT 01 | 0000 | 0000 | 0000 | DIRBUF | DPB 01 | CSV 01 | ALV 01 |
+--------+------+------+------+--------+--------+--------+--------+
......................................................................
+--------+------+------+------+--------+--------+--------+--------+
n-1 | XLTn-1 | 0000 | 0000 | 0000 | DIRBUF | DPBn-1 | CSVn-1 | ALVn-1 |
+--------+------+------+------+--------+--------+--------+--------+


The SELDSK subroutine is responsible for returning the base address
of the DPH for the selected drive, or 0000H if there is no such drive:

NDISKS EQU 4 ; Number of disk drives
.........
SELDSK: ; Select disk given by BC
LXI H,0000H ; Error return
MOV A,C ; Drive OK?
CPI NDISK ; Carry if so
RNC ; Return if error
; No error, continue
MOV L,C ; Low (disk)
MOV H,B ; Hi (disk)
DAD H ; *2
DAD H ; *4
DAD H ; *8
DAD H ; *16
LXI D,DPBASE ; First DPH
DAD D ; DPH(disk)
RET

The translation vectors (XLT 00 thru XLTn-1) are located elswehere in
the BIOS and simply correspond one-for-one with the logical sector number
zero through the sector count.

The Disk Parameter Block (DPB) for each drive type contains:

Offset Contents
------ --------
00H SPT 16b Total number of sectors per track
02H BSH 8b Data allocation block shift factor, determined
by the data block allocation size
03H BLM 8b Data allocation block mask (2[BSH-1])
04H EXM 8b Extent mask, determined by data block allocation
size and number of disk blocks
05H DSM 16b Total storage capacity of disk drive
07H DRM 16b Total number of directory entries minus one
09H AL0 8b Determines reserved directory blocks
0AH AL1 8b Determines reserved directory blocks
0BH CKS 16b Size of directory check vector
0DH OFF 16b No of reserved tracks at beginning of logical disk
0FH (end of table)

BSH and BLM are determined by BLS, the block size or data allocation size

BLS BSH BLM EXM
----- --- --- DSM<256 DSM>=256
1024 3 7 0 n/a
2048 4 15 1 0
4096 5 31 3 1
8192 6 63 7 3
16384 7 127 15 7

i.e. BLS = 2**n where n = 10 to 14
BSH = n-7
BLM = 2**BSH - 1
EXM = 2**(BHS-2) - 1 if DSM<256
EXM = 2**(BHS-3) - 1 if DSM>=256

DSM = maximum data block number supported by this particular drive, measured
in BLS (BLock Size) units, or simply "number of allocation blocks on drive".
Blocks are counted from 0 to DSM, and thus BLS*(DSM+1) = the number of bytes
on the drive (excluding the system tracks). If DSM<256, the disk map in
the directory entry of the file will be 1 byte/block. If DSM>=256 it will
be 2 bytes/block.

DRM = total number of directory entries minus one.

AL0/AL1 = the directory allocation vector. Consider it a bit map of
bits 16 bits, bit 0-15, where 0=hi bit of AL0, 7=lo bit of AL0, 8=hi
bit of AL1, 15=lo bit of AL1. Bits are assigned starting at bit 0 up
until bit 15. Suppose nbits is the number of bits seet to 1:

BLS Directory entries
--- -----------------
1024 32 * nbits
2048 64 * nbits
4096 128 * nbits
8192 256 * nbits
16384 512 * nbits

Example: if DRM=127 (128 directory entries) and BLS=1024 bytes, there
are 32 directory entries per block, requiring 4 reserved blocks. Thus
the 4 hi bits if AL0 are set, and AL0=0FH, AL1=00H

CKS = size of directory check vector
If drive media is removable, then CKS = (DRM+1)/4
If drive media is fixed, then CKS=0 (no dir records checked)

OFF = number of reserved tracks. This value is automatically added
whenever SETTRK is called. It can be used to skip reserved system
tracks, or for partitioning a large disk into smaller segmented
sections.

Several DPH's can address the same DPB if the drive characteristics
are identical. The DPB can be dynamically changed when a new drive
is addressed by simply changing the pointer in the DPH since the BDOS
copies the DPB values to a local area whenever the SELDKS function
is invoked.

The size of the CSV (scratchpad area to check changed disks) is CKS
bytes. If CKS=(DRM+1)/4, this area must be reserved. If CKS=0, no
storage is reserved.

The size of the ALV (scratchpad area for disk storage allocation info)
is (DSM/8)+1 bytes where DSM is the disk size in allocation blocks.


DISK PARAMETER TABLES FOR SPECIFIC DISKS
========================================

Standard CP/M 8" SSSD disk
--------------------------

128 bytes/sector
26 sectors/track
77 tracks - 2 system tracks
75 used tracks ==> 243.75 user KBytes/disk
1024 bytes/block ==> 243 blocks/disk ==> DSM=242
Directory in 2 first blocks ==> 64 directory entries ==> 241.75 KBytes data

Sector skew table (1 byte/sector):
1, 7, 13, 19, 25, 5, 11, 17, 23, 3, 9, 15, 21,
2, 8, 14, 20, 26, 6, 12, 18, 24, 4, 10, 16, 22

DPB

SPT 16b 26 Sectors per track
BSH 8b 3 Block shift factor
BLM 8b 7 Block shift mask
EXM 8b 0 Extent mask - null
DSM 16b 242 Disk size - 1 (in blocks)
DRM 16b 63 directory mask = dir entries - 1
AL0 8b 0C0H Dir Alloc 0
AL1 8b 0 Dir Alloc 1
CKS 16b 16 Directory check vector size
OFF 16b 2 Track offset: 2 system tracks

Dirbuf 128 bytes
ALV 31 bytes
CSV 16 bytes

Block size 1024 bytes ==> BSH=3, BLM=7

DSM = 242 blocks

Disk size: 243.75 KBytes excluding system tracks
250.25 KBytes including system tracks



Apple CP/M 5.25" disks
----------------------

Physical format: A B C

---- Standard ----- ----- Special ------
13-sect 16-sect 80-trk/16-sec/2-side

Bytes/sector 256 256 256
Sectors/track 13 16 16
Tracks 35 35 80
Heads 1 1 2

Sector skew table (1 byte/sector): no sector skew in CP/M BIOS
13-sector disks: hard sector skew
16-sector disks: soft sector skew in 6502 code (CP/M RWTS)

DPB A B C

SPT 16b 26 32 32 Sectors per track
BSH 8b 3 3 4 Block shift factor
BLM 8b 7 7 15 Block shift mask
EXM 8b 0 0 0 Extent mask
DSM 16b 103 127 313 Disk size - 1 (in blocks)
DRM 16b 47 63 255 Directory mask = dir entries - 1
AL0 8b 0C0H 0C0H 0F0H Dir Alloc 0
AL1 8b 0 0 0 Dir Alloc 1
CKS 16b 12 16 64 Directory check vector size
OFF 16b 3 3 3 Track offset: 3 system tracks

Block size 1024 1024 2048
Dir entries 48 64 256
Dir blocks 2 2 4
DSM+1 104 128 314 blocks
Disk size 104 128 628 KBytes (excluding system tracks)
113.75 140 640 KBytes (including system tracks)

Dirbuf 128 128 128 bytes
ALV 14 17 40 bytes
CSV 12 16 64 bytes



Larry

ldkraemer
Posts: 51
Joined: Thu Feb 28, 2013 3:47 am

Re: Creating a boot disk for rare CP/M computers - 8" & 5.25

Post by ldkraemer »

DazBit,
I stumbled on this 50 Pin to 34 Pin information at:
http://www.trs-80.com/wordpress/zaps-pa ... /hardware/

Convert 5″ Drive Cable to 8″ Drive Cable
The following pin configuration will effectively translate the 34 pin cable required by the 5″ disk drive to the 50 pin cable required
by an 8 inch disk drive.

34 pin connection 50 pin connection

pin 1...............pin 17
pin 2...............pin 22
pin 3...............pin 19
pin 4...............Cut
pin 5...............pin 21
pin 6...............pin 32
pin 7...............pin 23
pin 8...............pin 20
pin 9...............pin 25
pin 10..............pin 26
pin 11..............pin 27
pin 12..............pin 28
pin 13..............pin 29
pin 14..............pin 30
pin 15..............pin 31
pin 16..............pin 18
pin 17..............pin 33
pin 18..............pin 34
pin 19..............pin 35
pin 20..............pin 36
pin 21..............pin 37
pin 22..............pin 38
pin 23..............pin 39
pin 24..............pin 40
pin 25..............pin 41
pin 26..............pin 42
pin 27..............pin 43
pin 28..............pin 44
pin 29..............pin 45
pin 30..............pin 46
pin 31..............pin 47
pin 32..............pin 14
pin 33..............pin 49
pin 34..............Cut


Larry

Post Reply