Monday 1 February 2016

Atari Jet Fighter. No computer AI in one player games

So at my meet a few weeks back Jet fighter decided to play up... When in one player mode, the black Jet wasn't chasing or shooting at the white (player 1) Jet. Looking at the schematics and reading the circuit information in the manual, I could see that the position data from the white Jet (player 1) is used to make the black Jet move and fire. This AI had stopped working. In two player the game played fine with no issues.

The schematic below is from the area which deals with the one player games and the AI of the black Jet. The 74175 at P5 takes position data from Jet 1, these are passed into the address lines of a Prom at R5 which is programmed to output certain values at the 74153 at R6. It's these values which determine the way the AI moves the black Jet. There are four combinations of movement the black Jet can take as shown below:

R6 Pin 7 | R6 pin 9
   1                 0       Jet turns left
   0                 1       Jet turns right
   1                 1       Jet flies straight
   0                 0       Jet slows and fires



Using my trusty logic probe I honed in on the prom at R5 being the potential issue, Initially I thought the 7420 at C5 was a problem but after removing it from circuit it tested OK. The prom appeared to be getting pulsing data on its input address lines but the output pins were behaving in a strange manner. At times the would read as having low outputs and at other time my probe was reading that the pins were dead, these were reading .4v using my multimeter.

I needed to check the prom data to try and confirm if it was still good. From my repair of Tempest a while back I had to make an adapter to read the same type of prom, my programmer cannot read them as a native device but will read them as a 2716 as long as the pins are adapted, so I got out my adapter and tried reading it to compare with the known dump of the R5 file.

82S123 prom to 2716 pinout to read the data off the prom

Well it read the prom but the data was just garbage and didn't look anything like what it should have been. Looking for a solution (especially as my programmer wont program these proms) I found an old webpage by  Mark from Retroclinic whick describes using a reprogrammable Gal logic IC to replicate a prom.

With some help from Phil Murry to make the code file, I knocked up another adapter, this time to convert the Gal16V8 pinout into the prom pinouts. The pinouts below show the pin order we would need to use to hopefully make a replacement for the suspected bad prom.

82S123N Prom 32x8 Dip 16

         +--()--+
 D0    | 1  16|  Vcc (5V)
 D1    | 2  15|  /CS (GND for R5)
 D2    | 3  14|  A4
 D3    | 4  13|  A3
 D4    | 5  12|  A2
 D5    | 6  11|  A1
 D6    | 7  10|  A0
GND | 8   9 |  D7
         +------+


GAL 16V8

          +---()---+
          | 01   20| Vcc (5V)
          | 02   19| D0
          | 03   18| D1
 A4    | 04   17| D2
 A3    | 05   16| D3
 A2    | 06   15| D4
 A1    | 07   14| D5
 A0    | 08   13| D6
          | 09   12| D7
GND | 10   11| /CS (GND for R5)
         +--------+



With the Jet Fighter R5 Prom code entered, this compiles to a .jed file which is loaded onto the Gal16V8 via my programmer. .PLD code shown below.

[quote]
Name JetFighter_R5;
Partno 32x8prom;
Date 31/01/16;
Revision 03;
Designer Mark Haysman original;
Company Leopardcats original;
Assembly None;
Location None;
Device g16v8a; /** changed gal type **/

/** Example of 82s123 simulation **/
/** Uses Jet Fighter Prom R5 Data **/

/** Inputs **/
Pin 8 = d0;
Pin 7 = d1;
Pin 6 = d2;
Pin 5 = d3;
Pin 4 = d4;
/** Pin 3 = tristate; **/

/** Outputs **/

Pin [12..19] = [Q7..0];

/** Declarations and Intermediate Variable Definitions **/

field byte = [Q7..0];
field address = [d4..0];

/** byte.oe = !tristate; **/

table address => byte {
0 => 30;
1 => 87;
2 => 38;
3 => a7;
4 => e5;
5 => 1c;
6 => f1;
7 => 0c;
8 => 71;
9 => 87;
a => 71;
b => a7;
c => c3;
d => 9c;
e => e1;
f => 8e;
10 => 8e;
11 => e1;
12 => 9c;
13 => e5;
14 => a7;
15 => 71;
16 => 87;
17 => 71;
18 => 0c;
19 => e1;
1a => 1c;
1b => e5;
1c => 2f;
1d => 38;
1e => 87;
1f => 30;
}
[/quote]

After programming the prom and plugging in the adapter the game now works as it should :)

I will source a prom and get it programmed, but this was a good exercise in using a current reprogrammable device to replace some old technology.