Introduction: Smart Dustbin With Using Arduino

The goal of this project is to keep our

Environment clean. Benefits of using Smart

Dustbin Bins.

• It will stop overflowing of dustbins along

roadsides and localities as smart Dustbins

Are managed at real time.

• It also aims at creating a clean as well as

Green environment.

• By using the routing algorithm it will smartly

find the shortest route thus it will reduce the

number of vehicles used for garbage

collection.

This Project has been made in the KHERA JATTAN NOOK

Makers name

Jyoti

soni

Pawan

Step 1: Material

1. Ultrasonic Sensor

2. Arduino

3. Servo Moter S9

4. Jumper Wire

5. Switch

6. Battery

7. Battery Clipper

Step 2: Arduino Connect to Ultrasonic Sensor

First,take ultrasonic Sensor to Connect it With Arduino

VCC - 5V

Trig - -5

Echo - -6

Gnd - Gnd

Step 3: Arduino Connect to Servo Moter S9

Take a servo Moter S9.

Then servo Positive wire connects Arduino Pin 3.3V

Servo Negative wire Connects Arduino Pin Gnd and then Signal Wire Connect to Arduino Pin 7

Step 4: Connect Switch and Battery

Take a Battery and fix the battery Clipper in it.

Battery Positive Wire Arduino Pin VCC

Battery Negative wire is to Put one Side of the Switch and one side of the Switch Arduino pin GND

Step 5: Fix the Servo Pully With Sheet Metal

Step 6: Fix Material

First, took a box and then fix the ultrasonic sensor with the help of the Screwdriver.

Second, then fix the Arduino Uno

After that, the Servo motor fitted.

Step 7: Code Upload

#include

//servo library

Servo servo;

int trigPin = 5;

int echoPin = 6;

int servoPin = 7;

int led= 10;

long duration, dist, average;

long aver[3]; //array for average

void setup() {

Serial.begin(9600);

servo.attach(servoPin);

pinMode(trigPin, OUTPUT);

pinMode(echoPin, INPUT);

servo.write(0); //close cap on power on

delay(100);

servo.detach();

}

void measure() {

digitalWrite(10,HIGH);

digitalWrite(trigPin, LOW);

delayMicroseconds(5);

digitalWrite(trigPin, HIGH);

delayMicroseconds(15);

digitalWrite(trigPin, LOW);

pinMode(echoPin, INPUT);

duration = pulseIn(echoPin, HIGH);

dist = (duration/2) / 29.1; //obtain distance

}

void loop() {

for (int i=0;i<=2;i++) { //average distance

measure();

aver[i]=dist;

delay(10); //delay between measurements

}

dist=(aver[0]+aver[1]+aver[2])/3;

if ( dist<50 ) {

//Change distance as per your need

servo.attach(servoPin);

delay(1);

servo.write(0);

delay(3000);

servo.write(150);

delay(1000);

servo.detach();

}

Serial.print(dist);

}

Step 8: It's Ready

Would you like to watch Dustbin's video?

please Watch