SlideShare a Scribd company logo
Design of an IoT-based monitoring
system with automatic daily report
generator to optimize the efficiency of
municipal solid waste collection
ILUNGA WA LUNDA ARIEL
B00382810
Thesis Project for the partial fulfilment
of the requirements for the Master Degree
in Information Technology / Advanced Computer Systems
Development
University of the West of Scotland
School of Computing
11th
/01/2021
DECLARATION OF ORIGINALITY
I declare that this is an original study based on my own
work and that I have not submitted it for any other
course or degree.
Signature__________________________
Library Release Form
Surname: WA LUNDA
First Name: ILUNGA Initials: ARIEL
Banner No: B00382810
Course Code: COMP11024_01
Course Title: Masters Project
Project Supervisor: Dr. RACHNA SHARMA
Project Title: “Design of an IoT based monitoring system with
automatic daily report generator to optimize the efficiency of
municipal solid waste collection“
Session: 2020-21 Date of Submission: 11th/01/2021
Signature:
i
Abstract
The collection of municipal solid waste (MSW) generated by residents is one of the biggest
challenges facing municipalities around the world due to population growth, which leads to an
increase in solid waste production. One of the important requirements to face this challenge is
to collect and share information on the collection operation in order to allow municipal
authorities and stakeholders to work together and provide a quality service according to the real
needs of the municipality. This research addresses the problem of the lack of information in the
solid waste collection operation by proposing an IoT-based system that collects relevant
information and generates a daily report on the MSW collection. The proposed system uses
sensors, microcontroller, wireless network and web technologies to produce two artifacts, a
smart trash bin and a web application, to monitor the status of the trash bin in real time, collect
information on waste generation, monitor the performance of workers assigned to the MSW
collection program, and generate reports. The result of the artefact evaluation showed that the
system is able to help improve the MSW collection by increasing the performance of the workers
involved in the collection program.
Key words: solid waste collection, monitoring system, Internet of Things, smart trash bin, report
generator
ii
Acknowledgements
Before going any further in this work, I would like to thank Dr Rachna Sharma for supervising this
work with too much attention and pedagogy. I would like to thank the MSc Program leader, Dr
Graeme McRobbie, for his expert advice throughout this work. I would like to thank all the UWS
and ISBC staff for creating this opportunity to complete our master's degree in good conditions
despite the current health crisis. I would also like to thank my family members, brothers and
sisters for their support and encouragement. I also say thank you to everyone who in one way or
another has contributed to the successful completion of this work.
ILUNGA WA LUNDA ARIEL
iii
Table of contents
Table of contents ............................................................................................................................iii
List of figures....................................................................................................................................v
List of tables....................................................................................................................................vi
Introduction .................................................................................................................................... 1
Chapter 1 – Literature review......................................................................................................... 4
1.1 Overview of municipal solid waste collection.................................................................. 4
1.1.1 Solid waste generation and composition ................................................................. 5
1.1.2 Collection of solid waste and stakeholders .............................................................. 5
1.1.3 Why Monitor MSW Collection.................................................................................. 6
1.2 Challenges and Needs for efficient MSW collection........................................................ 7
1.3 Brief case studies of MSW collection............................................................................... 9
1.3.1 South Korea............................................................................................................... 9
1.3.2 Toronto, Canada ..................................................................................................... 10
1.3.3 India ........................................................................................................................ 11
1.3.4 Bangalore, India ...................................................................................................... 12
1.4 IoT-based solutions for efficient MSW collection.......................................................... 12
1.5 Summary ........................................................................................................................ 17
Chapter 2 – Methodology............................................................................................................. 19
2.1 Research approach......................................................................................................... 19
2.2 System development model .......................................................................................... 20
2.3 System requirements..................................................................................................... 21
2.4 System design................................................................................................................. 23
2.4.1 Smart Trash bin design............................................................................................ 24
2.4.2 Middleware............................................................................................................. 25
2.4.3 Design of mySWC app............................................................................................. 25
Chapter 3 – System implementation............................................................................................ 28
3.1 Smart bin........................................................................................................................ 28
3.1.1 Components used ................................................................................................... 29
iv
3.1.2 Interfacing............................................................................................................... 34
3.1.3 Coding ..................................................................................................................... 35
3.2 mySWC App.................................................................................................................... 37
3.2.1 Server setup............................................................................................................ 37
3.2.2 Database implementation ...................................................................................... 37
3.2.3 Application coding .................................................................................................. 38
3.2.4 Implementation output .......................................................................................... 41
3.3 Communication between smart trash bin and mySWC................................................. 45
3.3.1 HTTP request........................................................................................................... 47
3.3.2 Sending the data..................................................................................................... 47
3.3.3 Receiving the data................................................................................................... 48
Chapter 4 – Test and Evaluation................................................................................................... 49
4.1 Test................................................................................................................................. 49
4.1.1 Smart trash bin........................................................................................................ 49
4.1.2 Web app.................................................................................................................. 51
4.1.3 Communication....................................................................................................... 52
4.2 Evaluation....................................................................................................................... 53
Conclusion..................................................................................................................................... 57
Critical self-evaluation .................................................................................................................. 58
a. Project idea and relationship to mobile web development stream.................................. 58
b. Research approach ............................................................................................................ 59
c. Research objectives ........................................................................................................... 60
d. Personal benefit................................................................................................................. 60
References .................................................................................................................................... 61
Appendix 1: Flowcharts of smart trash bin operating modes ...................................................... 69
Appendix 2: Application Database structure................................................................................ 71
Appendix 3: W3C compliance test results.................................................................................... 72
Appendix 4: List of the properties for evaluating instantiation artifacts ..................................... 74
Project specification......................................................................... Error! Bookmark not defined.
v
List of figures
Figure 1: Software Development Life Cycle.................................................................................. 21
Figure 2: Block Diagram of the Smart trash bin............................................................................ 24
Figure 3: Application map............................................................................................................. 27
Figure 4: Smart trash bin Prototype ............................................................................................. 28
Figure 5: View of Ultrasonic sensor HC-SR04 ............................................................................... 29
Figure 6: View of load cells and HX711 Amplifier......................................................................... 30
Figure 7: RFID module Reader/Writer (on the left) and RFID tags (on the right) ........................ 31
Figure 8: Description of the composition of the GSM/GPRS module........................................... 32
Figure 9: Description of the Arduino board.................................................................................. 34
Figure 10: Capture of the Arduino IDE.......................................................................................... 36
Figure 11: XAMPP Control Panel................................................................................................... 37
Figure 12: phpMyAdmin Home page............................................................................................ 38
Figure 13: MVC architecture diagram........................................................................................... 39
Figure 14: Capture of the script used for the auto refresh of the table in the monitoring page. 40
Figure 15: Screenshot of the home page...................................................................................... 41
Figure 16: Screenshot of the monitoring page............................................................................. 42
Figure 17: Screenshot of the alert page........................................................................................ 43
Figure 18: Screenshot of the collected trash bin page ................................................................. 44
Figure 19: System diagram architecture....................................................................................... 46
Figure 20: URL construction (HTTP GET request) ......................................................................... 47
Figure 21: Capture the script to retrieve the data sent in the URL (newHistoric.php). ............... 48
Figure 22: View of values measured in Arduino serial monitor ................................................... 49
Figure 23: weights used to test the load cell (weight sensor)...................................................... 50
Figure 24: View of POSTMAN software ........................................................................................ 52
vi
List of tables
Table 1: Summary of main features of the system....................................................................... 22
Table 2: Description of main pages of the application................................................................. 26
Table 3: List of AT-commands used to send out the data from the smart trash bin ................... 33
Table 4: Smart trash bin component wiring table........................................................................ 35
Table 5: Result of the test of accuracy of the smart trash bin ..................................................... 51
1
Introduction
Nowadays, solid waste management is one of the most import challenges in urban areas
throughout the world and it is becoming a critical issue in developing countries where a rapid
increase in population has been observed. It encompasses the collection, the treatment, and the
disposal of solid material that is no longer useful and aims to protect human and environment
from adverse impacts of solid waste such as the transmission of diseases, the air pollution, the
greenhouse effect, etc., which can result from the mismanagement of solid waste material in a
municipality. To manage MSW properly, it is necessary to collect the solid waste generated by
the inhabitants of the municipality efficiently, to quantify and sort it accurately, and to treat it in
an appropriate manner. All these conditions for achieving an effective municipal solid waste
management (MSWM) system involve a challenging implementation of adequate infrastructure
and technologies at all levels of the management process, from production to final disposal of
solid waste.
From production to the final disposal of municipal solid waste, the intermediate activities
(collection, transport, treatment and disposal) are completely separate steps from each other.
Although they can be managed by a single authorized entity or by different organizations working
together for a healthy environment; the infrastructures, technology, and logistics used for
collection, transport, treatment and disposal are always different. The collection always consists
of picking up solid waste from different sources of generation in the municipality to the next level
of the process; the treatment of solid waste may consist of reusing, recycling, composting,
sorting, etc. depending upon the type of waste; and the disposal of waste may consist of
incineration, landfill, etc. Thus, most of the time it is necessary to pay attention to each activity
separately as they deal with different inputs, have different purposes and require different
infrastructure and logistics. Therefore, we focus our work on municipal solid waste collection
(MSW) by proposing an IoT-based monitoring system with an automatic daily report generator
to help obtain reliable data of MSW collection operation, which can be used to optimize the
efficiency of this operation.
2
Several researchers have carried out work on optimizing the efficiency of MSW collection
using IoT technology and have found favorable results. Most of them have been able to address
the challenges of cost savings, citizen participation in the solid waste collection activity, individual
safety seen in some practices, overflow of garbage bins, etc. However, they do not address the
question of collecting reliable data on everyday municipal solid waste collection operations. In
this project, we address the problem of lack of reliable information in MSW collection, which
raises the research question of how using an IoT-based system to collect data can help optimize
the efficiency of MSW collection.
Our assumption to this question is that IoT can help improve the collection of MSW by
collecting information on waste generation, stakeholders and trash bin status. In fact, one of the
main keys to improve any activity in a particular domain and maximize its efficiency is to be aware
of current situations and practices in that domain. Since municipal solid waste management is a
process that involves different participants such as workers, partners, contractors, and municipal
authorities; transparency, accountability and the exchange of accurate information or data
between participants are probably needed to achieve the expected results. Accordingly, in the
case of solid waste collection, some analyzes suggest that reliable data can solve problems that
can arise from the fact that the municipality does not obtain reliable information on this activity.
Thus, this work is put in order to address this gap and provide the municipality with a mechanism
able to generate reliable reports on garbage collection and all the stakeholders engaged in the
MSW management on a regular basis, which can be used to guide authorities in the process of
maximizing efficiency.
The overall aim of this work is to develop a system that enables an accurate gathering of
data that can be used to improve the efficiency of MSW collection, thereby provide a healthy
environment, then, evaluate it and determine in what measure it can optimize the efficiency of
the MSW collection. To do this, the key aim of this work is to design and implement an IoT-based
system, which includes a web application and a smart bin for monitoring and data acquisition
respectively, in order to produce relevant and reliable daily information (relevant data) of all
activities on the trash bin, thereby on the MSW collection operation.
3
To achieve the aim of the project, specific objectives are: (1) to identify the system
requirement for the system to design through the review of the literature; (2) to develop a web
app and a smart trash bin prototype using HTML, CSS, JavaScript, PHP, SQL, microcontroller,
communication module, sensors, etc.; (3) to test the web app and the smart bin in laboratory,
and evaluate whether the requirements have been met based on academic theories. The test of
the smart bin consist of verifying the response and the accuracy of sensors in different scenarios
of bin filling. The test of the web application consist of verifying the response and the behavior
of the application from different requests of the smart bin and generating report based on
different scenarios.
The work has two mains parts, a dissertation part and a development part. The
dissertation part is structured around four main chapters apart from the introduction and the
conclusion. The first chapter gives the background of our project. It focuses on highlighting
current issues, challenges and needs in MSW collection, and analyzes gaps in the existing
knowledge regarding IoT-based solution for efficient MSW collection. The second chapter
presents the methodology used to achieve the overall goal of the project. It presents the research
approach we adopted, the chosen software development model, the system requirements and
the system design. The third chapter deals with the implementation of the web application and
the prototype of the smart trash bin. It shows the components and technologies used, and the
outcome of the implementation. Finally, the fourth chapter gives the result of the test and
evaluation of the produced system. The development part of the work has two components, a
web application and a smart bin. The code for these two components is available on the GitHub
repositories given below:
Web application
- Repository name: myswc
- Released link: https://github.com/conordata/myswc
Smart bin
- Repository name: SmartTrash
- Released link: https://github.com/conordata/SmartTrash
4
Chapter 1 – Literature review
The aim of this chapter is to give the necessary background of our project. First, we give
an overview of the municipal solid waste (MSW) collection, in which we highlight different
sources of generation and the MSW composition, the solid waste collection and stakeholders of
this operation, as well as the reason why it can be important to monitor the collection of MSW.
Second, we analyze the challenges and needs for efficient MSW collection and highlights existing
issues encountered in the collection and transport of MSW. Third, we provide some information
that result from countries and cities across the world that use, as well as that do not use
technology or information system in the collection and transport of MSW. This analysis illustrates
what may be the expectation of using information system in the MSW collection, and assures
that implementing an IoT-based solution for MSW collection may help in some extent. Third, we
analyze existing IoT-based solutions for efficient MSW collection proposed by different
researchers. This survey analyzes strengths and weaknesses of existing solutions to meet current
needs for efficient solid waste collection. Finally, we outline how this project addresses the
problem of gathering relevant and accurate information of MSW collection.
1.1 Overview of municipal solid waste collection
According to Nathanson (2020, Section 4), the collection of MSW is a public service that
has important impacts on public health and the appearance of towns and cities. It consists of
implementing strategies and deploying necessary logistics to pick up (collect) and transport in an
appropriate manner solid waste generated by residents to a determined destination. The
strategy implementation for collecting and transporting MSW includes the definition of various
parameters or variables such as the type of waste to collect, the frequency of collection, the
haulage distance, the type of service to provide, the type of vehicles to use, who to assign to the
collection task (public employees or private companies), what technology to use, etc.
5
1.1.1 Solid waste generation and composition
MSW is any unwanted material that is not a liquid or gas in our surroundings resulting
from human activities (Speight, 2015, p. 279). It is mainly composed of solid material such as
cardboard, food wastes, glass, metals, leather, paper, plastics, rubber, textiles and wood. The
various known production sources of MSW are residences, industries, commerce (hotels,
markets, office buildings, restaurants, stores, etc.), institutions (schools, hospitals, prisons,
offices, etc.), construction and demolition, municipal services (beaches, landscaping, parks, street
cleaning, etc.) and agriculture.
Based on the types, MSW is generally classified into different categories defined in the
municipal solid waste management (MSWM) policy or regulation of different cities
(municipalities) or countries. This categorization consists of sorting MSW into different groups in
order to reuse material that can be fixed or repaired, send to the recycling facilities solid waste
material that can be recycled, reduce the amount of waste to dispose in the landfill, etc. The four
common categories of MSW in China are hazardous, recyclable, wet and dry waste (Zhou et al.,
2019, p. 2).
1.1.2 Collection of solid waste and stakeholders
The collection of MSW is an important activity in which all the components should be
designed and operate in a compatible manner in order to meet the needs and the expectations
of residents, and to avoid waste to be dumped in the street (Coffey and Coad, 2010, p. 32). Hence,
while defining the method of MSW two important questions should be asked. The first question,
which refers to the timing or the frequency of solid waste collection is “when MSW will be
collected?” This is a fundamental question encountered in any MSW collection system, and, the
public expectations and the type of solid wastes (biodegradable or non-biodegradable) mostly
influence the response to this question. The second question is “how the MSW will be collected?
This question concerns the location where the solid waste will pass from the control of the
producer to the control of the collection agency. For this question, there are different collection
6
methods including community containers, block collection system, Kerbside collection and door-
to-door collection (Laurieri et al., 2020, p. 3; Yadav and Karmakar, 2020, p. 2).
The involvement and participation of all stakeholders, including households, social
workers, urban planners, policy regulators, etc., is major aspect of the MSW collection (Joseph,
2006, p. 863). In general, local authorities are aware of the health risks and environmental issues
caused by inadequate solid waste management. Therefore, they typically look for new ways to
share their conventional roles with neighborhood associations, small businesses, large private
businesses and industries and other stakeholders in these areas. In addition, in order to establish
an effective system of waste services, the local authority can also attempt to mobilize the human
and financial resources of such actors.
1.1.3 Why Monitor MSW Collection
Many reasons can support the use of technology to keep track of the status of the MSW
collection in a region. Manual management of MSW collection may actually be very difficult due
to the huge amount of solid waste generated by residences and industry (Hassan, Jameel and
Şekeroğlu, 2016, p. 7). This could become a serious problem for the municipality due to improper
sorting and weighing of solid waste produced in various areas of the municipality, poor timing
and inefficient collection of garbage, insufficient transport of solid waste, etc. The main reason
for monitoring the collection of MSW is to ensure good service quality, adequate collection and
efficient transport of MSW. This can be achieved by using innovative technologies such as IoT.
Using IoT in the collection of MSW can help the municipality to obtain information about the
collection process, from the generation of solid waste to its final destination, from a centralized
control center with less labors and errors.
The activities that may be included in the solid waste collection are primarily collection,
loading, transport and unloading of waste (Coffey and Coad, 2010, p. 38). All of these activities
are performed separately from each other and then need to be connected together to create a
comprehensive collection system. Since all activities are linked in series, each activity should be
seriously considered to ensure that the entire system is functioning properly, as failure at one
7
stage of the system can lead to failure of the entire system. Thus, monitoring the collection of
MSW can consist of collecting information on garbage containers throughout the municipality
(filling, weight, location, temperature, etc.), tracking collection vehicles on the road, recording
activities of collector agents, predicting the evolution of solid waste generation, real-time
visualization, etc. (Pardini et al., 2019, p. 18; Khoa et al., 2020, p. 3).
Information on solid waste collection can be used to help MSW collection decision-
makers focus efforts and attention where and when it is really needed rather than deploying or
making efforts based on a usual routine that may no longer be appropriate due to constantly and
faster population growth or any other factor. In addition, it can lead to the optimization of the
vehicle collection route, to reduce the collection costs, to avoid the overflow of trash in the
municipality, to encourage the participation of citizens in the process of collection, etc. (Catania
and Ventura, 2014, p. 30; Sureshkumar and Prabha, 2019, p. 232).
It may also be used to evaluate the existing system in order to improve its efficiency in
terms of method of collection (collection point and timing) and transport of MSW. Besides, it also
may be used to estimate the resources that would be needed to extend the collection service to
new areas of the municipality. Moreover, with the data collected from other municipalities or
cities, it can help to compare different possible solutions for organizing MSW collection in terms
of resources, time, productivity, cost, efficiency, etc. Furthermore, information on MSW
collection may be used for designing a new MSW collection system (Coffey and Coad, 2010, p.
140).
1.2 Challenges and Needs for efficient MSW collection
According to Adipah and Kwame (2019, p. 147), solid waste management is a problem
encountered all over the world. In developing countries, solid waste management is one of the
most important challenges where the amount of solid waste generated is increasing rapidly due
to rapid population growth, urbanization, rapid industrialization and economic sustainability.
MSW generated by households, offices, small-scale institutions and commercial enterprises is
huge in amount and various in type. They generate different types of waste depending on the
8
demographic details, principal activities in the city or town, income levels, lifestyle of the
community, etc. (Nanda and Berruti, 2020, section 1). Regarding this, improper management of
MSW can lead to the illegal dumping and burning of solid waste, water pollution, breeding of
mosquitos, air pollution, transmission of diseases, etc., which in turn can have significant impact
on human wellbeing and environmental healthiness (Ferronato and Torretta, 2019, p. 1; Ejaz et
al., 2010, p. 381). Therefore, it is important to have a MSWM system efficient at all levels.
In order to implement and maintain an efficient solid waste collection system, having an
adequate and periodic data collection mechanism on the amount and composition of MSW
generated is one of the most important considerations for countries and municipalities (Priti and
Mandal, 2019, p. 1277). Weighing and categorizing MSW allow municipalities to determine the
adequate collection, processing and disposal method that could be adopted for a healthy
environment and better quality of life. In addition, it can help to select the type and number of
collection vehicles to deploy for solid waste transport and the number of collection points to set
up in different areas of the municipality. However, the main and delicate challenge to accurately
quantify and qualify MSW remains the implementation of an adequate data collection system,
which, if not properly considered, could lead to meaningless quantification of solid waste and
qualification outcomes.
Many researchers have discussed the issues of efficiency and sustainability of MSWM
systems from different angles. Throughout their studies, they identify the lack of relevant data
among the serious problems that may face a MSW collection system, and mention the
importance of a good information system in the management of MSW. Dui et al. (2020, p. 10)
agreed that it is important for MSWM decision-makers to have relevant information (data) on
current state of local system by identifying the lack of standard process of data collection and
analysis among the obstacles to a sustainable solid waste management system. They suggested
that, by using data relating to the source of generation, quantity and composition of solid waste,
treatment technology, stakeholder participation, institutions, as well as policies and regulation,
it is possible to implement adequate MSW collection system and to identify the challenges,
opportunities and all the solutions of MSW collection systems. Besides, Fernando (2019, p. 201)
noted that information quality and transparency is recommended from all the participants of
9
municipal solid waste management (municipality, laborers, contractors, etc.) since its
effectiveness highly depends on the people who closely work in the program. It is therefore
important for the municipality to think about encouraging the people involved in the system
according to the work they do by collecting reliable data that clearly allows everyone to find their
account. In the same way, (Silva, Prietto and Korf, 2019, p. 8) emphasized the importance for
local government and population to have an information system for communication and
transparency between them, as this practice can provide municipalities with a state-of-the-art
information system with relevant and current data for a sustainable MSWM.
1.3 Brief case studies of MSW collection
1.3.1 South Korea
South Korea is a country with an excellent solid waste management legislation and
initiatives in the world, which have significantly contributed to waste reduction since 1990
(Henam and Sambyal, 2019, section 1). The country has divided the disposal of MSW into
recycling, composting, landfill and incineration, and based the solid waste management
legislation on volume-based waste disposal fees (VBWF) system, deposit refund system,
extended producer responsibility (EPR), and bans on problematic plastic items and packaging.
Thus, Seoul, its capital, has been struggling with growing solid waste generation and diversion
issues for the last three decades due to rapid urbanization, and has come to favorable outcome
in terms of reducing MSW generation mostly thanks to the VBWF system.
In order to support the VBWF system established since 1990, the ministry of information
and communication of the country developed a SWM information system that comprises three
separate systems (Kaza et al., 2018, 179). First, a system for monitoring the amount of solid waste
collected and transported, analyzing the collection vehicle routes using geographic information
system, and gathering the necessary data to support evidence-based policy. The system digitally
records all statistics of MSW collection operation, from solid waste generation to transportation
and final disposal. Second, a system for obtaining information about food waste management
using RFID system that records the identity of households and the weight of food waste they
10
disposed each time they use their personal RFID chip to open and dispose of their waste. Thus,
they are charged a fee based on waste amount. Third, a centralized information platform that
matches supplier and buyers or business and firms of recycled materials by providing information
on recycling prices, technologies, etc.
In the end, thanks to the digital volume based-system introduced in 2001, Seoul the
capital of the country has achieved 20% reduction in food waste. Besides, the information system
has proved to be successful by saving MSWM cost, promoting transparency, and eliminating
illegal waste disposal in the country.
1.3.2 Toronto, Canada
Toronto is the capital city of the Canadian province of Ontario with a population of almost
2.73 million reported in 2016. It is the Canada's most populated city and the fourth most
populous city in North America (Wikipedia, 2020). The city's solid waste management systems
are responsible for collecting, transporting, processing, composting and disposing municipal and
private solid waste, including garbage, recyclables, food waste, yard waste, electronics and
household hazardous waste (Toronto, 2020a). The city possesses an information system based
on a comprehensive and interactive website that tells residents about the reduction, reuse and
recycling of waste in order to use community participation to create a foundation for a more
effective waste management system (Toronto, 2020b). The website readily provides information
on waste management specific to residents, such as source-segregation rules, drop-off points,
city policies, and disposal rates and fees in a user-friendly and enticing manner.
Thanks to the online website, residents can also request for service such as the pickup of
household hazardous waste, the deployment of additional garbage in an area, the removal of a
dead/dying city tree, the planting of a new tree by the city, the cleaning of a road surface, etc. In
addition, they can report bulky items not picked up, garbage not picked up, an overflowing bin,
a damaged garbage or recycling bin, etc. Furthermore, they can send their complaints about
Toronto waste management service or staff, submit their comments or suggestions, and access
the waste collection schedule as well (Toronto, 2020c). Another successful initiative to engage
11
residents includes the waste collection mobile app where volunteers are trained to educate
fellow residents about sustainable waste reduction, reuse and recycling practices (Kaza et al.,
2018, p. 164).
1.3.3 India
India is one of the largest countries in Asia with more than 377 million city dwellers living
in 7,935 cities and producing 62 million tonnes of MSW per year (Lahiry, 2019). Solid waste
management is one of the basic essential services provided by the country's municipal authorities
to deal with the waste produced and keep urban centers clean. Waste management rules in India
are based on the principles of sustainable development, precaution and polluter pays. In
addition, the increase in waste generation has led to various legislations to regulate the way of
disposal and treatment of waste generated under the general law of the Environmental
Protection Act.
In India, it is an essential requirement for each urban local body (ULB) to assess the
quantity and composition of waste generated in order to plan and design MSWM systems
effectively. However, the country is facing an issue regarding solid waste quantification due to
the weighting method in place (Central Public Health and Environmental Engineering
Organization, (CPHEEO), 2016, p. 44). In fact, currently two alternative methods are used to
quantify the rates of solid waste generation. One consists of measuring the load of waste in
collection vehicles either at a municipal or private weighbridge, while the other consists of
applying a rule of thumb of 400-500 Kg per cubic meter to determine the quantity of waste
transported per trip per type of vehicles. In that manner, the municipality gathers the data of
quantity and composition by weighing and/or counting the number of trips of vehicles delivering
the waste to landfills or to treatment facilities. Poland did use almost the same weighing
procedure and ended up by failure to collect accurate information on waste generation (Boer et
al., 2010, p. 370). The study shows that this method resulted in an informal trend between
companies involved in the collection of MSW, and a lack of data credibility as well. Similarly, in
India the quantity of waste measured at the transfer stations or disposal sites does not accurately
reflect waste generation rates.
12
1.3.4 Bangalore, India
Bangalore, one of the biggest city in India, is among cities facing a significant problem
regarding solid waste collection due to the insufficient number of auto tippers deployed by
contractors, the lack of transparency in partnership, and an inadequate system for data collection
in different areas of the municipality (Ram, 2019). In fact, for a more efficient and effective
approach in solid waste management, the Bruhat Bengaluru Mahanagara Palike (BBMP)
municipality has been divided into different units which are largely dependent on contractors
who deploy auto tippers and pushcarts to carry out door-to-door collection, street sweeping, and
transportation of MSW (Naveen and Sivapullaiah, 2020, p. 3). However, the average efficiency
of MSW collection in Indian cities and states is estimated to be around 70% (Balasubramanian,
2018, p. 258). This means that only around 70% of the total amount of waste generated is
collected regularly by authorized agencies across the country, while the rest of the waste remains
collected irregularly, resulting in environmental and health consequences. Besides, several
residents in different areas of the municipality have complained of garbage piling up on the roads
because the garbage trucks do not come regularly to collect their everyday solid waste. As result,
people have ended up dumping garbage on the roads, which represents a serious environmental
and health threat. In the final analysis, such a situation is just one of many that highlight that the
lack of reliable data in MSWM is a significant problem that should not be taken lightly.
1.4 IoT-based solutions for efficient MSW collection
In order to help cities around the world to cope with the mismanagement of MSW, many
researchers have carried out work and provided various innovative solutions to improve the
collection of MSW to a specific degree. This section discusses some of those solutions.
Nirde, Mulay and Chaskar (2017, p. 667-668) present a wireless solid waste management
system in where a smart trash bin is related with a web page to remotely monitor the ongoing
status of the trash bin in terms of filling level and weight. The proposed system mainly utilizes a
set of components including two ultrasonic sensors settled at the highest point of the trash bin,
a weight sensor mounted at the bottom part, a GSM module, a set of RF module transmitter, RF
13
receiver, and Arduino unit in order collect information and transfer it to a designed website page
for real-time monitoring. The entire system continuously sense the filling status of garbage inside
the bin in term of centimeter thanks to ultrasonic sensors, and measure the weight of garbage
thanks to the load sensor interfaced with the microcontroller. Its working principle holds in three
main steps, sensing the level of garbage inside the bin, comparing the value with a threshold, and
uploading the status on the website and sending a collection alert SMS or not depending upon
the result of the comparison. The system provides a real time global point of view of the status
of garbage bins deployed across a municipality through a web. Thus, the solid waste collection
department could effectively send vehicles for garbage collection where and when it is required.
Similarly, Sureshkumar and Prabha (2019, p. 230-231) propose a smart bin system as
solution to the problem of finding out whether a garbage bin is filled or not for an efficient MSW
collection. In addition to the level sensor for measuring the filling level of garbage in the bin as
seen in the previous system, this solution uses temperature sensor, gas sensor, GSM and GPS
modules, and a LCD display interfaced with NODE MCU microcontroller. The system fetches the
filling information of garbage bin via the level sensor, displays two types of messages on the LCD
display according to the value sensed, and sends the location of the bin to the truck collector
driver via SMS thanks to the combination of GPS and GSM module. Besides, the system
continuously measures the temperature of garbage inside the bin and send a SMS with the details
of the concerned bin to the fire station if a threshold of 80% of a preset value is reached. Thus, it
addresses not only the problem of garbage pilling up outside the bin, but prevent also the
problem of fire that can occur inside a garbage. However, this solution has none user interface
(uses SMS only) and it might get very tough to use such system if the number of bins increases.
Furthermore, Vasagade, Tamboli and Shinde (2017, 264-266) come up with a smart
system for solid waste management, which, in addition of checking the status and giving the alert
of bin fullness has the feature to sense and clean garbage present outside the bin. They mainly
built up this system with a set of IR sensor modules, an alarming system, a rotating mechanical
shaft, an elevator assembly, and a GSM module interfaced with an Advanced RISC Machine
(ARM). Thanks to the IR modules, the system checks continuously the bin fullness as well as the
presence of waste outside the bin. In case of the fullness detection, the system sends a message
14
to the respective authority in Municipal Corporation if the data from IR sensor inside the bin
exceeds a preset limit (80%), so they can come to collect the garbage. In case waste is detected
outside the bin, the system turn on an alarm and enable the mechanism (mechanical shaft and
elevator) to pick up the garbage and throw it inside the bin. This system is built to prevent three
types of issue. First, it prevents overflow of the Trash bin by sending SMS to respective authority;
second, it prevents waste piling up outside the bin; third, with the alarming system, it makes
people using the Trash bin properly by turning on the alarm in case of any misbehavior like
throwing garbage outside the bin.
Cloud-based systems are one of the innovative solutions proposed in the field of MSW
collection. These are basic IoT-based systems that use cloud computing for real-time monitoring
data storage and data visualization. Likotiko et al. (2018, p. 108-111) propose a solution for real-
time monitoring the level of garbage inside the bin based on a smart waste bin system with three
layers IoT architecture. The system has a distance level sensor interfaced with a microcontroller
at the first level, a GSM module for communication at the second level, and an IoT platform for
receiving, storing and updating data coming from the smart bin at the third level. The level sensor
is responsible for the continuous measurement of the garbage level inside the bin. This sensor is
connected to the MCU microcontroller node, which acts as a process unit by collecting
information from the level sensor, comparing it with a threshold to verify whether the bin is full
or not, and communicating with the GSM module to send the data to the upper layer. The GSM
module sends the detected status of the bin and the time of detection to the Thingger.io IoT
cloud for updating and storing the status of the bin in a database. The system send an alert via
SMS when the smart bin threshold is reached, and thanks to the Thingger.io inbuilt visualization
feature, the system plots the evolution of the smart bin activities for the administrator
visualization purpose.
Chaudhari and Bhole (2018) present an IoT-based solid waste collection system that
enables bin monitoring, dynamic planning, and the generation of the shortest path for the
collection of MSW. They propose a system with four main components to quantify the amount
of waste inside the bin and send the data to a central cloud server, track the status of the bins in
real time, create a dynamic waste collection schedule, and localize the bins on the regional area
15
map. The first part is mainly hardware made up of ultrasonic sensors to get the level of garbage
inside the bin and a set consisting of GSM module, GPS module and Arduino microcontroller to
send the trash bin filling status and the location to a central cloud server. The second part is the
cloud server. They used ThingSpeak free IoT platform to receive the data from the trash bin,
update the status of the bin in the system and display the updated status on a web application.
Besides, it also pushes notifications to client side’s mobile application (Garbage truck drivers and
municipal control center) mainly for garbage collection alert. The third and fourth parts are
entirely software. They are mobile applications that show the location and trash bin status on a
map, and module that generates and displays dynamic shortest path to reach quickly the desired
bins (filled garbage bins) from garbage truck current position thanks to Google Map API. This
solution for efficient solid waste collection mainly addresses the issue of garbage overflow,
garbage truck fuel consumption and collection time (cost and time reduction).
Pardini et al. (2020, p. 7-11) present another interesting proposal based on IoT
technology. They propose a system that optimizes the collection of MSW and encourage
citizenship in the process by using an architecture that considers three main layers. A perception
layer, a middleware layer and an application layer. The perception layer is a smart bin that has
various sensors and modules to gather all the necessary information on garbage and send it to
the next layer. It is made of an ultrasonic sensor that measures the filling level of waste inside
the bin to avoid the overflow, a load sensor that measures the weight of waste present in the
bin, a temperature and humidity sensor that gets additional information of the garbage. In
addition, it has a GPS module that enables the garbage truck driver to track the bin and allows
citizens to get the shortest path and distance between them and the nearest available bin.
Furthermore, the system has a GSM module that enables a wireless communication between the
smart bin and the rest of the system, and an Arduino board acting as a central processing that
interfaces sensors and modules. The IoT middleware is a software that interconnects different
components of IoT system to allow them communicate and exchange data properly. For this
layer, they used Inatel IoT (In.IoT) cloud to receive the data sent by the smart bin and store it for
the visualization of trash bin status in real-time through the web. The third layer is a mobile
application designed to involve citizens in the MSW via their smartphone. Thanks to this layer
16
(application layer), users can send requests to the middleware (Int.IoT) and obtain important
information such as the status of nearby bins, the distance between them and the unfilled bin,
and the path and the estimated time to it. Definitely, this system primarily solves the waste
overflow problem. However, it has an additional feature that involves inhabitant in the
management process and lets them know relevant details on the garbage bins surrounding them.
This way, they will not go to the trash bin to find it already full and end up throwing their garbage
outside.
Islam et al. (2012, p. 260-261) introduce a garbage collection and monitoring system
composed of an RFID system, a GSP and GPRS modules, a geographic information system (GIS)
and a webcam in order to optimize the collection of solid waste. The system is designed to work
in such a way that the driver of the collection truck must scan an RFID tag mounted on each bin
in order to record to a monitoring station the exact time and location each time a bin is collected.
The RFID tag on each bin contains a unique identification key that allows access to household
information (identifier, address, etc.) pre-stored in an SQL database and stores new collection
information by a simple scan. The GPS and GPRS modules allow tracking the exact position or
location of collection truck, and, thanks to the information they send, a GIS analyses and decides
where the waste should be dumped. The webcam makes it possible to take pictures of the trash
bin before and after the collection in order to send them to the monitoring station. As for the
principle of operation, once the RFID reader in the collection truck scans the RFID tag on the trash
bin, the reader fetches the ID of the trash bin and sends it to the processing unit in the truck. The
processing unit in turn takes the location sent by the GPS module, the images from the webcam,
associates the time of collection, and transmits all the information to the central monitoring
station in order to store them. In this system, the trash bin is not directly connected to the central
monitoring station or to the collection truck, and do not have in-built sensor to gather
information. The interface between the trash bin and the rest of the system is the RFID tag system
only (tag and reader). Thus, the monitoring of parameters such as filling level or weight of solid
waste inside the bin is not available. The system monitor the collection of solid waste by
recording the time and the location of each bin collection, and by storing pictures token by the
17
webcam present on the collection truck. It also monitors the move of the collection trucks and
helps to determine the nearest dumping location.
1.5 Summary
The papers reviewed above highlight some issues that can be solved with a good data
collection system and present some innovative solutions for effective municipal solid waste
collection process. From the case studies reviewed, we can see how some cities succeeded in the
collection of MSW by monitoring one or more activities in this operation, while cities managing
the collection of MSW without technology struggle with different type of issues to provide a good
and efficient solid waste collection service. Among issues that can be encountered in the
management of MSW, we can mention overflow of garbage outside the bin, the lake of accurate
quantification and qualification of solid waste generated in specific geographic areas, the lake of
transparency and accountability among stakeholders of the program, the lake of relevant
information for decision-making, etc. Hence, addressing one or more of these issues may be a
primordial need to improve the collection of MSW in cities. Therefore, various solutions have
been proposed to help municipalities improve MSW collection to some extent by addressing one
or more issues that can be encountered in this operation. However, many of them mainly focus
on solving the garbage overflow issue, finding the shortest path for garbage collection, real-time
monitoring of the garbage condition, and few of them on helping residents to obtain information
on the garbage bins around them. None of the solutions solves the problem of the lack of relevant
information on quantification, qualification, transparency and accountability, which are among
important key elements for the optimization of the efficiency of solid waste collection.
On this account, this project intends to present a new approach that addresses three
major problems in the collection of MSW, which are the garbage overflow, waste quantification
and qualification, as well as transparency and accountability thanks to an information system
based on IoT. To achieve this, the approach uses IoT devices (sensors, microcontroller,
communication module, etc.) that communicate with a remote web app via internet for
gathering the information of waste generation at the collection point including weight and type
18
of solid waste, and information on workers and contractors of MSW collection every time they
collect waste.
19
Chapter 2 – Methodology
This second chapter of our project mainly presents the methodology we used to conduct
our research and the design of our IoT-based system. It presents the research approach we used
in this project, the software development model we followed to produce a working system, the
requirements for developing our IoT-based system and its design, including the smart trash bin
and the web app.
2.1 Research approach
The research approach used in this study followed a process of design science that
consists of five iterative steps including awareness of problem, suggestion, development,
evaluation and conclusion (Saltuk and Kosan, 2014, p. 6; Hevner and Chatterjee, 2010, p. 26). This
approach suits well the objectives of our project and takes into account three research cycles to
produce excellent design in the field of information system and computing, which are the
relevance cycle, the design cycle and the rigor cycle. The relevance cycle provides the
requirements of the system that takes into account the needs of the environment where the
system will be used. The design cycle consists of building alternatives design and evaluating them
until a satisfactory design is reached according to the environment need. The rigor cycle provides
past knowledge including theories, frameworks, instruments, data analysis technics, design
validation criteria, etc. applicable in the design cycle (Hevner and Chatterjee, 2010, p. 16).
According to these three cycles, the first step in the design research is the awareness of
problems, which consists of undertaking relevant researches in order to recognize and articulate
problems to address, and come out with a proposal for a new research effort. The recognition
and articulation of problems can come from the survey of literature, the need for something, the
findings in another discipline, the development of new technology, etc. In our case, we conducted
a survey of the literature to find out current problems and needs in the collection of MSW, to
understand the benefit of using information technology in the collection of MSW, and analyze
the strengths and weaknesses of existing IoT-based solutions to address problems we have
20
discovered. The second point in the process is the suggestion of a tentative idea, which is a step
that consists of producing a tentative design of how problems might be addressed by creating
step to envision a new functional artifact or a novel configuration of existing elements. At this
step in our project, we produced a new design based on IoT architecture taking into account all
the problems to be addressed. The third point is the development of the proposed design that
consists of implementing and producing a functional system. Likewise, we also implemented and
produced a functional system that comports a smart bin and a web application communicating
via internet. The next step after producing a functional artifact is the evaluation of the system,
which consists to determine how well the system works and whether the system produced meet
or not the purpose for what is has been developed. For our system, we did the evaluation based
on the research question and the finding of the literature review conducted in the first place.
2.2 System development model
The design and implementation of our system followed the software development life
cycle (SDLC) that includes 5 phases, which are (1) analyze of requirements, (2) design, (3)
implementation, (4) test and (5) maintenance as shown in Figure 1 below (Mishra and Dubey,
2013, p. 65; Airbrake, 2013, section 1). Based on these five phases, several models of software
development are available; each follows a unique pattern of steps to ensure excellent
accomplishment in the process of software development. The most common models in SDLC are
Waterfall model, Spiral model, rapid application development (RAD) model, incremental model
and V-SHAPED model. In our case, we used the WATERFALL model to design and implement our
system for its clear, concrete, and well understood steps, which is relatively simple to follow and
makes it easy to develop a timeline for the entire process (Airbrake, 2016, section 3).
21
Source: (Airbrake, 2013)
Figure 1: Software Development Life Cycle
2.3 System requirements
The purpose of this initial phase is to methodically analyze the potential requirements of
the application and determine specifications that will serve as basis for all the future
development. The outcome of this analyze is a requirements documents that defines what the
application should do, but not how (Airbrake, 2016, section 2).
Likewise, as the design and implementation in this project is about producing a system
capable of helping the municipality to solve issues relating to poor data collection in the process
of MSW collection, we conducted an analysis based on the finding of the literature to determine
our system requirements. The literature survey showed that municipalities might encounter
three main problems in the collection of MSW process, which are transparency and
accountability of stakeholders, municipal garbage bins overflow, and waste quantification and
sorting. Based on this, the system should be able to allow:
- The surveillance of workers and contractors of MSW collection for purpose of
transparency;
- The promotion of PRP for motivating the engagement of workers and contractors;
22
- The availability of relevant information on the status of municipal bins installed in
different areas to avoid garbage overflow and collection delays;
- An accurate weighing and sorting of solid waste generated in different local areas for solid
waste quantification and qualification per area.
In addition to these functionalities, the system must be accessible, user-friendly and
available to authorized users or stakeholders involved in the MSW collection with different levels
of privileges, mainly for reasons of transparency. For this, different privileges are:
- The admin system should be able to monitor the operation and have access to all the
functionalities of the system including creating, reading, updating and deleting users,
contractors, trash bins and their own collection agents;
- The contractor admin should also be able monitor and have access only to the manage
their workers or agents including creating, reading, updating and deleting;
- Simple user should be able to monitor only (view only).
The summary of important features that should be embedded into the system is given in
Table 1 below.
Table 1: Summary of main features of the system
Feature Description
Data collection Collection of relevant data on waste
generation, solid waste collection workers
and contractors, and garbage bins filling
state.
Report generation Generate a report of daily collection activity
that contains relevant information such as
waste generation and bin collection cycle,
which can help improve solid waste
collection in different areas of a municipality
23
Trash bin management Add, remove or update trashcans in the
system.
Management of staff and waste collection
contractors
Add, remove or update the personnel or
contractors assigned to the collection of solid
waste in different areas.
Real-time monitoring Allows the monitoring of the state of all the
bins placed in the different corners of the
districts of the municipality.
User management Allows creating, deleting or updating the
users of the application taking into account
the access privileges.
2.4 System design
This stage in the project development focuses on defining technical design requirements
including programming language, services, data layers, etc. that the application should be made
with in order to meet the system requirement. This phase should clearly show how the system
should work in order to cover all the system requirements (Airbrake, 2016, section 2). Similarly,
in this phase of our project, we defined how the system should work and we designed it.
Based on what the system should perform as tasks (system requirements), our system
should be able to surveille and interact with different devices of the system remotely. For this
reason, we chose to use IoT to develop our solution as it is the most suitable technology for
remote communication and devices interconnection on large distances via internet in many
applications (Diène et al., 2019, p. 2). The system we proposed has two main components, a
smart trash bin made with sensors, microcontroller and communication modules for data
collection, and a web application for receiving the data from the trash bin for the system
management, monitoring and report regeneration.
24
2.4.1 Smart Trash bin design
The smart trash bin is the component responsible for collecting all the necessary
information needed to produce a solid waste collection report. It is made up with level sensor,
weight sensor, RFID sensor, and microcontroller and GSM module as illustrated in Figure 2. It is
mainly hardware and it is the first component of the system chain. Weight and level sensors are
responsible for gathering the data related to the weight and the level of garbage inside the trash
bin, and the RFID sensor is responsible for gathering the identity of the solid waste collector
agents when they come to collect waste. The microcontroller acts as a processing unit at the level
of the smart bin, which receives the data from the sensors and processes it before sending it to
the communication module, which in turn sends it to the remote server. The communication
module here is responsible for establishing remote communication between the smart trash bin
and the remote server.
Figure 2: Block Diagram of the Smart trash bin
Two operating modes are available for the smart bin, a mode for normal monitoring
(updating the trash bin status), and a mode for the collection process (recording the
performances of the collector agents). The flowcharts of these two operating modes are given in
appendix 1.
25
2.4.2 Middleware
The middleware is the interface used to interconnect all the main components of the
system (trash bin and web app). Since the smart bin cannot directly send the information it
gathers to the web app, it sends it first to the middleware, which in our case is a database on a
remote web server, then the web app accesses the information sent by the smart bin from the
database. The web server allows communication between the smart bin and the app, processes
and stores the data, and allows the management of the system database. The trash bin uses HTTP
requests to send out the data to the server, and the app uses SQL queries to access data.
2.4.3 Design of mySWC app
The web application is the component from which users can interact with the system. It
offers a user interface mainly designed in HTML, CSS and JavaScript; and interacts with the
database on the middleware using PHP and MySQL on the backend user. The user interface offers
to the user of the app the ability to manage the entire system. The user can manage the bins in
the system, the personal to be assigned to the collection process with their identities, the
collection agencies (contractors), monitor the status of the bins in real time, etc. The user
interface also allows the generation of reports, which can contain the records of the smart bin in
terms of filling and collection, or the records of the collector agents in terms of the weight they
have collected so far in different areas. The web app we designed has nine main pages described
in Table 2 below.
Since the information to be displayed in the application are dynamic, the data that the
application displays come from the database, which is the interface between the smart trash bin
and the app. The structure of the database that we designed for our app is given in appendix 2.
26
Table 2: Description of main pages of the application
Page Description
- Login page
- Home page Dashboard that leads to different pages of the application
- Monitoring page Page which gives an overview of the condition of all the
bins installed in the municipality
- Map page Which gives a view of the location of all the municipal bins
on the map
- Alert page Shows all the bins that need to be collected
- Report page Gives a report on daily collection activities (garbage
correctly collected, collection agent, time of collection,
weight and level of garbage, etc.).
- Trash bin page Allows the management of trash bin including adding,
deleting and updating trash in the system
- Worker and contractor page Allows the management of collection agent and
contractor including adding, deleting and updating
- And admin page Allows the management of users of the application
including adding, deleting and updating users with
different privileges.
A detailed application map is given in Figure 3 below.
27
Figure 3: Application map
28
Chapter 3 – System implementation
As mentioned in the design section, this project has two main components; a smart trash
bin that sends out the data collected from the field inputs to a central monitoring center; and a
web application that receives and stores data, and allows the management of the system. This
chapter presents the implementation of our system, including the components we used for the
smart bin and the technologies we used for the development of the web application. It also
presents the output of our implementation and the communication principle between the smart
bin and the web app.
3.1 Smart bin
The purpose of the smart trash bin is to collect all the data necessary for the production
of a detailed report on the solid waste collection operation. To do this, the system is composed
of a level sensor, a weight sensor, an RFID reader, a microcontroller and a GSM module as
illustrated in Figure 2. The result of the implementation of the smart trash bin is shown in Figure
4 below.
Figure 4: Smart trash bin Prototype
29
3.1.1 Components used
a. Level sensor
To measure the waste level inside the bin, we used the HC-SR04 ultrasonic level sensor
module shown in Figure 5 below.
Source: (Arduino project Hub, n.d.)
Figure 5: View of Ultrasonic sensor HC-SR04
As shown in Figure 5 above, this sensor has four pins, which are VCC, Trig, Echo, and GND.
VCC and GND are pins dedicated to module power supply (5V), Trig is an input pin to the sensor
and Echo is an output from the sensor. This sensor measures the distance between its position
and an object by emitting a 40 KHz ultrasound which moves through the air and by counting the
time it takes for the sound to travel and bounce towards the module when it encounters an
obstacle in its path (Arduino project Hub, n.d.). This sensor module is intended to work with a
microcontroller that gives the input signal and processes the information from the sensor module
(echo pin) to determine the distance between the object and the module.
b. Weight sensor
To measure the weight of the waste inside the trash bin, we used a 20 kg load cell with
an HX711 amplifier shown in Figure 6 for two main reasons. First, for its insensitivity to
temperature variations, and second, because it does not contain fluids, so it requires no much
30
maintenance. In addition, there is no possibility of contamination of the process if the diaphragm
breaks (Sivaranjith, 2018, section 3).
Source: (Drtorq, 2019)
Figure 6: View of load cells and HX711 Amplifier
Typically, the load cell has four wires labeled by different colors and connected directly
to one side of its body, which are red (E+), black (E-), green (A-) and white (A+). The letter and
sign associated with each wire are used in order to connect the load cell to the HX711 module,
which amplifies the signal and in turn delivers four pins to be connected to the microcontroller.
These pins are VCC and GND to power the module (5V-DC), DT to send the signal to the
microcontroller, and SCK for the module clock input (Circuit4you, 2016). For its easy use with
Arduino, this sensor comes with a free library available online.
c. RFID module
We used the RFID module RFID-RC522 shown in Figure 7 below as component of the
smart bin in order to allow collector agents to scan their ID card when they come to collect waste.
By this action, the smart bin gathers the information stored in the ID card of the agent
(identification number) and sends it to the microcontroller interfaced with the RFID module for
processing and transfer to the monitoring center.
31
Source: (Last minute Engineers, n.d. [a], section 2)
Figure 7: RFID module Reader/Writer (on the left) and RFID tags (on the right)
RFID system consists of two main components, a transponder/tag attached to an object
to be identified, and a Transceiver also known as interrogator/Reader (Last minute Engineers,
n.d. [a], section 1). In our case, the reader used is shown in figure 12 above (on the left side),
while the transponder is a microchip that contains a unique ID number mounted in the ID card
of the agent (on the right side). The working principle of this module consist of an antenna
present in the reader module that generates high frequency electromagnetic field to supply the
tag and read the information encoded on the tag when it is placed in close proximity to the
reader. This module comes also with a library in order to use it easily with Arduino.
d. Communication module
In order to enable our smart bin to communicate remotely with the rest of the system,
we made use of the SIM900A GSM/GPRS shield. SIM900A shield is a GSM modem that uses
mobile network service for making or receiving phone calls, sending or receiving SMS text
messages, connecting to internet through GPRS, TCP/IP, HTTP, and more (Last minute engineers,
n.d. [b]). In our case, we used it to enable the communication between our smart bin and the
web application through internet. The SIM900A GSM/GPRS module is designed with everything
32
necessary to make easy its interfacing with Arduino. Primarily, it has pins that allows it to be
interfaced with microcontroller (Rx and Tx pins), serial port (DB9) that allows a direct interfacing
with a computer, an Antenna for network connection, a SIM card slot, and a DC jack for power
supply. A brief description of a SIM900A module is given in Figure 8 below.
Source: (Poojary, 2017)
Figure 8: Description of the composition of the GSM/GPRS module
The GSM/GPRS module is controlled by a particular type of predefined commands known
as AT-Commands (where AT stands for Attention) in order to make it performs different tasks
such as sending SMS text, MMS, HTTP request, etc. (Electronicforu, 2019, section 1). These
commands may be used with either a computer or a microcontroller such as Arduino interfaced
with the GSM/GPRS module through Rx and Tx pins. This module supports a large number of
different commands depending on the task we want it to perform (Telit, 2016). Some commands
used in our project are given in Table 3 below. These commands allow the GSM/GPRS module to
send data to the remote server via the Internet using the HTTP GET method.
33
Table 3: List of AT-commands used to send out the data from the smart trash bin
AT-Command Description
Configuration
AT+CGATT Attach to or detach from, the terminal to the GPRS service
AT+SAPBR=3,1,”Contype”,”GPRS” Set the connection type to GPRS.
AT+SAPBR=3,1,”APN”,”www” Set the APN. Replace “www” with the APN of the network
used.
AT+SAPBR =1,1 Enable the GPRS
AT+SAPBR=2,1 Query if the connection is setup properly, if we get back a
IP address then we can proceed.
HTTP commands
AT+HTTPINIT Initialize HTTP communication
AT+HTTPPARA=“URL”, ”www” Set the url. Replace www with the address of the webpage
you want to access.
AT+HTTPACTION=0, 1 or 2 Set http action type. Give 0 for GET, 1 POST and 2 for HEAD
type of action
AT+HTTPREAD Read server response after HTTPACTION
AT+HTTPTERM End of communication
Source: (Pujar, n.d.)
e. Microcontroller
As processing unit of the smart trash bin, we used Arduino UNO, which is a cheap
microcontroller that matches our project in terms in terms of number of input/output. Figure 9
below gives a brief description of the Arduino UNO board.
34
Source: (Howedi and Jwaid, 2016, p. 4)
Figure 9: Description of the Arduino board
In order to be interfaced and interact with other components, the Arduino board has
twelve digital pins, which can be configured as input or output, and six analog inputs. Regarding
programming, the board supports the C language; for this task, we used the Arduino Integrated
Development Environment (IDE) to develop our code, which is the default IDE for programming
this board.
3.1.2 Interfacing
Interfacing refers to the wiring of components to allow them to communicate and interact
in order to achieve the overall purpose of the system. As we used Arduino as the processing unit,
all the components of the smart trash bin are interfaced with it as shown in Table 4 below.
35
Table 4: Smart trash bin component wiring table
Component pin Arduino pin
RFID Reader
- SCK 13
- MISO 12
- MOSI 11
- SDA(SS) 10
- RST 9
- 3.3V 3.3V
- GND GND
Level Sensor
- Echo 8
- Trig 7
GSM module
- Rx 6
- Tx 5
- GND GND
Load cell
- DT 4
- SCK 3
Card detection
- Push button (in pull-up resistor mode) 2
3.1.3 Coding
In order to program the Arduino, we used the Arduino IDE Ver. 1.8.13 shown in Figure 10
below. This software is available free on google and can be installed on any computer like any
other software.
36
Figure 10: Capture of the Arduino IDE
The complete Arduino sketch produced for the smart bin is available on GitHub open
source repository.
- Repository name: SmartTrash
- Released link: https://github.com/conordata/SmartTrash
Libraries have been used in this sketch, which are: (1) Adafruit MRF 630 RFID (MFRC522)
for the RFID module, (2) HX711 for load cell (weight sensor), (3) Serial Peripheral Interface (SPI)
for communicating with the RFID module quickly, (4) SoftwareSerial to allow serial
communication on other digital pins of the Arduino (other than Rx pin 0 and Tx pin 1).
37
3.2 mySWC App
The implementation of this element consisted of installing a server, creating a database,
and coding the application using HTML, CSS, JavaScript, SQL, and PHP.
3.2.1 Server setup
In this project, we deployed a local server that allowed us to develop and test the
application locally on our computer. For that, we used XAMPP Server Ver. 3.2.4 shown in Figure
11 below.
Figure 11: XAMPP Control Panel
3.2.2 Database implementation
For the database implementation, we made use of phpMyAdmin, which is a database
management system that comes with the XAMPP server. The home page of this database
management system from which we started to implement the database is displayed as shown in
Figure 12 below.
38
Figure 12: phpMyAdmin Home page
3.2.3 Application coding
The last task of the mySWC implementation was coding the application using web
technologies. For that, we used the Sublime text editor Ver. 3.2.2 as IDE. The development
component of this application is available on GitHub.
- Repository name: myswc
- Released link: https://github.com/conordata/myswc
a. Program Architecture
In order to make our code easy to understand and to maintain, we structured our
application following the Model-View-Controller (MVC) model, which consisted of separating our
application into three main logical components, the model, the view and the controller that each
handle a specific aspect of our app. An architectural diagram of the MVC model is shown in Figure
13 below.
39
Source: (Guru99, n.d., section 4)
Figure 13: MVC architecture diagram
The Model component handles all the data-related logic that the user works with, such
as retrieving information from the database, manipulate it and update it data back to the
database or use it to render data. The View component refers to all the elements of the user
interface logic of the application such as text boxes, dropdowns, form, etc. And the controller
acts as an interface between Model and View components to process all the logic and incoming
requests such as the interactions and inputs form, manipulates data using the Model component
and interacts with the Views to render the final output (Tutorialspoint, n.d., section 1). Likewise,
we put all the files relating to the view (design, table, form, etc.) in the main folder of the
application. The files which contain all the constructors and methods to extract and insert data
into the database (interact with the database) in the modals folder, and the files which handle
user interaction like form submission, updates, deletion of records, etc. in the controllers folder.
40
b. Technologies used
Nowadays, several web technologies are available to help the development of interesting
web applications in the easiest way. For our app, we used the JavaScript library jquery-3.4.1 for
auto-refreshing the table of data in the monitoring page as shown in Figure 14 below. We also
used the Google map API in the map view page to display the location of the saved trash on a city
map. Apart from the library and the API, the rest of the application is made up with native
technologies (no framework or further libraries).
Figure 14: Capture of the script used for the auto refresh of the table in the monitoring page
We used HTML5, CSS3, and JavaScript for the design of the front-end user of the
application, and SQL and PHP for the back-end user. HTML and CSS can be seen in almost the files
of the view component of the app. As for JavaScript, we mainly used it in:
 monitoring page for auto refreshing a specific part of the page
 map view to display the location of trash bin registered in the system on a map of
the municipality
41
 Collector agent and collected bin pages for data filter and dynamic average
calculation.
 And input validation.
3.2.4 Implementation output
a. Home page
The home page of our app is a dashboard that shows different options available on the
side bar and the main body as shown in Figure 15 below; each option leads to a specific page.
Figure 15: Screenshot of the home page
b. Monitoring page
The monitoring page of the app shows in real time the status of all the municipal bins
including:
 the id of the trash (as each trash is referred with a unique Id)
 the type of the bin (which can be seen by hovering over the bin ID in the table)
 the longitude and latitude of the bin location
42
 the area or local body where the bin is affected
 the current level and weight of garbage inside the bin
 the current status of the trash bin (normal – if the level is under the alert limit,
collection requested – if the level is under the alert limit but the garbage lasts for
more than 4 days, or alert – if the level of the trash bin is beyond the alert limit)
 the last time the data has been updated
 and the duration since the first garbage has been thrown in the bin.
The Figure 16 below gives a view of the monitoring page.
Figure 16: Screenshot of the monitoring page
c. Alert page
This page displays the full bins that need to be collected. It shows the id of the trash bin,
the longitude and latitude, the area where the trash is installed, the current level and weight of
garbage inside the bin, the time when the bin got full and the duration since it got full as shown
in Figure 17. The threshold to change the bin status from normal to alert and display it on this
page is set in the newHistoric.php controller. It is up to the system administrator to modify this
43
value as he wishes according to his expectations. In our case, we have set the threshold at 80%
of the filling level.
Figure 17: Screenshot of the alert page
d. Collected bin (in daily report)
This page displays all the bins collected during a given period. It shows the bin ID,
longitude and latitude, the area where the bin is installed, the level and weight that was collected,
the time the bin became full, the length of time it remained full before the collection took place,
and the identity of the agent who collected the bin as shown in Figure 18.
Three input fields are available on this page; at the top right are fields where we can
submit the period we want to display going from one given date to another; and at the left top
of the table is a field where we can filter the contents of the table by area.
44
Figure 18: Screenshot of the collected trash bin page
e. Collector agent page (in daily report)
This page displays all the collector agents involved in the municipal solid waste collection.
It shows the agent ID, full name, the area where the agent is affected, the organization where he
belongs (internal – if he is a municipal or public worker), and the cumulated weight during a given
period.
Similarly, three input fields are also available on this page; at the top right are fields where
we can submit a starting and ending date in order to see the quantity of waste a given agent has
collected in a particular period. At the top left of the table is a field where we can filter the
contents of the table by contractor.
f. Other pages
Other pages of the application are for the management of logistics part such as workers,
contractors, app users and trash bin. Details on these pages of the app are given in Table 2.
45
3.3 Communication between smart trash bin and mySWC
Our Iot system has four components in its value chain, from the measurement of
parameters in the smart bin to the web application.
- First, we have three sensors mounted directly in the trash bin in order to collect information
(level, weight and ID). These sensors are connected to the digital pin of Arduino, which is the
processing unit of the system.
- Second, the Arduino board receives the information from the sensors and processes it in
terms of calculating and converting the data type before sending it to the GSM/GPRS module
(SIM900A), which is responsible for sending the data to the web application using the HTTP
GET request. The GSM module is connected to the Arduino as well, and receives instructions
from it in form of AT-Commands shown in Table 3.
- Thirdly, once the Arduino has sent AT commands containing the data to send to the
application, the GSM/GPRS module in turn sends an HTTP GET request to the web app
controller hosted on an online server. The GSM/GPRS module uses the GPRS service of the
mobile or cellular network (depending on the SIM card used) which allows it to communicate
via the Internet.
- Fourth, the web application receives the request sent by the GSM/GPRS module in the
controller, uses a PHP GET method to retrieve the sent data and an SQL query to insert the
data into the database from which it can be accessed for different purposes.
The diagram architecture in Figure 19 below illustrates the communication principle
between the smart trash bin and the Web app.
46
Figure 19: System diagram architecture
47
3.3.1 HTTP request
HTTP is an Internet protocol that functions as a request-response mode between devices
designed to allow communications between clients and servers (W3C, n.d.). Typically, the client
(which can be a browser or any other device) sends an HTTP request to the server, and then the
server returns responses to the client with information containing the status of the request or
the requested content. To send the HTTP request to a server, there are different methods that
can be used such as POST, GET, HEAD, etc., each with its own advantages and disadvantages.
Likewise, in our system we have the smart trash bin, which is seen as a client sending requests to
an online server using GET method.
3.3.2 Sending the data
As mentioned earlier, data is sent to the server using the HTTP GET request, which is one
of the most common HTTP methods. With this method, the HTTP URL contains a variable
name/value query string as follows:
Server_address/path_of_the_file/file_to_reach.php?name1=value1&name2=value2
Similarly, this same principal is used in the smart trash bin in order to send the data to the
web app as shown in Figure 20 below.
Figure 20: URL construction (HTTP GET request)
48
In the same way that it is possible to embed HTML tags in PHP code using the “echo”
function, Arduino uses the same principle by embedding AT command instructions using the
“Print” function in order to execute them via serial communication between the Arduino board
and the GSM/GPRS module. The full step-by-step AT instructions (AT commands) used with
Arduino to send the data to the server (web application) are given in Table 3.
3.3.3 Receiving the data
To receive the data sent from the smart bin, two controllers are available in the web
application; one to receive the normal trash bin status updates for real-time monitoring, and the
other to receive the trash bin collection updates (of course, the smart trash bin sends requests
to these two controllers separately). These two controllers are newHistoric.php and
newScan.php. Once the controller receives the HTTP request, it executes a GET method in order
to retrieve the value sent in the URL and insert it into the database as shown in Figure 21 below.
Figure 21: Capture the script to retrieve the data sent in the URL (newHistoric.php).
49
Chapter 4 – Test and Evaluation
After the design and implementation of our system (smart bin and web application), this
chapter presents the result of the test we performed on the two components and the evaluation
of the system in order to answer our research question. The chapter presents the results of three
different tests of the system. First, it presents the accuracy test result of the smart bin to report
correct values; second, the test result of the web application in different use cases and its
compliance with the W3C standard; and third, the result of the communication between the
smart trash bin and the web application. Regarding the evaluation, the chapter shows how the
system fulfills a set of criteria or properties in order to determine how well the system answers
the research question.
4.1 Test
4.1.1 Smart trash bin
For the smart trash bin test, we used the Arduino “Serial.print” function that allowed us
to directly see the data measured by the sensors in the Arduino serial monitor as shown in Figure
22 below.
Figure 22: View of values measured in Arduino serial monitor
We performed a test on the accuracy of the weight sensor, as well as the accuracy of the
level sensor. For the weight sensor, we first had to calibrate the load cell to determine the
50
calibration factor, and then we performed tests using known weight shown in Figure 23 to see
how well the sensor reports the values correctly. For the level sensor, we have placed objects
inside the bin with different filling levels, we have measured the height for each filling level with
a ruler, and we compared the measured values and the reported values of the sensor in the serial
monitor.
Figure 23: weights used to test the load cell (weight sensor)
Regarding the weight sensor, the result shows that the load cell measures the weight with
a tolerance of +0.03 kg, which is quite acceptable given the application. However, to only work
with integer values, we used the Arduino “round” function, which changed the tolerance from
+0.03 to +/- 0.5 kg. Regarding the level sensor, the result shows that the sensor is not stable but
reports values almost close to the real values. The instability of the sensor is due to the fact that
the sensor is primarily intended for measuring distance with a flat reflecting surface, however,
the garbage inside the bin does not always offer this possibility. The result of this test is presented
in Table 5 below.
51
Table 5: Result of the test of accuracy of the smart trash bin
Input value Measured value Exact value
Weight Sensor
1 kg 1.03 kg 1 kg
1.5 kg 1.53 kg 1.5 kg
Level Sensor (trash bin depth: 18 cm)
18 cm 0% 0%
13 cm 33% 27%
8 cm 61% 55%
3 cm 94% 83%
4.1.2 Web app
For the web application, we first performed a W3C standard compliance test using the
W3C validator tool, which showed no HTML, CSS or JavaScript errors in our code (see the results
in appendix 3). The only errors that appeared was related to the PHP code present in the code.
Second, we performed user experience testing including adding, deleting, and updating trash bin,
workers, contractors, and app users. This test did not show any errors or malfunctions. We also
did a communication test without the smart trash bin to see how the application responds to the
HTTP request in localhost thanks to POSTMAN, which is a software that allows sending HTTP
requests to a server with different methods. The user interface of the POSTMAN software that
we used for this test is given in Figure 24 below. This test was primarily intended to test the
monitoring page, alert page, collected bin page, and collection agent page. To test the monitoring
and alert pages, we did the test with ten different bins for which we sent different weight and
level values, and for the collection, we did the test with two collection agents. This test also did
not show any errors in the operation of the system.
52
Figure 24: View of POSTMAN software
4.1.3 Communication
We were not able to test the communication between the smart trash bin and the web
app in localhost. To perform this test, we used 000webhost, which is an online web server that
offers limited free services. We hosted our application there, created a database and imported
our app's database dump using the database manager offered by the server. Next, we imported
all the files of our application into the public_html folder of the server. Finally, in the Arduino
sketch, we put in the URL part of the code the address of our online website as the address to
which the trash bin should send the data, which are:
- myswc-
monitoring.000webhostapp.com/controllers/newHistoric.php?idTrash=value1&level=value
2&weight=value3 – For monitoring (normal update)
- myswc-
monitoring.000webhostapp.com/controllers/newScan.php?idTrash=value1&idWorker=valu
e2 – For collection request
53
When sending HTTP requests with the smart trash bin, the server may return two different
responses:
- 601: indicates that there is a network error
- 200: indicates that the request has succeeded
This test also did not show any errors in the operation of the system.
4.2 Evaluation
The research question in this project is how the use of IoT can help to optimize the
efficiency of MSW collection. To answer this question, our hypothesis was that the IoT-based
system could help optimize MSW collection by solving the problems related to lack of accurate
information in the collection operation. Therefore, we developed two artifacts, a smart bin and
a web app that can help to collect accurate data, thereby contributing to the optimization of
MSW collection.
To evaluate this, we have developed in the literature review characteristics or criteria
(given in Table 1) that our system should integrate in order to resolve the MSW collection
information gap. Next, we selected six properties from a list of properties that can be applied to
assess software and hardware artifact proposed by Mijač (2019, p. 318) in order to evaluate how
well the system is achieving its goal and how it answers the research question. The list of all
properties is given in appendix 4. As properties for the evaluation, we have retained those with
an occurrence frequency greater than or equal to ten percent, which are:
1. Efficacy
System efficacy refers to how well the system achieves the purposes for which it was set
up. In our case, the purpose of the system is to collect accurate information or data in the MSW
collection operation that can help improve the efficiency of the operation. The system we have
built collects information on the weight of waste generated in different areas, information on the
filling level of the bins in real time, and information on the collection agents involved in the solid
54
waste collection program. However, it does not have any mechanism to determine the type of
waste inside the bin.
2. Usefulness
By collecting information on the solid waste collection operation, the system is useful to
the municipality in terms of giving the municipal authorities an overview on the collection
operation that can help them in decision-making, on the amount of waste generated by
residents, as well as on municipal agents assigned to the solid waste collection program. By giving
this overview, the usefulness of the system can be manifested in terms of avoiding waste
overflows, supporting the value for money, and accurate quantification of the waste generated.
In addition, it can be useful in assisting city’s authorities to focus their efforts and attention where
and when it is most needed.
3. Accuracy
The result of the test performed in the previous section shows that the system collects
data related to the weight and the collection agents assigned to the collection program very well.
However, concerning the level measurement, the system presents some inaccuracies.
4. Robustness
Robustness refers to the system's ability to handle invalid inputs. Regarding input from
app users, the app has input validation functionality implemented with JavaScript in the front-
end user, and empty field validation for mandatory fields implemented with PHP in the back-end
user. Regarding input data from smart bins, the app has a function to check whether the smart
bin that sends the data is registered in the system or not, as well as a function that checks if the
worker that sends the data is a registered worker. Hence, the system blocks the invalid entries
on the front-end and the back-end user. As for the smart bin, the system has three data entries,
which are level sensor, weight sensor and RFID reader. Here the system is less robust as it is open
to everyone (public) and does not have a system to check who uses the bin and how he uses it.
55
5. Scalability
The web server on which the application is hosted is the element that defines the
scalability of this system. Smart bins are considered here as clients of the server. There can be as
many as the server can support in terms of the number of requests and storage space available
on the server.
6. Operational feasibility
Operational feasibility refers to how management, employees and other stakeholders will
operate our system and integrate it into their daily practice. Regarding management, the
municipality can use this system to manage workers, contractors, smart bins in the system and
app users. The contractors can also use this system to manage their own workers at their level,
and monitor in real time the status of bins that are under their responsibility. Employees or
collection agents will use the system to record their performance in terms of the amount of waste
they collect, as well as their punctuality for the task by scanning their identity card each time they
come to collect the garbage. All stakeholders involved in this system could use this system
whether it is for monitoring only (receiving collection alert), personnel management or the use
of data on the production and collection of solid waste.
The extent to which our system can help the municipality to collect accurate information
is mainly defined by the accuracy of the smart bin and the robustness of the system in handling
invalid data. These two factors are key elements in solving the problem of transparency in the
collection process, imprecise weighing, as well as the problem of garbage overflow by correctly
reporting data and blocking invalid entries that can cause errors in the data processing.
When it comes to the efficiency of MSW collection, this IoT-based system can help
optimize it in case the system is accurate, robust, used appropriately, and successfully achieves
its purpose. Hence, the system can help optimize the efficiency of the solid waste collection
activity by promoting PRP system as it gathers all the information necessary to facilitate such a
practice (worker performance monitoring). According to Unger, Szczesny and Holderried (2020,
p. 10), implementing a PRP system can lead to an increase in employee productivity of up to 23%.
In fact, with such a practice, it is expected that workers and contractors will intend to maximize
56
their income by collecting as much solid waste as possible, thus avoiding the overflow of garbage
and the collection delays (IvyPanda, 2019, section 2). Apart from this, the system can aid in
decision making with its ability to report waste generation by area and worker performances.
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection
Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection

More Related Content

Similar to Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection

WIPAC Monthly - May 2022
WIPAC Monthly - May 2022WIPAC Monthly - May 2022
WIPAC Monthly - October 2020
WIPAC Monthly - October 2020WIPAC Monthly - October 2020
WIPAC Monthly - October 2020
Water Industry Process Automation & Control
 
WIPAC Monthly October 2018
WIPAC Monthly  October 2018WIPAC Monthly  October 2018
WIPAC Monthly August 2020
WIPAC Monthly August 2020WIPAC Monthly August 2020
Metal recycling
Metal recyclingMetal recycling
Metal recycling
Muhammad Amien
 
WIPAC Monthly - November & December 2023
WIPAC Monthly - November & December  2023WIPAC Monthly - November & December  2023
WIPAC Monthly - November & December 2023
Water Industry Process Automation & Control
 
common_report_2
common_report_2common_report_2
common_report_2RAHEEMA PP
 
Design of IOT Garbage Monitoring with Weight Sensing
Design of IOT Garbage Monitoring with Weight SensingDesign of IOT Garbage Monitoring with Weight Sensing
Design of IOT Garbage Monitoring with Weight Sensing
IRJET Journal
 
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
Tom Robinson
 
WIPAC Monthly August 2021
WIPAC Monthly August 2021WIPAC Monthly August 2021
Smart waste management in Schiedam
Smart waste management in SchiedamSmart waste management in Schiedam
Smart waste management in Schiedam
TECNIO Centre EASY & Smart Cities Master
 
Solid Waste Management
Solid Waste ManagementSolid Waste Management
Solid Waste Management
Minza Mumtaz
 
Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control
 
IoT Based Smart Trash Bins – A Step Toward Smart City
IoT Based Smart Trash Bins – A Step Toward Smart CityIoT Based Smart Trash Bins – A Step Toward Smart City
IoT Based Smart Trash Bins – A Step Toward Smart City
IRJET Journal
 
Smart Communities: Rethinking Infrastructure
Smart Communities: Rethinking InfrastructureSmart Communities: Rethinking Infrastructure
Smart Communities: Rethinking Infrastructure
Samantha Wagner
 
Digital business ecosystems
Digital business ecosystemsDigital business ecosystems
Digital business ecosystems
Yam Montaña
 
WIPAC Monthly - December 2021
WIPAC Monthly - December 2021WIPAC Monthly - December 2021
WIPAC Monthly - December 2021
Water Industry Process Automation & Control
 
WIPAC Monthly - January 2023.pdf
WIPAC Monthly - January 2023.pdfWIPAC Monthly - January 2023.pdf
WIPAC Monthly - January 2023.pdf
Water Industry Process Automation & Control
 
IRJET- Smart Waste Segregator and Monitoring System
IRJET- Smart Waste Segregator and Monitoring SystemIRJET- Smart Waste Segregator and Monitoring System
IRJET- Smart Waste Segregator and Monitoring System
IRJET Journal
 
Internet of Things- IoT (application to waste management)
Internet of Things- IoT (application to waste management)Internet of Things- IoT (application to waste management)
Internet of Things- IoT (application to waste management)
Minza Mumtaz
 

Similar to Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection (20)

WIPAC Monthly - May 2022
WIPAC Monthly - May 2022WIPAC Monthly - May 2022
WIPAC Monthly - May 2022
 
WIPAC Monthly - October 2020
WIPAC Monthly - October 2020WIPAC Monthly - October 2020
WIPAC Monthly - October 2020
 
WIPAC Monthly October 2018
WIPAC Monthly  October 2018WIPAC Monthly  October 2018
WIPAC Monthly October 2018
 
WIPAC Monthly August 2020
WIPAC Monthly August 2020WIPAC Monthly August 2020
WIPAC Monthly August 2020
 
Metal recycling
Metal recyclingMetal recycling
Metal recycling
 
WIPAC Monthly - November & December 2023
WIPAC Monthly - November & December  2023WIPAC Monthly - November & December  2023
WIPAC Monthly - November & December 2023
 
common_report_2
common_report_2common_report_2
common_report_2
 
Design of IOT Garbage Monitoring with Weight Sensing
Design of IOT Garbage Monitoring with Weight SensingDesign of IOT Garbage Monitoring with Weight Sensing
Design of IOT Garbage Monitoring with Weight Sensing
 
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
A Global Web Enablement Framework for Small Charities and Voluntary Sector Or...
 
WIPAC Monthly August 2021
WIPAC Monthly August 2021WIPAC Monthly August 2021
WIPAC Monthly August 2021
 
Smart waste management in Schiedam
Smart waste management in SchiedamSmart waste management in Schiedam
Smart waste management in Schiedam
 
Solid Waste Management
Solid Waste ManagementSolid Waste Management
Solid Waste Management
 
Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024
 
IoT Based Smart Trash Bins – A Step Toward Smart City
IoT Based Smart Trash Bins – A Step Toward Smart CityIoT Based Smart Trash Bins – A Step Toward Smart City
IoT Based Smart Trash Bins – A Step Toward Smart City
 
Smart Communities: Rethinking Infrastructure
Smart Communities: Rethinking InfrastructureSmart Communities: Rethinking Infrastructure
Smart Communities: Rethinking Infrastructure
 
Digital business ecosystems
Digital business ecosystemsDigital business ecosystems
Digital business ecosystems
 
WIPAC Monthly - December 2021
WIPAC Monthly - December 2021WIPAC Monthly - December 2021
WIPAC Monthly - December 2021
 
WIPAC Monthly - January 2023.pdf
WIPAC Monthly - January 2023.pdfWIPAC Monthly - January 2023.pdf
WIPAC Monthly - January 2023.pdf
 
IRJET- Smart Waste Segregator and Monitoring System
IRJET- Smart Waste Segregator and Monitoring SystemIRJET- Smart Waste Segregator and Monitoring System
IRJET- Smart Waste Segregator and Monitoring System
 
Internet of Things- IoT (application to waste management)
Internet of Things- IoT (application to waste management)Internet of Things- IoT (application to waste management)
Internet of Things- IoT (application to waste management)
 

Recently uploaded

HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
Robbie Edward Sayers
 
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
ssuser7dcef0
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
BrazilAccount1
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Dr.Costas Sachpazis
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
Kamal Acharya
 
Unbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptxUnbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptx
ChristineTorrepenida1
 
DfMAy 2024 - key insights and contributions
DfMAy 2024 - key insights and contributionsDfMAy 2024 - key insights and contributions
DfMAy 2024 - key insights and contributions
gestioneergodomus
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
TeeVichai
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
Neometrix_Engineering_Pvt_Ltd
 
Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdfWater Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation & Control
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
Massimo Talia
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
SamSarthak3
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
FluxPrime1
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
gdsczhcet
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
MdTanvirMahtab2
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
Vijay Dialani, PhD
 

Recently uploaded (20)

HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
 
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
 
Unbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptxUnbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptx
 
DfMAy 2024 - key insights and contributions
DfMAy 2024 - key insights and contributionsDfMAy 2024 - key insights and contributions
DfMAy 2024 - key insights and contributions
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
 
Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdfWater Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdf
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
 

Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection

  • 1. Design of an IoT-based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection ILUNGA WA LUNDA ARIEL B00382810 Thesis Project for the partial fulfilment of the requirements for the Master Degree in Information Technology / Advanced Computer Systems Development University of the West of Scotland School of Computing 11th /01/2021
  • 2. DECLARATION OF ORIGINALITY I declare that this is an original study based on my own work and that I have not submitted it for any other course or degree. Signature__________________________
  • 3. Library Release Form Surname: WA LUNDA First Name: ILUNGA Initials: ARIEL Banner No: B00382810 Course Code: COMP11024_01 Course Title: Masters Project Project Supervisor: Dr. RACHNA SHARMA Project Title: “Design of an IoT based monitoring system with automatic daily report generator to optimize the efficiency of municipal solid waste collection“ Session: 2020-21 Date of Submission: 11th/01/2021 Signature:
  • 4. i Abstract The collection of municipal solid waste (MSW) generated by residents is one of the biggest challenges facing municipalities around the world due to population growth, which leads to an increase in solid waste production. One of the important requirements to face this challenge is to collect and share information on the collection operation in order to allow municipal authorities and stakeholders to work together and provide a quality service according to the real needs of the municipality. This research addresses the problem of the lack of information in the solid waste collection operation by proposing an IoT-based system that collects relevant information and generates a daily report on the MSW collection. The proposed system uses sensors, microcontroller, wireless network and web technologies to produce two artifacts, a smart trash bin and a web application, to monitor the status of the trash bin in real time, collect information on waste generation, monitor the performance of workers assigned to the MSW collection program, and generate reports. The result of the artefact evaluation showed that the system is able to help improve the MSW collection by increasing the performance of the workers involved in the collection program. Key words: solid waste collection, monitoring system, Internet of Things, smart trash bin, report generator
  • 5. ii Acknowledgements Before going any further in this work, I would like to thank Dr Rachna Sharma for supervising this work with too much attention and pedagogy. I would like to thank the MSc Program leader, Dr Graeme McRobbie, for his expert advice throughout this work. I would like to thank all the UWS and ISBC staff for creating this opportunity to complete our master's degree in good conditions despite the current health crisis. I would also like to thank my family members, brothers and sisters for their support and encouragement. I also say thank you to everyone who in one way or another has contributed to the successful completion of this work. ILUNGA WA LUNDA ARIEL
  • 6. iii Table of contents Table of contents ............................................................................................................................iii List of figures....................................................................................................................................v List of tables....................................................................................................................................vi Introduction .................................................................................................................................... 1 Chapter 1 – Literature review......................................................................................................... 4 1.1 Overview of municipal solid waste collection.................................................................. 4 1.1.1 Solid waste generation and composition ................................................................. 5 1.1.2 Collection of solid waste and stakeholders .............................................................. 5 1.1.3 Why Monitor MSW Collection.................................................................................. 6 1.2 Challenges and Needs for efficient MSW collection........................................................ 7 1.3 Brief case studies of MSW collection............................................................................... 9 1.3.1 South Korea............................................................................................................... 9 1.3.2 Toronto, Canada ..................................................................................................... 10 1.3.3 India ........................................................................................................................ 11 1.3.4 Bangalore, India ...................................................................................................... 12 1.4 IoT-based solutions for efficient MSW collection.......................................................... 12 1.5 Summary ........................................................................................................................ 17 Chapter 2 – Methodology............................................................................................................. 19 2.1 Research approach......................................................................................................... 19 2.2 System development model .......................................................................................... 20 2.3 System requirements..................................................................................................... 21 2.4 System design................................................................................................................. 23 2.4.1 Smart Trash bin design............................................................................................ 24 2.4.2 Middleware............................................................................................................. 25 2.4.3 Design of mySWC app............................................................................................. 25 Chapter 3 – System implementation............................................................................................ 28 3.1 Smart bin........................................................................................................................ 28 3.1.1 Components used ................................................................................................... 29
  • 7. iv 3.1.2 Interfacing............................................................................................................... 34 3.1.3 Coding ..................................................................................................................... 35 3.2 mySWC App.................................................................................................................... 37 3.2.1 Server setup............................................................................................................ 37 3.2.2 Database implementation ...................................................................................... 37 3.2.3 Application coding .................................................................................................. 38 3.2.4 Implementation output .......................................................................................... 41 3.3 Communication between smart trash bin and mySWC................................................. 45 3.3.1 HTTP request........................................................................................................... 47 3.3.2 Sending the data..................................................................................................... 47 3.3.3 Receiving the data................................................................................................... 48 Chapter 4 – Test and Evaluation................................................................................................... 49 4.1 Test................................................................................................................................. 49 4.1.1 Smart trash bin........................................................................................................ 49 4.1.2 Web app.................................................................................................................. 51 4.1.3 Communication....................................................................................................... 52 4.2 Evaluation....................................................................................................................... 53 Conclusion..................................................................................................................................... 57 Critical self-evaluation .................................................................................................................. 58 a. Project idea and relationship to mobile web development stream.................................. 58 b. Research approach ............................................................................................................ 59 c. Research objectives ........................................................................................................... 60 d. Personal benefit................................................................................................................. 60 References .................................................................................................................................... 61 Appendix 1: Flowcharts of smart trash bin operating modes ...................................................... 69 Appendix 2: Application Database structure................................................................................ 71 Appendix 3: W3C compliance test results.................................................................................... 72 Appendix 4: List of the properties for evaluating instantiation artifacts ..................................... 74 Project specification......................................................................... Error! Bookmark not defined.
  • 8. v List of figures Figure 1: Software Development Life Cycle.................................................................................. 21 Figure 2: Block Diagram of the Smart trash bin............................................................................ 24 Figure 3: Application map............................................................................................................. 27 Figure 4: Smart trash bin Prototype ............................................................................................. 28 Figure 5: View of Ultrasonic sensor HC-SR04 ............................................................................... 29 Figure 6: View of load cells and HX711 Amplifier......................................................................... 30 Figure 7: RFID module Reader/Writer (on the left) and RFID tags (on the right) ........................ 31 Figure 8: Description of the composition of the GSM/GPRS module........................................... 32 Figure 9: Description of the Arduino board.................................................................................. 34 Figure 10: Capture of the Arduino IDE.......................................................................................... 36 Figure 11: XAMPP Control Panel................................................................................................... 37 Figure 12: phpMyAdmin Home page............................................................................................ 38 Figure 13: MVC architecture diagram........................................................................................... 39 Figure 14: Capture of the script used for the auto refresh of the table in the monitoring page. 40 Figure 15: Screenshot of the home page...................................................................................... 41 Figure 16: Screenshot of the monitoring page............................................................................. 42 Figure 17: Screenshot of the alert page........................................................................................ 43 Figure 18: Screenshot of the collected trash bin page ................................................................. 44 Figure 19: System diagram architecture....................................................................................... 46 Figure 20: URL construction (HTTP GET request) ......................................................................... 47 Figure 21: Capture the script to retrieve the data sent in the URL (newHistoric.php). ............... 48 Figure 22: View of values measured in Arduino serial monitor ................................................... 49 Figure 23: weights used to test the load cell (weight sensor)...................................................... 50 Figure 24: View of POSTMAN software ........................................................................................ 52
  • 9. vi List of tables Table 1: Summary of main features of the system....................................................................... 22 Table 2: Description of main pages of the application................................................................. 26 Table 3: List of AT-commands used to send out the data from the smart trash bin ................... 33 Table 4: Smart trash bin component wiring table........................................................................ 35 Table 5: Result of the test of accuracy of the smart trash bin ..................................................... 51
  • 10. 1 Introduction Nowadays, solid waste management is one of the most import challenges in urban areas throughout the world and it is becoming a critical issue in developing countries where a rapid increase in population has been observed. It encompasses the collection, the treatment, and the disposal of solid material that is no longer useful and aims to protect human and environment from adverse impacts of solid waste such as the transmission of diseases, the air pollution, the greenhouse effect, etc., which can result from the mismanagement of solid waste material in a municipality. To manage MSW properly, it is necessary to collect the solid waste generated by the inhabitants of the municipality efficiently, to quantify and sort it accurately, and to treat it in an appropriate manner. All these conditions for achieving an effective municipal solid waste management (MSWM) system involve a challenging implementation of adequate infrastructure and technologies at all levels of the management process, from production to final disposal of solid waste. From production to the final disposal of municipal solid waste, the intermediate activities (collection, transport, treatment and disposal) are completely separate steps from each other. Although they can be managed by a single authorized entity or by different organizations working together for a healthy environment; the infrastructures, technology, and logistics used for collection, transport, treatment and disposal are always different. The collection always consists of picking up solid waste from different sources of generation in the municipality to the next level of the process; the treatment of solid waste may consist of reusing, recycling, composting, sorting, etc. depending upon the type of waste; and the disposal of waste may consist of incineration, landfill, etc. Thus, most of the time it is necessary to pay attention to each activity separately as they deal with different inputs, have different purposes and require different infrastructure and logistics. Therefore, we focus our work on municipal solid waste collection (MSW) by proposing an IoT-based monitoring system with an automatic daily report generator to help obtain reliable data of MSW collection operation, which can be used to optimize the efficiency of this operation.
  • 11. 2 Several researchers have carried out work on optimizing the efficiency of MSW collection using IoT technology and have found favorable results. Most of them have been able to address the challenges of cost savings, citizen participation in the solid waste collection activity, individual safety seen in some practices, overflow of garbage bins, etc. However, they do not address the question of collecting reliable data on everyday municipal solid waste collection operations. In this project, we address the problem of lack of reliable information in MSW collection, which raises the research question of how using an IoT-based system to collect data can help optimize the efficiency of MSW collection. Our assumption to this question is that IoT can help improve the collection of MSW by collecting information on waste generation, stakeholders and trash bin status. In fact, one of the main keys to improve any activity in a particular domain and maximize its efficiency is to be aware of current situations and practices in that domain. Since municipal solid waste management is a process that involves different participants such as workers, partners, contractors, and municipal authorities; transparency, accountability and the exchange of accurate information or data between participants are probably needed to achieve the expected results. Accordingly, in the case of solid waste collection, some analyzes suggest that reliable data can solve problems that can arise from the fact that the municipality does not obtain reliable information on this activity. Thus, this work is put in order to address this gap and provide the municipality with a mechanism able to generate reliable reports on garbage collection and all the stakeholders engaged in the MSW management on a regular basis, which can be used to guide authorities in the process of maximizing efficiency. The overall aim of this work is to develop a system that enables an accurate gathering of data that can be used to improve the efficiency of MSW collection, thereby provide a healthy environment, then, evaluate it and determine in what measure it can optimize the efficiency of the MSW collection. To do this, the key aim of this work is to design and implement an IoT-based system, which includes a web application and a smart bin for monitoring and data acquisition respectively, in order to produce relevant and reliable daily information (relevant data) of all activities on the trash bin, thereby on the MSW collection operation.
  • 12. 3 To achieve the aim of the project, specific objectives are: (1) to identify the system requirement for the system to design through the review of the literature; (2) to develop a web app and a smart trash bin prototype using HTML, CSS, JavaScript, PHP, SQL, microcontroller, communication module, sensors, etc.; (3) to test the web app and the smart bin in laboratory, and evaluate whether the requirements have been met based on academic theories. The test of the smart bin consist of verifying the response and the accuracy of sensors in different scenarios of bin filling. The test of the web application consist of verifying the response and the behavior of the application from different requests of the smart bin and generating report based on different scenarios. The work has two mains parts, a dissertation part and a development part. The dissertation part is structured around four main chapters apart from the introduction and the conclusion. The first chapter gives the background of our project. It focuses on highlighting current issues, challenges and needs in MSW collection, and analyzes gaps in the existing knowledge regarding IoT-based solution for efficient MSW collection. The second chapter presents the methodology used to achieve the overall goal of the project. It presents the research approach we adopted, the chosen software development model, the system requirements and the system design. The third chapter deals with the implementation of the web application and the prototype of the smart trash bin. It shows the components and technologies used, and the outcome of the implementation. Finally, the fourth chapter gives the result of the test and evaluation of the produced system. The development part of the work has two components, a web application and a smart bin. The code for these two components is available on the GitHub repositories given below: Web application - Repository name: myswc - Released link: https://github.com/conordata/myswc Smart bin - Repository name: SmartTrash - Released link: https://github.com/conordata/SmartTrash
  • 13. 4 Chapter 1 – Literature review The aim of this chapter is to give the necessary background of our project. First, we give an overview of the municipal solid waste (MSW) collection, in which we highlight different sources of generation and the MSW composition, the solid waste collection and stakeholders of this operation, as well as the reason why it can be important to monitor the collection of MSW. Second, we analyze the challenges and needs for efficient MSW collection and highlights existing issues encountered in the collection and transport of MSW. Third, we provide some information that result from countries and cities across the world that use, as well as that do not use technology or information system in the collection and transport of MSW. This analysis illustrates what may be the expectation of using information system in the MSW collection, and assures that implementing an IoT-based solution for MSW collection may help in some extent. Third, we analyze existing IoT-based solutions for efficient MSW collection proposed by different researchers. This survey analyzes strengths and weaknesses of existing solutions to meet current needs for efficient solid waste collection. Finally, we outline how this project addresses the problem of gathering relevant and accurate information of MSW collection. 1.1 Overview of municipal solid waste collection According to Nathanson (2020, Section 4), the collection of MSW is a public service that has important impacts on public health and the appearance of towns and cities. It consists of implementing strategies and deploying necessary logistics to pick up (collect) and transport in an appropriate manner solid waste generated by residents to a determined destination. The strategy implementation for collecting and transporting MSW includes the definition of various parameters or variables such as the type of waste to collect, the frequency of collection, the haulage distance, the type of service to provide, the type of vehicles to use, who to assign to the collection task (public employees or private companies), what technology to use, etc.
  • 14. 5 1.1.1 Solid waste generation and composition MSW is any unwanted material that is not a liquid or gas in our surroundings resulting from human activities (Speight, 2015, p. 279). It is mainly composed of solid material such as cardboard, food wastes, glass, metals, leather, paper, plastics, rubber, textiles and wood. The various known production sources of MSW are residences, industries, commerce (hotels, markets, office buildings, restaurants, stores, etc.), institutions (schools, hospitals, prisons, offices, etc.), construction and demolition, municipal services (beaches, landscaping, parks, street cleaning, etc.) and agriculture. Based on the types, MSW is generally classified into different categories defined in the municipal solid waste management (MSWM) policy or regulation of different cities (municipalities) or countries. This categorization consists of sorting MSW into different groups in order to reuse material that can be fixed or repaired, send to the recycling facilities solid waste material that can be recycled, reduce the amount of waste to dispose in the landfill, etc. The four common categories of MSW in China are hazardous, recyclable, wet and dry waste (Zhou et al., 2019, p. 2). 1.1.2 Collection of solid waste and stakeholders The collection of MSW is an important activity in which all the components should be designed and operate in a compatible manner in order to meet the needs and the expectations of residents, and to avoid waste to be dumped in the street (Coffey and Coad, 2010, p. 32). Hence, while defining the method of MSW two important questions should be asked. The first question, which refers to the timing or the frequency of solid waste collection is “when MSW will be collected?” This is a fundamental question encountered in any MSW collection system, and, the public expectations and the type of solid wastes (biodegradable or non-biodegradable) mostly influence the response to this question. The second question is “how the MSW will be collected? This question concerns the location where the solid waste will pass from the control of the producer to the control of the collection agency. For this question, there are different collection
  • 15. 6 methods including community containers, block collection system, Kerbside collection and door- to-door collection (Laurieri et al., 2020, p. 3; Yadav and Karmakar, 2020, p. 2). The involvement and participation of all stakeholders, including households, social workers, urban planners, policy regulators, etc., is major aspect of the MSW collection (Joseph, 2006, p. 863). In general, local authorities are aware of the health risks and environmental issues caused by inadequate solid waste management. Therefore, they typically look for new ways to share their conventional roles with neighborhood associations, small businesses, large private businesses and industries and other stakeholders in these areas. In addition, in order to establish an effective system of waste services, the local authority can also attempt to mobilize the human and financial resources of such actors. 1.1.3 Why Monitor MSW Collection Many reasons can support the use of technology to keep track of the status of the MSW collection in a region. Manual management of MSW collection may actually be very difficult due to the huge amount of solid waste generated by residences and industry (Hassan, Jameel and Şekeroğlu, 2016, p. 7). This could become a serious problem for the municipality due to improper sorting and weighing of solid waste produced in various areas of the municipality, poor timing and inefficient collection of garbage, insufficient transport of solid waste, etc. The main reason for monitoring the collection of MSW is to ensure good service quality, adequate collection and efficient transport of MSW. This can be achieved by using innovative technologies such as IoT. Using IoT in the collection of MSW can help the municipality to obtain information about the collection process, from the generation of solid waste to its final destination, from a centralized control center with less labors and errors. The activities that may be included in the solid waste collection are primarily collection, loading, transport and unloading of waste (Coffey and Coad, 2010, p. 38). All of these activities are performed separately from each other and then need to be connected together to create a comprehensive collection system. Since all activities are linked in series, each activity should be seriously considered to ensure that the entire system is functioning properly, as failure at one
  • 16. 7 stage of the system can lead to failure of the entire system. Thus, monitoring the collection of MSW can consist of collecting information on garbage containers throughout the municipality (filling, weight, location, temperature, etc.), tracking collection vehicles on the road, recording activities of collector agents, predicting the evolution of solid waste generation, real-time visualization, etc. (Pardini et al., 2019, p. 18; Khoa et al., 2020, p. 3). Information on solid waste collection can be used to help MSW collection decision- makers focus efforts and attention where and when it is really needed rather than deploying or making efforts based on a usual routine that may no longer be appropriate due to constantly and faster population growth or any other factor. In addition, it can lead to the optimization of the vehicle collection route, to reduce the collection costs, to avoid the overflow of trash in the municipality, to encourage the participation of citizens in the process of collection, etc. (Catania and Ventura, 2014, p. 30; Sureshkumar and Prabha, 2019, p. 232). It may also be used to evaluate the existing system in order to improve its efficiency in terms of method of collection (collection point and timing) and transport of MSW. Besides, it also may be used to estimate the resources that would be needed to extend the collection service to new areas of the municipality. Moreover, with the data collected from other municipalities or cities, it can help to compare different possible solutions for organizing MSW collection in terms of resources, time, productivity, cost, efficiency, etc. Furthermore, information on MSW collection may be used for designing a new MSW collection system (Coffey and Coad, 2010, p. 140). 1.2 Challenges and Needs for efficient MSW collection According to Adipah and Kwame (2019, p. 147), solid waste management is a problem encountered all over the world. In developing countries, solid waste management is one of the most important challenges where the amount of solid waste generated is increasing rapidly due to rapid population growth, urbanization, rapid industrialization and economic sustainability. MSW generated by households, offices, small-scale institutions and commercial enterprises is huge in amount and various in type. They generate different types of waste depending on the
  • 17. 8 demographic details, principal activities in the city or town, income levels, lifestyle of the community, etc. (Nanda and Berruti, 2020, section 1). Regarding this, improper management of MSW can lead to the illegal dumping and burning of solid waste, water pollution, breeding of mosquitos, air pollution, transmission of diseases, etc., which in turn can have significant impact on human wellbeing and environmental healthiness (Ferronato and Torretta, 2019, p. 1; Ejaz et al., 2010, p. 381). Therefore, it is important to have a MSWM system efficient at all levels. In order to implement and maintain an efficient solid waste collection system, having an adequate and periodic data collection mechanism on the amount and composition of MSW generated is one of the most important considerations for countries and municipalities (Priti and Mandal, 2019, p. 1277). Weighing and categorizing MSW allow municipalities to determine the adequate collection, processing and disposal method that could be adopted for a healthy environment and better quality of life. In addition, it can help to select the type and number of collection vehicles to deploy for solid waste transport and the number of collection points to set up in different areas of the municipality. However, the main and delicate challenge to accurately quantify and qualify MSW remains the implementation of an adequate data collection system, which, if not properly considered, could lead to meaningless quantification of solid waste and qualification outcomes. Many researchers have discussed the issues of efficiency and sustainability of MSWM systems from different angles. Throughout their studies, they identify the lack of relevant data among the serious problems that may face a MSW collection system, and mention the importance of a good information system in the management of MSW. Dui et al. (2020, p. 10) agreed that it is important for MSWM decision-makers to have relevant information (data) on current state of local system by identifying the lack of standard process of data collection and analysis among the obstacles to a sustainable solid waste management system. They suggested that, by using data relating to the source of generation, quantity and composition of solid waste, treatment technology, stakeholder participation, institutions, as well as policies and regulation, it is possible to implement adequate MSW collection system and to identify the challenges, opportunities and all the solutions of MSW collection systems. Besides, Fernando (2019, p. 201) noted that information quality and transparency is recommended from all the participants of
  • 18. 9 municipal solid waste management (municipality, laborers, contractors, etc.) since its effectiveness highly depends on the people who closely work in the program. It is therefore important for the municipality to think about encouraging the people involved in the system according to the work they do by collecting reliable data that clearly allows everyone to find their account. In the same way, (Silva, Prietto and Korf, 2019, p. 8) emphasized the importance for local government and population to have an information system for communication and transparency between them, as this practice can provide municipalities with a state-of-the-art information system with relevant and current data for a sustainable MSWM. 1.3 Brief case studies of MSW collection 1.3.1 South Korea South Korea is a country with an excellent solid waste management legislation and initiatives in the world, which have significantly contributed to waste reduction since 1990 (Henam and Sambyal, 2019, section 1). The country has divided the disposal of MSW into recycling, composting, landfill and incineration, and based the solid waste management legislation on volume-based waste disposal fees (VBWF) system, deposit refund system, extended producer responsibility (EPR), and bans on problematic plastic items and packaging. Thus, Seoul, its capital, has been struggling with growing solid waste generation and diversion issues for the last three decades due to rapid urbanization, and has come to favorable outcome in terms of reducing MSW generation mostly thanks to the VBWF system. In order to support the VBWF system established since 1990, the ministry of information and communication of the country developed a SWM information system that comprises three separate systems (Kaza et al., 2018, 179). First, a system for monitoring the amount of solid waste collected and transported, analyzing the collection vehicle routes using geographic information system, and gathering the necessary data to support evidence-based policy. The system digitally records all statistics of MSW collection operation, from solid waste generation to transportation and final disposal. Second, a system for obtaining information about food waste management using RFID system that records the identity of households and the weight of food waste they
  • 19. 10 disposed each time they use their personal RFID chip to open and dispose of their waste. Thus, they are charged a fee based on waste amount. Third, a centralized information platform that matches supplier and buyers or business and firms of recycled materials by providing information on recycling prices, technologies, etc. In the end, thanks to the digital volume based-system introduced in 2001, Seoul the capital of the country has achieved 20% reduction in food waste. Besides, the information system has proved to be successful by saving MSWM cost, promoting transparency, and eliminating illegal waste disposal in the country. 1.3.2 Toronto, Canada Toronto is the capital city of the Canadian province of Ontario with a population of almost 2.73 million reported in 2016. It is the Canada's most populated city and the fourth most populous city in North America (Wikipedia, 2020). The city's solid waste management systems are responsible for collecting, transporting, processing, composting and disposing municipal and private solid waste, including garbage, recyclables, food waste, yard waste, electronics and household hazardous waste (Toronto, 2020a). The city possesses an information system based on a comprehensive and interactive website that tells residents about the reduction, reuse and recycling of waste in order to use community participation to create a foundation for a more effective waste management system (Toronto, 2020b). The website readily provides information on waste management specific to residents, such as source-segregation rules, drop-off points, city policies, and disposal rates and fees in a user-friendly and enticing manner. Thanks to the online website, residents can also request for service such as the pickup of household hazardous waste, the deployment of additional garbage in an area, the removal of a dead/dying city tree, the planting of a new tree by the city, the cleaning of a road surface, etc. In addition, they can report bulky items not picked up, garbage not picked up, an overflowing bin, a damaged garbage or recycling bin, etc. Furthermore, they can send their complaints about Toronto waste management service or staff, submit their comments or suggestions, and access the waste collection schedule as well (Toronto, 2020c). Another successful initiative to engage
  • 20. 11 residents includes the waste collection mobile app where volunteers are trained to educate fellow residents about sustainable waste reduction, reuse and recycling practices (Kaza et al., 2018, p. 164). 1.3.3 India India is one of the largest countries in Asia with more than 377 million city dwellers living in 7,935 cities and producing 62 million tonnes of MSW per year (Lahiry, 2019). Solid waste management is one of the basic essential services provided by the country's municipal authorities to deal with the waste produced and keep urban centers clean. Waste management rules in India are based on the principles of sustainable development, precaution and polluter pays. In addition, the increase in waste generation has led to various legislations to regulate the way of disposal and treatment of waste generated under the general law of the Environmental Protection Act. In India, it is an essential requirement for each urban local body (ULB) to assess the quantity and composition of waste generated in order to plan and design MSWM systems effectively. However, the country is facing an issue regarding solid waste quantification due to the weighting method in place (Central Public Health and Environmental Engineering Organization, (CPHEEO), 2016, p. 44). In fact, currently two alternative methods are used to quantify the rates of solid waste generation. One consists of measuring the load of waste in collection vehicles either at a municipal or private weighbridge, while the other consists of applying a rule of thumb of 400-500 Kg per cubic meter to determine the quantity of waste transported per trip per type of vehicles. In that manner, the municipality gathers the data of quantity and composition by weighing and/or counting the number of trips of vehicles delivering the waste to landfills or to treatment facilities. Poland did use almost the same weighing procedure and ended up by failure to collect accurate information on waste generation (Boer et al., 2010, p. 370). The study shows that this method resulted in an informal trend between companies involved in the collection of MSW, and a lack of data credibility as well. Similarly, in India the quantity of waste measured at the transfer stations or disposal sites does not accurately reflect waste generation rates.
  • 21. 12 1.3.4 Bangalore, India Bangalore, one of the biggest city in India, is among cities facing a significant problem regarding solid waste collection due to the insufficient number of auto tippers deployed by contractors, the lack of transparency in partnership, and an inadequate system for data collection in different areas of the municipality (Ram, 2019). In fact, for a more efficient and effective approach in solid waste management, the Bruhat Bengaluru Mahanagara Palike (BBMP) municipality has been divided into different units which are largely dependent on contractors who deploy auto tippers and pushcarts to carry out door-to-door collection, street sweeping, and transportation of MSW (Naveen and Sivapullaiah, 2020, p. 3). However, the average efficiency of MSW collection in Indian cities and states is estimated to be around 70% (Balasubramanian, 2018, p. 258). This means that only around 70% of the total amount of waste generated is collected regularly by authorized agencies across the country, while the rest of the waste remains collected irregularly, resulting in environmental and health consequences. Besides, several residents in different areas of the municipality have complained of garbage piling up on the roads because the garbage trucks do not come regularly to collect their everyday solid waste. As result, people have ended up dumping garbage on the roads, which represents a serious environmental and health threat. In the final analysis, such a situation is just one of many that highlight that the lack of reliable data in MSWM is a significant problem that should not be taken lightly. 1.4 IoT-based solutions for efficient MSW collection In order to help cities around the world to cope with the mismanagement of MSW, many researchers have carried out work and provided various innovative solutions to improve the collection of MSW to a specific degree. This section discusses some of those solutions. Nirde, Mulay and Chaskar (2017, p. 667-668) present a wireless solid waste management system in where a smart trash bin is related with a web page to remotely monitor the ongoing status of the trash bin in terms of filling level and weight. The proposed system mainly utilizes a set of components including two ultrasonic sensors settled at the highest point of the trash bin, a weight sensor mounted at the bottom part, a GSM module, a set of RF module transmitter, RF
  • 22. 13 receiver, and Arduino unit in order collect information and transfer it to a designed website page for real-time monitoring. The entire system continuously sense the filling status of garbage inside the bin in term of centimeter thanks to ultrasonic sensors, and measure the weight of garbage thanks to the load sensor interfaced with the microcontroller. Its working principle holds in three main steps, sensing the level of garbage inside the bin, comparing the value with a threshold, and uploading the status on the website and sending a collection alert SMS or not depending upon the result of the comparison. The system provides a real time global point of view of the status of garbage bins deployed across a municipality through a web. Thus, the solid waste collection department could effectively send vehicles for garbage collection where and when it is required. Similarly, Sureshkumar and Prabha (2019, p. 230-231) propose a smart bin system as solution to the problem of finding out whether a garbage bin is filled or not for an efficient MSW collection. In addition to the level sensor for measuring the filling level of garbage in the bin as seen in the previous system, this solution uses temperature sensor, gas sensor, GSM and GPS modules, and a LCD display interfaced with NODE MCU microcontroller. The system fetches the filling information of garbage bin via the level sensor, displays two types of messages on the LCD display according to the value sensed, and sends the location of the bin to the truck collector driver via SMS thanks to the combination of GPS and GSM module. Besides, the system continuously measures the temperature of garbage inside the bin and send a SMS with the details of the concerned bin to the fire station if a threshold of 80% of a preset value is reached. Thus, it addresses not only the problem of garbage pilling up outside the bin, but prevent also the problem of fire that can occur inside a garbage. However, this solution has none user interface (uses SMS only) and it might get very tough to use such system if the number of bins increases. Furthermore, Vasagade, Tamboli and Shinde (2017, 264-266) come up with a smart system for solid waste management, which, in addition of checking the status and giving the alert of bin fullness has the feature to sense and clean garbage present outside the bin. They mainly built up this system with a set of IR sensor modules, an alarming system, a rotating mechanical shaft, an elevator assembly, and a GSM module interfaced with an Advanced RISC Machine (ARM). Thanks to the IR modules, the system checks continuously the bin fullness as well as the presence of waste outside the bin. In case of the fullness detection, the system sends a message
  • 23. 14 to the respective authority in Municipal Corporation if the data from IR sensor inside the bin exceeds a preset limit (80%), so they can come to collect the garbage. In case waste is detected outside the bin, the system turn on an alarm and enable the mechanism (mechanical shaft and elevator) to pick up the garbage and throw it inside the bin. This system is built to prevent three types of issue. First, it prevents overflow of the Trash bin by sending SMS to respective authority; second, it prevents waste piling up outside the bin; third, with the alarming system, it makes people using the Trash bin properly by turning on the alarm in case of any misbehavior like throwing garbage outside the bin. Cloud-based systems are one of the innovative solutions proposed in the field of MSW collection. These are basic IoT-based systems that use cloud computing for real-time monitoring data storage and data visualization. Likotiko et al. (2018, p. 108-111) propose a solution for real- time monitoring the level of garbage inside the bin based on a smart waste bin system with three layers IoT architecture. The system has a distance level sensor interfaced with a microcontroller at the first level, a GSM module for communication at the second level, and an IoT platform for receiving, storing and updating data coming from the smart bin at the third level. The level sensor is responsible for the continuous measurement of the garbage level inside the bin. This sensor is connected to the MCU microcontroller node, which acts as a process unit by collecting information from the level sensor, comparing it with a threshold to verify whether the bin is full or not, and communicating with the GSM module to send the data to the upper layer. The GSM module sends the detected status of the bin and the time of detection to the Thingger.io IoT cloud for updating and storing the status of the bin in a database. The system send an alert via SMS when the smart bin threshold is reached, and thanks to the Thingger.io inbuilt visualization feature, the system plots the evolution of the smart bin activities for the administrator visualization purpose. Chaudhari and Bhole (2018) present an IoT-based solid waste collection system that enables bin monitoring, dynamic planning, and the generation of the shortest path for the collection of MSW. They propose a system with four main components to quantify the amount of waste inside the bin and send the data to a central cloud server, track the status of the bins in real time, create a dynamic waste collection schedule, and localize the bins on the regional area
  • 24. 15 map. The first part is mainly hardware made up of ultrasonic sensors to get the level of garbage inside the bin and a set consisting of GSM module, GPS module and Arduino microcontroller to send the trash bin filling status and the location to a central cloud server. The second part is the cloud server. They used ThingSpeak free IoT platform to receive the data from the trash bin, update the status of the bin in the system and display the updated status on a web application. Besides, it also pushes notifications to client side’s mobile application (Garbage truck drivers and municipal control center) mainly for garbage collection alert. The third and fourth parts are entirely software. They are mobile applications that show the location and trash bin status on a map, and module that generates and displays dynamic shortest path to reach quickly the desired bins (filled garbage bins) from garbage truck current position thanks to Google Map API. This solution for efficient solid waste collection mainly addresses the issue of garbage overflow, garbage truck fuel consumption and collection time (cost and time reduction). Pardini et al. (2020, p. 7-11) present another interesting proposal based on IoT technology. They propose a system that optimizes the collection of MSW and encourage citizenship in the process by using an architecture that considers three main layers. A perception layer, a middleware layer and an application layer. The perception layer is a smart bin that has various sensors and modules to gather all the necessary information on garbage and send it to the next layer. It is made of an ultrasonic sensor that measures the filling level of waste inside the bin to avoid the overflow, a load sensor that measures the weight of waste present in the bin, a temperature and humidity sensor that gets additional information of the garbage. In addition, it has a GPS module that enables the garbage truck driver to track the bin and allows citizens to get the shortest path and distance between them and the nearest available bin. Furthermore, the system has a GSM module that enables a wireless communication between the smart bin and the rest of the system, and an Arduino board acting as a central processing that interfaces sensors and modules. The IoT middleware is a software that interconnects different components of IoT system to allow them communicate and exchange data properly. For this layer, they used Inatel IoT (In.IoT) cloud to receive the data sent by the smart bin and store it for the visualization of trash bin status in real-time through the web. The third layer is a mobile application designed to involve citizens in the MSW via their smartphone. Thanks to this layer
  • 25. 16 (application layer), users can send requests to the middleware (Int.IoT) and obtain important information such as the status of nearby bins, the distance between them and the unfilled bin, and the path and the estimated time to it. Definitely, this system primarily solves the waste overflow problem. However, it has an additional feature that involves inhabitant in the management process and lets them know relevant details on the garbage bins surrounding them. This way, they will not go to the trash bin to find it already full and end up throwing their garbage outside. Islam et al. (2012, p. 260-261) introduce a garbage collection and monitoring system composed of an RFID system, a GSP and GPRS modules, a geographic information system (GIS) and a webcam in order to optimize the collection of solid waste. The system is designed to work in such a way that the driver of the collection truck must scan an RFID tag mounted on each bin in order to record to a monitoring station the exact time and location each time a bin is collected. The RFID tag on each bin contains a unique identification key that allows access to household information (identifier, address, etc.) pre-stored in an SQL database and stores new collection information by a simple scan. The GPS and GPRS modules allow tracking the exact position or location of collection truck, and, thanks to the information they send, a GIS analyses and decides where the waste should be dumped. The webcam makes it possible to take pictures of the trash bin before and after the collection in order to send them to the monitoring station. As for the principle of operation, once the RFID reader in the collection truck scans the RFID tag on the trash bin, the reader fetches the ID of the trash bin and sends it to the processing unit in the truck. The processing unit in turn takes the location sent by the GPS module, the images from the webcam, associates the time of collection, and transmits all the information to the central monitoring station in order to store them. In this system, the trash bin is not directly connected to the central monitoring station or to the collection truck, and do not have in-built sensor to gather information. The interface between the trash bin and the rest of the system is the RFID tag system only (tag and reader). Thus, the monitoring of parameters such as filling level or weight of solid waste inside the bin is not available. The system monitor the collection of solid waste by recording the time and the location of each bin collection, and by storing pictures token by the
  • 26. 17 webcam present on the collection truck. It also monitors the move of the collection trucks and helps to determine the nearest dumping location. 1.5 Summary The papers reviewed above highlight some issues that can be solved with a good data collection system and present some innovative solutions for effective municipal solid waste collection process. From the case studies reviewed, we can see how some cities succeeded in the collection of MSW by monitoring one or more activities in this operation, while cities managing the collection of MSW without technology struggle with different type of issues to provide a good and efficient solid waste collection service. Among issues that can be encountered in the management of MSW, we can mention overflow of garbage outside the bin, the lake of accurate quantification and qualification of solid waste generated in specific geographic areas, the lake of transparency and accountability among stakeholders of the program, the lake of relevant information for decision-making, etc. Hence, addressing one or more of these issues may be a primordial need to improve the collection of MSW in cities. Therefore, various solutions have been proposed to help municipalities improve MSW collection to some extent by addressing one or more issues that can be encountered in this operation. However, many of them mainly focus on solving the garbage overflow issue, finding the shortest path for garbage collection, real-time monitoring of the garbage condition, and few of them on helping residents to obtain information on the garbage bins around them. None of the solutions solves the problem of the lack of relevant information on quantification, qualification, transparency and accountability, which are among important key elements for the optimization of the efficiency of solid waste collection. On this account, this project intends to present a new approach that addresses three major problems in the collection of MSW, which are the garbage overflow, waste quantification and qualification, as well as transparency and accountability thanks to an information system based on IoT. To achieve this, the approach uses IoT devices (sensors, microcontroller, communication module, etc.) that communicate with a remote web app via internet for gathering the information of waste generation at the collection point including weight and type
  • 27. 18 of solid waste, and information on workers and contractors of MSW collection every time they collect waste.
  • 28. 19 Chapter 2 – Methodology This second chapter of our project mainly presents the methodology we used to conduct our research and the design of our IoT-based system. It presents the research approach we used in this project, the software development model we followed to produce a working system, the requirements for developing our IoT-based system and its design, including the smart trash bin and the web app. 2.1 Research approach The research approach used in this study followed a process of design science that consists of five iterative steps including awareness of problem, suggestion, development, evaluation and conclusion (Saltuk and Kosan, 2014, p. 6; Hevner and Chatterjee, 2010, p. 26). This approach suits well the objectives of our project and takes into account three research cycles to produce excellent design in the field of information system and computing, which are the relevance cycle, the design cycle and the rigor cycle. The relevance cycle provides the requirements of the system that takes into account the needs of the environment where the system will be used. The design cycle consists of building alternatives design and evaluating them until a satisfactory design is reached according to the environment need. The rigor cycle provides past knowledge including theories, frameworks, instruments, data analysis technics, design validation criteria, etc. applicable in the design cycle (Hevner and Chatterjee, 2010, p. 16). According to these three cycles, the first step in the design research is the awareness of problems, which consists of undertaking relevant researches in order to recognize and articulate problems to address, and come out with a proposal for a new research effort. The recognition and articulation of problems can come from the survey of literature, the need for something, the findings in another discipline, the development of new technology, etc. In our case, we conducted a survey of the literature to find out current problems and needs in the collection of MSW, to understand the benefit of using information technology in the collection of MSW, and analyze the strengths and weaknesses of existing IoT-based solutions to address problems we have
  • 29. 20 discovered. The second point in the process is the suggestion of a tentative idea, which is a step that consists of producing a tentative design of how problems might be addressed by creating step to envision a new functional artifact or a novel configuration of existing elements. At this step in our project, we produced a new design based on IoT architecture taking into account all the problems to be addressed. The third point is the development of the proposed design that consists of implementing and producing a functional system. Likewise, we also implemented and produced a functional system that comports a smart bin and a web application communicating via internet. The next step after producing a functional artifact is the evaluation of the system, which consists to determine how well the system works and whether the system produced meet or not the purpose for what is has been developed. For our system, we did the evaluation based on the research question and the finding of the literature review conducted in the first place. 2.2 System development model The design and implementation of our system followed the software development life cycle (SDLC) that includes 5 phases, which are (1) analyze of requirements, (2) design, (3) implementation, (4) test and (5) maintenance as shown in Figure 1 below (Mishra and Dubey, 2013, p. 65; Airbrake, 2013, section 1). Based on these five phases, several models of software development are available; each follows a unique pattern of steps to ensure excellent accomplishment in the process of software development. The most common models in SDLC are Waterfall model, Spiral model, rapid application development (RAD) model, incremental model and V-SHAPED model. In our case, we used the WATERFALL model to design and implement our system for its clear, concrete, and well understood steps, which is relatively simple to follow and makes it easy to develop a timeline for the entire process (Airbrake, 2016, section 3).
  • 30. 21 Source: (Airbrake, 2013) Figure 1: Software Development Life Cycle 2.3 System requirements The purpose of this initial phase is to methodically analyze the potential requirements of the application and determine specifications that will serve as basis for all the future development. The outcome of this analyze is a requirements documents that defines what the application should do, but not how (Airbrake, 2016, section 2). Likewise, as the design and implementation in this project is about producing a system capable of helping the municipality to solve issues relating to poor data collection in the process of MSW collection, we conducted an analysis based on the finding of the literature to determine our system requirements. The literature survey showed that municipalities might encounter three main problems in the collection of MSW process, which are transparency and accountability of stakeholders, municipal garbage bins overflow, and waste quantification and sorting. Based on this, the system should be able to allow: - The surveillance of workers and contractors of MSW collection for purpose of transparency; - The promotion of PRP for motivating the engagement of workers and contractors;
  • 31. 22 - The availability of relevant information on the status of municipal bins installed in different areas to avoid garbage overflow and collection delays; - An accurate weighing and sorting of solid waste generated in different local areas for solid waste quantification and qualification per area. In addition to these functionalities, the system must be accessible, user-friendly and available to authorized users or stakeholders involved in the MSW collection with different levels of privileges, mainly for reasons of transparency. For this, different privileges are: - The admin system should be able to monitor the operation and have access to all the functionalities of the system including creating, reading, updating and deleting users, contractors, trash bins and their own collection agents; - The contractor admin should also be able monitor and have access only to the manage their workers or agents including creating, reading, updating and deleting; - Simple user should be able to monitor only (view only). The summary of important features that should be embedded into the system is given in Table 1 below. Table 1: Summary of main features of the system Feature Description Data collection Collection of relevant data on waste generation, solid waste collection workers and contractors, and garbage bins filling state. Report generation Generate a report of daily collection activity that contains relevant information such as waste generation and bin collection cycle, which can help improve solid waste collection in different areas of a municipality
  • 32. 23 Trash bin management Add, remove or update trashcans in the system. Management of staff and waste collection contractors Add, remove or update the personnel or contractors assigned to the collection of solid waste in different areas. Real-time monitoring Allows the monitoring of the state of all the bins placed in the different corners of the districts of the municipality. User management Allows creating, deleting or updating the users of the application taking into account the access privileges. 2.4 System design This stage in the project development focuses on defining technical design requirements including programming language, services, data layers, etc. that the application should be made with in order to meet the system requirement. This phase should clearly show how the system should work in order to cover all the system requirements (Airbrake, 2016, section 2). Similarly, in this phase of our project, we defined how the system should work and we designed it. Based on what the system should perform as tasks (system requirements), our system should be able to surveille and interact with different devices of the system remotely. For this reason, we chose to use IoT to develop our solution as it is the most suitable technology for remote communication and devices interconnection on large distances via internet in many applications (Diène et al., 2019, p. 2). The system we proposed has two main components, a smart trash bin made with sensors, microcontroller and communication modules for data collection, and a web application for receiving the data from the trash bin for the system management, monitoring and report regeneration.
  • 33. 24 2.4.1 Smart Trash bin design The smart trash bin is the component responsible for collecting all the necessary information needed to produce a solid waste collection report. It is made up with level sensor, weight sensor, RFID sensor, and microcontroller and GSM module as illustrated in Figure 2. It is mainly hardware and it is the first component of the system chain. Weight and level sensors are responsible for gathering the data related to the weight and the level of garbage inside the trash bin, and the RFID sensor is responsible for gathering the identity of the solid waste collector agents when they come to collect waste. The microcontroller acts as a processing unit at the level of the smart bin, which receives the data from the sensors and processes it before sending it to the communication module, which in turn sends it to the remote server. The communication module here is responsible for establishing remote communication between the smart trash bin and the remote server. Figure 2: Block Diagram of the Smart trash bin Two operating modes are available for the smart bin, a mode for normal monitoring (updating the trash bin status), and a mode for the collection process (recording the performances of the collector agents). The flowcharts of these two operating modes are given in appendix 1.
  • 34. 25 2.4.2 Middleware The middleware is the interface used to interconnect all the main components of the system (trash bin and web app). Since the smart bin cannot directly send the information it gathers to the web app, it sends it first to the middleware, which in our case is a database on a remote web server, then the web app accesses the information sent by the smart bin from the database. The web server allows communication between the smart bin and the app, processes and stores the data, and allows the management of the system database. The trash bin uses HTTP requests to send out the data to the server, and the app uses SQL queries to access data. 2.4.3 Design of mySWC app The web application is the component from which users can interact with the system. It offers a user interface mainly designed in HTML, CSS and JavaScript; and interacts with the database on the middleware using PHP and MySQL on the backend user. The user interface offers to the user of the app the ability to manage the entire system. The user can manage the bins in the system, the personal to be assigned to the collection process with their identities, the collection agencies (contractors), monitor the status of the bins in real time, etc. The user interface also allows the generation of reports, which can contain the records of the smart bin in terms of filling and collection, or the records of the collector agents in terms of the weight they have collected so far in different areas. The web app we designed has nine main pages described in Table 2 below. Since the information to be displayed in the application are dynamic, the data that the application displays come from the database, which is the interface between the smart trash bin and the app. The structure of the database that we designed for our app is given in appendix 2.
  • 35. 26 Table 2: Description of main pages of the application Page Description - Login page - Home page Dashboard that leads to different pages of the application - Monitoring page Page which gives an overview of the condition of all the bins installed in the municipality - Map page Which gives a view of the location of all the municipal bins on the map - Alert page Shows all the bins that need to be collected - Report page Gives a report on daily collection activities (garbage correctly collected, collection agent, time of collection, weight and level of garbage, etc.). - Trash bin page Allows the management of trash bin including adding, deleting and updating trash in the system - Worker and contractor page Allows the management of collection agent and contractor including adding, deleting and updating - And admin page Allows the management of users of the application including adding, deleting and updating users with different privileges. A detailed application map is given in Figure 3 below.
  • 37. 28 Chapter 3 – System implementation As mentioned in the design section, this project has two main components; a smart trash bin that sends out the data collected from the field inputs to a central monitoring center; and a web application that receives and stores data, and allows the management of the system. This chapter presents the implementation of our system, including the components we used for the smart bin and the technologies we used for the development of the web application. It also presents the output of our implementation and the communication principle between the smart bin and the web app. 3.1 Smart bin The purpose of the smart trash bin is to collect all the data necessary for the production of a detailed report on the solid waste collection operation. To do this, the system is composed of a level sensor, a weight sensor, an RFID reader, a microcontroller and a GSM module as illustrated in Figure 2. The result of the implementation of the smart trash bin is shown in Figure 4 below. Figure 4: Smart trash bin Prototype
  • 38. 29 3.1.1 Components used a. Level sensor To measure the waste level inside the bin, we used the HC-SR04 ultrasonic level sensor module shown in Figure 5 below. Source: (Arduino project Hub, n.d.) Figure 5: View of Ultrasonic sensor HC-SR04 As shown in Figure 5 above, this sensor has four pins, which are VCC, Trig, Echo, and GND. VCC and GND are pins dedicated to module power supply (5V), Trig is an input pin to the sensor and Echo is an output from the sensor. This sensor measures the distance between its position and an object by emitting a 40 KHz ultrasound which moves through the air and by counting the time it takes for the sound to travel and bounce towards the module when it encounters an obstacle in its path (Arduino project Hub, n.d.). This sensor module is intended to work with a microcontroller that gives the input signal and processes the information from the sensor module (echo pin) to determine the distance between the object and the module. b. Weight sensor To measure the weight of the waste inside the trash bin, we used a 20 kg load cell with an HX711 amplifier shown in Figure 6 for two main reasons. First, for its insensitivity to temperature variations, and second, because it does not contain fluids, so it requires no much
  • 39. 30 maintenance. In addition, there is no possibility of contamination of the process if the diaphragm breaks (Sivaranjith, 2018, section 3). Source: (Drtorq, 2019) Figure 6: View of load cells and HX711 Amplifier Typically, the load cell has four wires labeled by different colors and connected directly to one side of its body, which are red (E+), black (E-), green (A-) and white (A+). The letter and sign associated with each wire are used in order to connect the load cell to the HX711 module, which amplifies the signal and in turn delivers four pins to be connected to the microcontroller. These pins are VCC and GND to power the module (5V-DC), DT to send the signal to the microcontroller, and SCK for the module clock input (Circuit4you, 2016). For its easy use with Arduino, this sensor comes with a free library available online. c. RFID module We used the RFID module RFID-RC522 shown in Figure 7 below as component of the smart bin in order to allow collector agents to scan their ID card when they come to collect waste. By this action, the smart bin gathers the information stored in the ID card of the agent (identification number) and sends it to the microcontroller interfaced with the RFID module for processing and transfer to the monitoring center.
  • 40. 31 Source: (Last minute Engineers, n.d. [a], section 2) Figure 7: RFID module Reader/Writer (on the left) and RFID tags (on the right) RFID system consists of two main components, a transponder/tag attached to an object to be identified, and a Transceiver also known as interrogator/Reader (Last minute Engineers, n.d. [a], section 1). In our case, the reader used is shown in figure 12 above (on the left side), while the transponder is a microchip that contains a unique ID number mounted in the ID card of the agent (on the right side). The working principle of this module consist of an antenna present in the reader module that generates high frequency electromagnetic field to supply the tag and read the information encoded on the tag when it is placed in close proximity to the reader. This module comes also with a library in order to use it easily with Arduino. d. Communication module In order to enable our smart bin to communicate remotely with the rest of the system, we made use of the SIM900A GSM/GPRS shield. SIM900A shield is a GSM modem that uses mobile network service for making or receiving phone calls, sending or receiving SMS text messages, connecting to internet through GPRS, TCP/IP, HTTP, and more (Last minute engineers, n.d. [b]). In our case, we used it to enable the communication between our smart bin and the web application through internet. The SIM900A GSM/GPRS module is designed with everything
  • 41. 32 necessary to make easy its interfacing with Arduino. Primarily, it has pins that allows it to be interfaced with microcontroller (Rx and Tx pins), serial port (DB9) that allows a direct interfacing with a computer, an Antenna for network connection, a SIM card slot, and a DC jack for power supply. A brief description of a SIM900A module is given in Figure 8 below. Source: (Poojary, 2017) Figure 8: Description of the composition of the GSM/GPRS module The GSM/GPRS module is controlled by a particular type of predefined commands known as AT-Commands (where AT stands for Attention) in order to make it performs different tasks such as sending SMS text, MMS, HTTP request, etc. (Electronicforu, 2019, section 1). These commands may be used with either a computer or a microcontroller such as Arduino interfaced with the GSM/GPRS module through Rx and Tx pins. This module supports a large number of different commands depending on the task we want it to perform (Telit, 2016). Some commands used in our project are given in Table 3 below. These commands allow the GSM/GPRS module to send data to the remote server via the Internet using the HTTP GET method.
  • 42. 33 Table 3: List of AT-commands used to send out the data from the smart trash bin AT-Command Description Configuration AT+CGATT Attach to or detach from, the terminal to the GPRS service AT+SAPBR=3,1,”Contype”,”GPRS” Set the connection type to GPRS. AT+SAPBR=3,1,”APN”,”www” Set the APN. Replace “www” with the APN of the network used. AT+SAPBR =1,1 Enable the GPRS AT+SAPBR=2,1 Query if the connection is setup properly, if we get back a IP address then we can proceed. HTTP commands AT+HTTPINIT Initialize HTTP communication AT+HTTPPARA=“URL”, ”www” Set the url. Replace www with the address of the webpage you want to access. AT+HTTPACTION=0, 1 or 2 Set http action type. Give 0 for GET, 1 POST and 2 for HEAD type of action AT+HTTPREAD Read server response after HTTPACTION AT+HTTPTERM End of communication Source: (Pujar, n.d.) e. Microcontroller As processing unit of the smart trash bin, we used Arduino UNO, which is a cheap microcontroller that matches our project in terms in terms of number of input/output. Figure 9 below gives a brief description of the Arduino UNO board.
  • 43. 34 Source: (Howedi and Jwaid, 2016, p. 4) Figure 9: Description of the Arduino board In order to be interfaced and interact with other components, the Arduino board has twelve digital pins, which can be configured as input or output, and six analog inputs. Regarding programming, the board supports the C language; for this task, we used the Arduino Integrated Development Environment (IDE) to develop our code, which is the default IDE for programming this board. 3.1.2 Interfacing Interfacing refers to the wiring of components to allow them to communicate and interact in order to achieve the overall purpose of the system. As we used Arduino as the processing unit, all the components of the smart trash bin are interfaced with it as shown in Table 4 below.
  • 44. 35 Table 4: Smart trash bin component wiring table Component pin Arduino pin RFID Reader - SCK 13 - MISO 12 - MOSI 11 - SDA(SS) 10 - RST 9 - 3.3V 3.3V - GND GND Level Sensor - Echo 8 - Trig 7 GSM module - Rx 6 - Tx 5 - GND GND Load cell - DT 4 - SCK 3 Card detection - Push button (in pull-up resistor mode) 2 3.1.3 Coding In order to program the Arduino, we used the Arduino IDE Ver. 1.8.13 shown in Figure 10 below. This software is available free on google and can be installed on any computer like any other software.
  • 45. 36 Figure 10: Capture of the Arduino IDE The complete Arduino sketch produced for the smart bin is available on GitHub open source repository. - Repository name: SmartTrash - Released link: https://github.com/conordata/SmartTrash Libraries have been used in this sketch, which are: (1) Adafruit MRF 630 RFID (MFRC522) for the RFID module, (2) HX711 for load cell (weight sensor), (3) Serial Peripheral Interface (SPI) for communicating with the RFID module quickly, (4) SoftwareSerial to allow serial communication on other digital pins of the Arduino (other than Rx pin 0 and Tx pin 1).
  • 46. 37 3.2 mySWC App The implementation of this element consisted of installing a server, creating a database, and coding the application using HTML, CSS, JavaScript, SQL, and PHP. 3.2.1 Server setup In this project, we deployed a local server that allowed us to develop and test the application locally on our computer. For that, we used XAMPP Server Ver. 3.2.4 shown in Figure 11 below. Figure 11: XAMPP Control Panel 3.2.2 Database implementation For the database implementation, we made use of phpMyAdmin, which is a database management system that comes with the XAMPP server. The home page of this database management system from which we started to implement the database is displayed as shown in Figure 12 below.
  • 47. 38 Figure 12: phpMyAdmin Home page 3.2.3 Application coding The last task of the mySWC implementation was coding the application using web technologies. For that, we used the Sublime text editor Ver. 3.2.2 as IDE. The development component of this application is available on GitHub. - Repository name: myswc - Released link: https://github.com/conordata/myswc a. Program Architecture In order to make our code easy to understand and to maintain, we structured our application following the Model-View-Controller (MVC) model, which consisted of separating our application into three main logical components, the model, the view and the controller that each handle a specific aspect of our app. An architectural diagram of the MVC model is shown in Figure 13 below.
  • 48. 39 Source: (Guru99, n.d., section 4) Figure 13: MVC architecture diagram The Model component handles all the data-related logic that the user works with, such as retrieving information from the database, manipulate it and update it data back to the database or use it to render data. The View component refers to all the elements of the user interface logic of the application such as text boxes, dropdowns, form, etc. And the controller acts as an interface between Model and View components to process all the logic and incoming requests such as the interactions and inputs form, manipulates data using the Model component and interacts with the Views to render the final output (Tutorialspoint, n.d., section 1). Likewise, we put all the files relating to the view (design, table, form, etc.) in the main folder of the application. The files which contain all the constructors and methods to extract and insert data into the database (interact with the database) in the modals folder, and the files which handle user interaction like form submission, updates, deletion of records, etc. in the controllers folder.
  • 49. 40 b. Technologies used Nowadays, several web technologies are available to help the development of interesting web applications in the easiest way. For our app, we used the JavaScript library jquery-3.4.1 for auto-refreshing the table of data in the monitoring page as shown in Figure 14 below. We also used the Google map API in the map view page to display the location of the saved trash on a city map. Apart from the library and the API, the rest of the application is made up with native technologies (no framework or further libraries). Figure 14: Capture of the script used for the auto refresh of the table in the monitoring page We used HTML5, CSS3, and JavaScript for the design of the front-end user of the application, and SQL and PHP for the back-end user. HTML and CSS can be seen in almost the files of the view component of the app. As for JavaScript, we mainly used it in:  monitoring page for auto refreshing a specific part of the page  map view to display the location of trash bin registered in the system on a map of the municipality
  • 50. 41  Collector agent and collected bin pages for data filter and dynamic average calculation.  And input validation. 3.2.4 Implementation output a. Home page The home page of our app is a dashboard that shows different options available on the side bar and the main body as shown in Figure 15 below; each option leads to a specific page. Figure 15: Screenshot of the home page b. Monitoring page The monitoring page of the app shows in real time the status of all the municipal bins including:  the id of the trash (as each trash is referred with a unique Id)  the type of the bin (which can be seen by hovering over the bin ID in the table)  the longitude and latitude of the bin location
  • 51. 42  the area or local body where the bin is affected  the current level and weight of garbage inside the bin  the current status of the trash bin (normal – if the level is under the alert limit, collection requested – if the level is under the alert limit but the garbage lasts for more than 4 days, or alert – if the level of the trash bin is beyond the alert limit)  the last time the data has been updated  and the duration since the first garbage has been thrown in the bin. The Figure 16 below gives a view of the monitoring page. Figure 16: Screenshot of the monitoring page c. Alert page This page displays the full bins that need to be collected. It shows the id of the trash bin, the longitude and latitude, the area where the trash is installed, the current level and weight of garbage inside the bin, the time when the bin got full and the duration since it got full as shown in Figure 17. The threshold to change the bin status from normal to alert and display it on this page is set in the newHistoric.php controller. It is up to the system administrator to modify this
  • 52. 43 value as he wishes according to his expectations. In our case, we have set the threshold at 80% of the filling level. Figure 17: Screenshot of the alert page d. Collected bin (in daily report) This page displays all the bins collected during a given period. It shows the bin ID, longitude and latitude, the area where the bin is installed, the level and weight that was collected, the time the bin became full, the length of time it remained full before the collection took place, and the identity of the agent who collected the bin as shown in Figure 18. Three input fields are available on this page; at the top right are fields where we can submit the period we want to display going from one given date to another; and at the left top of the table is a field where we can filter the contents of the table by area.
  • 53. 44 Figure 18: Screenshot of the collected trash bin page e. Collector agent page (in daily report) This page displays all the collector agents involved in the municipal solid waste collection. It shows the agent ID, full name, the area where the agent is affected, the organization where he belongs (internal – if he is a municipal or public worker), and the cumulated weight during a given period. Similarly, three input fields are also available on this page; at the top right are fields where we can submit a starting and ending date in order to see the quantity of waste a given agent has collected in a particular period. At the top left of the table is a field where we can filter the contents of the table by contractor. f. Other pages Other pages of the application are for the management of logistics part such as workers, contractors, app users and trash bin. Details on these pages of the app are given in Table 2.
  • 54. 45 3.3 Communication between smart trash bin and mySWC Our Iot system has four components in its value chain, from the measurement of parameters in the smart bin to the web application. - First, we have three sensors mounted directly in the trash bin in order to collect information (level, weight and ID). These sensors are connected to the digital pin of Arduino, which is the processing unit of the system. - Second, the Arduino board receives the information from the sensors and processes it in terms of calculating and converting the data type before sending it to the GSM/GPRS module (SIM900A), which is responsible for sending the data to the web application using the HTTP GET request. The GSM module is connected to the Arduino as well, and receives instructions from it in form of AT-Commands shown in Table 3. - Thirdly, once the Arduino has sent AT commands containing the data to send to the application, the GSM/GPRS module in turn sends an HTTP GET request to the web app controller hosted on an online server. The GSM/GPRS module uses the GPRS service of the mobile or cellular network (depending on the SIM card used) which allows it to communicate via the Internet. - Fourth, the web application receives the request sent by the GSM/GPRS module in the controller, uses a PHP GET method to retrieve the sent data and an SQL query to insert the data into the database from which it can be accessed for different purposes. The diagram architecture in Figure 19 below illustrates the communication principle between the smart trash bin and the Web app.
  • 55. 46 Figure 19: System diagram architecture
  • 56. 47 3.3.1 HTTP request HTTP is an Internet protocol that functions as a request-response mode between devices designed to allow communications between clients and servers (W3C, n.d.). Typically, the client (which can be a browser or any other device) sends an HTTP request to the server, and then the server returns responses to the client with information containing the status of the request or the requested content. To send the HTTP request to a server, there are different methods that can be used such as POST, GET, HEAD, etc., each with its own advantages and disadvantages. Likewise, in our system we have the smart trash bin, which is seen as a client sending requests to an online server using GET method. 3.3.2 Sending the data As mentioned earlier, data is sent to the server using the HTTP GET request, which is one of the most common HTTP methods. With this method, the HTTP URL contains a variable name/value query string as follows: Server_address/path_of_the_file/file_to_reach.php?name1=value1&name2=value2 Similarly, this same principal is used in the smart trash bin in order to send the data to the web app as shown in Figure 20 below. Figure 20: URL construction (HTTP GET request)
  • 57. 48 In the same way that it is possible to embed HTML tags in PHP code using the “echo” function, Arduino uses the same principle by embedding AT command instructions using the “Print” function in order to execute them via serial communication between the Arduino board and the GSM/GPRS module. The full step-by-step AT instructions (AT commands) used with Arduino to send the data to the server (web application) are given in Table 3. 3.3.3 Receiving the data To receive the data sent from the smart bin, two controllers are available in the web application; one to receive the normal trash bin status updates for real-time monitoring, and the other to receive the trash bin collection updates (of course, the smart trash bin sends requests to these two controllers separately). These two controllers are newHistoric.php and newScan.php. Once the controller receives the HTTP request, it executes a GET method in order to retrieve the value sent in the URL and insert it into the database as shown in Figure 21 below. Figure 21: Capture the script to retrieve the data sent in the URL (newHistoric.php).
  • 58. 49 Chapter 4 – Test and Evaluation After the design and implementation of our system (smart bin and web application), this chapter presents the result of the test we performed on the two components and the evaluation of the system in order to answer our research question. The chapter presents the results of three different tests of the system. First, it presents the accuracy test result of the smart bin to report correct values; second, the test result of the web application in different use cases and its compliance with the W3C standard; and third, the result of the communication between the smart trash bin and the web application. Regarding the evaluation, the chapter shows how the system fulfills a set of criteria or properties in order to determine how well the system answers the research question. 4.1 Test 4.1.1 Smart trash bin For the smart trash bin test, we used the Arduino “Serial.print” function that allowed us to directly see the data measured by the sensors in the Arduino serial monitor as shown in Figure 22 below. Figure 22: View of values measured in Arduino serial monitor We performed a test on the accuracy of the weight sensor, as well as the accuracy of the level sensor. For the weight sensor, we first had to calibrate the load cell to determine the
  • 59. 50 calibration factor, and then we performed tests using known weight shown in Figure 23 to see how well the sensor reports the values correctly. For the level sensor, we have placed objects inside the bin with different filling levels, we have measured the height for each filling level with a ruler, and we compared the measured values and the reported values of the sensor in the serial monitor. Figure 23: weights used to test the load cell (weight sensor) Regarding the weight sensor, the result shows that the load cell measures the weight with a tolerance of +0.03 kg, which is quite acceptable given the application. However, to only work with integer values, we used the Arduino “round” function, which changed the tolerance from +0.03 to +/- 0.5 kg. Regarding the level sensor, the result shows that the sensor is not stable but reports values almost close to the real values. The instability of the sensor is due to the fact that the sensor is primarily intended for measuring distance with a flat reflecting surface, however, the garbage inside the bin does not always offer this possibility. The result of this test is presented in Table 5 below.
  • 60. 51 Table 5: Result of the test of accuracy of the smart trash bin Input value Measured value Exact value Weight Sensor 1 kg 1.03 kg 1 kg 1.5 kg 1.53 kg 1.5 kg Level Sensor (trash bin depth: 18 cm) 18 cm 0% 0% 13 cm 33% 27% 8 cm 61% 55% 3 cm 94% 83% 4.1.2 Web app For the web application, we first performed a W3C standard compliance test using the W3C validator tool, which showed no HTML, CSS or JavaScript errors in our code (see the results in appendix 3). The only errors that appeared was related to the PHP code present in the code. Second, we performed user experience testing including adding, deleting, and updating trash bin, workers, contractors, and app users. This test did not show any errors or malfunctions. We also did a communication test without the smart trash bin to see how the application responds to the HTTP request in localhost thanks to POSTMAN, which is a software that allows sending HTTP requests to a server with different methods. The user interface of the POSTMAN software that we used for this test is given in Figure 24 below. This test was primarily intended to test the monitoring page, alert page, collected bin page, and collection agent page. To test the monitoring and alert pages, we did the test with ten different bins for which we sent different weight and level values, and for the collection, we did the test with two collection agents. This test also did not show any errors in the operation of the system.
  • 61. 52 Figure 24: View of POSTMAN software 4.1.3 Communication We were not able to test the communication between the smart trash bin and the web app in localhost. To perform this test, we used 000webhost, which is an online web server that offers limited free services. We hosted our application there, created a database and imported our app's database dump using the database manager offered by the server. Next, we imported all the files of our application into the public_html folder of the server. Finally, in the Arduino sketch, we put in the URL part of the code the address of our online website as the address to which the trash bin should send the data, which are: - myswc- monitoring.000webhostapp.com/controllers/newHistoric.php?idTrash=value1&level=value 2&weight=value3 – For monitoring (normal update) - myswc- monitoring.000webhostapp.com/controllers/newScan.php?idTrash=value1&idWorker=valu e2 – For collection request
  • 62. 53 When sending HTTP requests with the smart trash bin, the server may return two different responses: - 601: indicates that there is a network error - 200: indicates that the request has succeeded This test also did not show any errors in the operation of the system. 4.2 Evaluation The research question in this project is how the use of IoT can help to optimize the efficiency of MSW collection. To answer this question, our hypothesis was that the IoT-based system could help optimize MSW collection by solving the problems related to lack of accurate information in the collection operation. Therefore, we developed two artifacts, a smart bin and a web app that can help to collect accurate data, thereby contributing to the optimization of MSW collection. To evaluate this, we have developed in the literature review characteristics or criteria (given in Table 1) that our system should integrate in order to resolve the MSW collection information gap. Next, we selected six properties from a list of properties that can be applied to assess software and hardware artifact proposed by Mijač (2019, p. 318) in order to evaluate how well the system is achieving its goal and how it answers the research question. The list of all properties is given in appendix 4. As properties for the evaluation, we have retained those with an occurrence frequency greater than or equal to ten percent, which are: 1. Efficacy System efficacy refers to how well the system achieves the purposes for which it was set up. In our case, the purpose of the system is to collect accurate information or data in the MSW collection operation that can help improve the efficiency of the operation. The system we have built collects information on the weight of waste generated in different areas, information on the filling level of the bins in real time, and information on the collection agents involved in the solid
  • 63. 54 waste collection program. However, it does not have any mechanism to determine the type of waste inside the bin. 2. Usefulness By collecting information on the solid waste collection operation, the system is useful to the municipality in terms of giving the municipal authorities an overview on the collection operation that can help them in decision-making, on the amount of waste generated by residents, as well as on municipal agents assigned to the solid waste collection program. By giving this overview, the usefulness of the system can be manifested in terms of avoiding waste overflows, supporting the value for money, and accurate quantification of the waste generated. In addition, it can be useful in assisting city’s authorities to focus their efforts and attention where and when it is most needed. 3. Accuracy The result of the test performed in the previous section shows that the system collects data related to the weight and the collection agents assigned to the collection program very well. However, concerning the level measurement, the system presents some inaccuracies. 4. Robustness Robustness refers to the system's ability to handle invalid inputs. Regarding input from app users, the app has input validation functionality implemented with JavaScript in the front- end user, and empty field validation for mandatory fields implemented with PHP in the back-end user. Regarding input data from smart bins, the app has a function to check whether the smart bin that sends the data is registered in the system or not, as well as a function that checks if the worker that sends the data is a registered worker. Hence, the system blocks the invalid entries on the front-end and the back-end user. As for the smart bin, the system has three data entries, which are level sensor, weight sensor and RFID reader. Here the system is less robust as it is open to everyone (public) and does not have a system to check who uses the bin and how he uses it.
  • 64. 55 5. Scalability The web server on which the application is hosted is the element that defines the scalability of this system. Smart bins are considered here as clients of the server. There can be as many as the server can support in terms of the number of requests and storage space available on the server. 6. Operational feasibility Operational feasibility refers to how management, employees and other stakeholders will operate our system and integrate it into their daily practice. Regarding management, the municipality can use this system to manage workers, contractors, smart bins in the system and app users. The contractors can also use this system to manage their own workers at their level, and monitor in real time the status of bins that are under their responsibility. Employees or collection agents will use the system to record their performance in terms of the amount of waste they collect, as well as their punctuality for the task by scanning their identity card each time they come to collect the garbage. All stakeholders involved in this system could use this system whether it is for monitoring only (receiving collection alert), personnel management or the use of data on the production and collection of solid waste. The extent to which our system can help the municipality to collect accurate information is mainly defined by the accuracy of the smart bin and the robustness of the system in handling invalid data. These two factors are key elements in solving the problem of transparency in the collection process, imprecise weighing, as well as the problem of garbage overflow by correctly reporting data and blocking invalid entries that can cause errors in the data processing. When it comes to the efficiency of MSW collection, this IoT-based system can help optimize it in case the system is accurate, robust, used appropriately, and successfully achieves its purpose. Hence, the system can help optimize the efficiency of the solid waste collection activity by promoting PRP system as it gathers all the information necessary to facilitate such a practice (worker performance monitoring). According to Unger, Szczesny and Holderried (2020, p. 10), implementing a PRP system can lead to an increase in employee productivity of up to 23%. In fact, with such a practice, it is expected that workers and contractors will intend to maximize
  • 65. 56 their income by collecting as much solid waste as possible, thus avoiding the overflow of garbage and the collection delays (IvyPanda, 2019, section 2). Apart from this, the system can aid in decision making with its ability to report waste generation by area and worker performances.