Page 1 of 1

Floppy disk controller on FPGA

Posted: Sat Dec 27, 2014 3:56 am
by iocoder
Hello!

I am going to write a floppy disk controller in VHDL for a school project. If anybody has interesting documents that might help me, please post it [-o< :D

I have read the pinout of the 34-pin FDD cable, however I need more information about how data transfer between the controller and the FDD could be properly synchronized. I have also read that IBM PCs use modified frequency modulation (MFM), which needs great study. Finally, I need to know exactly how IBM PC disks are formatted and what is exactly stored in the gaps between sectors.

Since I have come up with the idea, I have been searching the internet for information. However, it seems like the available information about the points above is so little or I don't use proper search keywords. Any help will be really appreciated :)

Re: Floppy disk controller on FPGA

Posted: Sat Dec 27, 2014 9:14 am
by SpyderTL
Most of the answers you are looking for are on Wikipedia: http://en.wikipedia.org/wiki/Floppy-disk_controller
Floppy disk controller functions (FDC)
Translate data bits into MFM or GCR format to be able to record them
Interpret and execute commands such as seek, read, write, format, etc.
Error detection with checksums generation and verification, like CRC
Synchronize data with phase-locked loop (PLL)

External hardware functions
Selection of floppy disk drive (FDD)
Switching-on the floppy drive motor
Reset signal for the floppy controller IC
Enable/disable interrupt and DMA signals in the floppy disc controller (FDC)
Data separation logic
Write pre-compensation logic
Line drivers for signals to the controller
Line receivers for signals from the controller
Phase-Locked Loop: http://en.wikipedia.org/wiki/Phase-locked_loop

MFM Encoding: http://en.wikipedia.org/wiki/Modified_F ... Modulation

Re: Floppy disk controller on FPGA

Posted: Mon Dec 29, 2014 3:49 am
by jnc100
If you haven't already, I'd suggest getting a hold of the 8272A datasheet. It describes the interface between the FDC and the CPU, drive and DMA and PIC chips in detail.

Regards,
John.

Re: Floppy disk controller on FPGA

Posted: Sat Jan 03, 2015 9:26 am
by iocoder
Thank you friends!

This document (AN-505 Floppy Disk Data Separator Design Guide for DP8473) is also great and has helped me a lot.

I finished a version of the controller that supports reading data from (but not writing to) the disk. The code is posted here: http://pastebin.com/w0S40FV3. I hope it helps anyone who wants to make her own FDC or learn how it works from the inside.