Date: Wed, 11 Dec 1996 17:21:06 +0200 (IST) From: Eli Zaretskii To: hars AT dutch DOT nl cc: djgpp AT delorie DOT com Subject: Re: DOS/BIOS direct Floppy access In-Reply-To: <199612102145.QAA19099@delorie.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On 10 Dec 1996 hars AT dutch DOT nl wrote: > registers.h.dh = test_drive ; // drive 0x00=A 0x01=B ^^ Check your references. This should be DL, not DH. > registers.x.ss = registers.x.sp = 0 ; You should also zero out the registers.x.flags field. If you don't, it will work most of the time, but bite you one day. (Btw, it's best to use the `__dpmi_int' library function which does all this zeroing for you.) I also recommend to reset the drive (Int 13h/AH=0) after every unsuccessful call to function 02h, as some drives will report bad status forever and ever if you don't reset them.