|
Arduino Nano V3 |
x 1 | |
|
RASPBERRY PI ZERO W |
x 1 | |
|
CD74HC4067 16-Channel Analog Multiplexer/DemultiplexerTexas Instruments
|
x 4 | |
|
0.1μF Ceramic Capacitor |
x 4 | |
|
330Ω Resistor |
x 3 |
|
KiCADKicad
|
Turning a 1980s typewriter into a Linux terminal
From the late 1800s to the late 1900s, a typewriter was one of the best tools for writing documents. Sadly, they were largely rendered obsolete by the rise of home computers. I didn’t grow up using a typewriter, but a couple months ago I bought a Brother AX-25 electronic typewriter.
It uses a daisy wheel (a spinning wheel with letters molded into it) and a motorized hammer to type text, rather than type bars (or strikers) like in a traditional typewriter. The sound it makes is unmatched even by the clickiest of keyboards. Each keypress results in a short buzz as the motor selects a character, followed by a satisfying clack. The AX-25 has a 16-character LCD, 128 kB of ROM for the typewriter’s firmware, 128 kB of storage, and 16 kB of RAM.
These specs are pretty terrible by today’s standards. Luckily, it’s easy to repurpose old technology with open-source hardware! That’s why I used an Arduino and a Raspberry Pi to turn my typewriter into a Linux terminal.
Inspiration
Back in high school, one of my friends was working on making a computer using a Z80 for a school project. He had it set up on a few breadboards in a briefcase, and after we talked about it for a bit, we decided that we would try to put it in an old typewriter. We wanted to make our own Commodore 64. We gutted an old electronic typewriter, but never got around to putting the computer in it. For the past 6 years, I've had that typewriter's shell sitting in my room.
For a while, I wanted to turn the typewriter into a cyberdeck. I planned on putting a screen in it, and a Raspberry Pi with a hefty battery. I had that idea rolling around in my head until a couple years ago, when I saw CuriousMarc's video about his teletype turned into a Linux terminal. I wanted to do the same to a typewriter, but I never had the time to do it and couldn’t find a typewriter at any thrift stores. After graduating from college, I finally had enough spare time, and knowledge, to turn a typewriter into a computer.
What it can do
I can use all sorts of Linux commands, most CLI programs will work, but anything with a text-based interface (like Vim or Emacs) won’t work. By processing the escape sequences that the Raspberry Pi outputs, I can automatically toggle the typewriter’s formatting features. It can also print ASCII art! Here’s a video of it printing some art I found online, and some that I made using an ASCII art generator:
Reverse-engineering
The typewriter’s keyboard is wired up in an 8x11 matrix, and it connects to the typewriter using two connectors, one for the rows, and one for the columns.
The keyboard connectors with jumpers to my circuit plugged into them.
When you press one of the keys, it connects one of the row pins to a column pin, which the typewriter then detects. To figure out which pair of pins each key corresponds to, I connected each pair by hand one at a time, and wrote down what key was printed. I did this until I had the entire matrix mapped out.
The typewriter matrix's layout.
The typewriter uses a 7805 linear regulator to power its 5V components, and I was able to locate an unused 5V pad and ground pad that I can tap into to power my circuit. I had to add a heatsink to the regulator to accommodate for the increased power consumption of my circuit.
Controlling the typewriter
The Arduino code is available on my GitHub repository if you’d like to look at it in more detail! My Arduino controls the typewriter using two multiplexers, one connected to each of the keyboard connectors. The multiplexer’s signal pins are connected so they can be used to connect pairs of pins on the keyboard connectors together. To send a key, the Arduino selects a pin on each multiplexer to connect them, which tricks the typewriter into thinking that a key has been pressed.
My prototype for the typewriter control circuit.
The Arduino is connected via serial to the Pi, which has the serial console enabled on its UART pins. I chose to use an Arduino in addition to the Raspberry Pi because I’m more familiar with them, and it makes interfacing with the Raspberry Pi’s UART console much easier. The Arduino and the Raspberry Pi communicate at a rate of 120 characters per second, but the typewriter can only type 12 per second. To prevent long messages from getting cut off, I added serial flow control to my code. This allows the Arduino to tell the Pi when to start and stop sending text. The Raspberry Pi is running Raspberry Pi OS Lite, since I only need access to the terminal.
Keyboard
To scan the keyboard, I used essentially the same circuit; two multiplexers, one for the rows, one for the columns. The Arduino scans the keyboard one key at a time by selecting a channel on each multiplexer. When it detects that a key has been pressed, it sends that character to the Raspberry Pi so it can be processed.
My prototype for the keyboard scanning circuit.
I could have used the typewriter’s original keyboard for this project, but I chose to replace it with a custom mechanical keyboard with Matias Alps switches, which are super clicky and should feel great to type on!
The custom keyboard layout I designed for my typewriter.
Conclusion
By turning my typewriter into a computer, I was able to recreate the experience of using a teletype. Now I know what it was like to use Unix in the 1960s when it was originally being developed! The custom mechanical keyboard feels amazing to type on, and is a huge upgrade over the mushy membrane keyboard it originally had. With these upgrades, my typewriter is much more powerful now!
Turning a 1980s typewriter into a Linux terminal
*PCBWay community is a shared platform and we are not responsible for any design issues.
- Comments(1)
- Likes(2)
- Riley Artillect Sep 14,2022
- Engineer Sep 14,2022
- 2 USER VOTES
- YOUR VOTE 0.00 0.00
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
-
9design
-
9usability
-
10creativity
-
10content
-
9design
-
8usability
-
10creativity
-
10content
More by Riley Artillect
-
Open Source Very Large Stick - Freejoy & MMjoy2 breakout board
464 0 0 -
RF Control training board for students based on ESP32 C3
614 0 2 -
Aquarius+ Computer, Standard PCB
821 0 4 -
KINETIC COASTERS with a TWIST! Laser or 3D Print some DIY Magic
575 0 1 -
RPI - 8 IO PLC With ATTiny85 Watch Dog
503 0 1 -
Nintendo Famicom HVC-001 Controller Shells
597 0 1 -
COMMODORE 128 DIAGNOSTIC REV.785260 KEYBOARD DONGLE
553 0 4 -
COMMODORE 128 15KHz DISPLAY ADAPTER (C128 80 COLUMN ADAPTER)
752 1 5 -