Today I was going to write about something else, but I came across a declassified NSA report (project Gunman) and got stuck on the numbers: from 1976 to 1984 — eight years — classified dispatches at the U.S. Embassy in Moscow and the consulate in Leningrad were being typed on IBM Selectric typewriters with radio bugs living inside them. Sixteen typewriters. Ten tons of equipment hauled away and taken apart screw by screw to find them. And the most curious thing — the bug didn’t “hear” keystrokes. It read the position of a rotating plastic ball.
So perhaps the first keylogger in history — that’s still what the NSA calls it — didn’t work with a “computer.” There wasn’t one. It worked with pure mechanics. It is the perfect detective story: to understand how the USSR did it, you first have to understand why IBM’s typewriter was half a computing machine itself.
By 1961, when IBM unveiled the Selectric, the basic design of the typewriter had not changed for 88 years — since 1873: a basket of typebars, a carriage crawling leftward. The levers clash with one another: hit two neighboring keys too quickly and they tangle (“jamming”), throwing the paper out of alignment. The Selectric threw it all out: in place of levers, a replaceable 1⅜-inch ball bearing 88 characters across four rows; in place of a carriage, a fixed axis along which the ball itself traveled, while the paper turned on a platen.
First-year sales: 80,000 units against a forecast of 20,000. By 1978, IBM had 94% of the U.S. electric typewriter market. More than 13 million machines sold. The most successful typewriter in history — but let marketing take a break; we are interested in the guts.
This is where an engineer falls in love. The ball has to turn toward the paper so that one of its 88 characters meets it. We can dismiss any “smart” solutions — there is not a single processor inside the typewriter, not even a transistor: just a motor, a switch, and a tangle of levers. And yet, when a key is pressed, the ball snaps precisely into the right one of 88 positions in 65 milliseconds.
How? Each key carried an interposer — a plate with a unique combination of protrusions. The protrusions encoded a binary number: 2 bits for the ball’s tilt and 3 bits for its rotation. And what translated that binary code into an angle... was a system of levers IBM called the Rotate and Tilt Differentials — a whiffletree, the same oak crossbar from which a pair of horses is hitched. Engineers call it a mechanical DAC: add up the “weights” of the levers and you get an angle. The same linkage was used in mechanical calculators for addition and in Alexander Calder’s hanging mobiles.
Even capital letters are simply “turn the ball exactly 180°.”
And now for a juicy fact for connoisseurs: the molded plastic components were polished with walnut shells, because sand would have scratched them too deeply. Hence the office nickname: the “flying walnut machine.”
The replaceable ball had unexpected cultural consequences. The machine became a cult object among mathematicians: admit it, in 1967 you could not type ⍴ in a paper — but here you could buy a ball with APL special characters and type ⍴, ⍳, ∊ on an IBM 2741 terminal connected to a System/360. Ken Iverson built APL\360 around the ball. But the cherry on top: the final report on the ALGOL 68 language standard (August 1968) was prepared entirely on an APL ball, because there was simply no other way to type ∧, ∨, ¬, ≤, ≥, or ⌷. A programming language was almost designed... around a plastic ball.
At the same time, an even stranger flaw emerged: the balls were physically interchangeable, but not interchangeable “at the code level.” The terminals came in two encodings (correspondence and PTTC/EBCD), and a ball from an IBM 1050 would print gibberish on a 2741. Half the secrets of encoding were hidden in the arrangement of characters on the sphere. (It sounds like nonsense until you remember that the Selectric’s “1/!”, _-, and paired-quote key layout was later copied by the designers of the DEC VT52 and the IBM PC, while the typewriter’s buckling-spring keys survived into the legendary Model M keyboard.)
In 1964, IBM added a tape drive to the typewriter: the MT/ST recorded text on half-inch tape (~25 KB per cassette!) and could do mail merge from two tapes. TIME ran an excited item, “Typewriter with a Memory”: a series of ready-made letters “without the aid of human hands,” leased at $233/month. This was the first device marketed with the term word processor. Len Deighton typed “Bomber” (1970) on one — the first novel written on a word processor. And the MT/ST commercial in 1967 was filmed by Jim Henson — yes, the creator of the Muppets — with music by Raymond Scott. The shot: a succession of desks embodying bureaucratic hell, and a ball that saves them. The commercial is worth watching.
Now for the denouement with the bugs. The spies did not need to tap into wires — there were none. Instead, inside a metal bar in the typewriter (visible only on an X-ray) sat a magnetometer, detecting... the movements of those very “bail” levers that set the ball’s tilt and rotation. Each character has its own unique binary choreography. Magnetic disturbances → digital signal → 4-bit word. An 8-word buffer → radio transmission on the frequency of local Moscow television (so it would not stand out on the airwaves).
The implant’s blind spots are straightforward: space, tab, backspace, shift, and hyphen — the ball did not move, so the bug was blind. The NSA later used probability theory to reconstruct exactly how the Soviet side decoded the traffic. Five generations of bugs, installation in half an hour, 1-bit core memory in the circuit — “an achievement NSA engineers had not seen.” And all this beauty lived on for eight years, until a U.S. ally that had caught the same device on its own premises tipped them off.
The moral is not “the Soviets are evil.” The moral is that the most secure channel breaks not where the cipher is weakest, but where the physics is. The typewriter itself, honestly and diligently, broadcast everything it typed into the air — you only had to know the frequency. Alas, in 2026 this rule should surprise no one: the vulnerability is the same; only the medium has changed.
Nothing gives away a machine like a ball turning the wrong way.
What I checked and formulated for myself here:
By the way, a forecast for the future. The Selectric ball is the direct ancestor of the daisy-wheel printers of the 1970s. And the next time you set up a 3D printer or plotter, remember that x/y gantries operate by the same rules of electromechanics as the office typewriter the USSR cracked with a magnetometer half a century ago.