Quality Assured Publisher
Serving Researchers Since 2012
IJERT-MRP IJERT-MRP

Design and Development of an IOT Based Controller for Waste Management in Smart Cities

DOI : 10.17577/IJERTV14IS080093

Download Full-Text PDF Cite this Publication

Text Only Version

Design and Development of an IOT Based Controller for Waste Management in Smart Cities

Emenalom Chinyeaka Stanley, Matthew Olubiwe, Rukari Kenobi Gospel, J.K. Obichere, I. O Akwukwaegbu Department of Electrical and Electronic Engineering

School of Electrical Systems Engineering and Technology Federal University of Technology, Owerri

Imo State, Nigeria

Abstract

In this work, Design and development of an IoT Based Controller for Waste Management in Smart Cities is presented. It encompasses an overview of concepts of Internet of Things (IoT), applications of IoT based controllers, and concepts of waste management in smart cities for sustainable development. Related works were reviewed in this course as it applies to waste management in smart cities to gain insight and have an overview of concepts and technologies that have been previously deployed to solve the problem of waste management in smart cities. This work proffers solution to the challenges of waste management by leveraging sensor technology (ultrasonic sensors) to detect and give real time status of a waste bin. The status of the waste bin – the percentage by which it is empty or filled is detected by means of ultrasonic depth measurement and is sent using American Telegraphy and Telephony (AT&T or AT) command to an IoT device running an android app. A waste management agent can log on to this android app on a mobile phone to view the real time status of the waste bin. It also incorporates the use of visual indicating Light Emitting Diodes (LEDs) installed on the waste bin to indicate the status of the waste bin. This work demonstrates that by deploying sensor and IoT technology in this aspect of a city waste management, status of waste bins in cities can be monitored in real time. With waste management agents prompt with waste disposal, this will help address the challenges of over-filled waste bins and consequent environmental pollution with solid waste, which have been a major environmental challenge in our cities. The system has 99.99% connectivity success rate and 99.99% real time data update rate.

Keywords: Internet of Things (IoT) Ultrasonic Sensor, Controller, Waste Bin

1.0 INTRODUCTION

The authors [1] showed that people move to cities to improve their live quality, and the United Nations expects that by 2050, 70% of the worlds population will be settled in cities. The concept of smart cities deals with aspects of city life which technology can act upon to improve the welfare of the citizens and the environment at large [2], the concept results in sustainable development. The components of smart cities include smart waste management, smart traffic management, smart health management, smart street lighting, smart security systems etc. [3]. These components (systems) use two-way communications, enabled by sensors and remote operations; processors and microcontrollers are at the core of smart city components [4]. The authors [5] also noted that waste management problem is one of the big issues encountered by metropolitan cities. They also stated that UN-Habitat has characterized a portrait of urban prosperity as a compound of the following: productivity, infrastructure, quality of life, equity and inclusion, environmental sustainability, governance and legislation. As the main purpose of Smart City is to enhance the quality of life and prosperity of its citizen, this issue has been gaining importance in the agenda for policy makers. Herein, smartness is defined as the desire to improve the quality of life within cities and residents living there from several points of views by utilizing information and communications technology (ICT) [1]. This is the core concept of sustainable development; whereby improvements made do not spoil the natural environment for future use. The authors [4] noted that IoT involves the application of internet technology to a system with the intension of enhancing communication in that system. These systems require energy to operate, and energy efficiency and sustainability are key ingredients in the making of smart cities [6]. The Internet of Things (IoT) paradigm plays a vital role for improving smart city applications by tracking and managing city processes in real-time. One of the most significant issues associated with smart city applications is solid waste management, which has a negative impact on our societys health and the environment [7]. The traditional waste management process begins with waste created by city residents and disposed of in garbage bins at the source. Municipal department trucks collect garbage and move it to recycling centers on a fixed schedule. Municipalities and waste management companies fail to keep up with outdoor containers, making

it difficult to determine when to clean them or when they are full. There are different types of waste which include medical waste, organic waste, e-waste, plastic waste, water waste, energy and fuel waste, green waste, industrial waste, commercial waste and recyclable waste [8]. The application of IoT in waste management for smart cities is the core of this research.

The rapid urbanization and increasing demand for cleanliness in smart cities pose significant challenges to sustainability. Traditional method of keeping the city clean which begins with collecting waste generated by residents on a routine basis is grossly insufficient given the growing population living in cities [7]. Hence there is a problem of not knowing exactly when the waste is ready to be disposed of from the collection points. This, noted by [7], is evident in the non-adoption of technology models to implement IoT technology on waste management to facilitate real-time monitoring of the waste bins using appropriate technology.

The research objectives achieved included:

  1. Development of a mathematical model for waste bin emptiness measurement.

  2. Optimizing the utilization of low power consuming devices within the system and adopting reliable energy sources to ensure a robust waste management system.

  3. Deploying sensors and IoT node to implement IoT-based waste monitoring systems to seamlessly report on the status of the waste bin, enabling real-time monitoring, control, and data-driven decision-making.

  4. Development of an android app to enable more user-friendly real-time status report of the waste bins.

  5. Implementation of a proof-of-concept model for system analysis.

This work is scoped and limited to implementation of a proof-of-concept model for system analysis.

    1. MATERIALS AND METHODS

      The materials used for the actualization of the stated objectives included software and hardware materials:

    2. Hardware Materials

      1. The HC-SR04 Ultrasound Sensor

        This hardware component uses echo location concept to tell the distance from it to any object in its front, ranging from 2cm to 400cm. It has an ultrasound transmitter and receiver crystal. It has 4 pins (Vcc-power, Trig-trigger/transmitter, Echo-receiver and GND-ground) for interconnectivity. It consumes very little current as it requires 5V for its power supply and operates at a working frequency of 40KHz.

      2. Atmega328P Microcontroller

        This is the core component of the controller. It has an Arithmetic and Logic Unit (ALU) to handle computations, Random Access Memory RAM for volatile data storage, peripherals like serial port for communiation with other devices/components, Timers for time-based measurements and operations and General-Purpose Input Output (GPIO) pins for interconnectivity with other components. It is normally operated at 5V.

      3. ESP8266 Wi-Fi Module

        The module is used for Wi-Fi connectivity, to enable IoT communication. It uses serial port for its communication with a microcontroller. All IoT communication protocols and frameworks like I.P addressing; HTTP protocol and HTML data communication framework are all implemented by this module. It communicates with the core microcontroller using the AT command protocol. This module consumes very little amount of current and requires

        3.3V for its power supply.

      4. Light Emitting Diodes (LEDs)

        These are used to indicate the status of the waste bin; they are positioned at the top of the bin such that the emitted light is visible from a distance. When the waste bin is not full, a green light is emitted; when it is full, a red light is emitted.

    3. Software Materials

      1. Arduino Integrated Development Environment (IDE)

        This is an integrated development environment which has an editor for writing C++ programs to run on the Atmega328P microcontroller. Also, programs are edited and compiled in this IDE. Other code development capabilities of the Arduino IDE include debugging, In-circuit Serial Programming (ICSP) etc.

      2. Serial Monitor

        This is a software tool which is used to display and analyze data communicated over a serial communication link, often between a computer and a microcontroller like an Arduino. It enhances code development as the exact bytes being transmitted/received through the serial port is made visible for simulation, tests and debugging purposes. It also shows communication baud rate.

      3. Proteus Design Suite 8.0:

        This software tool is used to draw and simulate hardware circuits. It has a very wide array of components that can be used in different hardware design scenarios. After a project is designed in proteus, one can see the behavior of the hardware; take measurements using the provided instruments like multimeter, oscilloscope etc. with Proteus, the hardware designer can test a circuit in software before implementing it physically.

      4. MIT App Inventor

        This is a web-based android app development tool domiciled with Massachusetts Institute of Technology (MIT). This software tool uses block code to develop android apps. It has an interface for designing the app Graphical User Interface (GUI), a framework for testing and debugging the developed app. It has the capabilities to integrate hardware communication modules into the app being developed. It can pull data from android phones hardware communication interfaces like Bluetooth, Wi-Fi, etc. it also has development frameworks for deployment of IoT based communications.

    4. Methods

      Each specific objective and the methods used to actualize it is presented thus.

      1. Formulation of a Mathematical Model for Waste Bin Emptiness Measurement

        Diagrammatically shown in fig. 2.1 illustrates a waste bin of depth r, been the distance between the bottom of the waste bin and the sensor. The depth of the waste bin is measured by echo location technology using an ultrasound sensor. As illustrated in fig. 2.2, the sensor emits an ultrasound sound wave, which on its way down the waste bin hits an object (a waste) and is reflected to the sensor. The time of travel of the ultrasound signal is timed by the microcontroller with which it computes the fill level of the waste bin using the velocity, distance and time relationship. Since;

        = (2.1)

        r

        Sensor

        Waste

        Bin

        Fig. 2.1: Waste bin with depth r.

        Fig. 2.2: incident and reflected ultrasound wave. Let t1 be the time the ultrasound wave was emitted, and t2 the time it was received.

        During this period, the wave signal travelled 2r in time t given by.

        = 2 1 (2.2)

        This implies that the time the wave signal hit the object (waste) is half t, depth computation. The waste bin depth is computed thus.

        () =

        2

        () which is the time required for waste bin

        2

        (2.3)

        Where, the ultrasound wave in air is 340 m/s.

      2. Optimizing the Utilization of Low Power Consuming Devices within the System and Adopting a Reliable Energy Source for a Robust System

        LEDs

Atmega328P Microcontroller

ESP8226 Module

Ultrasound Sensor Module

Power Supply

The hardware components deployed are low power consuming devices. Whereas other components; Ultrasound Sensor, Atmega328P and the ESP8226 Module requires direct power supply from the source, the LEDs are powered by the microcontroller and are directly connected to it. Fig. 2.3 shows the power flow block diagram while the power need of the various components as extracted from their data sheets is tabulated in table 2.1.

Fig. 2.3: System Components Power Flow Block Diagram Table 2.1: System Components Power Requirements.

System Component

Operating Current (mA)

Operating Voltage (V)

Power Requirement

Ultrasound sensor module

15 mA

5 V

75 mW

ATmega328P controller

200 mA

5 V

1000 mW

ESP8266 Wi-Fi module

170 mA

3.3 V

561 mW

LED

10 mA

3.3 V

33 mW

Total Power Requirement

1669 mW

For a reliable energy source, the capacity of the power source must be more than the total power requirement of the system. Hence, the Li-ion cell having capacity of 7.2Whr at 3.7V is used. Three of these cells are connected in series to get 11.1V. This provides a reliable power supply for the system.

For power optimization, the ultrasound sensor must be in the quiescent mode in which it requires about 10mW to operate, most of the time. The LED will be operated using a duty-cycled signal provided by the microcontroller. At 25% duty cycle, the power requirement of the LED reduces as expressed in (2.4). With this reduced power requirement, the brightness of the LED still provides good visibility.

25

25% = (

100

) 33 = 8.25 (2.4)

      1. Deploying Sensor and IoT Node to Implement Waste Monitoring System to Seamlessly Report on the Waste Bin Status

        The various components of the waste monitoring system are interconnected and programmed to communicate for real time monitoring of the waste bin status.

        The HC_SR04 Ultrasound Sensor connects to the IO pins of the microcontroller through its trigger and echo pins.

        The ESP8226 Module connects and communicates with the microcontroller through the Universal Synchronous and Asynchronous Receiver and transmitter (USART). This connection is made through a voltage divider circuit shown in fig. 2.4, which translates the 5V logic from the microcontroller to 3.3V required to operate the ESP8226 Module.

        Fig. 2.4: 5V to 3.3V voltage divider circuit.

        From the voltage divider circuit shown in fig. 2.4.

        2

        (

        ) 5 = 3.3 (2.5)

        1 +

        2

        (

        1 + 2

        2

        ) = (

        3.3

        5

        ) (2.6)

        (

        1 + 2

        ) = 0.66 (2.7)

        Let R2 = 10k, R1 is calculated as follows using (2.7).

        Substitute 10000 for R2

        10000 (

        ) = 0.66 (2.8)

        1 + 10000

        1 = 5151.515 = 51k (2.9)

        To Controller IO pins.

        R

        LED

        R

        LED

        The multi-colour LED connects to the microcontroller through current limiting resistors as shown in fig 2.5.

        Fig. 2.5: Connection of the LEDs to IO pins of the microcontroller through limiting current resistors.

        From table 2.1, the forward current (I) and forward voltage (V) of the LED are 10mA and 3.3V respectively. Therefore, the voltage across the current limiting resistor V = supply voltage LED forward voltage.

        V = 5 3.3 = 1.7V.

        Thus, the value of the current limiting resistor is calculated as follows using Ohms law.

        = (2.10)

        I is the LED forward current = 10mA = 0.01A, V is the voltage across the current limiting resistor = 1.7V. Substituting these values in (2.10).

        = (

        1.7

        ) = 170 (2.11)

        0.01

        The circuit diagram of the deployed waste management controller as drawn and simulated using Proteus Design Suite

        8.0 is shown in fig. 2.6.

        System Operating Philosophy: To measure the depth of the waste bin, the microcontroller sets its trig pin high for about 10 microseconds and then starts its timer. At this time, the ultrasound sensor emits an ultrasound signal through its trigger pin, the reflected wave is received through the echo pin. The duration of this activity is measured by the microcontroller timer and is used to compute the depth of the waste bin using (2.3).

        Fig. 2.6: Waste Management Controller Circuit Diagram.

        To implement IoT communication, the Atmega328P used American Telegraphy & Telephony (AT&T or AT) command instruction to set up Wi-Fi connectivity between the waste management controller and the user smart phone. It also uses AT command instructions to convey Hyper Text Transfer Protocol (HTTP) functions and Hypertext Mark Up Language (HTML) data.

      2. : Development of an Android App to Enable more User-Friendly Real-Time Status Report

        The android app was developed in block code using the online Massachusetts Institute of Technology (MIT) App inventor tool. It runs on the user smart phone and provides the Graphical User Interface (GUI) to optimize user notification of the status of the waste bin.

        The App requires Wi-Fi connection to execute its functions. This is provided by a smart phone. Once the App loads, it first detects the availability of Wi-Fi connectivity to the waste bin controller serving as the server. Once connectivity is established, HTTP requests are sent to the server, which returns the requested information as HTML data displayed on the App GUI stating by what percentage the waste bin is filled.

        Start

        Connect to smart waste bin network

Search for available Wi-Fi networks

Send a http GET request to server

Retrieve html data

No

Is the waste

bin full?

Yes

Set notification

End

Update the GUI

The Android App function flowchart is shown in fig. 2.7

Fig. 2.7: Android App Function Flowchart.

      1. Implementation of a Proof-of-Concept Model for System Analysis

For the proof of concept, a waste bin provided with a cover, or a lid was acquired. The waste management controller components and circuitry were housed in an adaptable box. The base of the box was cut open such that the ultrasound sensor was installed such that the sensors fit in facing the base of the waste bin. Arduino board was acquired because it had the Atmega328p microcontroller. A plastic holder was made, the size of three Li-ion cells connected in series, for the purpose of holding in place the battery power supply. A plastic adaptable box was used to house all the electronic components and battery. The waste controller is inwardly mounted on the cover of the waste bin. The deployed waste bin and its controller are shown in fig. 2.8.

Fig. 2.8: Pictorial Illustrations of the Proof-of-Concept Model of the Waste Management Controller.

    1. RESULTS AND DISCUSSION

      This section describes the system tests undertaken and results achieved. The waste management controller system comprises of hardware components, the application software (Android App) and the IoT connection. The following tests were carried out.

    2. Hardware Test Result:

      The deployed waste bin shown in fig. 3.1 is a hardware comprised of the waste bin itself and the waste management controller box. Internally, the controller has its major components; Ultrasound Sensor, Altmega328P Microcontroller, ESP8266 Wi-Fi Module and Light Emitting Diodes (LEDs).

      The ultrasound sensor measures the depth (emptiness) of the waste bin using echo location technology, with the microcontroller providing the timing required for depth/emptiness computation using its millis() function.

      Table 3.1 shows the time (gotten using the millis() function) for the ultrasound waves to travel from the sensor to the depth of the bin and back to the sensor. It also shows the depth of the waste bin as computed by the microcontroller.

      Fig. 3.1: The Deployed Waste Bin.

      Table 3.1: Values of t (ms) and Waste Bin Depth r (cm) Computed by the Microcontroller.

      S/No

      t2 (ms)

      t1 (ms)

      t = t2 t1 (ms)

      Distance/Depth r (cm)

      Remark

      1

      152550

      2550

      150000

      255

      Sensor outside bin

      2

      19726

      2667

      17059

      29

      Sensor deployed

      3

      17987

      2693

      15294

      26

      Sensor deployed

      4

      15646

      2705

      12941

      22

      Sensor deployed

      5

      13181

      2592

      10589

      18

      Sensor deployed

      6

      11458

      2634

      8824

      15

      Sensor deployed

      7

      9150

      2689

      6471

      11

      Sensor deployed

      8

      7893

      2599

      5294

      9

      Sensor deployed

      9

      6768

      2650

      4118

      7

      Sensor deployed

      10

      5643

      2701

      2942

      5

      Sensor deployed

      11

      3856

      2679

      1177

      2

      Sensor deployed

      12

      3099

      2510

      589

      1

      Sensor deployed

      From table 3.1, it is seen that as more waste is added to the waste bin, time (t) decreases, so is the depth (r) of the waste bin indicating that it is getting filled up. The percentage fill level of the waste bin at any instant can be viewed as displayed on the serial monitor.

    3. IoT Connectivity Test Result

      The smart waste bin connects to the app using IoT communication. This is made possible by the microcontroller communicating with the ESP8266 Wi-Fi module using AT command. Once Wi-Fi set up is completed, the Wi-Fi module (waste bin server) can now broadcast its Service Set Identifier (SSID) as found by the smart phone as shown in fig. 3.2. This connectivity can also be seen as displayed on the serial monitor in fig. 3.3 indicating that a device is connected.

      Fig.3.2: Smart_waste_bin signal can be found by a smart phone.

      Fig. 3.3: Serial monitor indicating a device is connected.

    4. Android App Test Result

With IoT connection established as discussed in section 3.2, open the smart waste bin app on the smart android phone. Once the smart waste bin App launches as shown in fig. 3.3, it sends a GET request to the smart waste bin server which updates the App with the status of the waste bin as a HTML data through HTTP function. The data (waste bin status) is displayed on the App GUI from which the user (a waste management agent) can read out, as displayed in percentage, the fill status of the waste bin. The App automatically updates itself as long as connection exists.

Open the waste bin and put in more garbage, close the waste bin; the app immediately updates the bin status showing the current percentage fill value of the waste bin as shown in fig. 3.4.

Fig. 3.4: Smart Waste Bin App GUI Showing the Percentage Fill Level of the Waste Bin.

4.0 CONCLUSION

The problems of traditional waste management systems which included inadequate application of contemporary technology, inadequate user notification of the status of the waste bin at collection points and non-utilization of android app for real-time user monitoring of the status of the waste bin all contributed to sustainability problems in smart cities.

This research improved the situation by deploying sensor nodes to monitor the waste bin, implemented IoT based monitoring and developed an android App to be used for the waste bin status notification relying on IoT communication. To this end, the Atmega328p microcontroller was used to interface with the ultrasound sensor in order to measure the depth/empty status of the waste bin. To deploy IoT technology, the ESP8266 was interfaced with the microcontroller, and they communicated with the AT command to implement necessary connectivity requirements of the IoT. An android app was developed using the MIT app inventor online tool. This App received updated information from the smart waste bin using IoT communication technology.

The cost incurred in building the system was moderate; the app cost slightly less than 50% of the total cost. The system also has nearly zero running costs (running cost here is the cost of changing batteries). This shows that the smart waste bin system is very economical and cost effective.

REFERENCES

  1. Farmanbar,M., Parham, K., Øystein, A., and Rong,C., A Widespread Review of Smart Grids Towards Smart Cities. Energies, November 2019, 12, 4484; doi:10.3390/en12234484, pp 2 5.

  2. Bibri, S.E., Krogstie, J., "Smart sustainable cities of the future: an extensive interdisciplinary literature review. Sustainable Cities and Society. 31(25), March 2017Soc. https://doi.org/10.1016/ j.scs.2017.02.016. pp 1-4

  3. Abu-Rayash, A., Dincer, I. Development of an integrated energy system for smart communities. Energy. 202(15):117683, April 2020, https://doi.org/10.1016/j.energy.2020.117683. pp 2 4.

  4. Addae, B.A., Zhang, L., Zhou, P., Wang, F. Analyzing barriers of smart energy city in Accra with two-step fuzzy DEMATEL. Cities 89. Socio-technical evolution of Decentralized Energy Systems: a critical review and implications for urban planning and policy. Renew. Sustain. Energy Rev. 2019. https://doi.org/10.1016/j.rser.2015.12.079. pp218-227.

  5. Wahyu, A. P., Oktavia, A. A conceptual design of waste management: smart bin deployment in surabaya smart city. Acta Mechanica Malaysia, March 2021 4(1):

    DOI: http://doi.org/10.26480/amm.01.2021.05.09 , pp 15.

  6. Behzadi, A., Arabkoohsar, A. Feasibility study of a smart building energy system comprising solar PV/T panels and a heat storage unit. Energy 210, 2020, https:doi.org/10.1016/j.energy.2020.118528. pp 1 3.

  7. Dipak, S. G. & Aithal, P. S. Smart City Waste Management through ICT and IoT driven Solution. International Journal of Applied Engineering and Management Letters (IJAEML), ISSN:2581-7000, Vol 5, No. 1 May 2021 pp 4 10.

  8. Aalok, K. A novel framework for waste management in smart city transformation with industry 4.0 technologies. Elsevier publications – Research in Globalization 9, 2024 100234. doi.org/10.1016/j.resglo.2024.100234. pp 7 9.