Section 17.4: Disk addressing (Frame 1)                     [     ][home][next]

Since disks are actually memory devices, it must be possible for a computer to store data in one place and retrieve it later. To enable addressing, sectors are assigned numbers and a computer specifies a sector address with every read or write command. Since there are many tracks and many platters, a sector address is the concatenation of the surface number, track and sector. (Each platter has two surfaces.)

For example, the following C-like calls might be similar to ones that the operating system would give to a disk drive. Recall that a sector is often 512 bytes or more and each operation reads or writes one full sector.

int write (char data[512], int surface, int track, int sector) { ... }
int read (char data[512], int surface, int track, int sector) { ... }

The return value is an error code.