My project is a wooden security box designed in the shape of a house, combining safety with creativity.
It uses an Arduino-controlled electronic lock that opens only when the correct password is entered on a keypad. An LCD screen provides instructions and feedback, while a buzzer gives sound alerts.
All electronics are neatly installed inside the door to keep the storage space clean.
The goal is to provide a secure, user-friendly, and affordable alternative to traditional key-based boxes (which can be lost or copied) and expensive smart locks. The box is ideal for storing small valuables like USB drives.
I was inspired by my love for safe and well-designed boxes, DIY tech creators, real-world safes, and student projects.
This project lets me merge technology, creativity, and woodwork into a unique and functional design.
Fusion 360: to design the 3D model of the box in the shape of a house, including the internal compartments for electronic parts.
Fusion 360
LaserWork: to prepare the DXF files for cutting with the laser cutting machine
LaserWork
Cura: prepares 3D models for printing
Ultimaker Cura
Design the Enclosure with Fusion 360
1- I began with rule number 0, saving my project
2- Then I created a new component named Base with dimensions of 270 × 270 mm, extruding it to a height of 3 mm and off course I made sure the sketch is fully Defined
4- Next, I made a bottom sketch for the box measuring 240 × 240 mm, centered it inside the base sketch, and ensured it was fully defined before extruding it upward to 260 mm.
5- To form the walls, I applied a 3 mm shell, and then I used slicing to separate each side of the box, dividing it into the base, front, back, left, and right sides.
6- Each body was converted into an individual component by selecting it, right-clicking, and choosing Create Component from Bodies
7- After that I organized them all under the main component called Security Box, making sure each part had the correct name and position.
8- For the front side, I created a sketch of a triangle on the upper area with a height of 120 mm, drew a line from the top, mirrored it, and extruded the sketch by -3 mm
9- Then I repeated the same process for the back.
10- On the front sketch, I also added the lower pins that would connect the front side to the base, giving them dimensions of 80 × 3 mm.
11- Finally, I created a new component named Door with dimensions of 200 × 220 mm, a rectangle height of 100 mm, and extruded it to 3 mm thickness.
1- I began adding the electronic components I would use in my project to simulate their positions, dimensions, and overall design.
2- Using my browser, I searched on the GrabCAD website, I signed up on the website with my email and started searching for the Components.
3- I started with the Arduino UNO. I downloaded the ZIP file, extracted it, and uploaded the .step file into Fusion 360 by selecting it through the upload option.
4- I followed the same steps for the rest of the components, including the LCD I2C,
5- A servo motor (which I had planned for the “nice to have” version of my project)
6- The relay module (which didn’t match the real dimensions, so I measured it manually using a ruler)
7- The breadboard
8- The electric solenoid
9- The keypad
10- The LED metal holder
11- Each file was exported and uploaded into Fusion 360 as a .step file.
12- I had to re-upload the servo motor because the first file I downloaded didn’t contain a step file.
13- I also searched for a slide switch (as another optional component)
14- A DC power connector (which wasn’t applicable to my project)
15- A step-down converter (which I couldn’t use directly because the dimensions were inaccurate, so I measured it manually)
16- A buzzer.
17- Once all the components were placed and adjusted, I saved my project.
1- I began with the LCD by importing it into my design and projecting its outline to mark the hole positions.
2- I then used an extrude cut to create the openings and assembled the LCD in place, making sure the real-world dimensions matched accurately.
3- From the Assemble dropdown Menu, I selected Joint, first choosing the LCD and then the reference point on the door’s front side.
4- Since the LCD pins extend outward and should not touch the wood, I adjusted the spacing between the screen and the door to ensure a safe fit.
5- At first, I forgot to use Break Link after inserting the LCD into the project (which is necessary for every uploaded component), but later I corrected this.
6- For the keypad, I created a sketch that included the LED hole, projected the positions for the fixing holes of the keypad cover, and extruded them by 3 mm.
7- I also modeled the keypad strap by drawing a rectangle with the same dimensions.
8- Afterward, I assembled the keypad, LED holder, RGB LED, Arduino, and breadboard.
9- For the relay and the step-down converter, I measured the dimensions directly from the real components and imagined their placement in the design.
10- Finally, I positioned the solenoid to complete the electronic assembly layout.
After preparing the electronic components
1- I moved on to editing the sketches of the box sides and began assembling them together.
2- I drew the upper sides on offset planes, then used the mirror tool to create symmetrical parts before assembling the bodies in place.
3- Finally, I sketched and modeled the remaining pieces of the door, adjusted their dimensions, and assembled them with the rest of the box to complete the full structure.
5- Next, I began designing the hinges by taking the exact measurements from a real hinge piece and modeling it in Fusion 360.
6- I followed the same approach for the solenoid, since the version I downloaded from GrabCAD did not match the actual dimensions.
7- After that, I assembled the DC power connector and the ON/OFF switch in their proper positions.
8- After I noticed a small gap between the two upper pieces, I asked my instructor for advice, and he suggested a way to solve it. Following his guidance, I adjusted the design and then drew and modeled the curved upper side of the roof, which gave the box its final artistic house-like appearance.
I started adding brackets to my design
Since I had practiced modeling brackets before, I inserted the bracket into the design checked that it fit properly in the intended place
And assembled it using the holes I had already created in the house bodies.
For some brackets, I needed to adjust their dimensions to match the design requirements.
After making the necessary edits, I carefully reviewed everything to ensure the assembly was correct and well-aligned.
1st: In Fusion
1- I began by exporting the DXF files from Fusion 360.
2- From the Create dropdown menu, I selected Save as DXF for Laser Cutting
3- Chose the body I wanted
4- And saved the file as DXF
5- I made the same steps for all parts
2nd: In Laser Work Software
5- I opened the DXF files in the Laser Work software to prepare them for cutting with the laser machine.
6- After connecting my laptop to the machine via a USB cable
7- I imported the DXF files
8- Adjusted the settings and set the cutting power to 65 and the speed to 15, since my goal was to cut the parts only.
9- Once the files were ready, I pressed Download in the software, waited for the confirmation message, and then moved to the machine.
3rd: In Laser Cutting Machine
10- Then, I set the focus using a small wooden piece prepared for this purpose.
11- I selected the correct file
12- Checked that it fit properly on the plywood sheet by pressing the Frame button
13- Finally, started the cutting process.
13- For safety, I carefully closed the machine door before beginning.
14- I repeated these same steps with all of the DXF files until all parts were successfully cut
1- I worked in Fusion 360 by selecting the brackets and the handle individually
2- Then saving each one as a mesh file by: right-clicking on the component and choosing Save as Mesh.
3- In Cura, I dragged the mesh files into the workspace
4- Performed slicing to calculate the required printing time and the amount of filament needed
5- Then reviewed the settings: (For Brackets I didn't need to use supports as the hols is very small)
6- (For the Hand I needed to add supports)
7- I made the infill 10%
8- Thickness of walls is standard
9- Once everything looked correct, I saved each file as a .gcode file and renamed it with details such as the estimated time and filament weight in grams.
10- After that, I copied the files onto a micro memory card and inserted it into the (Creality Ender 3) 3D printer.
11- Using the scroll button on the machine, I selected the file and confirmed to start.
12- The printer first heated the nozzle and the build plate, and once both reached the target temperature, it began printing the parts (brackets and handle).
The electronic circuit of my project integrates several input and output components, all controlled by an Arduino Uno, to create a functional and secure smart system.
Tools:
Screwdriver
Multimeter Tester
Screws & Nuts
Breadboard
Male-Male & Male-Femal Jumper Wires
Crocodile Wires
Input Components:
1- Keypad (4x3): Used by the user to enter the password. It sends the pressed numbers as signals to the Arduino.
2- DC Power Supply (12V Adapter + Step-down Converter): Provides the required power to the system.
-- The 12V Adapter adjusts the voltage 12V to the Electric Solenoid Lock
--The step-down converter adjusts the voltage 5V for the Arduino and other components
Output/Action Components:
1- LCD (I2C): Displays messages, instructions, and feedback for the user, such as “Enter Password” or “Access Granted.”
2- Buzzer: Provides sound alerts, such as beeps when entering digits or an alarm sound for wrong passwords
3- RGB LED: Gives a visual indication of the system status (e.g., green for correct password, red for wrong password, purple for reset password)
4- Relay Module: Acts as a switch to control the higher-voltage solenoid lock safely using the low-voltage Arduino signal.
5- Electric Solenoid Lock: The main locking mechanism that physically secures the box. It opens only when the correct password is entered
6- Inside Lamp: Provides light inside the box when it is opened
Controller (the Brain):
Arduino Uno: The brain of the circuit. It processes the input from the keypad, verifies the password, and controls the output components (LCD, buzzer, LED, relay, and solenoid)
Integration:
The system works in the following sequence:
1- the user powers on the box
2- And enters the password through the keypad.
3- The Arduino reads the input
4- checks if it matches the stored password
5- And then takes action.
6- If the password is correct, the Arduino activates the relay, which powers the solenoid lock, unlocking the box.
7- Simultaneously, the LCD displays confirmation
8- The buzzer and LED give positive feedback, and the lamp turns on.
9- If the password is wrong, the Arduino triggers the buzzer and LED to indicate an error, and the lock remains closed.
Tinkercad: For simulating the circuit virtually before assembling the real one.
Arduino IDE: To program and upload the control code to the Arduino.
1- I simulated the circuit in Tinkercad by replacing the real relay modules with NPN transistors
2- replacing the solenoid with a DC motor
3- and using two power supplies: a 5 V / 2 A supply (as the step-down for the Arduino/logic)
4- and a 12 V / 2 A supply (as the 12v Adapter).
1- The power source for my project is a 12V DC adapter.
2- I selected it because the solenoid lock requires 12V to operate efficiently, and using this adapter ensures that it can be powered safely and reliably.
3- To supply the other electronic components, such as the Arduino UNO, relay module, LCD, keypad, and RGB Led, I integrated a step-down converter (buck converter), which reduces the 12V down to 5V.
4- This way, all components receive the proper voltage they need without risking damage.
5- I chose this setup after checking the voltage and current requirements of each component and making sure the adapter could provide enough power to handle all of them together.
6- For the design and verification, I used Fusion 360 for placement
7- Tinkercad for circuit simulation, and the actual step-down converter, relay, multimeter, and adapter in testing.
3. Password storage and buffers
EEPROM layout:
1- byte 0 stores password length.
2- bytes 1..(1+MAX_PASS_LENGTH-1) store password characters.
3- Default (in code) password is "1234" in RAM; loadPasswordFromEEPROM() may overwrite it.
4- inputBuffer holds digits typed before pressing # (Enter).
5- inputLength tracks typed digits
1- Wire.h: is for I²C communications (used by the I2C LCD).
2- LiquidCrystal_I2C.h: controls the 16×2 LCD over I²C.
3- Keypad.h: reads the 4×3 keypad.
4- EEPROM.h: reads/writes the Arduino's built-in EEPROM (to persist the password).
2. Pins and Constants
1- LCD I2C address 0x27, size 16×2.
2- Keypad wiring: rows on pins 5–8, columns on pins 2–4.
3- Relay (controlling the solenoid) on pin 13; buzzer on 12.
4- RGB LED uses pins 9 (R), 11 (G), 10 (B).
5- Lamp (interior light) uses A0 as a digital output.
6- RELAY_ACTIVE_LOW set to false — meaning relay is activated by HIGH.
If relay board is active-low, set this to true.
4. Flags and timing variables
1- solenoidActive + solenoidStartMillis used with millis() for a non-blocking 2-second open time.
2- starPressed and starPressedMillis detect the * then # quick sequence (within 1.5 s) to manually close the lamp/door.
3- lastStarMillis is used for detecting double * (two * presses within 1.5 s) to request password reset.
4- resetRequested indicates a requested password reset (pending # to begin entering a new password)
5. Helper functions
1- setRGB : Turns each RGB channel on/off. If your RGB is common-anode, invert logic (HIGH turns off).
2- relayOn / relayOff: Respect RELAY_ACTIVE_LOW so code can work for either active-low or active-high relay modules.
3- clearInput: Zeroes inputLength and inputBuffer
4- comparePasswords: Wrapper for strcmp to compare current input with stored password.
6. Tones (audible feedback)
1- successTone()
2- errorTone(),
3- savedTone()
4- tone(pin, freq, duration)
5- delay() to play simple melodies.
1- successTone()
2- errorTone(),
3- savedTone()
4- tone(pin, freq, duration)
5- delay() to play simple melodies.
7. 1- loadPasswordFromEEPROM()
2- Reads the stored length. If length is out of range, assumes length 4.
3- Reads each stored byte and sanity-checks that it is printable ASCII (32..126); otherwise it writes '0'.
4- Ensures password is null-terminated.
8. savePasswordToEEPROM(const char* p)
Writes new length and bytes using EEPROM.update() (which writes only if changed — extends EEPROM life).
Writes zeros for remaining unused bytes up to MAX_PASS_LENGTH.
9. LCD helper
updateStarsLCD() prints the prompt on the top line and > ****
(stars equal to entered digits) on the second line.
Used during password entry/new password entry.
10. void setup()
Sets pin modes for all used pins.
relayOff() and digitalWrite(LAMP_RELAY, LOW) to set known states.
Turns off RGB LEDs.
Initializes and clears LCD, prints initial prompt: "Enter password:" and > .
Clears input buffer and loads password from EEPROM.
11. void loop()
1- keypad.getKey() returns a char key (or 0 if no key pressed).
2- currentMillis for non-blocking timing.
Solenoid timer (non-blocking)
If solenoid was activated, turns it off after 1500ms (2 s). Non-blocking: keypad still processed.
If a key was pressed
All key-handling logic is inside if (key) { ... }.
1- Double * for reset request (only if lampOn)
2- If lamp is on, pressing * twice within 1.5 s shows "Reset Password" and sets resetRequested = true.
3- The user must then press # to start entering a new password.
4- return stops further processing for that keypress.
12. Start entering new password (resetRequested && key == '#')
1- Sets enteringNewPassword = true, clears resetRequested, clears input and shows stars LCD. Then return (start of new-password mode).
13. Entering new password flow (enteringNewPassword == true)
2- # finalizes and saves the new password if at least 1 digit was typed: copies inputBuffer to password, saves to EEPROM, shows "Password saved", plays tone, resets enteringNewPassword and returns to normal prompt.
3- digits (isdigit(key)) appended to inputBuffer if under MAX_PASS_LENGTH.
4- * deletes the last digit (backspace behavior).
5- return at the end ensures these steps are isolated.
14. Manual lamp/door close (* then # within 1.5s)
15- 6- If user presses * (sets starPressed=true and records time) then presses # within 1.5s,
and lampOn is true,
it will turn LAMP_RELAY LOW (off),
set lampOn=false,
update LCD ("Door closed"),
reset RGB,
clear input and show main prompt again.
7- If starPressed times out (more than 1.5 s), it is cleared.
16. Normal password entry
Digits are appended to inputBuffer, updateStarsLCD() shows stars.
When # is pressed:
1- comparePasswords(inputBuffer, password) checks the input.
2- If correct and lampOn is false:
3- Display "Access Granted" and "Door opened", set RGB green, play success tone.
4- relayOn() to open solenoid, solenoidActive=true, record solenoidStartMillis, turn LAMP_RELAY HIGH (lamp on), lampOn=true.
If wrong:
1- Show "Wrong Password", set RGB red, play error tone.
2- Clear input and restore main prompt.
Wiring
Assemble Electronic Components inside the Door
To integrate all the modules of my project, I started by designing the mechanical structure in Fusion 360, where I planned the placement of each electronic component.
For the electronic integration, I used a breadboard and wiring connections to connect all components to the Arduino UNO.
The main modules I integrated are:
Arduino UNO: the central controller.
LCD I2C: displays system messages and password input.
Keypad 3x4: user input for entering the password.
Relay Module: controls the solenoid lock safely.
Electric Solenoid Lock: locks/unlocks the box.
RGB LED: shows system status (green = access granted, red = wrong password, yellow = reset).
Buzzer: provides sound feedback for correct, wrong, or saved password.
Lamp Relay: controls the internal lamp after unlocking.
Step-Down Converter: regulates 12V from the adapter down to 5V for Arduino and modules.
On/Off Switch + DC Connector: for safe powering.
Wiring:
The solenoid lock was powered by the 12V adapter but controlled by the relay through Arduino.
The keypad rows and columns were connected to digital pins.
The RGB LED was connected with resistors to PWM pins.
The LCD I2C used SDA and SCL pins.
The lamp was powered by a separate relay connected to the Arduino.
Testing Process
1- Initial Power Test:
Connected the 12V adapter.
Checked with the multimeter that the step-down converter outputs 5V for Arduino and other components.
Verified the Arduino powers on and the LCD displays "Enter password".
2- Password Entry Test:
Entered the default password (1234).
LCD showed “Access Granted”, buzzer played success tone, RGB turned green, solenoid unlocked for 2 seconds, and lamp switched on.
3- Wrong Password Test:
Entered a wrong password.
LCD showed “Wrong Password”, buzzer played error tone, and RGB turned red.
4- Password Reset Test:
Double-pressed * while the lamp was on, then pressed #.
System entered reset mode and allowed me to type a new password.
New password was saved successfully in EEPROM and worked after restart.
5- Manual Close Test:
Pressed * then # within 1.5 seconds.
The solenoid stayed closed and the lamp turned off.
Results
1- All modules worked correctly after integration.
2- The solenoid reliably opened and closed with the relay.
3- The LCD gave clear instructions.
4- The buzzer and RGB LED provided immediate feedback.
5- The lamp worked only when the box was unlocked.
6- EEPROM ensured the password was saved even after powering off.
Yes, Throughout the project, I often asked for feedback and also gave help to my peers whenever I could
When I noticed a small space between the two upper roof sides in my design, I asked my instructor Hazem about it.
He suggested making a curved shape to fill the space and also showed me how to model it in Fusion 360, which gave the box a more artistic and complete look.
I also got help from my colleague Yossef, who supported me when I faced some issues sending the G-code files to the micro memory due to a problem with my laptop.
He guided me through the process and helped me solve this step.
On the other hand, I contributed by helping my colleague Salma in preparing her 3D printing files.
These are just examples, but actually, there were a lot of moments where we exchanged knowledge, ideas, and small tips with each other
Whenever I got stuck, I always turned to my instructors, Hazem and Manar
1- The biggest challenge for me in this project was designing the enclosure, especially the door part
When I fabricated it for the first time, it didn’t come out as I expected and had some issues in the fitting
At that point, my instructor Hazem stepped in and helped me fix the problem so I could continue
Actually, I faced many problems along the way, and I had to pause a few times to research or learn more before moving forward.
What I learned is that enclosure design looks simple but can be tricky if you don’t think carefully about the dimensions, the joints, and how the door will open and close.
If someone else were to do this project, I would advise them to double-check measurements, test the fitting virtually in Fusion 360 before fabricating, and not to rush the fabrication step, because small mistakes in design can cause big issues later.
One of the challenges I faced was making edits to my design after I had already completed most of the assembly.
1- I needed to reposition the relay module and the step-down converter so they would fit properly into the small right-side piece.
2- In addition, I had to reassemble both the Arduino Uno and the breadboard to ensure they fit neatly into the door’s front piece.
These adjustments required careful repositioning and alignment but helped me refine the overall design to be more practical and organized.
I would focus on two main improvements:
1- Adding an Automatic Mode
I want to integrate a servo motor to handle the opening and closing mechanism automatically.
This way, the system would have two modes - manual and automatic.
and the user could switch between them using a slide switch. This would make the project more flexible and closer to a real-world smart locker system.
2- Enhancing the Inner Design of the Box
I would divide the inner space of the box into several and varied parts to make it more practical.
For example, I could design compartments to fit a mobile phone, accessories, memory cards, and maybe even add a small drawer for better organization.
These changes would not only improve the usability of the system but also give it a more professional and user-friendly design.