Smart Dustbin with Ultrasonic Sensor and Servo Motor

Smart Dustbin with Ultrasonic Sensor and Servo Motor

A smart dustbin is a modern type of garbage bin that opens its lid automatically when a person comes close. This system uses simple electronic parts like an ultrasonic sensor, a servo motor, and a microcontroller (Arduino) to make waste disposal easy and hygienic. The main aim of this project is to reduce the spread of germs, promote cleanliness, and encourage people to throw garbage properly without touching the bin.


🔹 Working Principle

The smart dustbin works with the help of an ultrasonic sensor, which is used to detect the distance of objects. The sensor sends out ultrasonic sound waves, and when a person’s hand comes in front of the dustbin, the sound waves bounce back. The sensor measures the time taken for the waves to return and calculates the distance.

When the distance is less than a set value (for example, 10–15 cm), the Arduino microcontroller gives a signal to the servo motor. The servo motor is connected to the lid of the dustbin. Once it receives the signal, the servo motor rotates and opens the lid. After a few seconds, the motor automatically brings the lid back to the closed position.


🔹 Components Used

  1. Arduino Board (Uno or Nano) – The brain of the system.
  2. Ultrasonic Sensor (HC-SR04) – Detects the presence of a person’s hand.
  3. Servo Motor (SG90 or MG995) – Opens and closes the dustbin lid.
  4. Dustbin Body – The physical container for garbage.
  5. Jumper Wires & Breadboard – For connections.
  6. Power Source – USB or battery supply.

🔹 Step-by-Step Operation

  1. The dustbin is in closed state.
  2. When a person comes close, the ultrasonic sensor detects the movement.
  3. Arduino receives the signal from the sensor and activates the servo motor.
  4. The servo motor rotates about 90° and lifts the lid.
  5. The lid remains open for a few seconds so the user can throw garbage.
  6. After the delay, the servo motor rotates back, and the lid closes.

🔹 Advantages of Smart Dustbin

  • Touchless Operation: No need to touch the bin, which helps in maintaining hygiene.
  • Prevents Germs Spread: Useful in hospitals, schools, and public places.
  • Encourages Clean Habits: Makes throwing waste more convenient.
  • Low Cost and Easy to Build: Uses simple electronic parts.
  • Eco-Friendly: Can be further upgraded with waste segregation (wet/dry).

🔹 Applications

  • Homes and offices for daily waste disposal.
  • Public places like malls, railway stations, and parks.
  • Hospitals and clinics for medical waste management.
  • Schools and colleges to teach students about technology and cleanliness.

🔹 Future Scope

This project can be upgraded by adding sensors to separate wet and dry waste, connecting the bin to the Internet for monitoring when it is full, or even adding solar power for eco-friendly operation.


✨ Conclusion

The Smart Dustbin with Ultrasonic Sensor and Servo Motor is a simple but very useful project. It not only makes garbage disposal easy but also helps in promoting hygiene and reducing the spread of diseases. This system is a perfect example of how technology can be used in daily life for a cleaner and healthier environment.

Code : https://github.com/starlitelectronics/Smart-Dustbin-with-Ultrasonic-Sensor-and-Servo-motor.git

Leave a Reply

Your email address will not be published. Required fields are marked *