I want to read a large capacity disk using ATA commands sending though DeviceIoControl(). Sending commands using ATA_PASS_THROUGH_EX
structure is the main problem. Actually CurrentTaskFile[]
arary of UCHAR
type is not able to send a sector no greater than 16777215.
CurrentTaskFile[2] = 0xFF;
CurrentTaskFile[3] = 0xFF;
CurrentTaskFile[4] = 0xFF;
That is
CurrentTaskFile[2] = 0xFF
is Sector number register,
CurrentTaskFile[3] = 0xFF
is Cylinder low register,
CurrentTaskFile[3] = 0xFF
is Cylinder High register.
Now what to do if i want to read sectors no more than 16777215 (If I want to read a 1 TB disk's last sector). How to send sector no more than 16777215. Actually i have to read disk with capacity upto 4 TB.