Running Windows 3.x with FreeDOS
(See also Win32)
Note: the information below currently only tested with Windows 3.11 standard (not to be confused with Windows for Workgroups 3.11) but should generally apply to Windows 3.0 through WfW 3.11. Installing Windows9x (use SETUP /NM /IS to avoid the "system doesn't have at least 16MB of RAM" error message ) or NT/2000/XP/2003 (use WINNT /B to avoid being forced to create bootdisks) isn't covered in this document
In the past, not only much software was written for the DOS platform, but also quite a lot of software for the Windows environment. Before the release of Win95, previous versions of Windows ran on top of a DOS flavour. Sometimes existing software wasn't compatible with newer versions of this graphical environment, which nowadays explains why people still want to run Windows 3.xx on top of their DOS. Because FreeDOS aims to be very compatible DOS replacement for other DOS flavours, we also want to be able to run Windows.
For unknown reasons, the DOS (versions 7.00 up to 8.00) included in Win95/98/ME refuse to run Windows 3.xx, although there are various patches available to not only access DOS but also run Windows 3.xx
- todo: Dosghost site for win3.1 on single diskette
- todo: MFD hack to allow to reach DOS 8.00 from WinME
- todo: Fix IO.SYS/HIMEM bug (44KB use of HIMEM, instead of only 1.5KB)
- todo: Fix to allow windows 3.1 on dos 7.x0 (and 8.00?)
- todo: MSDOS.SYS text options
these old Windows versions have 3 running modes:
- Real mode (only up to Windows 3.00)
- Standard mode (286 compatible)
- Enhanced (386) mode (Windows 3.1x only)
FreeDOS Beta9 Service Release #2 will attempt to include a kernel file that allows running Windows 3.xx on top of FreeDOS. Hopefully that will be kernel 2035b (not yet available, in the meantime use test kernel http://www.fdos.org/kernel/test/kernel.win.sys renamed to kernel.sys; see http://www.fdos.org/kernel/test/win31.diff for differences from current dev kernel). We recommend to start as simple as possible: no (memory) drivers loaded. If everything is allright then, try to load one of the memory drivers mentioned below. We recommend to first try loading the kernel low in that case (do not add DOS=HIGH to config.sys, our kernel is incompatible with some revisions of MS's HIMEM.SYS driver, like the one from Windows98).
Command Interpreter: FreeCom works in some cases, though you may wish to use the freeware 4DOS command.com for better compatibility.
Share: the FreeDOS version of Share must be loaded. Failure to do this will usually result in Windows immediately exiting and/or crashing/hanging/creating an unstable system.
Japheth has modified share to fix a bug which disallowed Microsoft Office from running in Windows. This version of share (including source and binary) is available at http://www.japheth.de/Download/share.zip and will be included in the next Beta 9 Enhanced Release ISO release.
Memory Managers: XMS support should be loaded.
- Use the MS himem (and optionally EMM386) that are provided with Windows or free downloads from MS' site. Using just MS himem seems to work fine for standard or enhanced mode, using 4DOS or FreeCom. (MS-DOS 6 or Win3's Himem should be ok, Win98's Himem may not be fully compatible with the kernel.)
- FreeDOS HIMEM: will very probably work (more likely for enhanced mode) or may cause Windows to exit with a "not enough memory" error message (standard mode)
- FreeDOS FDXMS286: untested
- FreeDOS FDXMS: untested
- FreeDOS FDXXMS: untested
- The FreeDOS emm386 equivalent should NOT be loaded, as it lacks some undocumented proprietary interfaces hidden in MS EMM386.
- UMBPCI: untested
- Quarterdeck QEMM: will probably work, as it existed in the same era as Windows. Compatibility level between QEMM386? and FreeDOS kernel is not known. As an added benefit to using QEMM, if you use its QDPMI driver you can start windows kernel directly (SYSTEM\KRNL386.EXE or SYSTEM\KRNL286.EXE) if you don't want DOS boxes.
- 386MAX: untested & unknown
- DR DOS himem/emm386: untested & unknown?
- Try DPMIONE. I haven't tried as it crashes on startup. Claims to support starting windows kernel directly (as mentioned for QEMM), so if it loads for you then should work fine.
- Try HX DOS Extender. I haven't tried yet. May support running kernel directly, includes a replacement DOSX if you don't need DOS boxes that essentially does that.
Disk Cache: optional
Smartdrive comes with Windows.
FreeDOS one untested.
Mouse: optional
Windows provides its own mouse driver
Cutemouse is packaged with FreeDOS, it should be Windows compatible
System.ini changes needed for enhanced mode:
{TODO: see if just OverlappedIO=false works instead}
For all possible settings to System.ini's [386Enh] section, please see Microsoft's Win3.x knowlegde base articles A-L and M-Z.
Config.sys changes needed for better compatibility:
Add (or change from 9,256 to) the line 'STACKS=9,512' though for Win3.0 using 0,0 may work better?
NOTE: (with FD kernel) Windows in standard and enhanced mode supports DOS boxes, but only when FD SHARE is loaded and possibly only with 4DOS instead of FreeCom. Running multiple DOS boxes should be avoided as it seems to cause loss of ability to type characters (or they are hidden) in other sessions when one is closed; but ctrl-alt-del may allow you kill the remaining DOS box. DOS boxes can run full screen or windowed in enhanced mode.
For more information about Windows and FreeDOS see http://www.coli.uni-saarland.de/~eric/stuff/soft/specials/win3.x-dosext-freedos-notes.txt
Example CONFIG.SYS:
DEVICE=C:\WINDOWS\HIMEM.SYS
DEVICE=C:\WINDOWS\SMARTDRV.EXE /DOUBLE_BUFFER (optional)
SHELL=C:\COMMAND.COM C:\ /P (or SHELL=C:\4DOS.COM /P)
FILES=255 (possibly not needed, but keeps windows from doing it)
STACKS=9,512
DOS=LOW (change to HIGH if that works for you)
Example AUTOEXEC.BAT:
@ECHO OFF
C:\FDOS\BIN\SHARE
set PATH=C:\DOS;C:\FDOS\BIN;C:\WINDOWS
WIN
>
| Name | Total | Conventional | Upper Memory
|
| SYSTEM | 21,616 | (21K) | 21,616 | (21K) | 0 | (0K)
|
| WIN386? | 9,520 | (9K) | 9,520 | (9K) | 0 | (0K)
|
| SHARE | 9,072 | (9K) | 9,072 | (9K) | 0 | (0K)
|
| COMMAND | 3,328 | (3K) | 3,008 | (3K) | 320 | (0K)
|
| WIN | 1,664 | (2K) | 1,664 | (2K) | 0 | (0K)
|
| DISPLAY | 11,952 | (12K) | 11,952 | (12K) | 0 | (0K)
|
| NLSFUNC | 2,416 | (2K) | 2,416 | (2K) | 0 | (0K)
|
| KEYBDATA | 112 | (0K) | 112 | (0K) | 0 | (0K)
|
| KEYB | 1,472 | (1K) | 1,472 | (1K) | 0 | (0K)
|
| CTMOUSE | 3,328 | (3K) | 3,328 | (3K) | 0 | (0K)
|
| COMMAND | 129,952 | (127K) | 129,952 | (127K) | 0 | (0K)
|
| Free | 455,472 | (445K) | 455,472 | (445K) | 0 | (0K) |