For this project, I created an automated safety mechanism using a small household trash can, an
Arduino Uno, and an HC-SR04 ultrasonic sensor.
The goal of the project was to create a system that could automatically control access to an opening
in the trash can. A square opening approximately 6 inches by 6 inches was cut into the lid of the
container. A sliding door mechanism was then installed to cover and uncover the opening.
Mechanical System
The mechanical portion of the project consisted of:
- Small trash can
- Modified lid with access opening
- Sliding door mechanism
- Linear movement system for the door
The sliding door was designed to move horizontally across the opening to either allow or prevent access.
Mechanical System
The sliding door was connected to a motor-driven mechanism controlled by an Arduino Uno. The actuator
provided the force required to move the door between the open and closed positions.
Automation
An HC-SR04 ultrasonic sensor was mounted near the opening and continuously monitored the
area in front of the trash can.
The Arduino processed distance measurements from the sensor and automatically controlled the position of
the sliding door based on object detection.
Application
The system was designed as a safety feature to help prevent objects from being deposited into the container
when a person or object was detected nearby.
When the sensor detected an object within the programmed distance threshold, the sliding door moved
into position to block the opening.
When no object was detected within the sensor's field of view, the door returned to its normal position.
Results
The project successfully demonstrated the integration of a mechanical system, electronic actuation,
sensor-based automation, and a practical application. The sliding door responded automatically to
changes detected by the ultrasonic sensor and operated without manual intervention.
What I Learned
This project helped me better understand how mechanical motion, sensors, actuators, and microcontrollers can
work together to create automated systems. I also learned the importance of designing mechanical components
that move reliably while coordinating their operation through software and sensor feedback.