Rotor

An Enigma, drawn by hand. Type and watch the lamps.

The machine

AIAIIAIIIQWERTZUIOASDFGHJKPYXCVBNML

Typed

Lamps

Inside the lid

Left
Middle
Right
Reflector

Pairs such as AB-CD: up to ten, each letter once.

Open the code with these settings and the message comes back on the lamps line.

How it works

Each key closes a circuit. The current runs through the plugboard, the three rotors and the reflector, then back by a different path to one lamp.

Before it flows, the right rotor turns one step, so the same key lights a different lamp next time. A rotor passing its notch carries its neighbour; the middle rotor then moves twice in a row, the double step.

Why the same settings decode: the reflector turns the current round, so the path from A to G is the path from G to A, run backwards. Set the machine the same way, type the code, and the message comes back. It is also why no letter ever lights itself.