Dec 282017
Tools for programming your own ROM's for AT, etc.
File ROMTOOLS.ZIP from The Programmer’s Corner in
Category Miscellaneous Language Source Code
Tools for programming your own ROM’s for AT, etc.
File Name File Size Zip Size Zip Type
ADDROMS.EXE 1588 847 deflated
CHKSUM.EXE 1252 597 deflated
ROMTOOLS.DOC 5760 2410 deflated
SPLIT.EXE 1716 790 deflated

Download File ROMTOOLS.ZIP Here

Contents of the ROMTOOLS.DOC file


Anyone intersted in the source codes for these programs,
send $5 to the address below to cover disk & mailing costs.


WRITTEN by: Pete Korner|
10509 Hunt Ave.|
South Gate, Ca.|

CHKSUM provides the true checksum of any file, any size, but primarily
written to use on PC/AT roms. The roms may be edited but their cheksum
must be adjusted to end with 00 in order for them to boot up. The first
two bytes (I.E. XX00) can end up to be any hex charaters.
SPLIT separates a file into even and odd byte files for eprom use in the
AT or AT clone type computers.
ADDROMS reverses the action of SPLIT , combines even and odd roms files
into one file which allows for easier editing.
PC/XT roms are 8 bit and DO NOT require splitting into evn/odd files.

Note: PC/XT clones have no basic roms, only the BIOS. The rom
is at fe00:0 to fe00:ffff for 2000h bytes. Change the move
address in AT's debug routine to fe00:0 2000 cs:100 and set CX to
2000h instead of 8000h and only one file needs to be named/written.
IBM PC/XT basic rom adresses are at f600:0 , f800:0 , fa00:0 and
fc00:0 for the four basic roms. The PC/XT BIOS rom is at fe00:0 .

If you are interested in editing your roms, READ the rest of this file.
I'll go through a relatively simple example of editing the disk para-
meter table and 'fixing' up the checksum afterwords.

The following debug routine may be used to read the AT or AT clone roms.

debug 'CR';start debug
-;debug's cursor
rcx;set CX register
8000;for 8000h bytes
n 1st.hlf;name for the 1st half of rom
m f000:0 8000 cs:100;move 1st half of rom into debug's segment
w;write the file to disk
n 2nd.hlf;name fo 2nd half of rom
m f800:0 8000 cs:100;move 2nd half of rom into debug's segment
w;write the file to disk
q;quit debug

At this point we have two files, 1st.hlf and 2nd.hlf 32768 decimal bytes
each. Most AT clones have 128k roms, in which case the 1st.hlf is all 'ff's
and we do not need it. In this case the 2nd.hlf file is the complete bios rom.

IBM's AT roms are 256k each so we need to combine the two files. Use the
folowing commands from dos.
copy /b 1st.hlf+2nd.hlf atrom;creates new file ATROM
del 1st.hlf ;we do not need
del 2nd.hlf;these any more

Now we have the complete ROM in one file. Running the chksum program
should yield a hex number which ends with '00'. All roms must have a
'XX00' cheksum, otherwise they won't boot.
In the AT roms the hard disk parameter table starts at 'offset 6401' ,
6501 if using debug. Each group of 16h bytes corresponds to a 'type' ,
of hard disk starting with type 1 at offset 6501.
This table may be modified if you are installing a hard disk whose
parameters do not match any of the standard values in the rom.
[i.e. # of cylinders, heads etc.] We can maximize hard disk capacities
by matching these parameters.
I modified my AT clone's rom for RLL use with the WD 1003 - RA2
controller by replacing the 11h [# of setors/track] byte in the
table with 1Ah [26 sectors]. This provided 50% more capacity on my
hard disk.
After modification the checksum must be made to end with 00's again.
Here is how we can do it...
After modifing the rom file to your liking write it back out to
disk with debug's 'W'command.
Run the chksum program on the file.
Write down the new checksum.
Let's say the new checksum is 2233h.
Load the modified rom file again with debug. [i.e debug atrom]
Type the following at debug's prompt: H ffff 2233
Debug comes back with the sum and diff: 2232 DDCC
What we need is the last two bytes of the diffrence. The 'CC'.
We need to change an unused 'FF' in the rom to 'CC'.

The starting precomp cylinder bytes for some AT hard disks is ff ff
in the table.
At 6556 and 6557 we find a couple of 'ff's corresponding to
the precom cyl. bytes for type 6 hard disk.
This disk is 615 cyl 4 heads [20meg] with the precom cyls. 'ff ff'
As long as the precomp cyls # is greater then the # of cylinders
[6702h reversed = 0267h = 615dec ] the controller will not format
any cylinders with precomp.
So we can freely change the first byte to anything so our checksum
will come out to "xx00".
In our case we change it to 'CC' [-E 6556 FF.CC ]
and write it back out with a "W'.
Now if we rerun the chksum on the file it will have an 'XX00' checksum.
AT roms are split evn/odd [low/high] because of the 16 bit address bus.
We need to split our file in this fashion to make it usable as a ROM
in an AT or AT clone. [Remember the checsum MUST end with 'xx00' for
the combined file not neccesarily for the split ones individualy.]

When we run the SPLIT program on our new file ATROM, we get ATROM.EVN and
ATROM.ODD suitable as input files for eprom burners.

I hope you'll find these ROMTOOLS useful... Pete Korner

 December 28, 2017  Add comments

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>