I had 5.25" disks in various formats: PC, BBC, RM380Z, and Commodore PET/C64, plus several that weren't clearly labelled. Probing and reading disks in FM/MFM formats should be a good deal more convenient on a PC than on the BBC, so the next job was to hook up some 5.25" disk drives to my disk imaging machine.
5.25" disk drives
One came from my IBM 5170 — the original IBM AT:
This machine was quite beaten up when I got it; to replace the original floppy drive, someone had fitted a TEAC "360k" (40-track double-sided double-density) drive. This drive is quite interesting to watch in action, since it uses a conventional rotary stepper motor to move the heads...
A second drive came from my BBC B, a Mitsubishi MF503A-301ME 80-track double-sided double-density drive:
A web search found the datasheet for the drive in an AtariAge post and some notes on similar drives in a Tandy article. As configured for the BBC, it had the following jumpers set:
- TD (termination on)
- DS0 (drive #0)
- RR (output selected by DRIVE SELECT)
- MM (motor power controlled by MOTOR ON)
- 40/80 switch across TS3 (switch up is 40T, down is 80T)
PC drives need to be configured as drive 1 — so I removed DS0 and added DS1. After some experimentation, adding the DC (disk change signal active low) jumper made it work correctly on the PC.
Software for imaging floppy disks
To test out the drives, I booted the PC into FreeDOS and fired up Dave Dunfield's freeware ImageDisk. ImageDisk can identify, read and write any disk format that a PC floppy controller can handle — so it can do most FM/MFM formats, but not Amiga disks with odd timing, or Commodore 8-bit disks with GCR encoding. It stores images in IMD binary format, which is clearly described in the ImageDisk manual.
ImageDisk's TESTFDC
reported that the M1543C's controller supported
all the FM and MFM modes I needed, so I tried imaging a few disks.
After cleaning the heads on the drives, these read successfully, except
for a pile of PC disks that had clearly got damp at some point in the
past and were visibly shedding oxide.
However, I'd rather read disks under Linux than under FreeDOS — access to my NFS filestore and long filenames make life much easier. There are a couple of options for this if you know what the disk format is already (described here):
-
Use
setfdprm
from fdutils to configure the floppy block device, then useddrescue
or similar. -
Use
dsktrans
from LibDsk, which knows about lots of existing disk formats.
Neither of those works if you don't know the format, though — or if it's one that you can't describe easily (e.g. the mix of FM and MFM tracks that ImageDisk reported on some of the RM disks).
Handily, the fdutils documentation includes a guide to identifying unknown disk formats by driving the floppy controller directly. Based at their instructions and the datasheet for my machine's floppy controller, I wrote dumpfloppy, which does approximately the same job as ImageDisk's probe/read functions. Since ImageDisk's IMD format is well-designed and quite popular, I based dumpfloppy's internal data model on it, and wrote a separate tool (imdcat) to convert IMD to emulator formats such as BBC SSD.
One challenge was how to find the index hole on the disk when probing the list of sectors. I solved this by asking the disk controller to read a sector number that definitely wasn't present; the datasheet says it'll return an error after seeing the index hole for a second time. This is theoretically racy, but it seems to work OK. (I wonder what ImageDisk does?)
I tested dumpfloppy by reading back some disk images that I'd written out using the BBC and checking the result was bitwise identical to the original image — it was — and by comparing its output to ImageDisk's for some of the more complex RM disks.
Some interesting disks
5.25" disks have much more varied branding than 3.5" disks:
That Banana disk is unusual because it's a "flippy" disk — it's got two index holes and two write-protect notches, so you can use both sides in a single-sided drive by turning the disk over. (A cheaper alternative was to buy a regular disk and use a hole punch.)