Студопедия.Орг Главная | Случайная страница | Контакты | Мы поможем в написании вашей работы!  
 

Disks and Tapes



There are two important groups of input/output (i/o) devices. There are devices that provide data storage, like disks and tapes, and there are devices that connect the computer system to the external world (keyboards, printers, displays, sensors).

Most personal computers have two or three different types of disk storage unit. There will be some form of permanently attached disk (the main "hard disk"), some form of exchangeable disk storage (a "floppy disk" or possibly some kind of cartridge-style hard disk), and there may be a CD-ROM drive for read-only CD disks.

Optical disks. CD disks encode 0 and 1 data bits as spots with different reflectivity. The data can be read by a laser beam that is either reflected or not reflected according to the setting of each bit of data; the reflected light gets converted into a voltage pulse and hence the recorded 0/1 data values gets back into the form needed in the computer circuits. Currently, optical storage is essentially read-only – once data have been recorded they can't be changed.

Magnetic disks. Most disks use magnetic recording. The disks themselves may be made of thin plastic sheets (floppy disks), or ceramics or steel (hard disks). Their surfaces are covered in a thin layer of magnetic oxide. Spots of this magnetic oxide can be magnetically polarized. If a suitably designed wire coil is moved across the surface, the polarized spots induce different currents in the coil – allowing data to be read back from the disk. New data can be written by moving a coil across the surface with a sufficiently strong current flowing to induce a new magnetic spot with a required polarity. There is no limit on the number of times that data can be rewritten on magnetic disks. The bits are recorded in "tracks" – these form concentric rings on the surface of the disk. Disks have hundreds of these tracks. Tracks are too large a unit of storage – they can hold tens of thousands of bits. Storage on a track is normally broken down into "blocks" or sectors. Nowadays, the operating system program that controls most of the operations of a computer will mandate a particular block size. This is typically in the range 512 bytes to 4096 bytes (sometimes more). The disk controller may identify blocks by block number and track number.

Files. Data files on disk are made up out of blocks. The operating system is responsible for choosing the blocks used for each file, and for recording details for future reference. The data in the blocks form a table of entries with each entry specifying a file name, file size (in bytes actually used and complete blocks allocated), and some record of which blocks are allocated. The allocation scheme uses a group of contiguous blocks to make up each individual file. This makes it easy to record details of allocated blocks, the directory need only record the file size and the first block number.

File directory. In addition to the table of entries describing allocated files, the directory structure would contain a record of which blocks were allocated and which were free and therefore available for use if another file had to be created. One simple scheme uses a map with one bit for each block; the bit is set if the block is allocated.

Tapes. Tapes are now of minor importance as storage devices for users' files. Mostly they are used for "archival" storage – recording data that are no longer of active interest but may be required again later. All the processes using tapes, like skipping to file marks, sequential reads etc, are slow.





Дата публикования: 2015-06-12; Прочитано: 258 | Нарушение авторского права страницы | Мы поможем в написании вашей работы!



studopedia.org - Студопедия.Орг - 2014-2024 год. Студопедия не является автором материалов, которые размещены. Но предоставляет возможность бесплатного использования (0.006 с)...