Now Try a 'Space Invaders' Demo to Test Your Setup
Author: Paul Schreiber (via the FPGA-Synth list)
I just figured out the "da Vinci Code" in getting this to work on the 3E demo board.
The original code/files can be found on the FPGA Arcade page
- Spartan-3E demo board
- VGA monitor
- PS/2 Keyboard
- 2 * 3k3 resistors
- 2 * 4n7 capacitors
- Headphones/Line input
- Go to your xilinx\spartan3e directory on your drive. Make a new sub-directory called invaders.
- Go to www.synthtech.com/fpga and download the 2 files into that
One file is the BIT file that tells the Xilinx FPGA how to interconnect all the logic gates. The other file is a batch file that will call the iMPACT serial downloader, look for the board, and program the FPGA.
- Connect the 3E demo board by attaching the USB cable. Also, attach your VGA monitor to the VGA connector, and the keyboard to the PS/2 connector. Turn power on. The board will run whatever is in FLASH (most likely the program that shipped with it).
- Run the invaders.bat file. This will shell out to MS-DOS, the BIT file should download to the board. The whole process is 10 seconds or so.
- The LCD will 'freeze' where it was (Invaders does not use the LCD).
BUT....you should see on the VGA screen *sideways* the game running! Note:
chances are, you will have to manually adjust the horizontal size controls on
your monitor (on my LCD, I had to 'squish' the image about 20%).
The left and right arrow keys move, the spacebar fires.
To start, hit the C key (for coin) and press 1 or 2 for # of players.
- Audio comes out via the a pair of pins on teh right hand side of the board (labeled IO11 and IO12), wire the pins as per the 'readme.txt' file.
you don't have too use the resistor/cap, but be warned the output is very hot if you don't.
This is running a full Intel 8080 CPU *and* uses the original 2K EPROM files from the machine. The game uses about 33% of the available gates in the 3E device. Enjoy!