Date: Thu, 25 Sep 1997 11:28:42 +0200 (IST) From: Eli Zaretskii To: Mitch Randall cc: djgpp AT delorie DOT com Subject: Re: Lauching ASPI from DJGPP In-Reply-To: <3426D17B.2A6B@ncar.ucar.edu> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Mon, 22 Sep 1997, Mitch Randall wrote: > Does anyone have an example code snippet of a call to ASPI that's known > to work? I've ported working code from Watcom to DJGPP. However, > there is no response from the ASPI manager with the DJGPP version. I cannot be sure without seeing the original Watcom code, but I think the following is the source of your trouble: > /* point real mode data structure to real mode entry point */ > regs.x.cs = aspientry >> 16; > regs.x.ip = aspientry & 0xFFFF; It should say instead this, I think: regs.x.cs = aspientry >> 4; regs.x.ip = aspientry & 0xF; Real-mode addresses are formed by segment*16+offset. Multiplication by 16 is equivalent to a shift by 4 bits, not 16.