Re: Running Mikeos on a *real* 8086
Posted: Sun May 06, 2012 9:00 am
Well it turned out that the always trustworthy PC Hardware Book doesn't mention that the sectors per FAT on a 720Kb disk are 3 and not 9. I found out the correct value by examining the boot sector of a 720Kb DOS-formatted disk [why didn't I think of that before? I've been banging my head against the wall two days because of this].
FYI, these are the correct values for a 720Kb 3.5" disk:
With the above in mind I've been fiddling around a bit with the FAT driver and been able to boot the 720Kb disk in QEMU but I didn't get past the start menu due to me too lazy to check for each entry in the driver [atm I can list the floppy contents but that's it]. Anyway, booting the 8086 M24 would be a completely different matter due to the lack of the popa/pusha opcodes. I admit I lose interest in this but hey, it was worth a try and it got me the urge to write my first real-mode OS
Ciao!
FYI, these are the correct values for a 720Kb 3.5" disk:
Code: Select all
OEMLabel db "MIKEBOOT"
BytesPerSector dw 512
SectorsPerCluster db 2 ; 1 for 1.44Mb disk
ReservedForBoot dw 1
NumberOfFats db 2
RootDirEntries dw 112 ; 224 for 1.44Mb disk
LogicalSectors dw 1440 ; 2880 for 1.44Mb disk
MediumByte db 0F9h ; 0F0h for 1.44Mb disk
SectorsPerFat dw 3 ; 9 for 1.44Mb disk
SectorsPerTrack dw 9 ; 18 for 1.44Mb disk
Sides dw 2
HiddenSectors dd 0
LargeSectors dd 0
DriveNo dw 0
Signature db 41
VolumeID dd 00000000h
VolumeLabel db "MIKEOS "
FileSystem db "FAT12 "
Ciao!