SX Game System
Picture of the system's PCB.
This page describes a SX28-based color video game system I made during year 2002.
Now, beginning of 2007, almost five years after I made the first design
I've updated the layout of the PCB and added a version of the PCB that has built-in gamepads and I also have made it
possible to buy PCBs,
color carrier oscillators and of course
from me in my web shop.
Since all games use the same hardware I have chosen to describe the game system hardware here on a separate page, and describe game specific stuff on the games pages. So far I've only made two games, Pong and Tetris, but some day there might be more games for the system.
The main hardware.
The power supply is standard, a 7805 regulates the voltage to 5v, there is a rectifier at the input to be able to run the system on both AC or DC, the voltage can be 8..15v something. Then there is a bunch of caps on the board to get rid of noice etc.
The video generation is quite simple; it is just a five bit R-2R resistor ladder. It might seem a little bit strange that I connected it to bit 1...5 instead on 0..4, but that is because when I first made the prototype it hade six bits for video and four for audio. I chose six bits first as it is the largest number of bits you should use with an R-2R ladder when using 1% tolerance resistors. Later I understood that it was not needed that many bits for video, that last bit would be better off in the audio generation. At the end of the R-2R ladder I have put one 1pF cap to get a a little bit of filtering if the TV's input has to high bandwidth as my color generation technique generates square wave that needs to be filtered so only the "sinus part" remains. The resistor ladder has an open output as it is supposed to be connected to the TV that has an 75Ohm input that ends the ladder.
The audio part is very similar to the video part, also a five bit DA using an R-2R ladder. The difference is at the end of the ladder, the audio has a 100 Ohm pot to regulate the volume. The 100Ohm pot also ends the ladder as the audio impedance varies a lot between different audio inputs. (1k...20kOmh)
A classic Tac2 joystick
The joystick inputs are extremely simple, just five pins on the chip connected directly to the joystick inputs. The joystick pins on the SX-chip have their internal pull-up resistors enabled so there is no need for external resistors. There are two joystick inputs, and as with my PIC-based games I used old C64/Amiga/Atari joysticks. If you don't have one you could build one quite easy using the schematic here to the right using five off(on) switches and a 9pin female dsub.
Schematic for a C64 compatible joystick
My ancient signal generator.
One of the more tricky parts is the Oscillator. This should run at 12 times the color carrier of the TV-system. The built in generator in the SX-key programmer is not accurate enough for video generation, so an external oscillator is needed. During the development of the games I used an almost 30 years old frequency generator (as new ones cost a fortune) seen at the picture here to the right, which made the development a lot easier. There chip-oscillators available that can be programmed once just like you can program a microcontroller. You can buy such oscillators from my webshop preprogrammed to NTSC frequency. (Currently that is the only ones I sell because my games works so poorly for PAL and most modern TVs support both PAL and NTSC anyway). See the table below for what frequencies to use if you program your oscillator yourself or have another solution to generate the frequency.
|TV System||Carrier Frequency||ClockFreq = 12 x Carrier Frequency|
|PAL||4.4297125 MHz||53.156550 MHz|
|NTSC||3.579545 MHz||42.954540 MHz|
|PAL-N*||3.575611 MHz||42.907332 MHz|
|PAL-M*||3.582056 MHz||42.984672 MHz|
*Note: None of the games have been tested and calibrated for PAL-M or PAL-N
Schematic for connecting system to a SCART-input.
The system is connected to the TV's SCART input with a cable with RCA inputs and a scart contact at the end. These cables are available in most TV stores. The best thing to do is buying a finished cable, building one is more expensive and doesn't give a good result, however if you still want to build one you should follow the schematic here to the right.
PCB with built-in joysticks
As it has been requested by several people, now I've created a special version of the PCB with two joypads on the PCB, as seen in the picture here to the right. Both the layout woth the built-in joystick and the standard one (using a C64/Amiga/Atari joystick) are included in the zip-file. The layout supports two common footprints and thus can be used for several types of buttons. There is a separate building instruction page for the joypad version of the layout.
Pictures of three types of buttons supported by the PCB. (Click to enlarge). (Actually, the pictures come from my PIC-based game system but the layout of the buttons is the same for the SX-system)
More info about video signals.
There is not much written on generating color video signals in software, but there some stuff written about generating B&W signals. If you want to know more about generating video signals check out some of these links:
The schematics and layout is included in the games, but if you want you could download it here as a separate file: sxgamesys.zip(113kB)
SX Game System (C) Rickard Gunee. This is open source, use this at your own risk ! You may use the information on this page for your own projects as long as you refer to the original author (by name and link to authors homepage), don't do it for profit and don't hurt or harm anyone or anything with it. The author can not be held responsible for any damage caused by the information on this and related pages.