Ever since I first learned about display lists on my Atari 65xe computer, I realized that one day I wanted to create my own Atari Coarse Scroll Demo with an enhanced coarse scrolling effect. This example demonstrates a program that allows the screen to move in any in any direction using a joystick controller. It also changes some of the characters on the screen using a process known as a Redefined Character Set.
As you can learn from my Display list page, every time a GRAPHICS command is used on the Atari home computer, the ANTIC microprocessor builds a display list to create the screen affect you see. Anytime you add 16 to the GRAPHICS command, it removes the text window that appears in modes GRAPHICS 1 and above.
Atari Display List Lines
The Atari Coarse Scroll Demo program below generates a display list to the screen, fills the memory randomly with a brick wall scattered around (as a redefined character), and utilizes joystick control to scroll the screen in any direction.
For our example, I set the top line to GRAPHICS 0 to emulate a display panel. Below this the screen will contain a black background with GRAPHICS 1. This tutorial will cover the display list a little in depth if you decide not the visit the link on the page yet.
Display List in depth
As mentioned earlier, the Atari computer utilizes a microprocessor chip known as ANTIC that allows the generation of the data you see on the screen. When a display list is being created, it takes into account the overscan lines at the top of the screen. These are indicated by the number 112 (or $70 in hexadecimal), which occupy the first 3 lines (appearing as a black top border).
The next line shows a 66 ($42 in hexadecimal) to tell the ANTIC chip that a memory address will appear on the line scan line. So the two lines proceeding this will be listed in a (low/high byte) order to point to address of the beginning of screen memory.
Atari Scan Lines
After this will begin a series of repeating numbers to emulate the GRAPHICS 1 screen for each individual scan line for our Atari Coarse Scroll Demo. A scan line is a single blank line going from left to right across the screen. So each scan line you draw to the screen (by POKEing into into memory), will begin to cover the screen with black lines (when using GRAPHICS 1 and above).
Close to the end of the display list will be the number 66. This is an instruction that informs ANTIC to wait for a vertical blank before returning to the beginning of the display list. See the Atari Raster Scanpage for further information and clarification.
Atari Smooth Scrolling
The Atari Coarse Scroll Demo program utilizes a process known as coarse scrolling. This runs inside a vertical blank interrupt to create a smoother effect and scrolls the individual pixels (scan lines) on the screen (54276 – hexadecimal = $D404). It was written in assembly language using the MAC/65 cartridge.
I’m hoping to evolve this eventually into a full scrolling game on the Atari 65xe home computer. It will also have the ability to run in the Altirra emulator once it is complete. It has always been a dream of mine to create an original commercial game for this system.
Finally the program code for the Atari Coarse Scroll Demo is listed below for your viewing pleasure!