RPRadPaul Prints

Arduino · 3D printing · Everyday tools

A little calculator.
A handy companion.

I designed this desktop unit converter to sit beside my computer while I work in CAD. Switch between length and weight conversions with a button, enter a value, and get the answer on the LCD.

Get the free build filesSee how it works
RadPaul's 3D-printed Arduino unit converter with a 4-by-4 keypad and LCD showing one inch equals 25.40 millimeters
The finished calculator displaying 1 inch = 25.40 mm.
Built for the workbench.

An Arduino Nano, a 4 × 4 keypad, an LCD, and a printed enclosure make a dedicated conversion tool. The original Arduino code and enclosure design are available free.

Simple controls

Enter. Choose. Convert.

Use the mode button to select length or weight. The A–D keys select the starting and destination units.

  1. Choose length or weight mode with the push button.
  2. Enter the number on the keypad. Use * for a decimal point.
  3. Press the letter for the unit you are converting from.
  4. Press the letter for the unit you are converting to. Read the result on the LCD.

Press # to clear the input and start again. After one minute without activity, the display backlight turns off and the input resets. A key press wakes the backlight.

1 → A → B = 25.40 mm

Example in length mode: enter 1, press A for inches, then B for millimeters. Choose different source and destination units.

Keypad reference

The same four keys serve both modes.
KeyLength modeWeight mode
AInches (in)Pounds (lb)
BMillimeters (mm)Kilograms (kg)
CCentimeters (cm)Grams (g)
DMeters (m)Milligrams (mg)

Make your own

Free files to get started.

Arduino source · TXT

Original Arduino code

Download the original sketch and copy it into the Arduino IDE. It uses the Wire, Keypad, and LiquidCrystal_I2C libraries. Make sure the required keypad and LCD libraries are installed before compiling.

Download Arduino code ↓
Enclosure design · Tinkercad

3D-print the enclosure

Open the original Unit Conversion Keypad for Arduino Nano project in Tinkercad to access the enclosure design and print-file options.

Open the 3D-print design ↗

The code download is the original project file, preserved unchanged.

Build resources

The parts behind the project.

These are the original component links from my build.

Amazon links may be affiliate links. Purchases through them may earn a commission.

Keypad hookup guide

The original project links to DIYables for connecting the 4 × 4 keypad to an Arduino.

View the keypad guide ↗

In the supplied sketch: keypad rows use pins 9, 8, 7, and 6; columns use pins 5, 4, 3, and 2. The mode button uses pin 10. The LCD is configured as a 16 × 2 I²C display at address 0x27.

Project video

See the calculator in action.

Watch the original video from the unit converter project.

Watch on YouTube ↗

Let's talk projects

Questions about the build?

Get in touch with RadPaul.

Email RadPaul →