FAT12 - 2600, 2610?

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
HanzZ

FAT12 - 2600, 2610?

Post by HanzZ »

Hi :)
I'm trying to understand how works FAT12. But i don't know, what mean bytes 2600-2610 (on floppy). 2620-2630 are file description,i think. I give heed to next bytes (2640-2650). These have structure like bytes 2600-2610. Does anybody knows, what is on bytes 2600-2610 and 2640-2650 etc......?

This is my root dir:
[tt]
00002600 41 62 00 6f 00 6f 00 74 00 00 00 0f 00 dd ff ff |Ab.o.o.t........|
00002610 ff ff ff ff ff ff ff ff ff ff 00 00 ff ff ff ff |................|
00002620 42 4f 4f 54 20 20 20 20 20 20 20 10 00 00 48 a5 |BOOT ...H.|
00002630 57 33 57 33 00 00 c0 6b 2e 2e 02 00 00 00 00 00 |W3W3...k........|
00002640 41 6b 00 72 00 6e 00 6c 00 2e 00 0f 00 2f 78 00 |Ak.r.n.l...../x.|
00002650 00 00 ff ff ff ff ff ff ff ff 00 00 ff ff ff ff |................|
00002660 4b 52 4e 4c 20 20 20 20 58 20 20 20 00 00 7a 2a |KRNL X ..z*|
00002670 5c 33 57 33 00 00 7a 2a 5c 33 06 00 00 40 00 00 |\3W3..z*\3...@..|
00002680 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
[/tt]
thanks ;) (btw... is phrase "give heed to" good there?)
AR

Re:FAT12 - 2600, 2610?

Post by AR »

IIRC, those first 2 lines ARE a file entry, just of the type "Volume Label" (The label in the bootsector is meaningless, don't ask me why Microsoft thought it'd be good to have 2), the "Volume Label" exists only in the root directory of the drive (including HDDs) and contains the real label.
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:FAT12 - 2600, 2610?

Post by Pype.Clicker »

it seems - too - that your files have 'long filenames', which explains why you have both "BOOT" and "Ab.o.o.t." entries...
GenX

Re:FAT12 - 2600, 2610?

Post by GenX »

Hey,

Like AR said they are both just file entries, however the first is not the volume label (I am guessing you never entered one when formatting the disk), by the looks of it, in the root directory you have a sub-directory called 'boot' and a file named 'krnl.x'. If you had of entered a volume label when formatting the disk it would be the first entry as AR thought.

The two entries you are interested in are actually long file names (as Pype just mentioned), they both have ATTR_LONG_NAME (0x0f) for their attributes. Starting at 2620 and 2660 are the standard or short (8.3) file names.

Cheers. :)
HanzZ

Re:FAT12 - 2600, 2610?

Post by HanzZ »

:) thanks for explanation
Can somebody add this information to the FAQ?
http://www.osdev.org/osfaq2/index.php/FAT12%20document
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:FAT12 - 2600, 2610?

Post by Pype.Clicker »

afaik, there is a document somewhere (http://www.asmlove.co.kr/os/filesystem/longfilename.pdf) that describes long filename thoroughly. Probably it would be great to have 'FAT12' page somehow extended with some more 'real case' examples showing how filenames are searched, what structure do look like, etc.
B.E

Re:FAT12 - 2600, 2610?

Post by B.E »

if you have not done so already download the FAT specification
http://www.microsoft.com/whdc/system/pl ... atgen.mspx
each
I'm trying to understand how works FAT12. But i don't know, what mean bytes 2600-2610 (on floppy). 2620-2630 are file description,i think
yes, 2600-2A00 are all file descriptors.
a file descriptor is 32 bytes long. and there are 32 file descriptors in the root dir.
Post Reply