home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frostbyte's 1980s DOS Shareware Collection
/
floppyshareware.zip
/
floppyshareware
/
USCX
/
DOSUT-08.ZIP
/
MEM640.DOC
< prev
next >
Wrap
Text File
|
1983-12-11
|
7KB
|
222 lines
640K Memory Size Support
A Modification to PC-DOS 2.0 BIOS
By
John A. Chapman
CIS [70205,1217]
844 S. Madison St.
Hinsdale, Illinois 60521
Machine Configuration
This modification applies ONLY to those machines which have installed
more than 544K byte of contiguous main storage, AND DO NOT HAVE THE NEW
BIOS CHIP. The new BIOS chip IBM supplies, both with the expansion
interface and new 256K motherboard PC's already supports 640K of memory.
Please note that attempts to use this modification on machines with less
than 608K storage may cause the system to fail.
Limitation and Disclaimer
Since this modification alters the behavior of BIOS in a static fashion,
use of the modified system is thereafter LIMITED to machines WITH THE
SAME MEMORY SIZE, since there is no dynamic size determination capability
in this version of the mod.
THIS MODIFICATION IS SUPPLIED ON AN AS-IS BASIS. EACH USER MUST DETERMINE
THE FITNESS AND APPLICABILITY OF THIS CHANGE FOR THE SPECIFIC ENVIRONMENT
IN WHICH IT WILL BE INSTALLED. THE AUTHOR ASSUMES NO LIABILITY FOR
FAILURE OR DAMAGE CAUSED BY THIS MODIFICATION.
This modification is in use on the author's system, which is an
"original" PC (the old 16K mother board with the OLD bios chip) which
has the following equipment installed on it:
Vista MAXI-RAM (576K memory board)
ABM OMNI-Board (Clock 2-serial, 1-parallel, game adapter)
IBM Disk Controller (2 TEAC FD-55B's 1 Tandon 101-4)
IBM Color Graphics Adapter
This modification works on the configuration described above. If you
report a bug, please include a description of the configuration on which
the bug was encountered. No known bugs exist in this version of the
modification, which has been in use since DOS 2.0 was released. Please
report any bugs you find to the author, at the address shown above.
1
Overview
Older PC's are limited by the BIOS code and switch setting support (in
the ROM BIOS chip) to 544K. It is possible to add 576K to the machine,
giving a total memory of 640K, or even 704K, if you don't have, and don't
need the monochrome display. To access this memory it is necessary to
have it recognized at BOOT time. DOS 2.0 maintains pointers to the top
of memory which are set at initialization. This modification to the INIT
routine of DOS 2.0 BIOS, initializes the memorsize field in low memory
to 640K, and leaves a "footprint" similar to the one left by the keyboard
routine when ALT-CTRL-DEL sequence is detected.
The code added to BIOS does three things:
1) Checks for the "footprint" and skips all MEM640 processing
if the footprint is present (We've been here before) -
This prevents conflict with RAMDRIVE software that causes
a "warm" re-boot to alter memory size, to allocate memory
for the ramdrive.
2) Modifies the memory locations containing memory size and
I/O-bus memory size, in the system data segment at X'40'
3) Clears the memory above 544K to zeros.
Installing the Modification
To use this modification on a 640K machine, simply run the DEBUG script
contained in the file MEM640.ZAP, as follows:
a) B: drive must contain the DOS 2.0 formatted disk to be modified
b) A: drive must contain the DEBUG command, and the file MEM640.ZAP
When the disks are in the correct drives, the command:
a:debug <b:MEM640.ZAP
will invoke the DEBUG script supplied. A listing of the actions taken
will display on the screen, and eventually the DOS prompt will return.
After the script has run, the newly modified diskette should be booted,
to assure that the modification was correctly installed. The CHKDSK
command can be used to verify that the additional memory is accessable.
The code sequences to support greater that 544K are simple and static.
The code should be easy to understand, and easy to modify. A listing of
the debug script, with the comments and indications of where changes must
be made to support other memory sizes, is included as Attachment I to
this document.
2
ATTACHMENT I: The DEBUG Script
l100,1,5,1 <======== First line of script
e10b,20
w100,1,5,1
nb:ibmbio.com
l
r <==== Action of script begins here
R CX
1230 <== change length of BIOS before rewriting
A12d0,12ff <== Begin assembly entry of mod
PUSH AX
PUSH ES
PUSH DI
XOR AX,AX
MOV ES,AX
MOV DI,0472 Change the two values pointed to below if
MOV AX,4321 you wish to support a memory size between
ES: 544 and 640.
CMP AX,[DI]
JZ 12F7
MOV DI,0413
MOV AX,0280 <-- TOTAL MEMORY SIZE IN HEX <<CHANGE>>
STOSW
MOV AX,0240 <-- I/O bus Memory (Total - 64K) <<CHANGE>>
STOSW
CALL 1300 <-- invoke memory clear routine to prevent
MOV DI,0472 parity checks on read references to memory
MOV AX,4321 <-- OUR FOOTPRINT !!!
STOSW
POP DI
POP ES
POP AX
MOV AL,02
STOSB
JMP 08DC <-- Jump back to BIOS init code
PUSH CX <===========Routine to clear ememory above 544K
PUSH DX (If you have less than 640K you don't have
PUSH SI to change this routine, but If you have
MOV DX,8800 704K or 768K, start and length values
MOV AH,03 must be changed.
MOV AL,00
MOV ES,DX
MOV CX,8000
SUB DI,DI
REPZ
STOSB
ADD DX,0800
DEC AH
JNZ 130A
XOR AX,AX
MOV ES,AX
POP SI
POP DX
POP CX
RET
NOP [[[ Continued on next Page ]]]
3
ATTACHMENT I: The DEBUG Script
NOP
NOP
NOP <======= This section pads out the MOD to an even boundary
NOP
NOP
E,3E7,B0,00
A8D9
JMP 12D0 <====== Jump to the additional INIT code
W
l100,1,5,1
e10b,27 <====== This sequence resets IBMBIO.COM to Hidden
w100,1,5,1 and System attributes, updating the directory
Q