Introduction: Arduino Key Safe

Ideas from:

I'm a person who always lost my things for no reason. I make this key safe so then I can remember to put my things inside, without things getting lost.

In this project, I've made some improvements on the lock, I added LED lights onto the lock, so when people get the wrong password, the red light will turn on. Also, when they get the right password, the green lights will turn on. On the other hand, I change the wording on the LCD board. Which makes it look more like a normall key safe.

Step 1: Prepare the Materials

Arduino Leonardo

- Matrix Keypad 4x4

- LCD 16x2

- Jumper Wires Male to Female

- Jumper Wires Male to Male

- Tape

- Welding Gun

- Green and Red LED light

- Charger

Link to the store:

Step 2: Type the Code

1. Download 4 system from the library.

2. Make sure to declare the servo pin as 4 (any number except 2 or 3: both of them will not work if LCD occupies SDA and SCL).

3. Set up own passcode for the lock.


“resetLocker” means when the system turns back to origin: LCD prints “Get Some Food” and “Pin”, and the servo turns to 40 degrees, which locks the box.

“unlockdoor” works if the user enters the correct password, making the servo to turn to 110 degree (open) and the LCD print “pass”. In the other hand, the LCD will print “Wrong! Try Again” if the passcode is incorrect.

By pressing “*”, users can clear the password they entered; by pressing “#”, the machine can check for the passcode.


Step 3: Make Your Arduino

1. Group the Device

2. Put them into a box

3. Tries to make it fit inside the box.

*Example is shown in the image*

4. Then after, upload your code

5. Put on your charge for external power supply

Step 4: Test for Final Product

1. Drop the keys inside the box

2. Press “*” for clearing the password, and press “#” for checking the passcode (LCD).

3. If the passcode is incorrect, the lock will not open; if the passcode is correct, the lock will open (servo).

4. Take out the key by entering the right password (entering the house).

Let's see if your Key Safe works as well as mine!