Chapter
4
I
MS-DOS
Disk
Allocation
18H-19H
Date the file was created
or
last updated. The year,
month, and day are mapped into two bytes
as
follows:
Offset 19H
YYYYYM
1; 1;
15
14
13
12
11
10
1
17
16
15
14
1;
1;
1:
1:
1
Offset 18H
MMMD
where:
YYYYYYY
is
0-119 (1980-2099)
MMMM is 1-12
DDDDD
is
1-31
Starting cluster; the cluster number of the first
cluster in the file.
Note that the
first
cluster for data space on all
disks is cluster 002.
The cluster number is stored with the least signifi-
cant byte first.
Note: Refer
to
the section “How
to
Use the File Al-
location Table” for details about converting cluster
numbers
to
logical sector numbers.
File size in bytes. The
first
word is the low-order
part of the size.
1AH-1BH
1CH-1FH
File Allocation Table (FAT)
This section is included for system programmers who wish
to
write installable device drivers.
It
explains how MS-DOS uses
the File Allocation Table
to
convert the cluster numbers
of
a file
to
logical sector numbers. The driver is then responsible
for
lo-
cating the logical sector on disk. Programs must use the
MS-
DOS file management function calls
for
accessing files. Pro-
grams that access the FAT are not guaranteed
to
be upwardly
compatible with future releases of MS-DOS.
168