Page 1 of 1

Big FAT CHS problems

Posted: Mon Aug 11, 2008 10:53 am
by Revelation
In the FAT table info like the number of heads and the number of sectors per track is saved by the format utility. My code uses it to convert the LBA cluster number to CHS for int 13. This should work well in theory, if the BIOS uses the same CHS settings. But it is not working, so I guess the BIOS picks different settings.

How can I fix this problem?


edit: I should notice that I use an USB pen to boot.

Re: Big FAT CHS problems

Posted: Mon Aug 11, 2008 12:59 pm
by AJ
Hi,

I don't know if this has all the info you want, but you may find int 13h AH=08h (get drive parameters) useful.

Cheers,
Adam

Re: Big FAT CHS problems

Posted: Mon Aug 11, 2008 1:10 pm
by Revelation
Not long after my post, I implemented int 13 0x8. It's working for me in bochs, but not on the real system. Maybe it's because the real boot device is an usb pen, while in bochs it is a hdd image.

edit: it's not working on the real system, because my device is larger. when I tested the 10mb image I dd'd on the usb pen, it did work. I guess I'm crossing a maximum.