XBoard or XM RAM and POKEY banking
The following entry is an adapted excerpt from the XBoard product page. The XM has been designed to be compatible with the XBoard, so interface information for the XBoard should apply equally to the XM.
The XBoard is a multi-functional expansion board for the Atari 7800 gaming console. The board is equipped with 128Kbyte of fast, banked SRAM that can be used for program code, graphic data and of course plain old game data ;-)
It also has a socket for an Atari POKEY sound chip. This is the same sound chip found in the Atari 400/800 and other Atari 8-bit computers as well as the Atari 5200 game console.
The XBoard was designed to sit in the place of the MARIA chip inside the A7800. This poses a problem for many NTSC A7800's as the MARIA chip is soldered onto the PCB. For PAL A7800's this is not a problem as the MARIA is socketed and the XBoard is simply dropped into the place of the MARIA.
The X-Board is exclusively sold by AtariClassics
The XBoard introduces three new devices into the memory map of the A7800. The first device is the control register of the XBoard. This register is used to enable or disable the two other devices, the RAM and the POKEY. The control register also contains the bank select bits which allows you to select one of the 8 16KByte banks.
|bit 7||bit 6||bit 5||bit 4||bit 3||bit 2||bit 1||bit 0|
|not used||not used||not used||POKEYEN: Enable POKEY support (1 = POKEY's enabled)||MEMEN: Enable SRAM and banking support (1 = SRAM enabled)||BS2, BS1, BS0: Selects 1 out of 8 16K banks|
All bits are reset to 0 at power on, which means both the POKEY and SRAM is disabled when the system is started.
This is how the XBoard maps into the A7800 memory map.
|Description||Start Address||End Address||Size (bytes)||Notes|
|POKEY2||$0460||$046F||16||The control PLD on the board has a chip select for the second POKEY routed to a connector the board.|
Sound output section
The output signal from the sound chip is fed through an analog switch which is controlled by the POKEYEN bit in the XCTRL register. The reason for this output switch is that the POKEY chip does not have any external way of reseting it and could theoretically start up playing a sound. To avoid this the analog switch disables the sound when POKEYEN bit is zero.
The board is also prepared for adding a second POKEY with a connector that connects to the POKEY sound output. More information about this will be available later.
Due to the complexity the board needs some setting up before it can be used. Here's a snippet that will help you to enable the memory and do a quick memory test. The code is only to give you an indication on how it can be done, if you have a better algorithm please feel free to share with the rest of us.
You also need to completely inititalize the POKEY before starting to use it. This example shows you how.