Atari 8-bit architecture and homebrew versions
Posted: 16 Nov 2019, 01:10
When I was a teen, I owned an Atari 800 that I still have today. Recently, I've been researching the Atari 8-bit computers. It is interesting how the hobbyist and FPGA community have made all sorts of mods and are still using them or homebrew versions of them today.
Atari 8-Bit Computer Architecture
Atari 8-bit computers use a modified 6502 processor that they nicknamed "SALLY." Atari modified the 6502 CPU to add a /halt line in place of an unused pin and may have added a second R/W line. Atari literature refers to the Sally chip as a 6502C but it is a modified 6502B. That was unofficial since the MOS 6502C does not have a /halt pin. The earliest Ataris added 4 chips to disable the 6502 while ANTIC accessed the RAM. So the Sally 6502 reduced the chip count.
Atari uses the Sally 6502 because they also use a video coprocessor called ANTIC (Alpha-Numeric Television Interface Controller) which needs to access memory. ANTIC also acts as a DMA controller. In addition to running user code, SALLY writes a display list, then ANTIC takes over to process the display list. In turn, ANTIC sends its output to the GTIA (or CTIA, or FGTIA, depending on the television standard used and the exact Atari model). The CTIA was a lower-cost version of GTIA with fewer graphics modes. ANTIC uses an interrupt signal to get SALLY to run display list handlers. The GTIA makes things displayable and sends output to the RF modulator.
"Freddie" and the MMU chips handle the refresh, using ANTIC as a DMA controller. The port and keyboard controller, POKEY, handles the sound, and along with the Peripheral Interface Adapter (PIA), POKEY also handles the ports.
1088 XEL
The 1088 XEL is an interesting project. It uses 5 of the original Atari chips (Sally 6502, Antic, GTIA, Pokey, and PIA). It adds a 2nd POKEY to add true stereo. It uses SRAM, so the FREDDY and MMU chips do not exist. That improves performance since there is no DRAM refresh, so ANTIC doesn't pause SALLY for that reason. I wonder if using dual-ported SRAM would improve performance since Sally could be attached to one channel and ANTIC and the rest could connect to the other. Then maybe the /halt line could be disconnected since memory accesses would be safe. The 1088 XEL does not include a ROM since it is made from the ground up to use the Ultra 1 meg daughterboard, and the Ultra 1M replaces the ROM in stock Atari machines. Other modifications from the original design include using a PS2 keyboard and mouse.
The 1088 XEL only provides S-video and maybe composite, but if you add the VBXE mod, you can get enhanced RGB/CGA with extra modes. You might be able to modify the FPGA core and change a crystal to get the VBXE to work with some VGA monitors. With the Sophia mod, you can get DVI. The VBXE mod replaces the Antic chip, and the Sophia mod intercepts the GTIA. If I had a 1088 XEL, I'd add the Rapidus mod which sits between Sally and its socket. The Rapidus adds a W65C816 CPU, which is a 16-bit version of the 6502, and it is clocked at 20 Mhz.
Rapidus Upgrade
There is the Rapidus modification that can upgrade stock Atari machines and possibly even the 1088 XEL by adding a 65816 CPU. That is a 16-bit CPU with some modifications and added instructions when compared to the 6502. The 65816 is not fully pin-compatible with the Sally 6502, so if you want to use it, you'd need a multiplexer or some other chip to make up for the generations and implement a /halt line. The Rapidus board allows you to switch between the original SALLY 6502 and the 65816.
I like the one Rapidus benchmark that is on Youtube. It compares between the regular BASIC cartridge in stock Atari mode, the Turbo BASIC cartridge in stock Atari mode, the Veronica BASIC cartridge in stock Atari mode, and Turbo Basic running with the Rapidus in 65816 mode. Regular BASIC with the Rapidus disabled takes about a minute and 55 seconds to draw a sphere. Turbo Basic with the 6502 takes 33 seconds to do it. Turbo Basic has faster drawing routines and faster FPU emulation. Veronica BASIC takes 8 seconds. Veronica BASIC cheats because, in addition to having better drawing and FP routines, it has a 65816 in the cartridge that is clocked at 8 times the 6502 clock rate. Having the Rapidus mode enabled and running Turbo BASIC runs the program in 3 seconds.
Universal Memory Upgrade and Repair Kit
There is also a universal Atari memory problem repair kit. It is a 64k SRAM board that fits between the "Sally" 6502 and the socket. Other than that, you remove all the memory boards, and optionally, you can solder the CAS-disable wire between the SRAM board and the appropriate pin on the motherboard or CPU board, depending on which exact model you put it in. Some models may require an alternative FREDDIE chip to disable the DRAM refresh. So if you have a problem with a memory board or the DRAM refresh circuitry, this is a simple workaround. If you disable the refresh, it should work a tad faster since ANTIC halts the CPU less. So it only halts the CPU to process the video and not refresh the RAM.
Atari 2600 Video Game
The Atari 2600 video game system is simpler than the Atari computers. It uses a 6507 (a 28-pin version of the 6502 with 13 instead of 16 memory address pins, though they only used 12, no /halt line, and no interrupt lines), the TIA chip (like GTIA, but not as complex), and the RIOT chip (RAM, I/O, Timer). Other than that it has mostly discrete resistors and a few pots, inductors, capacitors, and crystals. The cartridges were the ROM and software. One company did make a keyboard and a homebrewer made a BASIC for it.
Atari 8-Bit Computer Architecture
Atari 8-bit computers use a modified 6502 processor that they nicknamed "SALLY." Atari modified the 6502 CPU to add a /halt line in place of an unused pin and may have added a second R/W line. Atari literature refers to the Sally chip as a 6502C but it is a modified 6502B. That was unofficial since the MOS 6502C does not have a /halt pin. The earliest Ataris added 4 chips to disable the 6502 while ANTIC accessed the RAM. So the Sally 6502 reduced the chip count.
Atari uses the Sally 6502 because they also use a video coprocessor called ANTIC (Alpha-Numeric Television Interface Controller) which needs to access memory. ANTIC also acts as a DMA controller. In addition to running user code, SALLY writes a display list, then ANTIC takes over to process the display list. In turn, ANTIC sends its output to the GTIA (or CTIA, or FGTIA, depending on the television standard used and the exact Atari model). The CTIA was a lower-cost version of GTIA with fewer graphics modes. ANTIC uses an interrupt signal to get SALLY to run display list handlers. The GTIA makes things displayable and sends output to the RF modulator.
"Freddie" and the MMU chips handle the refresh, using ANTIC as a DMA controller. The port and keyboard controller, POKEY, handles the sound, and along with the Peripheral Interface Adapter (PIA), POKEY also handles the ports.
1088 XEL
The 1088 XEL is an interesting project. It uses 5 of the original Atari chips (Sally 6502, Antic, GTIA, Pokey, and PIA). It adds a 2nd POKEY to add true stereo. It uses SRAM, so the FREDDY and MMU chips do not exist. That improves performance since there is no DRAM refresh, so ANTIC doesn't pause SALLY for that reason. I wonder if using dual-ported SRAM would improve performance since Sally could be attached to one channel and ANTIC and the rest could connect to the other. Then maybe the /halt line could be disconnected since memory accesses would be safe. The 1088 XEL does not include a ROM since it is made from the ground up to use the Ultra 1 meg daughterboard, and the Ultra 1M replaces the ROM in stock Atari machines. Other modifications from the original design include using a PS2 keyboard and mouse.
The 1088 XEL only provides S-video and maybe composite, but if you add the VBXE mod, you can get enhanced RGB/CGA with extra modes. You might be able to modify the FPGA core and change a crystal to get the VBXE to work with some VGA monitors. With the Sophia mod, you can get DVI. The VBXE mod replaces the Antic chip, and the Sophia mod intercepts the GTIA. If I had a 1088 XEL, I'd add the Rapidus mod which sits between Sally and its socket. The Rapidus adds a W65C816 CPU, which is a 16-bit version of the 6502, and it is clocked at 20 Mhz.
Rapidus Upgrade
There is the Rapidus modification that can upgrade stock Atari machines and possibly even the 1088 XEL by adding a 65816 CPU. That is a 16-bit CPU with some modifications and added instructions when compared to the 6502. The 65816 is not fully pin-compatible with the Sally 6502, so if you want to use it, you'd need a multiplexer or some other chip to make up for the generations and implement a /halt line. The Rapidus board allows you to switch between the original SALLY 6502 and the 65816.
I like the one Rapidus benchmark that is on Youtube. It compares between the regular BASIC cartridge in stock Atari mode, the Turbo BASIC cartridge in stock Atari mode, the Veronica BASIC cartridge in stock Atari mode, and Turbo Basic running with the Rapidus in 65816 mode. Regular BASIC with the Rapidus disabled takes about a minute and 55 seconds to draw a sphere. Turbo Basic with the 6502 takes 33 seconds to do it. Turbo Basic has faster drawing routines and faster FPU emulation. Veronica BASIC takes 8 seconds. Veronica BASIC cheats because, in addition to having better drawing and FP routines, it has a 65816 in the cartridge that is clocked at 8 times the 6502 clock rate. Having the Rapidus mode enabled and running Turbo BASIC runs the program in 3 seconds.
Universal Memory Upgrade and Repair Kit
There is also a universal Atari memory problem repair kit. It is a 64k SRAM board that fits between the "Sally" 6502 and the socket. Other than that, you remove all the memory boards, and optionally, you can solder the CAS-disable wire between the SRAM board and the appropriate pin on the motherboard or CPU board, depending on which exact model you put it in. Some models may require an alternative FREDDIE chip to disable the DRAM refresh. So if you have a problem with a memory board or the DRAM refresh circuitry, this is a simple workaround. If you disable the refresh, it should work a tad faster since ANTIC halts the CPU less. So it only halts the CPU to process the video and not refresh the RAM.
Atari 2600 Video Game
The Atari 2600 video game system is simpler than the Atari computers. It uses a 6507 (a 28-pin version of the 6502 with 13 instead of 16 memory address pins, though they only used 12, no /halt line, and no interrupt lines), the TIA chip (like GTIA, but not as complex), and the RIOT chip (RAM, I/O, Timer). Other than that it has mostly discrete resistors and a few pots, inductors, capacitors, and crystals. The cartridges were the ROM and software. One company did make a keyboard and a homebrewer made a BASIC for it.