datum tables are a set of tables that are needed for running the code. There are 4 tables that start at addressed $6000, $6100, $6200, and $6300 respectively.

The first two tables are the high and low bytes respectively of the address of each scan line in page 1 of hires. Each is 192 bytes.

The second table is an index of which byte in a scanline should be written to based on X coordinate ranging from 0-140. It's really X/7 * 2. 140 bytes.

The third table is an index of which shape should be used for a given X coordinate. It's really X % 7. 140 bytes.

The reason why these are all on page boundaries is that the 6502 penalized you for indexing across a page boundary, so I use less than optimal packing to get bet performance in bit-blitting.

Technically, the source for these tables isn't source, but the output of a little BASIC program with an assembly language subroutine to generate them. I made those tables lovingly by hand in around 1981 and had been using copies of the same file since then.

Last edited Apr 23, 2013 at 4:46 PM by plinth666, version 1

Comments

No comments yet.