tier
asked on
Once again: Read hard disk sectors
I have been told that direct access to hard disk sectors is not possible with delphi2 (32 bit)(It would be possible through VXDs). Is it possible with Delphi1 (16 bit) by using the int 13h and running the application in Windows 95?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
In 32-bit code, you can do *some* DOS/BIOS interrupts using CreateFile on '\\.\VWIN32' and then doing DeviceIOControl to have it execute the ints for you. Int 13h is not supported using these methods.
In 16-bit code, you can do a few more ints, most of the int 13 functionality is supported. However, here you cannot use the VWIN32 VxD. You need to use DPMI to perform the ints, and the volume locking functions to obtain a lock of the correct level for the volume you wish to read/write. In some cases, the lock must be obtained in a two-step operation, where you first gain a intermediate level lock on a volume, and using this lock gets a exclusive lock.
In 16-bit code, you can do a few more ints, most of the int 13 functionality is supported. However, here you cannot use the VWIN32 VxD. You need to use DPMI to perform the ints, and the volume locking functions to obtain a lock of the correct level for the volume you wish to read/write. In some cases, the lock must be obtained in a two-step operation, where you first gain a intermediate level lock on a volume, and using this lock gets a exclusive lock.
Interesting indeed,
Yes, as I said before you need to use INT 32h (DPMI). The questions
is how to call Int 13h exactly using int31h or are there any procedures/documentations ???
Yes, as I said before you need to use INT 32h (DPMI). The questions
is how to call Int 13h exactly using int31h or are there any procedures/documentations ???
Regards,
Erik.