Star Trekulator - a Trek Themed Calculator From the 70s
by megardi in Circuits > Electronics
327 Views, 1 Favorites, 0 Comments
Star Trekulator - a Trek Themed Calculator From the 70s



In the 70s MEGO was known for making Star Trek toys, including a cassette player that (sorta) looked like a tricorder and communicator styled walkie-talkies. One of these products caught my eye. Released in 1976 the Star Trekulator was a working six function calculator with a Star Trek themed "look". It doesn't appear to correspond with any actual artifact from the series but to drive the point home it featured a cool still image "screen" featuring Kirk, Spock and Uhura plus some blinken lights for effect.
Even though it was only produced for a limited time and likely in small quantities, I was lucky enough to find one at a reasonable price on eBay (see above). With this original in hand I set about creating a reproduction. But I didn't want to stop there. I wanted to create a "Next Generation" model, still a calculator, but with a working touch screen and the capability to play Trek themed sound bytes.
Supplies



To make a Star Trekulator you will need the following.
- 2 - Custom Trekulator 2024 PCBs (see Step 1 for details).
- 1 - LED 7-Segment display 8-digits MAX7219 based - 9.5mm. Amazon.
- 1 - I2S 3W Class D Amplifier Breakout MAX98357A based. Amazon.
- 1 - LCD Module,3.5 Inch TFT Touch Screen Display, 480x320, SPI, ILI9488 based. Amazon.
- 1 - ESP-WROOM-32 Board, USB Type-C and 38-PIN. Amazon.
- 20 - Assorted Female-Female Jumper Wires. Digi-Key. (See details below.)
- 20 - 12 mm x 12 mm 4-pin Tactile Switch SPST. Digi-Key. (Pictured above. Note the square shaft.)
- 20 - 1N4148 Fast Switching Electronic Components Circuit Diodes. Amazon.
- 5 - 10K 1/4 watt resistors.
- 1 - Round Internal Magnet Speaker Loudspeaker 8 Ohm 2W 50mm Dia. Amazon.
- 1 - 12.6 mm x 5.7 mm x 6.5 mm Micro Switch SPDT. Amazon. (Pictured above.)
- 1 - 5.5mm x 2.1mm 3 Pin Female DC Power Jack Panel Mount. Amazon. (Pictured above.)
- Various Male Header 1 X N Pin 2.54 mm Pitch Straight and Right Angle Headers.
Assorted Jumper Wires
Order the PCBs
There are two PCBs required for the Star Trekulator.
The CPU Board
This is a four layer board that is designed to hold the ESP32 with break out headers that are used wire the displays, touchpad, sound card, and keypad. Also pins for external power.
The Keypad Board
A two layer board used to mount the physical keys and their associated diodes. Also footprints for five 10K pull-down resistors.
The KiCad files for these boards are available on GitHub. In addition I have posted the Gerber files that I used to have these boards fabricated at JLCPCB.
Print the Parts
While you are waiting for your PCBs to arrive you can get on with the rest of the build by printing the parts. All of the printed parts were designed with Autodesk Fusion. I'm a big fan. I printed the parts with no supports and the following settings unless otherwise instructed.
Print Resolution: .2 mm
Infill: 20%
Perimeters: 3
Filament: AMZ3D PLA
Colors: Light Blue, Black, White, Dark Red
Notes: Print the parts in their default orientation.
You will need to print the following parts:
- 1 - Case Bottom
- 1 - Case Top (Requires supports.)
- 1 - Keypad Mounting Block (Contains Block and PCB Separator.)
- 1 - Large Display Mount (Requires supports.)
- 6 - Locking Tab
- 1 - Screen Mask
- 1 - Screen Mask Buttons
- 1 - Set of Red Switch Covers (Pause at 4.8 mm to switch filaments for labels.)
- 1 - Set of White Switch Covers (Pause at 4.8 mm to switch filaments for labels.)
- 1 - Small Display Mount
- 1 - Speaker Mount
- 1 - Switch Holder (Two parts.)
- 1 - Top Panel
- 5 - Wire Clamp
- 1 - Wire Tiedown
Note: The Red and White Switch Covers and Screen Mask are alternately setup as "Plates" to take advantage of Bambu printers with AMS units. In the case of the Switch Covers the key labels can be printed "imbedded" into the key. The Screen Mask can be printed with the blinken light holes filled with transparent filament to create "light pipes".
Downloads
Populate the PCBS


Populate the Keypad PCB with the diodes, switches, and a single 90 degree header mounted below the PCB.
Add the headers and sockets to the CPU PCB as pictured above.
- Be careful when installing the 1N4148 diodes as they have polarity. The stripe around the end of the diose goes to the left as indicated by the PCB silk screen.
- The Keypad PCB pictured above was my first version. When I was testing the keypad I realized that I need some pull down resistors which I bogged in as seen above. The PCB files uploaded have been modified to have proper footprints for the resistors.
- The silk screen for the first version of my CPU PCB had the power labels reversed (dangerous mistake). Fixed in the latest Gerbers.
While the soldering iron is still hot add the headers to the sound and display boards.
Assemble the Keypad Block


Put together the sub-assembly that holds the Keypad and CPU PCBs.
- The Keypad PCB is inserted into the Keypad Assembly Block so that the 90 degree connector is aligned with the cutout in the Block.
- Once the Keypad PCB is in place add the PCB Separator.
- Add the CPU PCB as pictured above then hold the assembly in place with three Locking Tabs.
Assemble the Case Top



Put together the parts that comprise the Case Top.
- Glue the Small Display Mount to the Top Panel. The Small Display Mount slots in from the back of the Top Panel. Use a good CA glue. I prefer Gorilla Micro Precise Super Glue because of its adhesion and the convenience of the applicator.
- Glue the Large Display Mount to the Case Top. The Large Display Mount slots in from the back of the Case Top.
- Carefully glue the Keypad Assembly Block to the underside of the Top Panel. Slide the keycaps through the holes in the Top Panel to ensure proper alignment. Make sure that all the keys can be depressed freely before the glue sets. When set, glue the Top Panel onto the Case top. The Top Panel drops into the front of the Case Top.
Mount the Power Switch




- The Power Switch is made up of three parts: The Switch Holder, Switch Slider, and the Micro Switch itself.
- Assemble the three parts as seen in this image. Pay Attention. There is only one way the parts go together like this. No glue required.
- Once assembled the power switch is glued to the underside of the Top Panel beside the Small Display Mount as pictured here.
- This is what the upper side of the Top Panel should look like when the Power Switch is installed.
Wire Power and Sound

- Mount the ESP-WROOM-32 Board and I2S MAX98357A Sound Card onto the CPU PCB sockets.
- Attach the Speaker Mount to back of the Case Top as shown. I used two sided tape to do this. Slide the speaker into the mount.
- Solder two 200 mm wires to the Speaker and run them to the Sound Card. Attach the wires to the Sound Card via the two screw terminals. I used jumper wires with a male header at one end to make them easier to attach
- Mount the DC Power Jack onto the hole in the back of the Case Top.
- Solder one jumper wire with a female header to the center pin of the Power Jack and attach it to the +5V pin on the CPU PCB. (Remember that in this version of the PCB the power labels are incorrectly reversed.) Solder a wire between the GND pin on the Power Jack and the center pin on the Power Switch. Solder a jumper wire with a female header to the bottom most pin of the Power Switch and attach it to the GND pin on the CPU PCB. Double check that the power is going to the proper pins.
Wire the Rest

- Install the 7-Segment and TFT Displays. The 7-Segment Display is secured in place with four M3 x 4 mm bolts, and the TFT Display with a couple of Lock Tabs (yellow circles). Finish the wiring using the image above as a guide. All of the pin headers on the CPU PCB and the Display boards are clearly labeled so just be sure that the cables are correctly oriented.
- Lock down the Keypad cables with the Wire Tiedown and two M3 x 10 mm bolts.
- Lock down the rest of the cables with the five Wire Clamps.
Finish the Case

The Screen Mask is comprised of two parts, the Mask itself and the Screen Mask Buttons. The Buttons piece is inserted into the Mask from the rear and attached with some small drops of glue (the yellow circles seen below) so that the Buttons are free to bend in when pressed.
- Attach the Screen Mask on top of the TFT Display with a little glue or two sided tape around the edges. Do not get any glue on the display itself.
- Cut a 60 mm x 12 mm "window" to cover the 7-Segment Display. I used a translucent green plastic "document cover" that I found at Staples. Attach the window with a little two sided tape around the edges.
- Print the attached Logo.pdf onto a transparency. Be sure to print at 100% (i.e. no "Scale to Page" and the like). Note that the logo is reversed so that the printed side will end up facing the case protecting it from scratches. Carefully cut out the logo and attach it to the case as shown above. I used thin strips of two sided tape around the edges and found that it did not "show through" to the front as glue would have.
Downloads
Setup the Software
Prepare The SD Card
Insert a 32GB (or less) SD card into a card reader on your PC. Format the SD card with the FAT32 file system. Copy the sound and image files inside the GitHub SD Card folder to the root of the physical SD Card. Move the SD Card to the slot on the Trekulator TFT Display board.
Install The Trekulator Firmware
Open the Arduino IDE and load the attached Trekulator.ino sketch file. Attach the ESP-WROOM-32 Board to your PC with a USB cable.
For my ESP32 board I used the above Tools settings. Verify and Upload the sketch to the ESP32.
Downloads
Running the Trekulator
If you plug in the Trekulator to a 5V power source and flip the switch to on this is what you should see.
Things You Can Do
- Of course first and foremost you can just use the calculator functions.
- If you touch the images of Spock, Kirk, and Uhura the Trekulator will play a "random" quote from that person. There are collections of quotes stored on the SD Card in the sounds folder with separate folders for spock, kirk, and uhura. You can add your own MP3 files to these folders if you want and they will automatically be included.
- The buttons down the left had side do the following: Top - Photon Torpedo, Middle - Slide Show, Bottom - Tricorder Sound. If you want to change the function of a button you will have to modify the sketch. It's not hard.
- Images shown in the Slide Show (Middle Button) are stored in the images folder on the SD Card. You can add you own JPG files to have them included in the show.
Wrapping Up

So in the end you have a Next Generation Trekulator with a nice screen and a bunch of new capabilities. The built-in SD Card reader has a lot of capacity to store sounds and images. The touch screen can be used to implement some cool interfaces. For instance one thought I had was to implement some scientific calculator capabilities using the touch screen to add buttons to trigger these new functions while continuing to use the 7-segment display for results. Or how about adding a Tricorder like interface. The sky's the limit as they say.
I might be interested in circling back to revisit some of these ideas but for now I'm ready to move on to the next challenge.
If you would like to see more details about the project you can check out my Build Blog.