← All three video options

LIFE-1: a colour Life machine that never was

A theoretical late-1970s demonstration unit: a CDP1802 and CDP1864 built into a colour monitor cabinet, with Conway's Life in ROM. Everything below runs on a cycle-counted emulation of that hardware, executing the real 1802 machine code. Switch it on and it starts.

LIFE-1 RCA COSMAC · colour
Power

Service panel

Generation— Rate— 1802 clock— Instructions/s— Background— Mode— 1864 sync errors—

Keyboard works too: 0–9 and A–F press the matching key. Keys 4–F are read by the ROM and reserved for later features.

CDP1802 registers

Hardware manual

The 1864 gives colour only once per 8 pixels across, which would limit a full-colour Life field to 8 cells wide. LIFE-1 adds a colour expansion board, built only from 74LS logic and 2114 RAM, that gives every 2-pixel pair its own colour. The 1864 still does the timing, DMA, interrupts, background colour and sync. This is Rev B, corrected against RCA's CDP1864C data sheet.

Memory map

AddressContents
0000–07FFROM, 2716
1000–15FFBitmap, 64 × 192, 8 bytes a line, read by 1864 DMA
1600–18FFCell ages now, 32 × 24
1900–1BFFCell ages next generation
1C00–1F73Alive flags with wrapped borders, 34 × 26
1F80–1F8BVariables: key state, counter digits, random seed
1FFF ↓Stack
2000–2FFFColour RAM, write only: 2000 + row×64 + lane×8 + byte

I/O

LineUse
INP 1 (69)1864 display on: enables its interrupt and DMA requests
OUT 1 (61)1864 background step: blue → black → green → red. The colour board's shadow counter steps with it
INP 4 (6C)1864 display off
OUT 4 (64)1864 tone latch, unused: AOE is tied low
INP 2 (6A)Keypad code, low 4 bits. The 1864 ignores N1, so port 2 is free
EF11864 EF: low 4 lines before the display starts and 4 lines before it ends
EF3Key held (74C922 data available)
INT1864 field interrupt, two lines before the picture

N0 and N2 together are an illegal command for the 1864, so ports 5 and 7 are never used.

How a frame is made

The CDP1864C is a PAL part. With INLACE low it makes 312-line, non-interlaced fields at 50.08 Hz, with 14 machine cycles to a 64 µs line at 1.75 MHz. Two lines before the picture, it interrupts the 1802. RCA's rule is that exactly 29 cycles must pass between the interrupt response and the first DMA, one of them an early 3-cycle instruction. The ROM's interrupt routine follows that pattern from the data sheet's Fig. 5 and points R0 at the bitmap. For each of the 192 picture lines, the 1864 then takes 8 DMA cycles and reads 8 bytes (64 pixels). A 3-cycle instruction during the picture would make the 1864 skip cycles to resync, which shifts lines by 8 pixels. So the routine holds the CPU in 2-cycle branches on EF1 until the picture ends. Life runs in the other 120 lines, which is about 38% of the CPU.

While each byte goes out, the colour board uses the same address lines to read a 16-bit word from colour RAM. Address bits A3–A5 are left off, so one word covers 8 lines: one cell row. Each 4-bit lane colours one 2-pixel pair. A pixel shows its lane's colour when both the bitmap bit and the lane's LIT bit are set. Otherwise, inside the picture area, it shows the background colour. The Life field keeps every bitmap bit on, so the colour RAM alone draws the cells, and the bitmap is used only to cut the counter out of a white box. One generation of the 32 × 24 field takes about 1.1 seconds at the real clock speed.

The ROM

On reset, the ROM seeds a random-number generator from the garbage the RAM powers up with, turns all bitmap pixels on, switches the display on and makes a 30% soup. Each generation slides 3-cell column sums along every row of the padded alive array. The cell's own state is part of that sum, so a total of 3 means alive next generation, and 4 means the cell keeps its current state. Ages go up to 16, then a 17-byte table turns age into a colour nibble. The keypad is polled once per row, between pictures. Keys 2 and 3 act straight away. Key 0 or 1 stops the generation in progress and redraws, so the counter appears or disappears within a fraction of a second. Key 3's colour change waits for the next generation, because the table is only read when the field is redrawn.

Schematic

The schematic has four sheets, drawn in net-label style: pins with matching labels are connected. Red labels are signals and green labels are power. A name starting with / is active low, and × marks a pin with no connection. Each part's power pins are listed under its symbol. Sheet 4 shows the decoupling: a 0.1 µF capacitor at every IC supply pin.

Design notes

Bill of materials

QtyReferencePartDescription
Netlist ( nets)
ROM listing (1802 assembly, bytes)

A theoretical design: the parts are real and of the period, but this exact machine was never built. Emulation: 1802 instruction set with real cycle counts, the 1864's PAL timing, control codes and sync rules from its data sheet (the emulator counts any rule violation), colour board and keypad as described above.