Confusion about media descripter byte in OEM block

If you are new to development, plan on spending some time here before visiting the other forums.

Moderator: Moderators

Confusion about media descripter byte in OEM block

Postby brainbarshan » Sat Feb 20, 2010 2:58 pm

In tutorial 5 (Bootloaders 3) of operating system developement series :

The Media Descriptor Byte (bpbMedia) is a byte code that contains information about the disk. This byte is a Bit Pattern:
Bits 0: Sides/Heads = 0 if it is single sided, 1 if its double sided
Bits 1: Size = 0 if it has 9 sectors per FAT, 1 if it has 8.
Bits 2: Density = 0 if it has 80 tracks, 1 if it is 40 tracks.
Bits 3: Type = 0 if its a fixed disk (Such as hard drive), 1 if removable (Such as floppy drive)
Bits 4 to 7 are unused, and always 1.

so for floppy disk we have to set 11111000 = 0xF8, because 3rd bit to be set is 1 ( for floppy drive , as mentioned)

but the 3rd bit has been set 0 and so the byte is set 0xF0.
which one is correct?
Posts: 9
Joined: Fri Feb 19, 2010 12:58 pm

Re: Confusion about media descripter byte in OEM block

Postby Mike » Thu Mar 11, 2010 7:50 pm


I apologize for the late reply. We need to verify the information in that table is correct. For 1.44 MB (and 2.88 MB) media the media descriptor byte should be 0xf0 not 0xf8.
Lead Programmer for BrokenThorn Entertainment, Co.
User avatar
Site Admin
Posts: 463
Joined: Sat Oct 20, 2007 7:58 pm

Return to Beginners

Who is online

Users browsing this forum: No registered users and 1 guest