Home-Computer Light Guns · Volume 6

Side by Side, and Using One Today

Seven latch formats compared; calibration, dark targets and averaging as each maker described them; why one maker's gun so rarely worked with another's games; and what it takes to run, emulate or bench-test a home-computer gun now

Figure 1 — Own-work table of what each home-computer video chip latches when the pen line fires: ANTIC's colour-clock and line counts, the VIC's and VIC-II's dot and raster counts, the 6845's memory address, …
Figure 1 — Own-work table of what each home-computer video chip latches when the pen line fires: ANTIC's colour-clock and line counts, the VIC's and VIC-II's dot and raster counts, the 6845's memory address, the V9938's column and row, the Amiga's beam counters and the Atari STE's pixel position, with each chip's resolution and quirks as stated in its maker's document.

The previous four volumes went machine by machine. This one lines the machines up, draws out what their makers’ documents say in common, and turns to the practical question for anyone who owns one of these guns now: what it needs to work, how to run its games in an emulator, and how to test it on a bench.

6.1 Seven latches compared

Table 1 — Seven latches compared

ChipMachineFrozen valueHorizontal stepVertical stepFires onRe-arms
ANTICAtari 8-bitColour clock 0–227; line count / 22 colour clocks (LSB “inaccurate”)2 linesAny trigger line pulled lowEvery edge (the registers are “modified when” the line goes low)
VIC 6560/6561VIC-20Dot across, dot downNot statedNot statedPin 6 lowAfter the registers are read
VIC-IIC64, C1288 MSBs of 9-bit X; raster line2 dots1 lineLow-going edgeOnce per frame
6845BBC Micro, Amstrad CPCRefresh memory address1 character1 character rowRising edge, taken on the next character clockEvery edge
V9938MSX2Column X0–X8, row Y0–Y9Not statedNot statedLight detected, flag FLWhile S#5 is unread
AgnusAmigaVPOSR/VHPOSR beam counters2 low-res pixels1 line (2 interlaced)Pin 6 “Beam Trigger”At vertical position 20
(not named)Atari STEX, Y in 320×200 pixels4, 8 or 16 pixels by mode1 pixelGun or pen in “Joystick 0”Not stated

Every entry is from the maker’s document cited in its machine’s volume: Volume 2 for ANTIC, Volume 3 for the Commodore chips and the Amiga, Volume 4 and Volume 5 for the 6845, the V9938 and the STE.

Two design choices separate them. What is latched: the 6845 latches an address and leaves the arithmetic to software, while every chip designed for a home computer latches counts the program can use directly. When it re-arms: the VIC-II takes the first edge of a frame and ignores the rest, which biases a gun towards the top of whatever patch it sees; ANTIC and the 6845 take every edge, so the value read is the last one before the program looked. Neither is better for a gun. Both need the program to know which it has.

6.2 The three problems every maker named

The makers’ documents, written years and companies apart, name the same three problems.

Calibration. Atari: “each system must be calibrated. Software which uses the light pen should contain a user-interactive calibration routine.”1 The BBC’s Advanced User Guide: “slow light pen response will require a delay factor to be subtracted”.2 The VICE emulator, which has to make the old games work, keeps a separate horizontal and vertical offset for each gun type, tuned against particular games, and its authors comment that “new software (and cracks) should introduce a calibration feature” because those offsets differ.3 The delay comes from the phosphor’s rise, the sensor and amplifier, and the chip’s own sampling; it is almost all horizontal, because a microsecond is several pixels across but a tiny fraction of a line. The History of Light Guns, Volume 3 shows the same fixed-delay-plus-jitter budget for the console guns.

Dark targets. Atari: “The pen will not work if it is pointed at a black area of the screen, since the electron beam is turned off.”1 COMPUTE!‘s review of the Atari pen found that some dark colours “won’t register a reading at all”.4 A gun game draws its targets bright, or flashes the screen white on the trigger pull, for this reason.

Averaging. Atari: “It is a good idea to read two (or more) values and average them”. The VIC-II datasheet: “you must take several samples … (3 or more samples, average)”. The Amiga manual: “you should average several readings together.”156 A pen held by hand wobbles; a gun held at arm’s length, across a room, wobbles more.

6.3 Why guns did not cross over

The pen’s sensor line was, nearly everywhere, the same pin. The trigger was not, and that is the whole reason a gun from one maker so often did nothing in another maker’s games:

Table 2 — The pen's sensor line was, nearly everywhere, the same pin. The trigger was not, and that is the whole reason a gun from one maker so often did nothing in another maker's games

MachineGun or penTrigger or button lineSource
Atari 8-bitXG-1, CX75 penPin 1 (forward), normally closedAntic 1988; Ratcliff; VICE
C64Stack Light RiflePin 3 (left)VICE
C64Magnum, Cheetah DefenderPin 9 (POT X)VICE
C64Gun StickPin 6; sensor on pin 2VICE
AmigaLight penA potentiometer inputAmiga HRM
CPC Plus, GX4000Trojan PhazerJoystick fire 2CPCWiki
CPC 464/6128MagnumMerged with the sensor signalCPCWiki
SpectrumMagnum, DefenderNot documented—

The reviews record the result. Your Sinclair found that the Magnum worked with the Cheetah Defender’s games but the Defender would not work with the Magnum’s,7 and the C64-Wiki records that the XG-1’s trigger “isn’t compatible” on a C64.8 When buying an old gun, buy it with its games, or check that the games were written for that gun.

6.4 What a home-computer gun needs today

A cathode-ray tube. Every gun in this dive times the beam of a CRT, directly or through a latch. A flat panel has no beam, draws the frame at once or in a different order, and adds a frame or more of processing delay; the guns do not work on one. The signal-level reasons are set out in History of Light Guns, Volume 6. The television should be a plain 50 Hz or 60 Hz set to match the computer; Console Light Guns, Volume 7 notes that Namco’s GunCon manual excluded 100 Hz CRTs and sets with a frame memory, and the same caution applies here.

The right port and machine. A C64 gun goes in control port 1 only. An Amiga 1000 pen goes in port 1; an A500’s in port 2 unless the jumper has been moved.6 A CPC 464 gun needs the 464’s expansion edge, not the joystick socket.9

Power. The Spectrum Magnum needs a 9 V battery in the gun when it is plugged into the MIC socket, which supplies none.9 On the joystick ports, Commodore rated pin 7 at 100 mA on the VIC-20 and 50 mA on the C64; a modern replacement sensor board must stay inside that.105

Brightness and distance. Atari recommended three to five feet and a bright, contrasty picture; the Magnum manual, two to four feet.119

6.5 Emulation

Emulators that implement these guns substitute the mouse for the gun, firing the latch when the emulated beam passes the pointer.

  • VICE (Commodore) lists seven pen and gun types in its source: “Light Pen (up trigger)”, “Light Pen (left trigger)”, “Light Pen (Datel)”, “Light Gun (Magnum Light Phaser)”, “Light Gun (Stack Light Rifle)”, “Light Pen (Inkwell)” and, as an experimental device, “Light Gun (Gun Stick)”. They work on “native joystick port 1” of the C64, C128 and VIC-20 emulators.3
  • MAME implements, for the BBC Micro’s analogue port, the Datapen, Robin and Stack light pens and the Stack Light Rifle.12
  • Caprice32 (Amstrad CPC) has partial Magnum and Trojan support; its developers reported the Magnum working only in windowed mode and not in screen mode 0 or full screen, and the Gun Stick “almost” working through the Trojan emulation.13

Atari 8-bit, Spectrum and MSX emulators were not checked for this dive.

6.6 Bench-testing an original gun

No maker’s test procedure for any of these guns was found, so what follows is what a test must account for, not a procedure from a manual.

  1. Continuity first. Check the plug against the machine’s pinout in its volume: sensor to the pen line (pin 6 on Atari and Commodore, pin 9 on the BBC analogue port, pin 47 on the CPC expansion edge), trigger to whichever line the gun’s maker chose, power and ground. Note whether the trigger is normally open or normally closed: the XG-1’s is closed at rest (Volume 2).
  2. Power it without the computer. Supply 5 V (or the 9 V battery for a Spectrum Magnum) from a current-limited bench supply and watch the current: the C64 port allows 50 mA.
  3. Look at the sensor output on a scope. Aim the gun at a CRT showing a white field from any source. A working sensor chain gives one short pulse per line it sees, about 64 µs apart, in a burst once per frame. Measure the pulse’s rise time and its delay after the line’s sync; that delay is the fixed offset the game calibrates away, and its spread from shot to shot is the jitter it cannot.
  4. Check the polarity at the plug against what the chip needs: low-going for ANTIC, the VIC and VIC-II and the Amiga; rising at the 6845. The BBC’s port label and its documentation disagree (Volume 5), so measure.

6.7 What this means for a modern build

The guns in this dive are the ancestors of a modern camera gun only in their shells and triggers. Their sensing ended with the CRT. Two things carry over to the build in Reference Electronics:

  • The trigger convention matters. The incompatibilities in this volume were all about where the trigger went, not about the sensor. A gun that must work with existing software has to match that software’s expectation exactly, which is why the Open-Source Firmware dive’s guns present themselves to the computer as standard mouse, joystick and keyboard devices.
  • Calibration, averaging and dark-target handling are the same three problems for a camera gun, in a different form: offset and tilt instead of sensor delay, frame-to-frame jitter instead of hand wobble, and a dark scene in place of a black target. Aiming Maths and Calibration takes them up.

Converting a home-computer gun’s shell to a modern sensor is a Modding Classic Light Guns subject.

6.8 What could not be verified

  • The VIC, V9938 and STE resolution and re-arm entries marked “not stated”: the documents read do not give them.
  • Whether ANTIC latches on both edges of the trigger line, as a forum post claims; Atari’s manual says “pulled low”.
  • Emulator support for the Atari 8-bit, Spectrum and MSX guns.
  • Prices. Collector prices for these guns were not researched for this dive.
  • The bench-test values in §6.6 (pulse spacing, delay, rise time) are what a working CRT-era gun should show in principle; none has been measured here.

Sources

Footnotes

  1. Atari, Inc., Atari 400/800 Computer System Hardware Manual, November 1980, “Light Pen”, https://archive.org/details/Atari400800HardwareManualNovember1980, read 2026-10-19. ↩ ↩2 ↩3

  2. A. C. Bray, A. C. Dickens and M. A. Holmes, The Advanced User Guide for the BBC Micro, Cambridge Microcomputer Centre, 1983, §18.9.3, https://archive.org/details/manualcomputergame-bbc-cambridgemicrocomputercentre-theadvanceduserguideforthebbcmicro-1983-c048, read 2026-10-19. ↩

  3. VICE emulator source, vice/src/joyport/lightpen.c (GPL-2), https://github.com/VICE-Team/svn-mirror/blob/main/vice/src/joyport/lightpen.c, read 2026-10-19. ↩ ↩2

  4. Tom R. Halfhill, review of the Atari Touch Tablet and Light Pen, COMPUTE! No. 53, October 1984, p. 106, https://www.atarimagazines.com/compute/issue53/039_1_REVIEWS_Atari_Touch_Tablet_And_Light_Pen.php, read 2026-10-19. ↩

  5. Commodore, Commodore 64 Programmer’s Reference Guide, 1983, appendix I and appendix N, https://archive.org/details/Commodore_64_Programmers_Reference_Guide_1983_Commodore, read 2026-10-19. ↩ ↩2

  6. Commodore-Amiga, Amiga Hardware Reference Manual, 3rd edition, 1991, “Reading a Light Pen”, https://archive.org/details/amiga-hardware-reference-manual-3rd-edition, read 2026-10-19. ↩ ↩2

  7. Your Sinclair No. 47, November 1989, Cheetah Defender review, via ZX Spectrum Reviews, https://spectrumcomputing.co.uk/zxsr.php?id=1000110, read 2026-10-19. ↩

  8. C64-Wiki, “Light gun”, https://c64-wiki.com/wiki/Light_gun, read 2026-10-19. ↩

  9. Magnum Light Phaser instructions, Virgin Mastertronic, https://spectrumcomputing.co.uk/pub/sinclair/hardware-info/m/MagnumLightPhaser_Manual.txt, read 2026-10-19. ↩ ↩2 ↩3

  10. Commodore, VIC-20 Programmer’s Reference Guide, 1983, “Game I/O”, https://archive.org/details/VIC-20ProgrammersReferenceGuide1stEdition6thPrinti, read 2026-10-19. ↩

  11. Atari Corporation, XE Game System owner’s manual, 1987, https://archive.org/details/atari-xegs, read 2026-10-19. ↩

  12. MAME source, src/devices/bus/bbc/analogue/lightpen.cpp (Nigel Barnes; BSD-3-Clause), https://github.com/mamedev/mame/blob/master/src/devices/bus/bbc/analogue/lightpen.cpp, read 2026-10-19. ↩

  13. Caprice32 issue #34, https://github.com/ColinPitrat/caprice32/issues/34, read 2026-10-19. ↩

Comments (0)

  1. Loading…

Comments are held for moderation — nothing appears until approved.