Inspiration

Waste segregation at the source is one of the biggest challenges in modern waste management. Despite awareness campaigns, improper segregation still leads to contamination of recyclable materials, increased landfill waste, and environmental pollution. We were inspired to build a system that makes segregation automatic, intelligent, and efficient using Artificial Intelligence and embedded systems. Our goal was to combine Machine Learning and IoT to create a smart dustbin that not only segregates waste but also improves collection efficiency.

What it does

SnapSort is an AI-powered smart waste segregation and collection monitoring system. When a user places waste in front of the camera: The system captures the image. A trained ML model classifies it as biodegradable or non-biodegradable. The result is sent to an ESP32 microcontroller. A servo motor rotates the dustbin flap to the correct side. The system tracks bin capacity digitally. When the bin reaches its limit, it can notify a centralized authority. This creates a fully automated segregation system with intelligent collection monitoring.

How we built it

We built SnapSort by integrating multiple technologies: Machine Learning: Trained a TensorFlow model on 25,000+ waste images. Computer Vision: Used OpenCV for image processing. Frontend Interface: Developed using Streamlit for real-time interaction. Backend Logic: Python handles prediction and serial communication. Embedded System: ESP32 microcontroller controls servo movement. Hardware Integration: SG90 servo motor connected via PWM for flap rotation. The system connects AI software with hardware automation through serial communication.

Challenges we ran into

Serial communication conflicts between Arduino IDE and Python. COM port permission errors on Windows. ESP32 resetting during serial initialization. Servo motor not responding due to wiring and power supply issues. Matching model output labels with hardware control logic.

Accomplishments that we're proud of

Successfully trained a custom ML model from scratch. Integrated AI with embedded hardware seamlessly. Built a fully working automated flap mechanism. Implemented smart fill-level tracking. Designed a complete end-to-end prototype within hackathon constraints. Achieved reliable real-time waste classification. We are proud of building a full-stack AI + IoT solution from scratch.

What we learned

Through this project, we learned: Real-world ML deployment challenges. Serial communication between software and microcontrollers. Importance of power management in hardware systems. Debugging hardware-software integration. System architecture design for scalability. Team collaboration under time constraints. This project helped us understand how AI systems behave outside controlled training environments.

What's next for SnapSort

Future improvements include: Cloud-based IoT monitoring dashboard. Mobile application for municipal authorities. Multi-class waste classification (plastic, metal, paper, glass). Solar-powered deployment. Smart route optimization for waste collection vehicles. Integration with smart city infrastructure. Our long-term vision is to make SnapSort a scalable smart waste management solution for cities.

Built With

  • ai
  • c++
  • computer-vision
  • convolutional-neural-networks-(cnn)
  • esp32
  • hardware-software-integration
  • iot-(internet-of-things)
  • machine-learning
  • opencv
  • pwm-(pulse-width-modulation)
  • python
  • serial-communication-(uart)
  • tensorflow
Share this project:

Updates