3.5 inch 1.44m floppy disk structure, capacity and allocation

Source: Internet
Author: User

Old things may be useful: can be used to understand the fat format

 

1. Structure: 2-sided, 80-sided, 18-sector, 512Bytes/Sector
Total number of sectors = 2x80/x 18 sectors/sectors = 2880 sectors
StorageCapacity= 512Bytes/Sector X 2880 sector = 1440 KB

2. Physical fan Area No:
Face 2: Serial No. 0----1;
80: No. 0----79
18 sectors: No. 1----18

3. Relative fan area number: A total of 2880 sectors. The range of the relative fan area number is 0----2879.
Serial number order:
The physical number of the slice is relative to the fan area number.
0 sides, 0 channels, 1 sector 0
0, 0, 2 Sectors 1
0 sides, 0 channels, 3 sectors, 2
.........................
0, 0, 18 sectors, 17
1 plane, 0 channels, 1 sector 18
.................
1 plane, 0 channels, 18 sectors, 35
0-sided, 1-way, 1-sector, 36
0-sided, 1-way, 18-Sector 53
1 plane, 1 track, 1 sector 54
.........
1 plane, 79 channels, 18 sectors 2879

4. Formulas for mutual conversion between physical fan area numbers (A, B, C) and relative fan area numbers (s:
Sector (1--18) of head/face (0--1) (0-79)
A B C
Example: 1-plane, 15-track, 7-sector
(0 channels ---- 14 channels) * 2 sides * 18 + 0 sides 15th sectors 18 sectors + 1 side 15th sectors 7 sectors-1
15*2*18 + 18 + 7-1
When a = 1 S = B * 18*2 + 18 + C-1
When a = 0 s = B * 18*2 + C-1
GENERAL: S = B * 18*2 + 18 * A + C-1
S = B * 18*2 + 18 * A + C-1
C = (S % 18) + 1
A = (INT (S/18) % 2
B = int (S/36)
Cluster: The smallest unit allocated to the file by the disk. 1 cluster = 2n sector, n =, 2 ,........
Sector: The smallest unit of disk read/write.
Bytes: The smallest unit of memory read/write
Bit: The minimum unit of CPU processing.

5. 3.5-inch MB Floppy Disk Storage Structure
1. Boot Sector
(0 sectors)
Purpose:
Record basic information about the disk.
Oem id: format the software version number of the floppy disk.
Bytes per sector: per sliceBytesCount (512)
Sector per cluster: number of sectors per cluster (1)
Fat copies: number of file allocation tables (2)
Root directory entries: number of files that can be accommodated in the root directory (224)
Total sectors on disk: Total number of disk sectors (2880)
Media descriptor byte: features of the current Disk TypeBytes(F0)
Sectors per fat: number of sectors occupied by each fat (9)
Sectors per track: number of sectors per track (18)
Sides: Number of disks (2)
Volume serial number: volume ID (18f53a49)
File System ID: File System ID (fat12)
2. File Allocation Table fat1
(1--9 sector)
Purpose:
Records the usage of each cluster in the disk space and their relationships. 9x512 = 4608Bytes, With 12 binary bits (1.5Bytes)
Indicates the status of a cluster. A maximum of 3072 clusters can be managed, and 2847 clusters can be managed, with 334.5BytesFree.
Values and meanings of each fat unit:
000 h empty Cluster
002h----fefh the cluster has been used and its value is the cluster number of the next cluster.
Ff7h bad Cluster
FF8H----FFFH this cluster is used and is the last cluster
FF0H----FF6H retention Cluster
3. File Allocation Table fat2
(10--18 sectors)
Purpose:
As a backup of fat1. Same as above
4. root directory
(19--32 sectors) 14 sectors in the root directory 14 * 512b
In the file directory table, each file registration item occupies 32Bytes. A total of 224 files can be stored. (14*512/32)
32Bytes: 1-8 file Master name (8B)
9-11 file extension (3b)
12 file attributes (1B)
B7 B6 B5 B4 B3 B2 B1 B0
Archive, subdirectory, volume label, system, implicit, read-only

13-22 ReservedBytes(10B)
23-24 Last Updated Date of the file (2b)
[4-digit, 5-digit, and 7-digit (+ 1980)]
25-26 last file update time (2b)
[Hour 5 bits, minute 6 bits, second 5 bits (* 2)]
Starting cluster number (2B) of the 27-28 File)
29-32 file size (4B)

First file nameBytesMeaning:
00: This directory item is not used, and there is no directory item below
E5: Directory items of the deleted files
2e: Sub-directory item
Others: the first character of the file name
5. data in the data Zone
(33-2879 sectors, 2847 sectors in total, 1 cluster = 2n sectors, N 0, 2847 clusters in total, numbered 2-28 48)
Fat1 and fat2:
Fat features 2 3 4 5 6 7
F0f fff 2848 0 0 0 0 0
8 9 10 11 12 13 14 15
0 0 0 0 0 0 0

...............................................................

2841 2842 2843 2844 2845 2846 2847
0 000 0 0 0 0 fff
Note: F0 is3.5 floppy diskFeatures (in the boot Area)

Relationship between the cluster number and the relative fan area number:
Range of available sectors of the disk (expressed by the relative sector number): 33--2879
Cluster number: 2-2848
Cluster number = relative fan area number-31
**********************
Fat12 can manage up to 4 k clusters. For example, if a GB hard disk uses fat12, each cluster is about 30 m.
Fat16 can manage up to 64 k clusters. For example, if a 1.9 GB hard disk uses fat16, each cluster is about MB.
FAT32 can manage up to 4G clusters. For example, if a G hard disk uses FAT32, each cluster is about 30B.
***************************
Fat1: nine sectors, 9*512Bytes
Represents the status of a cluster with 12 binary bits (1.5b)
9*512*8/12 = 3072 (clusters)
Offset: Offset, which is the first sector.BytesLocation.

Fat12: 12B = 4096 (clusters)
1.44 m 1 cluster = 1 Sector
4*1024*1024*2 sector/4096 Cluster
1 cluster = 2048 sectors
***********************************
Problem:
1. fat12 uses 12 binary values to indicate the status of a cluster. Why does a MB Floppy Disk fat need 9 sectors?
(2847 + 2) * 1.5 = 2849*1.5 = 4273.5Bytes,
Convert to Sector 4273.5/512 = 8.34 to an integer 9
Fat12: 12B = 4096 (clusters)
4 GB 4*1024*1024*2 sector/4096 Cluster
1 cluster = 2048 sectors
2. If a 4 GB hard disk is managed by fat12, how many sectors are there in each cluster?
3. for a fat system disk, which of the following operations is performed on each disk region (BOOT, fat1, fat2, root, and data) by deleting a file?
Put the first file name in RootBytesChange to e5h
Change the status of the cluster occupied by the file to 0 in fat.

Fat12 uses 12 binary values to indicate the status of a cluster,
Need (2847 + 2) * 1.5 = 4274Bytes, Converted to Sector 4274/512 = 9
F0 is3.5 floppy diskFeatures (in the boot Area)
2847 + 2 = 2849 2849*12/8 = 4274Bytes8.34 sectors (9 sectors)
************************************
Hard Disk structure:
Cylindrical (0-----1023), header (0-15), Sector (1---63)
1024x16x63x512 = 540 MB
1024x256x63x512 = 8 GB

0 heads, 0 channels, 1 sector: MBS (primary Boot Sector)
MBS (primary Boot Sector): 1. Primary boot program: MBR (446b) 0--1bdh
Command fdisk/MBR: reconstructs the main Bootstrap program
2. Partition Table: (16x4 = 64b) 1beh-1fdh
The hard disk is divided into four areas, and one type of operating system can be installed in each area.

Every 16bBytesDescribes the basic information of a hard disk partition:
Guide flag, 1B
Starting physical location 3B
Operating System ID, 1B
Physical location of the end, 3B
The relative fan ID at the beginning, 4B
Total number of available sectors. 4b
3. Primary guide sector ID: 55aah (2b) 1feh-1ffh
Hard drive with 0 heads, 0 channels, 1 Sector (512b), and primary Boot Sector
0-445: (000-1bdh) 446b primary Boot Record primary boot program
446-461 :( 1beh-1cdh) 16B first partition information
462-477 :( 1ceh-1ddh) 16B second partition information
478-493 :( 1deh-1edh) 16B third partition information
494-509 :( 1eeh-1fdh) 16B fourth partition information
510-511 :( 1feh-1ffh) 2B main guide record mark, content: 55aah
***********
Information about each partition (16b)
0: indicates the activation of the partition. 00 h/80 h (not bootable/bootable). Only one 80 h can be found in the four partitions.
1-3: Header, track, and sector at the beginning of the partition
4: OS logo installed in this partition
5-7: The end header, track, and sector of the partition
8-11: The relative fan area number starting from the current Partition
12-15: Total number of available sectors in the current Partition

3.5 floppy diskStorage Structure
Boot (0 sectors) fat1 File Allocation Table 1 (1--9 sectors) fat2 File Allocation Table 2 (10--18 sectors)
Root directory (19--32 sectors)
Data zone (2847 sectors, 2847 clusters, No.: 2-----2848)

2847 + 2 = 2849 2849*12/8 = 4274Bytes8.34 sectors (9 sectors)

Cluster: The smallest unit allocated to files by the disk.
File Allocation Table (FAT): records the usage of each cluster in the disk space and their relationships.
The range of available sectors of the disk (expressed by the relative sector number ):
33--2879
Cluster ID: 2--2848
Fat1: nine sectors, 9*512Bytes
Represents the status of a cluster with 12 binary bits (1.5b)
9*512*8/12 = 3072 (clusters)
Offset: Offset, which is the first sector.BytesLocation.

F0 FF 00 40 00 05 60 00
Fat features
Fat12: 12B = 4096 (clusters)
1.44 m 1 cluster = 1 Sector
4 GB 4*1024*1024*2 sector/4096 Cluster
1 cluster = 2048 sectors

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.