I am using Bochs 2.4.5 to write a boot sector code. I use the INT 13H to read sectors from floppy. But I found that if the sector count to read > 72, the INT13 will fail. An
According to Standard Floppy Disks Supported by MS-DOS, the number of sectors per track on a 1.44 MB floppy disk is 18. Since 18*4 = 72, that might be a clue. It's possible that the BIOS doesn't want to read more than a certain number of tracks at once.
You're using Bochs, so the answer can be found in the Bochs BIOS source: the BIOS is performing an explicit range check on the number of sectors, and rejecting it if it is greater than 72 (or equal to 0).
The simple answer as pointed out by Matthew Slattery is that this is merely a range check performed by Bochs. This is based on a 2.88Mb floppy multi track floppy disk controller read which would be limited to 72 sectors.
The happy answer is that current BIOS due to backwards compatibility only support a single side read which for a 1.44Mb floppy is a maximum of 18 sectors. This depends on the starting sector so that the actual maximum would be up to the total remaining on the track. Booting and running from a USB flash drive is a simple alternative to the obsolete floppy disk for os dev. The same BIOS disk/diskette functions can be used depending on the boot drive identifier (dl
register).