On 14 Aug 2012 at 23:45, David Griffith wrote:
Is there anyone here who understands 16-bit DOS coding well enough to
help me make some 32-bit code work in 16-bit DOS?
The solution depends on what you mean as "32 bit code". If you're
talking about code that uses the full set of 32-bit registers, but
otherwise stays within the bounds of 16-bit real mode addressing
(640K), it's simple--you simply tell the assembler that your program
is running in 16-bit real mode and use the 32-bit registers
explicitly. The proper code will be generated. (I can send you
samples if you'd like).
Otherwise, you're going to flip the operating mode of the CPU. Do
you want to run in segmented/protected mode or "flat 32 bit"mode
where 32-bit addressing across the entire memory space of the CPU is
used? In both cases, some sort of DPMI (DOS Protected Mode
Interface) server is required to handle allocation of memory and to
switch the CPU back to 16-bit real mode whenever a DOS system call or
BIOS call is made.
--Chuck