Working With Disk Protection (INT 13h)
I have previously mentioned that INT 13h copy protection schemes are
hardly ever used anymore. Nevertheless, it would be good practice for someone
to learn how to create and understand the code. You will most likely see
INT 13h used with function 2, read sector. This means that:
Register | Description |
AH | will contain the number 2 (function 2) |
AL | the number of sectors to read in. This is commonly only 1 since you just want to check a few sectors for disk validity. |
CH | will contain the cylinder number |
CL | will contain the sector number |
DH | will contain the head number |
DL | will contain the drive number 00h - 7Fh for floppies 80h - FFh for fixed disks |
ES:BX | will point to the address into which the data read from the disk will be written to |
Also refer to:
Introduction to disk protection
Advanced discussion