Raw disk access under Windows 95, 98 & ME

When I first wrote Explore2fs it was for Windows NT.  NT allows you to access and direct access storage device as a random access file.  This meant that I could just open the appropriate disk and read the data off.

There was however a cry for support from Windows 95 users who were suffering from an OS with no design at all.  I did a lot of research on disk access and all I could work out was how to crash windows.  Eventually I found a MS Knowledge base article which pointed me at a solution.  The article can be found here http://support.microsoft.com/support/kb/articles/q137/1/76.asp

Armed with this information I set about writing a 16 bit DLL which would do the disk access for me.  Using an old copy of Borland C++ 3.1 I was able to build a DLL which implemented the appropriate functions.  Of course I could not have done that without the help of Ralf Brown's Interrupt List.

The next task was to call the code from Win32.  The Microsoft Thunk compiler was a load of crap which did not have any useful documentation or examples but I eventually found a solution, and just to make my life easy for a change the code was already written in Delphi. QT Thunk is a method of calling 16 bit library functions from Win32 without and crap in the middle. http://red.east.net.cn/~develop/Delphi/Document/thunk95.htm

Once I had this working I could access disks using the original BIOS interrupts from Win32.  The next problem was that the PC BIOS can not read disks larger that 8 Gig.  Some further research turned up Extended Interrupt 0x13, a standard extension to Int 0x13 which allowed large disk access.  Armed with Ralf Browns Interrupt List once again I updated the 16 bit DLL to support this new interface.

On the other side of the problem, I had a disk IO method for Windows NT and a method for 95.  I created a base class for disk access and an implementation for NT and 95, each using the appropriate method.  The final result is a relatively clean cross MS OS disk access library.

The complete delphi source can be obtained from the Explore2fs Package.  The source to diskIO2.dll can be downloaded from here

      

       Win32

         /\

        /  \

       /    \

      /      \ 

     |        |

     |        |

 Win16    NT Win32 Subsystem

     |

     |

 DPMI

     |

     |

BIOS Int 0x13

      

Last modified 26/02/01
Maintained by John Newbigin
Hit Count
Page Counter