MS-DOS 6.22 EMS Emulation from XMS Memory Driver
In MS-DOS 6.22, running software that requires Expanded Memory
Specification (EMS) on modern or extended-memory-equipped systems
requires an expanded memory manager. This article identifies the
specific driver responsible for emulating EMS out of Extended Memory
(XMS), details the prerequisite drivers, and explains the exact
CONFIG.SYS configuration necessary to enable and control
this behavior.
The EMS Emulation Driver: EMM386.EXE
The driver that enables virtual EMS emulation from XMS memory in
MS-DOS 6.22 is EMM386.EXE.
Operating on Intel 80386 and later processors,
EMM386.EXE utilizes the CPU's Virtual 8086 mode to map
pages of extended memory (XMS) into the Upper Memory Area (UMA)—the
region between 640 KB and 1024 KB. This process establishes a 64 KB EMS
page frame (typically at segment address E000 or
D000), divided into four 16 KB pages, providing full LIM
EMS 4.0 compatibility to DOS programs without requiring dedicated
hardware expanded memory boards.
Prerequisites: HIMEM.SYS
EMM386.EXE cannot function independently because it
relies on existing XMS memory to create the virtual EMS pool. Therefore,
HIMEM.SYS, the default MS-DOS extended
memory manager, must be loaded prior to EMM386.EXE.
Configuring CONFIG.SYS for EMS Emulation
To activate EMS emulation, both drivers must be added to your
CONFIG.SYS file in the proper sequence.
DEVICE=C:\DOS\HIMEM.SYS
DEVICE=C:\DOS\EMM386.EXE RAM
Key Parameters:
RAM: InstructsEMM386.EXEto provide both EMS emulation and Upper Memory Blocks (UMBs). UMBs allow you to load drivers and TSR programs into high memory using theDEVICEHIGHandLOADHIGHcommands.- Memory Size (Optional): By default,
EMM386.EXEdynamically allocates as much EMS as requested by running applications. To set a specific allocation limit in kilobytes, specify the number before the parameters:
This restricts EMS allocation to 4,096 KB (4 MB).DEVICE=C:\DOS\EMM386.EXE 4096 RAM NOEMS(Contrast): If your system only requires UMBs and does not require expanded memory, specifyingNOEMSdisables the 64 KB page frame entirely, freeing up that address space for loading high drivers while disabling EMS emulation.
Verifying the Configuration
After rebooting the system with the configured
CONFIG.SYS, verify that EMS emulation is active by running
the following command at the DOS prompt:
MEM
The output will display the total, used, and free expanded memory
available, confirming that EMM386.EXE is successfully
emulating EMS from XMS.