
Frequency modulation encoding, or simply FM, is a method of storing data that saw widespread use in early
floppy disk drives
A floppy disk or floppy diskette (casually referred to as a floppy, a diskette, or a disk) is a type of disk storage composed of a thin and flexible disk of a magnetic storage medium in a square or nearly square plastic enclosure lined with a ...
and
hard disk drive
A hard disk drive (HDD), hard disk, hard drive, or fixed disk is an electro-mechanical data storage device that stores and retrieves digital data using magnetic storage with one or more rigid rapidly rotating hard disk drive platter, pla ...
s. The data is modified using
differential Manchester encoding
Differential Manchester encoding (DM) is a line code in digital frequency modulation in which data and clock signals are combined to form a single two-level self- synchronizing data stream. Each data bit is encoded by a presence or absence of ...
when written to allow
clock recovery
Clock recovery is a process in serial communication used to extract timing information from a stream of serial data being sent in order to accurately determine payload sequence without separate clock information. It is widely used in data communi ...
to address timing effects known as "jitter" seen on disk media. It was introduced on
IBM
International Business Machines Corporation (using the trademark IBM), nicknamed Big Blue, is an American Multinational corporation, multinational technology company headquartered in Armonk, New York, and present in over 175 countries. It is ...
mainframe drives and was almost universal among early
minicomputer
A minicomputer, or colloquially mini, is a type of general-purpose computer mostly developed from the mid-1960s, built significantly smaller and sold at a much lower price than mainframe computers . By 21st century-standards however, a mini is ...
and
microcomputer
A microcomputer is a small, relatively inexpensive computer having a central processing unit (CPU) made out of a microprocessor. The computer also includes memory and input/output (I/O) circuitry together mounted on a printed circuit board (P ...
floppies. In the case of floppies, FM encoding allowed about 80 kB of data to be stored on a -inch disk.
IBM began introducing the more efficient
modified frequency modulation, or MFM, starting in 1970. They referred to this format as "double density", with the original FM retroactively becoming "single density". MFM was more difficult to implement and it was not until the early 1980s that low-cost all-in-one MFM floppy drive controllers like the
WD1770 emerged. This led to the rapid demise of FM encoding in favor of MFM by the mid-1980s.
Underlying storage mechanism
Main memory
Computer data storage or digital data storage is a technology consisting of computer components and recording media that are used to retain digital data. It is a core function and fundamental component of computers.
The central processin ...
systems in modern
computer
A computer is a machine that can be Computer programming, programmed to automatically Execution (computing), carry out sequences of arithmetic or logical operations (''computation''). Modern digital electronic computers can perform generic set ...
s store binary information using two different electrical signals, typically voltages. In
DRAM
Dram, DRAM, or drams may refer to:
Technology and engineering
* Dram (unit), a unit of mass and volume, and an informal name for a small amount of liquor, especially whisky or whiskey
* Dynamic random-access memory, a type of electronic semicondu ...
for instance, the presence of a
voltage
Voltage, also known as (electrical) potential difference, electric pressure, or electric tension, is the difference in electric potential between two points. In a Electrostatics, static electric field, it corresponds to the Work (electrical), ...
over a certain threshold represents a binary one, while any voltage below that value represents a zero. The letter "A" in
ASCII
ASCII ( ), an acronym for American Standard Code for Information Interchange, is a character encoding standard for representing a particular set of 95 (English language focused) printable character, printable and 33 control character, control c ...
is represented as 01000001 in binary, which might be stored in a typical late-1970s DRAM like the Mostek MK4116 as a series of 0 and 5 V voltages in the individual
capacitor
In electrical engineering, a capacitor is a device that stores electrical energy by accumulating electric charges on two closely spaced surfaces that are insulated from each other. The capacitor was originally known as the condenser, a term st ...
s making up the memory.
In contrast,
magnetic recording
Magnetic storage or magnetic recording is the storage of data on a magnetized medium. Magnetic storage uses different patterns of magnetisation in a magnetizable material to store data and is a form of non-volatile memory. The information is ...
systems like
floppy disk
A floppy disk or floppy diskette (casually referred to as a floppy, a diskette, or a disk) is a type of disk storage composed of a thin and flexible disk of a magnetic storage medium in a square or nearly square plastic enclosure lined with a ...
s record this data as a change in
magnetic polarity
A magnet is a material or object that produces a magnetic field. This magnetic field is invisible but is responsible for the most notable property of a magnet: a force that pulls on other ferromagnetic materials, such as iron, steel, nickel, c ...
. This is due to the way the data is read and written, using
magnetic induction. During reading, the disk is rotating so its surface moves rapidly past the
read/write head
A disk read-and-write head is the small part of a disk drive that moves above the disk platter and transforms the platter's magnetic field into electric current (reads the disk) or, vice versa, transforms electric current into magnetic field ...
, a small
electromagnet
An electromagnet is a type of magnet in which the magnetic field is produced by an electric current. Electromagnets usually consist of wire (likely copper) wound into a electromagnetic coil, coil. A current through the wire creates a magnetic ...
. When the polarity of the magnetic charge on the disk changes, a brief pulse of electricity is induced in the head which is read as a one, any section where the polarity does not change produces a zero. To encode the same letter A, assuming the previous data ended with a zero, a disk would use 01111110. The first zero-to-one transition causes a 1 to be output, the stream of ones following causes no output, and finally the last one-to-zero creates the final 1.
In addition to the data being stored in patterns that require on-the-fly conversion to and from their internal format, the disk faces additional problems associated with being an analog system – noise, mechanical effects and other issues. In particular, disks suffer from an effect known as
jitter
In electronics and telecommunications, jitter is the deviation from true periodicity of a presumably periodic signal, often in relation to a reference clock signal. In clock recovery applications it is called timing jitter. Jitter is a signifi ...
due to small changes in timing as the media speeds up and slows down during rotation. One form of unavoidable jitter is due to the
hysteresis
Hysteresis is the dependence of the state of a system on its history. For example, a magnet may have more than one possible magnetic moment in a given magnetic field, depending on how the field changed in the past. Plots of a single component of ...
of the magnetic media, which can lead to an effect known as bit shift that causes the strings of magnetic transition to be stretched out in time. These effects make it difficult to know which bit a particular transition belongs to.
To address this problem, disks use some form of
clock recovery
Clock recovery is a process in serial communication used to extract timing information from a stream of serial data being sent in order to accurately determine payload sequence without separate clock information. It is widely used in data communi ...
using additional signals written to the disk. When the data is read, the clock signal is separated out and data bits can then be clearly seen in the signal and be cleanly lined up into the appropriate slots in memory.
Encoding
FM encoding uses a simple system to encode the original data in such a way that every bit of data will contain at least one transition, ensuring there are enough transitions during a given period for a successful clock recovery. To do this, it operates with a basic data period twice that of the maximum frequency of the recording media. These are known as "clock windows", with up to one clock transition and one data transition per window. Since each bit of data requires two minimum times, FM encoding stores about half the amount that is theoretically possible on that media.
FM uses an implementation of the
differential Manchester encoding
Differential Manchester encoding (DM) is a line code in digital frequency modulation in which data and clock signals are combined to form a single two-level self- synchronizing data stream. Each data bit is encoded by a presence or absence of ...
. A zero in the original data is encoded by a single magnetic flux transition during the period, and ones are encoded as two transitions. For instance, if a byte of data from the original system contains the bits 01000001, the
floppy disk controller
A floppy-disk controller (FDC) is a hardware component that directs and controls reading from and writing to a computer's floppy disk drive (FDD). It has evolved from a discrete set of components on one or more circuit boards to a special-purpo ...
will translate this into the series 1011101010101011, inserting additional signals in front of every bit to represent the clock. When this signal is then sent to the read/write head, the polarity will be flipped every time there is a pulse. In this example, if the head was originally in the low state at the end of writing the last data, the leading 1 will flip it to the high state, and the following zero will leave it there. The result is a single transition in that window. The next bit will first flip the state back to low, and then flip it back to high, for two transitions in the window.
Encoding these transitions requires the system to accept digital data from the host computer and then re-code it into the underlying FM format. On reading, the system has to separate out the clock signal again and leave only the data bits. Because the FM system is so simple, it could be implemented in single-chip forms using late 1970's
semiconductor fabrication
Semiconductor device fabrication is the process used to manufacture semiconductor devices, typically integrated circuits (ICs) such as microprocessors, microcontrollers, and memories (such as RAM and flash memory). It is a multiple-step photol ...
techniques. This greatly lowered the cost of implementation of a complete drive controller, which consisted largely of a clock, a drive controller chip, a chip to communicate with the host computer, and some buffer memory. Especially popular was the
Western Digital FD1771
The FD1771, sometimes WD1771, is a floppy disk controller chip, the first in a line of floppy disk controllers produced by Western Digital. It uses single density FM encoding introduced in the IBM 3740. Later models in the series added support ...
and its variations.
Data encoding vs format
The material above refers to bytes being written to disk, but this is a simplification. In most disks, the only unit of data is the
sector
Sector may refer to:
Places
* Sector, West Virginia, U.S.
Geometry
* Circular sector, the portion of a disc enclosed by two radii and a circular arc
* Hyperbolic sector, a region enclosed by two radii and a hyperbolic arc
* Spherical sector, a po ...
, and the individual bytes within it have no meaning to the controller. When data is written, the controller is handed a full sector's worth of data and told to write it as a single atomic operation as a series of bits. The controller cannot align the bits with the bytes based solely on the FM information. Thus it is not only the bits within the data that have to be aligned on reading, but the starting point of the sector's data as a whole.
This is not accomplished with the encoding scheme, but the
disk format
Disk formatting is the process of preparing a data storage device such as a hard disk drive, solid-state drive, floppy disk, memory card or USB flash drive for initial use. In some cases, the formatting operation may also create one or more new fi ...
instead. When the controller writes a sector of data, it adds a header section containing information about the data that follows, as well as the address of the sector so it can be found in the future. During the write process, the controller also writes out a series of special "sync bytes" before the header and the data. In the IBM format, this consists of a series of thirteen zeros followed by three
hexadecimal
Hexadecimal (also known as base-16 or simply hex) is a Numeral system#Positional systems in detail, positional numeral system that represents numbers using a radix (base) of sixteen. Unlike the decimal system representing numbers using ten symbo ...
A1
's in front of the header and data areas. These are not FM encoded, so the controller can easily identify them on-the-fly. The controller locks onto these signals to find the start of data, which immediately follows the last sync byte. After that, it reads out each eight bits into subsequent bytes in the buffer.
Replacement with MFM
As each bit of data requires two transition periods in the FM system, it makes use of only half the potential storage capacity of the disk. This led to a series of more advanced encodings that make better use of the available space. The most widely used replacement was
modified frequency modulation, or MFM. This system recorded only a single bit in every window, which produced the underlying clock signal. The value of the bit, 1 or 0, was encoded by the location of the pulse within the window. 1's were encoded with pulses in the center of the window; 0's with the pulse at the end.
Because the accuracy of the transition transition timing is more demanding, MFM requires a more complex solution to recovering the clock signal. Generally this takes the form of a
phase locked loop
A phase-locked loop or phase lock loop (PLL) is a control system that generates an output signal whose phase is fixed relative to the phase of an input signal. Keeping the input and output phase in lockstep also implies keeping the input and ou ...
or similar system that will produce a steady output clock signal from a noisy input. This was beyond the capabilities of low-cost ICs from the late 1970s, which is why FM remained popular during the early
home computer
Home computers were a class of microcomputers that entered the market in 1977 and became common during the 1980s. They were marketed to consumers as affordable and accessible computers that, for the first time, were intended for the use of a s ...
era in the early 1980s. MFM IC's were available, and were used on more expensive platforms like the
IBM PC
The IBM Personal Computer (model 5150, commonly known as the IBM PC) is the first microcomputer released in the List of IBM Personal Computer models, IBM PC model line and the basis for the IBM PC compatible ''de facto'' standard. Released on ...
, but using them required the clock recovery to be performed by external hardware, the "data separator". IC manufacturing was advancing rapidly during this period, and by the mid-1980s all-in-one MFM controllers appeared and the market rapidly moved to the double-density format.
References
Citations
Bibliography
*
*
{{Bit-encoding
Line codes
Rotating disc computer storage media