SWITCHLIGHT / THE 8800 ROOM

A whole computer. Eight glowing clues.

Play a letter-guessing game on a real simulated 1975 computer. No coding needed.

Start with the letter game. The machine gives HIGHER / LOWER clues — can you find its secret A–Z in five guesses?

OFF/ON
STOP
RUN
SINGLE STEP
EXAMINE
EXAMINE-NEXT
DEPOSIT
DEPOSIT-NEXT
RESET
CLR
PROTECT
UNPROTECT
A15
A14
A13
A12
A11
A10
A09
A08
A07
A06
A05
A04
A03
A02
A01
A00
CTRL-C (BREAK)
RUBOUT (_)
KILL LINE (@)
LINE FEED
CLEAR PAPER
Nothing has printed yet. Run a program that reads the serial board - try Teletype echo from Load - then type here.

            
Step
Run to
◀
▶
Follow PC
Zero All Memory

Meet the Machine

The Altair 8800 had no screen and no keyboard: its front panel was all there was. What it shows, and what is behind it. Each Show points it out.

An Altair 8800 beside a Model 33 Teletype. Photo: Tim Colegrove, CC BY-SA 4.0

In January 1975 the Altair 8800 was on the cover of Popular Electronics.

On the front panel

  1. The status lamps, top left, show what the 8080 is doing: reading memory (MEMR), fetching an instruction (M1), halted (HLTA).
  2. The data lamps D7–D0 show the byte on the data bus: lit is 1.
  3. The address lamps A15–A0 show the address the CPU is using. WAIT, beside them, is lit while the machine is stopped.
  4. The address/data switches set an address to examine, or a byte to deposit: up is 1. A program can read A15–A8 as its sense switches.
  5. The control switches spring back after each throw: STOP and RUN, SINGLE STEP, EXAMINE, DEPOSIT, RESET. OFF/ON, at the far left, is the power.

Inside the box

  1. Behind the panel is a box of cards on a bus. See it whole in 3D.
  2. The CPU card: the Intel 8080, the one chip that runs every program.
  3. The memory card: what the Memory menu installs. More memory is more cards.
  4. The serial cards: the way to the Teletype, where BASIC talks to you.
  5. The bus: every card plugs into the same 100 lines, so any card fits any slot.
  6. The power supply: three transformers and their board, making the voltages every card needs.

Your turn

  1. Now take it apart yourself: switch OFF, click the lid, then a card; click a part again to put it back, or press Put it all back. Views ▸ Taken apart shows every part. Drag to turn it, scroll to zoom.

Your First Program

How to input and run the following program to calculate 1 + 2 = 3:

LDA 0080H  ; 00 111 010
           ; 10 000 000
           ; 00 000 000
MOV B,A    ; 01 000 111
LDA 0081H  ; 00 111 010
           ; 10 000 001
           ; 00 000 000
ADD B      ; 10 000 000
STA 0082H  ; 00 110 010
           ; 10 000 010
           ; 00 000 000
JMP 0000H  ; 11 000 011
           ; 00 000 000
           ; 00 000 000

Enter the program

  1. Turn on the Altair 8800 with the OFF/ON switch.
  2. Set switches A7–A0 to 00 111 010 (up for 1, down for 0).
  3. Click "DEPOSIT".
  4. Set switches A7–A0 to 10 000 000.
  5. Click "DEPOSIT NEXT".
  6. Repeat steps 4–5 to enter the following bytes one by one: 00 000 000, 01 000 111, 00 111 010, 10 000 001, 00 000 000, 10 000 000, 00 110 010, 10 000 010, 00 000 000, 11 000 011, 00 000 000, 00 000 000.

Enter the two numbers

  1. Set switches A7–A0 to 10 000 000.
  2. Click "EXAMINE".
  3. Set switches A7–A0 to 00 000 001 (the first number to be added, or 1 in decimal).
  4. Click "DEPOSIT".
  5. Set switches A7–A0 to 00 000 010 (the second number to be added, or 2 in decimal).
  6. Click "DEPOSIT NEXT".

Run it

  1. Click "RESET".
  2. Click "RUN" and wait for a few seconds.
  3. Click "STOP".

Read the answer

  1. Set switches A7–A0 to 10 000 010 (the address that holds the sum).
  2. Click "EXAMINE".
  3. The data lamps D7–D0 show the result 00 000 011 (3 in decimal).
  4. Turn off the Altair 8800.

Writing in Assembly

The same machine, without toggling each byte by hand: write the program in Intel's assembly language, and let the assembler make the bytes. A program that copies the sense switches to the data lamps:

  1. Open the Assembler, under the panel, and type these three lines:
    LOOP:   IN      0FFH    ; read the sense switches
            OUT     0FFH    ; light them on the data lamps
            JMP     LOOP    ; and again, for ever
  2. Beside each line, the listing shows its address and the bytes it makes: IN 0FFH is DB FF, at 0000H. A mistake is marked on its line, with what is wrong under the source.
  3. Click Assemble, or press Ctrl+Enter. The machine is switched on if it was off, the program goes into memory, and RESET is pressed.
  4. Click RUN on the front panel, then flip the switches A15–A8: the data lamps follow them.

More to try: the Assembler's Examples menu has fourteen programs, from lamps on the front panel to a game on the Teletype, macros included. Intel's own manual, in References, describes the whole language.

Running Microsoft BASIC

The Altair's first piece of software, and Microsoft's: Altair BASIC 3.2, written in 1975 by Bill Gates, Paul Allen and Monte Davidoff. How to start it:

Load it

  1. In the Memory menu, choose 4 KB (or 8 KB, for room to write longer programs). Installing memory switches the machine off, which is what opening the case would have done.
  2. In the Load menu, choose Microsoft 4K BASIC. The machine powers up, the tape is read for you, RESET is pressed, and the Debugger opens to show what arrived.
  3. Before going any further, look at the memory map above the dump. Fifteen of the sixteen pages of a 4 KB machine are full: that is BASIC, and the one page left over is all the room you have for a program. This is what "4K BASIC" means.
  4. The address switches A15–A8 tell BASIC which terminal board to use: all down is the 88-SIO at ports 00H and 01H, switch A11 up is the 88-2SIO at 10H and 11H. The teletype here is wired to both slots, so either setting works - a real Altair would have had only one of the two boards fitted, and the wrong setting left it silent.

Talk to it

  1. Click RUN on the front panel.
  2. Open the Teletype, under the panel. BASIC asks MEMORY SIZE? - press Enter to take everything it found. Press Enter again for TERMINAL WIDTH?, then Y for WANT SIN? to keep the maths functions.
  3. It prints how many bytes are free, then OK. Try PRINT 22/7 for an answer straight away. To enter a program, type these lines one at a time, pressing Enter after each:
    10 FOR I=1 TO 10
    20 PRINT I,I*I
    30 NEXT I
    RUN
  4. The keyboard is upper case only. Underscore rubs out the last character, at-sign throws away the line, and Ctrl-C stops a running program.

What loading 4K BASIC skips: on a real Altair you first toggled a 28 byte boot loader in through the front panel, one byte at a time, then started the paper tape reader and waited about seven minutes while BASIC clattered in. Get one switch wrong and you did it again.

Load Hex Bytes

Bytes in hex, put into memory from 0000H. Spaces, commas and line breaks may separate them.

Replace the Source?

Share a Link

What should the link open?

About

Version

An Altair 8800 you can switch on in a web page: its front panel, a teletype running Microsoft's 4K BASIC, an 8080 assembler, and a debugger the real one never had.

Licences

Simulator
Apache License 2.0
4K BASIC tape
© Microsoft · roms/NOTICE
8080 CPU core
8080js © Martin Maly · BSD
3D model
CC BY-SA 4.0
Model review
Mike Douglas
3D engine
three.js © three.js authors · MIT
Photo
Tim Colegrove · CC BY-SA 4.0
Icons
Material Icons © Google · Apache 2.0