Smart Dustbin using WIZnet EVB-Pico and TinyML

It automates the process of opening the lid of the dustbin only when a person is in front of the dustbin.
ORIGINAL POST
By Innovation Kim
components
Hardware Components
WIZnet W5100S-EVB-Pico
X 2
Ultrasonic Sensor - HC-SR04 (Generic)
X 1
SG90 Micro-servo motor
X 1
Arducam Mini 2MP Plus – OV2640 SPI Camera Module
X 1
Jumper Wires
X 3
Software Apps and online services
Arduino IDE
details

_357IcPR1rS.jpg

Abstract

One of the major reasons for various diseases is not having enough cleanliness. One of the main reasons for this is overflowing garbage bins which have no lid on it. One of the solutions for this problem is by having IOT-based smart garbage. This document is about a prototype for this smart dustbin.

Introduction

One of the major problems faced in the world is waste management and not proper cleaning of waste. For example on the roads dustbins overflow and make the surroundings very dirty. Leaving garbage open in the surroundings could lead to a lot of diseases. So to prevent such diseases we must close the dustbins in our surroundings and see to it that we keep all our surroundings clean and green. With the help of IoT, we can automate the process of opening the lid of the dustbin only when a person waves he is hand in front of the sensor and it automatically closes the lid after a stipulated amount of time. This way the lid won’t remain open after the garbage is thrown.

Description of the project

Features of WIZnet Pico Board:

  • RP2040 microcontroller with 2MByte Flash
  • 1.8-3.3V IO Voltage (NOTE. Pico IO voltage is fixed at 3.3V)
  • 2 × UART, 2 × I2C, 2 × SPI, 16 × PWM channels
  • 1 × Timer with 4 alarms, 1 × Real Time Counter
  • Micro-USB B port for power and data (and for reprogramming the Flash)
  • 40 pin 21×51 ‘DIP’ style 1mm thick PCB with 0.1″ through-hole pins also with edge castellations
  • 3-pin ARM Serial Wire Debug (SWD) port
  • 10 / 100 Ethernet PHY embedded

Features Ultrasonic Sensor:

  • Transparent object detectable
  • Resistant to mist and dirt
  • Complex-shaped objects detectable

Features 9v Servo Motor:

  • The 9v servo motor is used in the project to open the lid of the dustbin depending on the command given by the pico.

Features 9v Jumper wires:

  • These wires are used for all the connections in the entire project.

Working on the smart dustbin

In this project, we are using a raspberry pico board as a micro controller to control the 9v servo motor and the ultrasonic sensor. The ultrasonic sensor would detect the movement and then send the signal to the pico board. According to the code written on the pico board, the motor will move 90 degrees which will pull the lid of the dustbin and in turn open the lid. After the stipulated time of 5 seconds. The raspberry pico would send the signal again to the servo motor to close the lid. This way the motor will automatically open and shut the lid of the dustbin.

Explanation of the code

The pins used in this project are declared in void setup(), From which camera input is taken by Pin(09), Echo Pin (13) and Trigger Pin (12) is used for ultrasonic sensor and the servo Motor trigger Pin (10). When the input from the ultrasonic sensor is high and the distance calculated is less than 30cm the ultrasonic sensor’s input will be considered true. For the module to work it will also need the high (1) value from the camera module (refer to the below link for the human detection). If both the conditions are met the servo motor will be triggered and the lid will open for 5 seconds. After 5 seconds the lid will close automatically.

Conclusion

SmartBin uses two sensors (Camera module and Ultrasonic) and one actuator (Servo motor) which helps in detecting the human and opening the lid only when the human is in front of the dust bin. IoT is only limited by the imagination of the developer. This can have endless more prospects that can be added to the future scope of this project, having more rigorous AI for detecting only human hands, automatic bifurcation of wet and dry waste etc. SmartBin is the base model of a working smart dust bin that helps in the automation of any household.

_357IcPR1rS.jpg

Abstract

One of the major reasons for various diseases is not having enough cleanliness. One of the main reasons for this is overflowing garbage bins which have no lid on it. One of the solutions for this problem is by having IOT-based smart garbage. This document is about a prototype for this smart dustbin.

Introduction

One of the major problems faced in the world is waste management and not proper cleaning of waste. For example on the roads dustbins overflow and make the surroundings very dirty. Leaving garbage open in the surroundings could lead to a lot of diseases. So to prevent such diseases we must close the dustbins in our surroundings and see to it that we keep all our surroundings clean and green. With the help of IoT, we can automate the process of opening the lid of the dustbin only when a person waves he is hand in front of the sensor and it automatically closes the lid after a stipulated amount of time. This way the lid won’t remain open after the garbage is thrown.

Description of the project

Features of WIZnet Pico Board:

  • RP2040 microcontroller with 2MByte Flash
  • 1.8-3.3V IO Voltage (NOTE. Pico IO voltage is fixed at 3.3V)
  • 2 × UART, 2 × I2C, 2 × SPI, 16 × PWM channels
  • 1 × Timer with 4 alarms, 1 × Real Time Counter
  • Micro-USB B port for power and data (and for reprogramming the Flash)
  • 40 pin 21×51 ‘DIP’ style 1mm thick PCB with 0.1″ through-hole pins also with edge castellations
  • 3-pin ARM Serial Wire Debug (SWD) port
  • 10 / 100 Ethernet PHY embedded

Features Ultrasonic Sensor:

  • Transparent object detectable
  • Resistant to mist and dirt
  • Complex-shaped objects detectable

Features 9v Servo Motor:

  • The 9v servo motor is used in the project to open the lid of the dustbin depending on the command given by the pico.

Features 9v Jumper wires:

  • These wires are used for all the connections in the entire project.

Working on the smart dustbin

In this project, we are using a raspberry pico board as a micro controller to control the 9v servo motor and the ultrasonic sensor. The ultrasonic sensor would detect the movement and then send the signal to the pico board. According to the code written on the pico board, the motor will move 90 degrees which will pull the lid of the dustbin and in turn open the lid. After the stipulated time of 5 seconds. The raspberry pico would send the signal again to the servo motor to close the lid. This way the motor will automatically open and shut the lid of the dustbin.

Explanation of the code

The pins used in this project are declared in void setup(), From which camera input is taken by Pin(09), Echo Pin (13) and Trigger Pin (12) is used for ultrasonic sensor and the servo Motor trigger Pin (10). When the input from the ultrasonic sensor is high and the distance calculated is less than 30cm the ultrasonic sensor’s input will be considered true. For the module to work it will also need the high (1) value from the camera module (refer to the below link for the human detection). If both the conditions are met the servo motor will be triggered and the lid will open for 5 seconds. After 5 seconds the lid will close automatically.

Conclusion

SmartBin uses two sensors (Camera module and Ultrasonic) and one actuator (Servo motor) which helps in detecting the human and opening the lid only when the human is in front of the dust bin. IoT is only limited by the imagination of the developer. This can have endless more prospects that can be added to the future scope of this project, having more rigorous AI for detecting only human hands, automatic bifurcation of wet and dry waste etc. SmartBin is the base model of a working smart dust bin that helps in the automation of any household.

documents
Code
Source code link of human detection
Schematics
Circuit Diagram
Others
Youtube

COMMENTS

Please Login to comment
  Subscribe  
Notify of