Mail Archives: djgpp/1999/06/29/14:35:33
David Mitchell wrote:
>
> Umm, I have written the following for NASM:
> mov bp, sp
. . .
> mov ax, [bp+4]
> int 10h
. . .
> and compiled it as a COFF, then I compiled it with this file :
. . .
> using the line (DJGPP):
> >>gcc main.c graphics.o
DJGPP is a 32-bit environment. That means you must use
esp instead of sp, ebp instead of bp, and ebp+8 instead of
bp+4.
DJGPP is a protected mode environment. Instructions like
"int 10h" cannot go directly to the BIOS. They must be
intercepted by the DOS extender and redispatched in V86 or
real mode.
DJGPP code can be run several different environments (such
as CWSDPMI or Windows DOS boxes etc.). I don't remember whether
all, some or none of them redispatch int 10h's for you. I
expect it is in the FAQ.
--
http://www.erols.com/johnfine/
http://www.geocities.com/SiliconValley/Peaks/8600/
- Raw text -