Video game controllers

Apr 21, 2008 09:54 GMT  ·  By

I'm sure most of us, if not all, had or still have a home video game, or went to play arcade games at some point in time. You might have noticed a remote-like device resembling a firearm or a pistol that can be used to shoot objects displayed on a TV screen, generally referred to as a video game light gun. The purpose of this article is to briefly explain the basic principle on which the video game light gun works.

Inside the light gun, you can find an electronic circuit connected to a light detector placed inside the barrel. The light detector can be either a photodiode or a phototransistor, depending on the specifications of the manufacturer. As one triggers the light gun, the photodetector receives a light signal from the screen, so that the computer controlling the game can evaluate whether or not the gun is pointing towards the designated target.

Television screens, similarly to most electronic displays, alight objects in accordance to the horizontal and vertical retrace signals received from the screens driver, therefore the computer knows exactly the position of a particular object on the display. Nonetheless, this is not enough to make the video game light guns work properly, due to unknown relative position of the gun. In order to simplify the detection technique, the computer uses a simple signal filtering system.

In fact, there are two techniques used to do that, again depending on the specifications established by the manufacturer.

The first one uses an image rendering sequence relying on introducing frames of black screen images and the target objects. By synchronizing the image rendering with the signals received from the light gun, the computer controlling the game measures, with the help of the photodetector, the luminosity of the display when the gun is triggered. If the luminosity is low, it means that the gun is pointed towards an area of the screen other than were the target object is located, and scores a miss.

However, if the luminosity is high, then the gun is pointed towards the target object, thus when the gun is triggered the computer scores a hit.

The second detection technique is slightly more complicated, albeit it works roughly on the same principle. The computer first inputs a command to make the whole screen black. Then, it immediately renders the whole screen white. Although unnoticeable to the human eye, it takes a certain amount of time for the electron beam to trace the whole screen and paint it white. By comparing the reading received from the photodetector with the amount of time between the moments when the black screen starts to turn white, the computer can estimate towards what direction of the screen the gun is pointing.

Again, if the rendered image corresponds to the direction of the gun, it will score a hit.