A Safe for Valuable Things
by Daniel Liu 劉宸均 in Circuits > Arduino
1767 Views, 8 Favorites, 0 Comments
A Safe for Valuable Things
Firstly, I need a safe to put my money in. Chinese New Year is coming. I will get red envelopes from my great-grandma, grandparents, great-uncles, great-aunts, uncles, and aunts. I need a safe to store my money. I can also use it to put anything valuable to me.
Secondly, I need a safe to put my snacks. My father usually eats up all my candy, chocolate, and cookies when he feels hungry. To help my father control his weight, I need a safe to store my snacks. With the safe, my snacks are safe, and my father will be thinner and healthier.
With the safe, my money and my snacks will be safe.
Prepare the Hardware Required
What you need:
1. Breadboard x1
2. Arduino board (I am currently using Arduino Leonardo.)
3. LCD (Liquid Crystal Display) module
4. One Keypad
5. Two servo motors
6. One button
7. One NeoPixel LED Ring
8. Wires
9. One Paper Box
Assemble All the Parts
After getting all the materials needed, assemble all the parts. The ways of assembling are shown in the circuit diagram.
To open the safe, you need to key in the password.
Programming
Now it's time for programming. You can change the values of some parameters to meet your needs. You can change the password, the number of LEDs on your NeoPixal ring, and the arrangement of your keypad. The ways of changing these parameters are shown in the picture I've uploaded.
**Download and install Fastled library from https://downloads.arduino.cc/libraries/github.com...
**Download and install Keypad library from https://downloads.arduino.cc/libraries/github.com...
After you've downloaded these two libraries, open your Arduino IDE, click on Sketch > Include Library > Add .ZIP Library. Then choose the zip file you just downloaded.
After following the steps above, paste this code into your Arduino IDE.
The complete code is attached below.
https://create.arduino.cc/editor/danielliu0000/b1bd3903-877f-44d8-b044-508600011a9b/preview
Testing
Make sure to test if your code can run well before you arrange and hide all the materials.
Find a Suitable Box and Cut Out Holes
Find a suitable box and cut out holes used to show the button, the LCD module, the servo motors, the keypad, and the LED lights.
Arrange All the Materials and Do the Decoration.
After Hiding all the wires into the box and doing the decorations, you are done. Now you can put your valuable things in it.