Category Archives: Floppy disc R/W project

The pain of (almost-)failure

It seems this project has consisted of one cockup after another…

– First off, I managed to swap the A and B buses on the level translator chips. The “A” bus goes to the disc drive, the “B” bus goes to the FPGA board. Get it the wrong way round, and the FPGA gets zapped with +5V. Cost: a spool of Roadrunner wire, 1/8th of a reel of solder, four tubs of desolder wick, and two days of tedious desoldering and repair work.
– Next, I cocked up the wiring on the disc drive port. Shorted the RD DATA pin with the TRACK0 pin (these are both outputs from the drive to the host). Cost: 20 minutes of signal tracing with the multimeter, a bit more desolder wick (it was just a solder bridge) and a few inches of solder.
– For additional bonus points, I managed to swap the READY/DISKCHANGE and WRITE PROTECT pins at the level translator. I could have just scribbled over the schematic but I figured I might as well fix it… Cost: an hour, a bit of Roadrunner wire, some solder, a craft knife blade, and a few lacerated fingers.
– To finish the whole shooting match off, the disc drive I pulled out of my junk box just happens to have a slightly iffy hub motor. Specifically, in certain orientations (“lying flat on the desk” being one of them), it won’t spin up. Turn it upside down and slam the disc in against the end-stop, and it will. Just. Interestingly once the disc is in place, it works OK. So I’m fine as long as I don’t have to swap the disc. Y’know, I think I might just find another drive…

Next problem: it spins the disc, seeks to a track and so on, but it doesn’t really read or write anything. “Your challenge, should you choose to accept it… make the damn thing work!”

Floppy disc reader/writer project — update 200810/1

A few of you might be aware of my pet project — a floppy disc reader/writer that operates at an insanely low level (it operates on individual magnetic flux transitions). The advantage of this thing being that it’ll be able to read (and write!) just about any disc format that can be read in a standard 3.5″, 5.25″ or 8″ disc drive.

Well the big news is that I’ve got approval to cover the software side of things for my final year university project. I’ve also taken a different route to developing the hardware — I’m going to use an Altera Cyclone II Starter Kit (and a pair of bodge-boards) to build a prototype, then work on pulling it into the CAD software later. Given that the HDL code is basically done, this means I can spend nearly all of my 30 weeks (well, 27 weeks now) getting the software finished.

For anyone who hasn’t seen the C2SK board, it’s basically a rebadged TerASIC DE1 development board. 18 LEDs, four momentary switches, 10 two-position switches, a four-digit seven-segment display, 8MBytes of SDRAM, 4MBytes of flash, 512KBytes of SRAM, an SD card slot (!), VGA out, RS232, audio in and out, a PS/2 keyboard connector and two User I/O connectors… which are good old 40-pin IDC sockets. All for £99 plus VAT from Digikey.

And the default startup program does a neat LED chaser display that has been described as “[airport security attract mode](http://flickr.com/photos/68931440@N00/1590316984/)”. I can’t help but agree, the demo sequence is very show-offy.

Software-wise, I’ve done a few quick tests to do histogram analysis of disc track data, but I’m going to have a crack at some MFM decoding over the next week or so. Chuck G. was kind enough to send me some FM, MFM and GCR samples last year, which I’m ashamed to admit I haven’t had a serious look at yet. I really need to get my hands on a few floppy discs from “strange and unusual” machines. I’m aiming for Amiga and BBC Micro at the moment, but I’ll probably add PC floppies to the mix later on.

But first, I need to get the SDRAM working with the FDDReaderWriter HDL code…

Floppy disc reader – stage one complete!

Yes, I know, it’s been a while since I’ve posted anything here — a few days shy of two months in fact. Hopefully this little posting will make it worth the wait 🙂

Over the last couple of years, there’s been something of a resurgence of interest in ‘vintage’ computer platforms – the old BBC Micro, ZX Spectrum, et cetera, et cetera. A lot of the people involved in saving these machines from landfill (or ‘recycling’, i.e. chopping them up and melting the remains down to salvage the metal) have been trying to archive data from the discs – system software and boot discs especially. The problem is, these discs are – in some cases – over 20 years old, and well beyond their intended service life. Not only that, but the formatting is often rather odd and can’t be read by modern PC floppy disc controllers. There is a solution already – the Catweasel disc controller. Shame it’s so expensive and hard to get hold of, not to mention the fact you need a full sized PC to actually use it – totally impractical for ‘my friend has a copy of the PRIMOS master discs and I want to archive them, but he won’t let them out of his sight’ type situations.

So I’m attempting to come up with my own solution to the problem – a portable disc reader with a USB (or RS232) interface, capable of decoding just about any floppy disc format known to man.

So far the sum total of the work I’ve done on it is getting the data separator and synchronisation word detector working. I can’t make it archive discs yet, but what I’ve done is most of the ‘hard stuff’. The only stuff left to do now is the MCU interface (and firmware) and RAM interface for reading and writing. If I manage to do this in less than two XC9572XL gate array chips, I’ll consider it a miracle.

And without further ado, here are some pretty screenshots for you to look at:
Logic trace – data separator/sync detector locking onto an IAM on a 3.5″ DSDD (720K) floppy disc:

Logic analyser trace - syncing against 720K floppy

hpla-fdd-reader-syncing-against-720k-floppy-zoomed-long.png

Logic trace – data separator/sync detector locking onto an IAM on a 3.5″ DSHD (1.4MB) floppy disc:

hpla-fdd-reader-syncing-against-1440k-floppy.png