2.2 Review of IoT Applications in Environmental Engineering . ..... Figure 5. CCS 811 sensor and the wiring of it to the microprocessor board . .... communicating to the cloud or just the abnormally in the collected data will be .... gradually and its applications begin to flourish due to a reduction in the cost of sensors and also.
IoT BASED EDGE AND CLOUD COMPUTING FOR SMART ENVIRONMENTAL ENGINEERING APPLICATIONS by JAVAD ROOSTAEI THESIS Submitted to the Graduate School of Wayne State University, Detroit, Michigan In partial fulfillment of the requirements for the degree of MASTER OF SCIENCE 2018 MAJOR: COMPUTER SCIENCE Approved by:
Dr. Weisong Shi
Date
Dr. Fengwei Zhang
Date
Dr. Yongli Zhang
Date
DEDICATION I dedicate my dissertation work to my family and many friends. A special feeling of gratitude to my wife whose words of encouragement and push for tenacity ring in my ears. I also dedicate this dissertation to my many friends who have supported me throughout the process. I will always appreciate all they have done.
ii
ACKNOWLEDGMENT An exclusive appreciation is extended to Dr. Weisong Shi and Dr. Yongli Zhang for providing me the opportunity to explore using computer science knowledge in the environmental engineering field, and also for their encourage, efforts, suggestions, and advice.
iii
TABLE OF CONTENTS Dedication ……………………………………….……………………………………………………….. ii Acknowledgments …………...……………………………..……………………………………………. iii List of Tables ………………………………………….…………………………….………………….. viii List of Figures ………………………………………..………..…………………………………………. ix CHAPTER 1 INTRODUCTION .................................................................................................................. 1 1.1 Statement of Problem .......................................................................................................................... 1 1.2 Problem Statement .............................................................................................................................. 1 1.3 Research Objectives and Approach .................................................................................................... 2 1.4 Our Contribution ................................................................................................................................. 3 1.5 Thesis Outline ..................................................................................................................................... 3 CHAPTER 2 LITERATURE SURVEY, DESIGN & IMPLICATIONS ..................................................... 5 2.1 Introduction ......................................................................................................................................... 5 2.2 Review of IoT Applications in Environmental Engineering............................................................... 5 2.2.1 Ecological-Environmental Protection .......................................................................................... 7 2.2.2 Superfund Site Monitoring........................................................................................................... 8 2.2.3 Smart Water and Energy Management ...................................................................................... 11 2.3 Edge Computing Review .................................................................................................................. 11 2.4. Cloud Computing in IoT applications .............................................................................................. 12 2.5 Design and Implementation .............................................................................................................. 13 2.5.1 CCS 811 Sensor ......................................................................................................................... 14 2.5.2 BME 680 Sensor ........................................................................................................................ 14
iv
2.5.3 Camera Sensor: Pixy CMUcam5 Sensor ................................................................................... 15 2.5.4 pH Sensor ................................................................................................................................... 15 2.5.5 Adafruit Feather 32u4 FONA Board.......................................................................................... 16 2.5.6 Adafruit Feather 32u4 FONA Board.......................................................................................... 17 2.5.7 Adafruit Feather HUZZAH with ESP82 .................................................................................... 17 2.5.8 Edge Server, Raspberry Pi 3 ...................................................................................................... 18 2.5.9 Intel Edison Board ..................................................................................................................... 18 2.6 Naming the IoT Sensors and Edge Servers ....................................................................................... 19 2.7 Power Management .......................................................................................................................... 20 2.8 Connectivity of the Distributed Sensor Network .............................................................................. 21 2.9 Summary ........................................................................................................................................... 21 CHAPTER 3 CASE STUDIES of UNSIG IoT BASED EDGE and CLOUD COMPUTING ................... 23 3.1 Algae Wastewater Treatment ............................................................................................................ 23 3.1.1 Algal farm System ..................................................................................................................... 23 3.1.2 WSU IoT Lab and EPA P3 Project ............................................................................................ 25 - Describe the question........................................................................................................................ 25 - State what has been done in the question above ............................................................................... 26 - The problems that we are solving .................................................................................................... 26 - Image Processing Applications......................................................................................................... 29 - Machine Learning Applications ....................................................................................................... 31 3.2. Superfund Sites and Landfill Monitoring ........................................................................................ 32
v
- Statement of the Problem.................................................................................................................. 34 - Purpose of the Study ......................................................................................................................... 34 - Methodology ..................................................................................................................................... 35 - Results .............................................................................................................................................. 36 - Latency Evaluation ........................................................................................................................... 37 - Energy Efficiency Evaluation ........................................................................................................... 38 - Energy Efficiency Experiment two (deep sleep) .............................................................................. 39 3.3. Lake Erie Algal Bloom Monitoring ................................................................................................. 41 - Using Drones for Data Gathering ..................................................................................................... 42 3.4. Summary .......................................................................................................................................... 45 CHAPTER 4 TECHNO-ECONOMIC ANALYSIS ................................................................................... 46 4.1 MS Azure .......................................................................................................................................... 46 4.2 ThingSpeak web service ................................................................................................................... 46 4.3 Amazon Web Services (AWS) ......................................................................................................... 47 4.4 Cost comparison for different web servers ....................................................................................... 47 4.5 In Summary ....................................................................................................................................... 49 CHAPTER 5 CONCLUSION AND FUTURE STUDIES ......................................................................... 50 5.1 Conclusion ........................................................................................................................................ 50 5.2 Lessons Learned................................................................................................................................ 50 5.3 Some of the Achievements ............................................................................................................... 52 5.4 Future Studies ................................................................................................................................... 53
vi
Appendix A ................................................................................................................................................. 54 Instructions for assembling the IoT package for Environmental Engineering Applications ...................... 54 Ap.1.1 Arduino IDE Installation............................................................................................................. 54 Ap.1.2 Grove-Starter Kit ........................................................................................................................ 54 Ap.1.3 Grove LED Bar ........................................................................................................................... 55 Ap.1.4 Connecting to Wi-Fi ................................................................................................................... 55 REFERENCES ........................................................................................................................................... 62 AUTOBIOGRAPHICAL STATEMENT ................................................................................................... 68
vii
LIST OF TABLES Table 1. Results of latency evaluation in different scenarios...................................................................... 37 Table 2. Results of Energy Efficiency for different test ............................................................................. 40 Table 3. Results of using ThingSpeak web service and energy efficiency code ........................................ 48 Table 4. Results of using AWS web service and energy efficiency code ................................................... 48 Table 5. Results of using MS Azure and energy efficiency code ............................................................... 48
viii
LIST OF FIGURES Figure 1. Thesis Structure and steps ............................................................................................................. 4 Figure 2. IoT paradigm as a result of converging of different visions [10] .................................................. 6 Figure 3. Real-time monitoring of the AMCO Superfund site ................................................................... 10 Figure 4. Using IoT based Edge Computing applications in different environmental Engineering situations ..................................................................................................................................................... 13 Figure 5. CCS 811 sensor and the wiring of it to the microprocessor board .............................................. 14 Figure 6. BME 680 sensor used for VOC monitoring ................................................................................ 15 Figure 7. Camera Sensor: Pixy CMUcam5 Sensor for image processing .................................................. 15 Figure 8. pH sensor with the capability of Arduino programming ............................................................. 16 Figure 9. Adafruit Feather 32u4 FONA Board [36] ................................................................................... 16 Figure 10. Metro M0 board for some of the sensor package development ................................................. 17 Figure 11. Adafruit Feather HUZZAH with ESP82 ................................................................................... 17 Figure 12. Raspberry Pi 3 for Edge Server and Edge Computing .............................................................. 18 Figure 13. Intel Edison board and setup ..................................................................................................... 19 Figure 14. Different methods of connectivity in the IoT sensor network [38] ........................................... 21 Figure 15. Process diagram of research idea............................................................................................... 26 Figure 16. Wastewater Algal Treatment in Large Scale and the demand for IoT data collection .............. 27 Figure 17 Sensor for algae cultivation monitoring ..................................................................................... 28 Figure 18. IoT and Edge computing equipped algae cultivation system .................................................... 29 Figure 19. Image processing and the algae yield real-time data collecting system .................................... 30 Figure 20. Machine Learning applications for algae prediction ................................................................. 31 Figure 21. an application for this research is the Lake Erie Algae Bloom Monitoring .............................. 32 Figure 22. Different scenarios for sensor application in Environmental Monitoring ................................. 34 Figure 23. The idea for developing sensor packages that can be used for environmental monitoring ....... 35 ix
Figure 24. Different prototypes that we have developed in the lab for environmental monitoring ............ 36 Figure 25. Raspberry PI as an Edge server and the Huzzah sensor board ................................................. 36 Figure 26. Experiment Design and the results of running on Edge server and the lab ............................... 37 Figure 27. Power efficiency code for avoiding unnecessary communications if the conditions are good . 38 Figure 28. Sensor Package design for deep sleep experiment. ................................................................... 39 Figure 29. Sensor package will go to deep sleep and restart after 60 second ............................................. 40 Figure 30. Activities for using drones in algal monitoring ......................................................................... 43 Figure 31. Data collection area in the western basins of Lake Erie. ........................................................... 44 Figure 32. The concept of using edge computing in the drone imaging for water quality ......................... 45 Figure 33. The cost of different cloud service per number of data sent one a day ..................................... 47
x
CHAPTER 1 INTRODUCTION 1.1 Statement of Problem Earth environment is currently facing many challenges such as environmental pollutions, waste disposal, and extreme events such as climate change, ozone layer depletion and many other concerns that directly affect all humans, animals, and plants [1, 2]. Preserving, protecting, recycling and restoring the environment is an absolute necessity in all countries [3-5]. To protect the environment, we need to gather data, analyze it and make decisions based on that. Collecting data for environmental problems, which usually has a large scale, is a costly process [6]. Currently, most of the techniques that are being used are outdated and not in real-time. Internet of Things (IoT) is a trend that pushes the collecting of data and information to be less expensive and mostly in real-time. IoT sensors have not been efficiently utilized in the field of environmental engineering due to problems such as limitation of access to the power source or internet access. This research is one of the primary research that tries to push the application of IoT sensors in the field of environmental engineering. Since most of the data collected from the environment are not necessarily needed to be sent to the cloud server, the concept of Edge Computing is also utilized in this research for the aim of reducing the cost and removing the latency. In the Edge Computing Systems, most of the analytics are happening on the edge of the system, and the final results are communicating to the cloud or just the abnormally in the collected data will be communicated to the cloud. 1.2 Problem Statement Most of the environmental challenges are big in terms of scale and the demand for continuous data gathering. Current technologies for environmental data gathering mostly are not real-time but just storing the information and save it for the user that can access to it in the future
1
by manually transferring to the computer. Although in the past ten years there are some movements to use more real-time sensors in the environmental data gathering, the cost of this kind of data is a prohibitive factor. IoT sensors are mostly cheap and open source which can easily be programmed for different applications. As a result, this could give the environmental scientist a better opportunity to expand the network of data collecting by less expensive and more real-time sensor networks. Another problem that should be addressed is the huge amount of data which will be collected in a distributed sensor networks. For instance, when the environmental conditions are good based on the defined thresholds, there is no need to send the data to a cloud server. Sending all data to the cloud could cause tremendous cost and latency. Edge computing is a solution for these challenges and it helps flourishing of the IoT sensors applications in the filed of environmental engineering to be more feasible. 1.3 Research Objectives and Approach The first goal of this research is to push the applications of IoT in the field of environmental engineering. We first reviewed the state of the art of the IoT applications in the field of environmental engineering. We have developed sensor packages for different applications that sending the information to our server. Microsoft Azure has been used for cloud computing. The goal of this part of the research is to develop low-cost IoT sensors for different applications. We have used these IoT sensor packages in some of the research projects such as EPA P3 (Environmental Protection Agency: People, Prosperity, Plant) project and CLEAR (Center for Leadership in Environmental Awareness and Research) project. The second goal is to apply the Edge Computing tools for saving energy, reducing the cost and latency in the distributed IoT sensor networks. For this goal, we have developed edge servers
2
and used it as tools for collection and computation of data at the edge of the system. The final results after computing will be sent to the cloud if necessary. Additionally, some machine learning and image processing applications have been developed in this research due to some specific needs of the project which will be explained in the future chapters. 1.4 Our Contribution Since the benefits of low-cost data gathering by IoT sensors have not been reached yet to the environmental application, this work focuses on some hands-on experience of using those IoT sensor packages in the environment. Additionally, this research contributes to the reduction of computing costs by integrating Edge and Cloud Computing in the process of data gathering. Usually, the financial support for solving environmental issues are coming from taxpayers’ money. These works reduce the cost of collecting and processing the data for the distributed IoT sensor networks. 1.5 Thesis Outline In the Second chapter, we reviewed the current state of the art in using IoT based Edge and Cloud Computing in the environmental engineering. Chapter three will present the instructions of and the case studies of some applications using IoT, Edge Computing, and Cloud Computing in Environmental Engineering by this research. Machine Learning and Image processing applications are also reviewed in this chapter. The results of our work for energy efficiency and edge computing have been presented in this chapter. Since the cost reduction is one of the main claim of our work, we have shown in chapter four the results of some techno-economic analysis of using IoT in our projects. Finally, in chapter five the conclusion and the direction for future studies are presented. Figure 1 shows different stages of this thesis.
3
Literature Review
Environmental IoT Sensor Package Development Edge Computing Applications
Techno-Economic Analysis
Figure 1. Thesis Structure and steps
4
CHAPTER 2 LITERATURE SURVEY, DESIGN & IMPLICATIONS 2.1 Introduction In this chapter, various applications of IoT, Edge Computing, and Cloud Computing in the environmental engineering have been reviewed. Although the applications of these technologies have been researched in some fields such as autonomous cars, smart homes, etc., in the environmental engineering, it is usually new and rarely reported. Especially technologies such as edge computing is in the growing phase and applications of that are still under development. Studies have shown that by utilizing the IoT applications in the surrounding environment, we can be more effective in different applications such as resource management, waste reduction, and pollution control [7, 8]. 2.2 Review of IoT Applications in Environmental Engineering As an official term, for the first time, Internet of Things (IoT) has been mentioned by Kevin Ashton executive director of Auto-ID center at MIT [9]. IoT since that time started to grow gradually and its applications begin to flourish due to a reduction in the cost of sensors and also internet [10, 11]. Utilization of IoT could be enormous, and each year new industries such as healthcare, transportation, smart homes, etc. are utilizing IoT capabilities [11, 12]. Atzori et all mentioned the IoT is the convergence of different applications as in can be seen in figure 2.
5
Figure 2. IoT paradigm as a result of converging of different visions [10] Application of Internet of Things (IoT) in the field of environmental engineering could be numerous. Environmental Engineering is a field that producing a considerable amount of information. Challenges such as poor water quality, massive floods, drought, pollutions of soil and air are all related to some extent [13-15]. Using IoT sensors and analyzing the data gathered for these challenges can provide a comprehensive model which results in better understanding of us about our surrounding environment. In the following sections, we are going to review some potential applications using IoT and Edge Computing. Sustainable development is one of the keys to environmental engineering, and the methods of sustainability analysis have been discussed before [16, 17]. IoT sand Edgee computing can contribute to the sustainable development. On the other had sustainable development of IoT systems needs many consideration such as privacy, connectivity, security and power management [18]. 6
2.2.1 Ecological-Environmental Protection
One of the applications for using the IoT sensors is reported by Wu et al., 2013 for ecological-environmental protection of long-distance water diversion project [19]. Water is abundant in the world but is unevenly distributed. To solve this issue and use water resources more effectively, long-distance water diversion projects are developed all around the world. These projects, however, have negative impacts on the environment due to the construction work and operations. Wu et al. discusses the harmful effects of long-distance water diversion project has on the ecological environment and how IoT applications are being used to prevent and protect these effects [19]. Some of the main incentives of long-distance water diversion projects are utilizing water resources more efficiently, bringing in water in dryland cities, and use as hydroelectric power. However, with added benefits, there are several drawbacks such as it makes noises and contributes to pollution during the construction, aridity to the diversion area, destruction of estuarine ecoenvironment, increases water consumption and salinization in the intake, etc. IoT technologies can be a colossal phenomenon in the water industry. It uses different apparatuses such as laser scanning, sensors, and GPS to collect and monitor data specific network system with the Internet. IoT has been applied in the water industry to improve and promote water conservancy [19]. In this project Wireless sensors that detect water level and water quality sensors (that are used to monitor water quality to help prevent pollution) are installed in each water quality monitoring site. In addition, Integrated circuit (IC) cards are used to store a significant amount of information. Information includes freight type, quantity, as well as the level of danger of ships could be stored in the IC. This information is sent to the Internet Information database. Moreover, sometimes long-distance water transfer project may transport hazardous aquatic organisms from diversion area. To detect the hazardous organisms, radio frequency identification technology 7
(RFID) has been used. The RFID tags are installed on harmful aquatic organisms and these tags detect for the hazardous organisms, and they prevent the transport of these organisms [19]. Furthermore, long-distance water diversion project can add to accidents such as slipping and drowning of pedestrians, etc. IoT technologies with GPS data logger is embedded into the long-distance water transfer project to report abnormalities in the process. Using GPS technology can achieve positioning and dynamic tracking of things. So, although long-distance water diversion project negatively influences the ecological environment using IoT system in the operation of these project will create a database that can help prevent and protect the environment from these harmful effects or at least reduce the effects [19]. 2.2.2 Superfund Site Monitoring
Real-time monitoring in the Superfund sites is one of the areas that IoT sensors can be utilized effectively. As an example, we reviewed the AMCO site. AMCO Chemical is a Superfund site and was a chemical distribution company which operated from the 1960s to 1989, located in Oakland, California. In 1995, while they were digging on the site, the utility workers detected a strong smell. The California Department of Transportation, DC Metals, and the Environmental Protection Agency (EPA) conducted an investigation, and the sample indicates the presence of vinyl chloride and other chlorinated solvents in soil, soil gas and groundwater [20]. Before the 1960s, a variety of businesses, including an Anheuser Busch Store House, a bottle and rag dealer, and Walter Cole Tank Works, were located on site. Then, from the 1960s to 1989, AMCO owned and operated a chemical distribution facility on site. Bulk chemicals in that time were off-loaded from a rail spur on site and then stored in drums and storage tanks before again being transferred to smaller containers for resale [20].
8
In present times, the site is being operated by the U.S. EPA Superfund cleanup site program. To remove the toxins, from 1997-1998, EPA’s Emergency Response Program (EPR) began operating a treatment system to remove vinyl chloride-contaminated groundwater and soil vapors. Eventually, the system got cut off because the community had a concern that the system might expose the people to contaminants from the system’s exhaust stack. The AMCO cleanup expands on more than two decades of EPA’s efforts to protect public health and the environment in Oakland. To get workers on the site, EPA has awarded Cypress Mandela Training Center to train low-income, unemployed residents, and veterans of Oakland about how to manage hazardous waste and cleanup. This program costs $1.6 million since 1998 [21]. Currently, EPA is teaming up with community and partner agencies at the federal, state and local level to combat air pollution related to the truck, rail, and boat transport at the Port of Oakland. The real-time data gathering and the possibility of using IoT for management of this sites are described in this section. EPA has installed 69 underground electrodes throughout the site. These electrodes heat up the soil and boil groundwater to temperatures of up to 100°C, to vaporize and capture contaminants, such as trichloroethylene (TCE) and vinyl chloride. The contaminated material is then collected and transported offsite for safe disposal [22]. The air quality is monitored in some off-site residential area close to the AMCO site. Figure 3 shows the different accepts of real-time data gathering in this area. The average daily VOC (volatile organic compounds) is measured by sensors. Each sensor records readings for TCE (trichloroethylene), PCE (tetrachloroethylene), and Vinyl Chloride. The results that are collected from all off-site residential area by sensors then are displayed in a web page [23].
9
a)
d) TCE (trichloroethylene)
e) PCE (tetrachloroethylene)
c)
f) b)
Residential
Figure 3. Real-time monitoring of the AMCO Superfund site a) temperature contour map from the 69 underground electrodes [24], b) air monitoring sensors for real-time sampling and analysis to monitor system effectiveness [25], c) the results for one of the sensors in the site, d, e, f) Off-Site Residential Air Monitoring real-time graph presentation of three parameters in the site. Note: on the day that we visited the website the measurements in sensors was indicated zero [23].
10
2.2.3 Smart Water and Energy Management
Digitization of physical infrastructure with connected sensors has been considered as the most important driver for utilization of Big Data and IoT in the smart environment [26]. The recent research of Curry et all in Europe shows that using IoT-enabled applications in different pilots such as homes, schools, offices, university, and the airport can reduce the water usage and also emissions [8]. In this study data for user experience has been collected from different pilots in a period from 6 to 16 months. One of the primary attributes of this is that the IoT-enabled applications enhance the people awareness of using water and energy [8]. In summary, the IoT has a great potential to be used in different environmental applications. Reviewing the previous literature indicates that environmental engineering has utilized the IoT sensors to some level, but there are still huge applications that have been untouched. 2.3 Edge Computing Review Edge computing is a new analytics system that allows sensors to communicate with a decentralized computing system [27]. In this method, the data processing is happening to some extent at the network edge, instead of entirely on the cloud. Some of the promising benefits of Edge Computing is reduced the bandwidth cost and latency and also increase the battery life and privacy of the data. Although there are some concerns that the security of the whole system may be compromised or need more attention in the decentralized system [27, 28]. To fully utilize the potential of IoT sensors we have to analyze a portion of data on the edge of systems. Applications of Edge computing is growing. For example, autonomous vehicles are one of the areas that edge computing can solve massive amount of problems. Each autonomous cars will generate around 4 TB of data according to Intel [29]. Transferring this amount of data to the cloud
11
and analyzing it would be a considerable challenge. Edge computing could be a promising method for analyzing the data. An edge server in the car that analyzes the data captured by the camera and other sensors would yield more efficient response time and data processing [28, 30]. Applications of Edge computing in the area of Environmental Engineering is rarely reported. However, there are many useful applications for edge computing for environmental engineering monitoring, control, and emission reduction. For example, reports suggested that with the ever growing of data gathering and computation in the cloud experts have predicted that data centers in the near future are going to consume three times more energy in comparison with the previous decades [31]. US Department of Energy has predicted that the data centers consume 3% of the US electric power for running and maintaining the servers, computers and doing highperformance components [32]. Studies predicted that 2% of total greenhouse gas emission is based on the amount of energy which is consumed by data centers [31]. Edge computing can help to reduce the amount of energy needed for transferring and computing data in the servers. 2.4. Cloud Computing in IoT applications Since cloud computing has been studied for many years we are not going to discuss it much in this research. Part of the work that have done is related to the cloud computing applications. The system of sensors that are used in the environment is a distributed system. We can use cloud computing to take advantage of cloud elasticity and cost-effectiveness. Since in this project we are using Microsoft Azure platform, the Azure Auto-Scaling Block tool is used to elastically increase the capability of the system when memory or CPU reaches to certain thresholds. One tool in the Windows Azure is the Queue component.
12
In summary some of the applications of IoT and Edge Computing is presented in figure 4. The goal for using the Edge computing is to reduce the amount of data that is needed to be transferred to the cloud.
Figure 4. Using IoT based Edge Computing applications in different environmental Engineering situations 2.5 Design and Implementation In this section, the implementation of different IoT sensors, Edge and Cloud Computing in this research is explained. The step by step detail design is described in Appendix A. Some of the sensors and its capabilities can be seen in the following sections.
13
2.5.1 CCS 811 Sensor
This sensor has the capability of measuring Total Volatile Organic Carbon (TVOC) and equivalent Carbon Dioxide (eCO2). This sensor can detect a wide range of Volatile Organic Compounds (VOCs) and is intended for indoor air quality monitoring. This sensor has the capability to measure eCO2 concentration within a range of 400 to 8192 parts per million (ppm), and TVOC concentration within a range of 0 to 1187 parts per billion (ppb). It can detect Alcohols, Aldehydes, Ketones, Organic Acids, Amines, Aliphatic and Aromatic Hydrocarbons [33].
Figure 5. CCS 811 sensor and the wiring of it to the microprocessor board 2.5.2 BME 680 Sensor
This sensor is another environmental sensor that we purchased and worked. BME 680 contains temperature, humidity, barometric pressure and VOC gas sensing capabilities. The precision of this sensor is as following: humidity with ±3% accuracy, barometric pressure with ±1 hPa absolute accuracy, and temperature with ±1.0°C accuracy. BME 680 has a Metal Oxide SemiConductor (MOX) Gas Sensors that changes resistance based on the volatile organic compounds (VOC) in the air. It can be used to detect gasses & alcohols such as Ethanol, Alcohol and Carbon Monoxide and perform air quality measurements. The results are based on resistance value, with overall VOC content, it cannot differentiate between gasses or alcohols. The disadvantages of this sensor is that it this sensor, like all VOC/gas sensors, has variability and to get precise measurements we need to calibrate it against known sources [34]. 14
Figure 6. BME 680 sensor used for VOC monitoring
2.5.3 Camera Sensor: Pixy CMUcam5 Sensor
For image analysis, we have used the Pixy CMUCam. The Pixy CMUCam 5 is an image sensor with a powerful processor. We can program this camera for sending the information that we needed. We have used this for microalgae concentration track. The Pixy CMUCam can export its information in a variety of useful ways - UART serial, SPI, I2C, digital out, or analog out. As a result, the different microcontroller can communicate easily while still doing other tasks [35].
Figure 7. Camera Sensor: Pixy CMUcam5 Sensor for image processing 2.5.4 pH Sensor
One of the other sensors that we used is this analog pH meter which is designed for Arduino environment. This sensor has the capability of measuring pH in the range of 0-14 and with the accuracy of ± 0.1pH (25°C).
15
Figure 8. pH sensor with the capability of Arduino programming Different microcontroller boards are evaluated for making the sensor packages. We have introduced some of them here. 2.5.5 Adafruit Feather 32u4 FONA Board
This board is a very lightweight that can be used for portable microcontroller applications. One of the specific applications of this board is that it is Arduino-compatible + audio/sms/data capable cellular with built-in USB and battery charging. The board has an ATmega32u4 clocked at 8 MHz and at the 3.3V logic for processing. This chip has 32K of flash and 2K of RAM, with built-in USB so not only does it have a USB-to-Serial program & debug capability built in with no need for an FTDI-like chip [36].
Figure 9. Adafruit Feather 32u4 FONA Board [36] 16
2.5.6 Adafruit Feather 32u4 FONA Board
The Metro M0 Express can be used for Arduino IDE and also Python Programming. This board has an ATSAMD21G18 chip, and it requires a 3.3 V power support [37]. We have used this sensor for some of the packages that we have developed in the SWEET lab.
Figure 10. Metro M0 board for some of the sensor package development 2.5.7 Adafruit Feather HUZZAH with ESP82
This Board has the capability of connecting to the WIFI system with very low energy usage. We have used this as the development board for different experiments that we had. The board is low-weight and the battery usage is not very demanding.
Figure 11. Adafruit Feather HUZZAH with ESP82 17
2.5.8 Edge Server, Raspberry Pi 3
We used Raspberry Pi 3 for the purpose of Edge server and a computation processor that is working at the edge of the system. This board has the next generation Quad Core Broadcom BCM2837 64-bit ARMv8 processor which makes it has 1.2 GHz speed in processing. Also, the BCM43438 WIFI chip BUILT-IN to this Raspberry Pi. So, there is no need for WIFI adapters. Also, this board can power more device in its USB ports because of the upgraded switched power source.
Figure 12. Raspberry Pi 3 for Edge Server and Edge Computing 2.5.9 Intel Edison Board
This board is one of the most powerful boards that we have utilized. This board is designed to lower the barriers for IoT and wearable computing products. It can support Arduino Sketch, Linux, Wi-Fi, and Bluetooth. It has 20 digital input/output pins, including 4 pins as PWM outputs plus 6 analog inputs.
18
Figure 13. Intel Edison board and setup 2.6 Naming the IoT Sensors and Edge Servers Many types of IoT sensors and “things” are available in a distributed sensor network. Adding edge servers to this paradigm is also going to be a new challenge so each thing should be named and be accessible without any problem. Accessing a specific thing without interrupting with other sensors is a crucial problem in sensor and network development. The access point is the gait to reach a things and perform an operation. Studies show that currently there is no efficient and standardized naming system for edge computing devices [28]. We have to distinguish between access points and addresses. An effective system of naming is one of the essential features of the. We considered the following rule for naming our sensors objects:
19
Country Code Zip Code
Year
of
Installation
Month
(Ref)
Installation Days of Installation
of A
A
letter number from
from
a to z 1000
to
9999 US The
48201
2018
02
04
a
1000
2-letter The 5-Digit
codes
code
US4820120180204a1000 (20 characters) This coding system is specific to the US and at each zip code, and each day it can generate 26*8999=251972 things can be installed Other details about the exact position of the sensor, type of it, etc can be in another layer of information which need additional permission access.
Three levels we can consider in this –
Global level: top-level nodes. Jointly managed.
–
Administrative level: middle level. Separately managed.
–
Managerial level: bottom nodes. Need effective mapping techniques.
2.7 Power Management To manage power in our system we have used sleep mode. In many conditions the environmental condition is normal, so there is no need to communicate data to the server. We have considered that in these situations our sensor packages go to sleep mode and again start working after certain amount of time that we have defined. The results of our experiment are presented in the next chapter. 20
2.8 Connectivity of the Distributed Sensor Network As mentioned before, connectivity in environmental IoT applications is one of the main challenges that we have. There are many tools and platforms has presented in recent years. As we can see in figure 14 for different situations we have different options. Since we have worked in home networking, we used mostly WIFI. However due to level of security in WSU WIFI we had the issue of connectivity in the lab, so we have used our cellphone hotspot to get connected.
Figure 14. Different methods of connectivity in the IoT sensor network [38] LoRa is one of the technologies that I have reviewed to some extent. LoRa stands for Long Range. In this technology signal detection below 1GHz is provided to the user. This has a good potential to be utilized these technology for future studies. 2.9 Summary In this chapter, some of the previous applications of IoT sensors in the environmental engineering filed has been reviewed. Then, different IoT sensors and boards which we have used in this research has been reviewed. Specifically, the Edge server (Raspberry Pi 3) and the WIFI
21
board in this research have been used for different applications which are reviewed in more detail. At the end, our strategy for naming our distributed sensor network has been introduced.
22
CHAPTER 3 CASE STUDIES of UNSIG IoT BASED EDGE and CLOUD COMPUTING In this chapter, we utilized IoT and Edge Computing applications in Environmental Engineering. Most of these works have been done by a collaboration of Mobile and Internet Systems (MIST) Lab and Sustainable Water Environmental Energy Technologies Lab (SWEET) Lab. 3.1 Algae Wastewater Treatment Traditional wastewater treatment systems are energy intensive. Using algae farms is one of the methodologies that has been suggested to remove contamination and P and N nutrients from the wastewater resources that caused Algal bloom. Our previous studies show that we can use wastewater in the US to sustainably produce 1 billion gallons of bio-oil per year [39]. IoT and Biofuel are mentioned among one of the disruptive civil technologies with the potential of impacts on the US interest [40]. 3.1.1 Algal farm System
Environmental sensors have become a tool for understanding and controlling environmental phenomena. Recently, the IoT has gained much interest as a method to connect everyday objects with sensors and creating a network for sending and receiving data with lower cost. IoT is poised to transform the way we live and work radically, and there are many unexplored areas especially in environmental engineering which may significantly advance our understanding of the environment. One of the fields that need to be controlled is the treatment of wastewater in algal ponds. Open pond algae cultivation nowadays is the primary method of large-scale algae cultivation because of low capital cost and smooth operation. Parameters such as light density, temperature, wind velocity, and nutrient concentrations affect the algae growth yield. However,
23
our understanding about the just in time conditions is usually predefined, and the running and operations are not determined based on real-time data and daily variations. The quality of water in Lake Erie has become a concern in recent decades. Especially harmful algal blooms (HABs) in the western side of the lake is a common phenomenon in the summer. The shutdown of Toledo water treatment plant on the year 2014 is one example of how much this algal bloom is severe. Besides that, this algae species produce toxic material which are harmful to human and animal health. In term of economic effects, the HABs causes that beaches in the affected area to be closed and fishery industry reduced as well. Lake Erie is a relatively short depth lake in comparison to other Great Lakes. Besides that, this lake is in a warmer area, and especially in the summer, the weather condition is good enough to promote the HABs. Another issue that helps HABs is the amount of nutrient loads, phosphorus in particular, that drains from upstream agriculture watershed to the western basin. This work is going to use the current predictive models and data gathering systems and add some new features. Also, because many of WWTPs in the rainy seasons may have difficulty treating input wastewater, they may have released the extra discharge to the adjacent river without treatment which finally reaches to the Lake Erie. In this study, we are going to have a model that consider this effect. Our group is doing this project with SWEET Lab in Wayne State University. This research, for the first time, has addressed using the IoT sensors in controlling the algal cultivation in a laboratory prototype. To reduce the cost due to transferring huge amount of data to the cloud and avoid latency in processing the data, the Edge Computing technology has been used. Combination of IoT and Edge Computing in the collecting and analyzing of data at the edge of the system have resulted in faster computation and decision making. The processed data will be transferred to the cloud for storage and further analysis.
24
Results indicate that there are promising potentials for using IoT and Edge Computing in algal wastewater treatment in term of reducing the cost and increasing the controllability. The maximum algae growth was calculated based on the real-time measured data. The results indicate that using the sensors in the system to collect and communicate real-time data and control the system can increase the efficiency of algae growth yield by 30% and decrease labor costs by 60%. In addition, the platform and sensor packages in this research can be used in many other environmental applications. 3.1.2 WSU IoT Lab and EPA P3 Project - Describe the question
Using more environmentally friendly techniques nowadays helps communities to be more sustainable in the long run. We want to propose a more cost and energy effective solution for wastewater treatment and energy production. The main purpose of our research is to find out the feasibility of growing different types of microalgae (autotrophic, heterotrophic, mixotrophic) in an open pond system for biofuel production and evaluating the CO2 capturing potential as a way of reducing greenhouse gases. Another goal of this research is to evaluate the increase of open pond depth from current 30-50 cm to 70-100 cm as a new method for reducing land usage resources and wastewater treatment. Figure 15 shows the main idea of the research proposal, which is designing a more efficient and productive open pond system.
25
Figure 15. Process diagram of research idea - State what has been done in the question above
Algae-bacteria-based wastewater treatment has been receiving increasing interest for a costeffective strategy of algal biofuel production and wastewater treatment. Open pond algae cultivation nowadays is the main way of large-scale algae cultivation because of low capital cost and easy operation. Our previous work has evaluated the use of wastewater in the US and the potential of biofuel production in a sustainable manner [41]. Using open pond wastewater treatment with heterotrophic algae is a novel idea that so far has been studied at the laboratory scale. In our research, by designing a stratified pond we will use mixed algal cultures (autotrophic, heterotrophic, and mixotrophic) as a new suggestion for commercial microalgae cultivation. By using heterotrophic or mixotrophic culture we have suggested that the depth of open ponds can be increased from 0.3 m to 1.0 m (330% increase) which dramatically decrease the area needed for the open pond. Adoption of heterotrophic and mixotrophic algae along with autotrophic algae for large-scale algal wastewater treatment seems promising in terms of more biomass production and less land use. - The problems that we are solving
This project will be done of Water-Environmental-Energy Sustainability (WEES Lab) at the college of engineering. Using stratified algal growth is one of our suggestion for cultivating 26
different types of algae in the pond. Here the different species of algae can grow in stratified layers which increases the use efficiency of open pond. The top layer is an autotrophic layer which use light as the energy source and the middle layer is a mixotrophic layer which can use both light and organic carbon as a source of energy and finally the bottom layer is a heterotrophic layer which only use organic carbon as an energy source. As Civil and Environmental Engineering Researches it was the first time that we are exposed to these open equipment and sensors. It was challenging, but we believe it is rewarding at the end.
Figure 16. Wastewater Algal Treatment in Large Scale and the demand for IoT data collection
27
The whole procedure of Algal Biofuel Production needs many input data and also produces enormous amount of output data. By using the sensors, we can control the cultivation ponds more effective and produce higher biofuel algae with less energy.
Figure 17 Sensor for algae cultivation monitoring
Our work on this project continued and we got EPA People, Planet, (P3). We presented the results on the April 2018 at Washington DC. Figure 18 is presenting the designed stratified algae cultivation experiment that we have presented. Different IoT sensors and Edge server has been used in this model to track and optimized the algae cultivation.
28
Realtime presentation in Our website
pH Sensor Image Processing Results Light and Tempreture Sensors
Camera Sensor
Figure 18. IoT and Edge computing equipped algae cultivation system - Image Processing Applications
As we described in the previous chapter, we have used the Pixy Camera and performed image processing for real-time measurement of algae concentration as an indicator for algae yield. We trained the camera for different concentration and then connected that trained model with the algae yield data. The results were that the camera was presenting the results in real time and the concentration of the algae samples.
29
Figure 19. Image processing and the algae yield real-time data collecting system
30
- Machine Learning Applications
Machine learning has been used in many fields such as medicine, autonomous cars, manufacturing, etc [42-46]. We have tried to used this techniques in Environmental Engineering as another set of application that we performed is to train a regression model based on the huge amount of data that we collected in the lab. This model will predict the algae yield based on some parameters such as light intensity or temperature that affects the yield.
Regression Model Results
Independent Variables
Real-time calculation of algae yield
Figure 20. Machine Learning applications for algae prediction
31
This mythology can be used in this lake to analyze and train the algorithm for coming up to predict algae bloom in the Lake Erie which is a huge problem. We can easily track and measure parameters such as light intensity, temperature etc. But measuring algae concentration requires more expensive sensors. So, machine learning could be a solution for reducing the cost.
Figure 21. an application for this research is the Lake Erie Algae Bloom Monitoring 3.2. Superfund Sites and Landfill Monitoring Southeast Michigan supports a high population density living in relative proximity to landfills and superfund sites. The emission of Volatile Organic Compounds (VOCs) from these sites poses significantly ecological and human health risk. Sensing is gaining increasing interest in advancing understanding of environmental conditions and changes affecting both human and ecological health [47]. This technology identifies earth surface materials, including waste contaminants, based on the interaction of electromagnetic energy with the molecular structure of the material being sensed [47, 48]. It has been used to detect fugitive contamination at a number of Superfund hazardous waste sites in Pennsylvania. In addition, hyperspectral sensors can record reflected and emitted electromagnetic energy in hundreds of narrow wavelengths, resulting in data that can be analyzed with the same chemical 32
spectroscopic techniques [47]. This method has been used in a few studies to identify organic pollutants such as Trichloroethylene (TCE) in various environments [49]. In this aim, autonomous drones installed with hyperspectral sensors (available in the market) will be used to detecting potential VOCs commination for one Superfund site. This will generate high-resolution date coverage for the entire superfund site to screen contaminated hotspots for further investigation. Developing IoT sensor networks with edge computing for real-time monitoring of VOCs at the Superfund site and selected homes is the main goal of this research. IoT sensor networks are emerging technologies that provides real-time sensing and control with improved efficiency, accuracy, economic benefit and reduced human intervention. Edge computing provides a new computing paradigm for much more efficient data processing at the edge of the network [27]. Integrating IoT sensor networks with edge computing is particularly promising in environmental monitoring with the benefit of real-time detection and fast and efficient data gathering / processing. In this project, an end-to-end distributed monitoring network that contains sensors will be developed and installed around one Superfund site and selected homes as a pilot project to monitor and analyze VOCs in real time. Automated monitoring is a key for managing superfund sites efficiently. Developing this IoT sensor network for one superfund site could be used and scaled for other superfund sites. For this project, different technologies for data collection will be used, including drone equipped with hyperspectral sensors, in situ and portable VOCs sensors. In addition to VOCs data, environmental conditions at each monitoring site such as temperature, pH and humidity will be simultaneously monitored. These environmental parameters will be easily obtained by using available sensor packages. Edge computing will be used to process collected data from different.
33
- Statement of the Problem
Having a reliable source of energy in a distributed sensor network in the environmental monitoring is considered as the main problem of utilizing the IoT sensors. This challenge is mostly addressed by using solar panels or more robust battery packages which are costly and inefficient. On the other hand, when the system is scaled up, managing this distributed sensor network in term of energy efficiency is an additional challenge that can contribute to the cost of data collecting and transferring. - Purpose of the Study
In this project, we compared three methods of data collection for the application in the environment. The sensor packages that we worked can collect different parameters such as Temperature, Pressure, Humidity and Volatile Organic Carbon (VOCs). Figure 22 depicts the three methods of data collecting and communicating. Latency is another aspect of the problem that can be improved.
Figure 22. Different scenarios for sensor application in Environmental Monitoring a) Computation happens at the microprocessor on the sensor package, b) all the data transmitted to the cloud for further processing, c) Data transmitted to the Edge server and then the results of that transmitted to the cloud for further analysis
34
- Methodology
In this project we made different sensor packages that collect the environmental data and compare the energy efficiency for the three scenarios that we proposed in figure 22 We Microsoft Azure, and Raspberry Pi 3 as a cloud platform and edge server. In terms of latency efficiency, the data gathered from the environment in most case do not need to send very fact and latency is tolerable, but we want to address this challenge as well. Figure 23 Shows the general idea of developing IoT sensors for environmental monitoring. In the following pictures, we have shown different sensor packages that we have developed.
Figure 23. The idea for developing sensor packages that can be used for environmental monitoring Based on this we have purchased many sensors and boards for collecting data, and we assembled and programmed those packages for different applications.
35
Intel Edison Board
Metro Express Board
Arduino Uno Board
Figure 24. Different prototypes that we have developed in the lab for environmental monitoring Since Adafruit Feather HUZZAH with ESP8266 can be operated on low power and has the capability to programmed and send the data to cloud via WIFI, we decided to use the future experiments based on this board. Also, we used Raspberry Pi 3 as our Edge server.
Figure 25. Raspberry PI as an Edge server and the Huzzah sensor board We used Linux environment for programming and Microsoft Azure for cloud computing. Besides that, the results of our real-time monitoring are projected to our website at SWEETLAB.TECH. - Results
In this section first, we will present some screenshot of the different running environment of the project.
36
Figure 26. Experiment Design and the results of running on Edge server and the lab - Latency Evaluation
For evaluation of the latency of sending the information via different methods, we have put some time tracking lines of code. To get the actual time both initial time and the final time have been calculated in the sensor package processor. As first the sensor sends the information to the edge server or the Microsoft Azure cloud platform. Then in the server, it is compared with the thresholds that we set (CO2 ≤ 1000ppm, TVOC ≤200ppb, and T≤35°C). If the condition for each of these criteria is above these levels, it sends an error code to the sensor package. Then in the sensor package, we read the error code and with an if loop we project the condition of the environment and record the time. The latency is the time that sensor sends the data and then sensor project the error code in the computer. The results for different scenarios are presented in table 1. Based on the data we can see the latency in the edge server is less than on the cloud computing.
Table 1. Results of latency evaluation in different scenarios Processing the abnormal conditions On the microprocessor of the sensor package On the Raspberry Pi edge server On the Microsoft Azure Cloud server 37
Latency (µS) 10 490 (13% less than cloud) 560
- Energy Efficiency Evaluation
We have implemented additional line of codes and wiring in the board in the processor for evaluating the energy efficiency. This purpose of this code is to avoid unnecessary communications if the conditions of the environment are good (all three parameters are below the threshold). We implemented some additional steps. If the conditions are good delay the second recording by 1000 millisecond, So the next running will happen after two seconds instead of one. If still conditions are good, keep delaying until 10 seconds and then restart the power efficiency code to the delay zero. By this method, we can avoid the unnecessary communications that cause energy consumption. Figure 27 shows the code and the results of running power efficiency code in the algorithm.
Figure 27. Power efficiency code for avoiding unnecessary communications if the conditions are good
38
By this, we can reduce the sensor data communication by 40%. However, the real effect of this method on the reducing energy efficiency needs more experiment, and I plan to do it in the future. - Energy Efficiency Experiment two (deep sleep)
In another set of experiment, we have analyzed the energy efficiency of similar batteries with different condition. We have used the capability of restarting the sensors after a period of sleep. We call it deep sleep test. Figure 28 depicts the connectivity of sensor package for going to deep sleep and a built-up packages that we used for this purpose.
Figure 28. Sensor Package design for deep sleep experiment. So, in this experiment, when the condition is good the sensor went to a deep sleep and then restart after 60 seconds.
39
Figure 29. Sensor package will go to deep sleep and restart after 60 second As a control we test another similar package without any energy efficiency code that avoid the system to goes to deep sleep. We have used two similar 500 mAh batteries for this experiment with different charging time of 1 hours, 2 hours, and 3 hours. We also switched the batteries between different sensors that remove the issue of factory dissimilarities in case. There are 15 seconds delay between each recording which we considered so the data is showing up in our website. The sensor package with energy efficiency code will has a period of 60 seconds deep sleep, and the sensor package without energy efficiency will have not. The results of this test have been presented in table 2.
Table 2. Results of Energy Efficiency for different test
These results indicate that when the condition is good (TVOC < 200 ppm) the sensors can go to sleep mode and avoid unnecessary transmission of the data. For example, in 2 hours charging duration we can reduce the number of data point sending to our server about 50% and also, we can 40
increase the duration of functionality in the sensors by about 30%. This test indicates that we can implement energy efficiency to reduce the cost of data sending to the cloud server and increase the duration of operation. In Chapter 5 we have reviewed the techno economic analysis of using energy efficiency techniques in combination with Edge Computing platform. This project was evaluating the application of IoT sensors for environmental monitoring of VOC gases. We have developed multiple sensor packages and evaluated the performance of HUZZAH with ESP8266 as a microprocessor with CCS 811 sensor. Three methods are evaluated. First, all processes happening on the sensor packages. Second, multiple sensor packages send the data to the edge server, and the third method is the sensor package send date to MS Azure. The results of these methods indicate that we can improve the latency by using edge server in comparison to the cloud. For just one sensor package we can see 13% less latency on the edge server. This latency could scale up when we have multiple sensor packages communicating to the edge server, and at the same time, it can reduce the cost of communication. Besides that, we have tried the energy efficiency by using codes to avoid unnecessary communication. This code is delaying the next measurement by 1000 millisecond if the conditions are good. The delay will continue until the total of 10-second delay has been recorded. Then the code restarts the measurement to the usual situation. By using this algorithm, we could reduce the unnecessary communication by 40% which can result to lower energy usage. However, more field study is needed to finalize the exact number of energy efficiency management in this IoT sensor network.
3.3. Lake Erie Algal Bloom Monitoring Algae bloom is a huge problem in the great lakes area, specifically in Lake Erie. Tracking nutrients such as nitrogen and phosphorous in real-time are something that is recently happening around the west section of Lake Erie. However, the resolution of data in these systems is not good enough to give us a comprehensive understanding of the whole quality, and also the current 41
technologies are quit costly and need manpower. Using IoT sensors for tracking blue-green algae and other contaminants can be a potential method with lower cost. Sensor packages could also be used by people in communities for gathering data. This is usually referred to as citizen science. The sensor packages can be used by high school students in their fields trips for gathering scientific information about water quality. To reduce the amount of raw data that is sent by sensors to the cloud server, we can send the analyzed results of this raw data, or even transfer the abnormality in data. Here the concept of Edge computing will be helpful. Edge Computing is considered a technology that allows computation to happen at the edge of the network, close to the data center. Edge computing can provide more efficient data transferring and analyzing. Some of the applications of using IoT sensors with EC are described here: - Using Drones for Data Gathering
A camera with different set of filters that can track algae bloom can be installed in drones. The data could process in the board installed in the drone or in a local data server. This could avoid the communication of the whole data set to the cloud. Only when the quality of water is not good and there is a sign of algae bloom, the data will be communicated to the cloud. Of course, there should be a training data set and an algorithm that helps compare the pictures with a set of pictures that indicates the algae bloom. Another application of using drone is the package sensors that can be installed in the drone. These sensors can track different quality parameters for air, water and soil quality. In case of water, the sampling can be happened by submerging the sensor package in the water or also taking samples and bring it to the lab. In the case of air quality, the sampling can happen by flying drones with the sensors in the zone of interest and measuring the quality of air.
42
Again Edge Computing could provide great opportunity in this area. The whole trace of data can be analyzed in the edge of the system, and only the abnormalities are communicated to the cloud. For example, if the temperature or pH of water in all areas of sampling is in a defined safe range, the data will be stored locally, and when the measurements are out of the defined range (a sign of air pollution), the system can send the data back to the cloud. Superfund sites need continuous monitoring to prevent leakage and avoid health problems. Here IoT sensors and Edge computing can reduce the costs of monitoring and also provide a set of data with higher resolutions. Different quality sensors can be installed around the sites and also in households near the site. The collected data then can be analyzed in the Edge Computing, and the results of that in case of any abnormalities can be communicated to the cloud for further analyses so that the authorities can make informed decisions.
Figure 30. Activities for using drones in algal monitoring Based on this we have tried some of the IoT sensors installed in the drone for sampling and image collection in Lake Erie on Summer 2017. Figure 31 shows some of the applications of this 43
work. Additionally, considering the concept of edge server is one of the main factors that affect the application of drones. We can analyze many of the data with an edge server that is installed in the drone (figure 32).
Figure 31. Data collection area in the western basins of Lake Erie. Each red circle indicates one sampling area with 6-8 collection sites summer 17.
44
Figure 32. The concept of using edge computing in the drone imaging for water quality 3.4. Summary In this chapter, we have reviewed different applications of using IoT and Edge Computing in the field of environmental engineering. Some parts of our works have received further funding and for EPA and WSU. Also, the results of our works have been presented at some conference and workshops. Considering energy saver technologies such as deep sleep mode in our sensor packages we have reduced the amount of unnecessary data communication by around 50% and increase the battery operation duration by 130%. In conclusion, we can see a high potential for using IoT and Edge Computing in the area of environmental engineering such as algal wastewater treatment, VOC monitoring and algae bloom monitoring.
45
CHAPTER 4 TECHNO-ECONOMIC ANALYSIS This chapter we are reviewing the cost saving of using our deep sleeping code for saving energy. We have first collected information on the cost of using this data communications to different cloud servers. 4.1 MS Azure The information for cost has been gathered from the following website. We have considered standard tier. https://azure.microsoft.com/en-us/pricing/details/iot-hub/ 1 – 8,000 messages sent per day = Free 8,001 - 400,000 messages sent per day = $25/month 400,001 - 6,000,000 messages sent per day = $250/month 6,000,001 - 300,000,000 messages sent per day = $2500/month
4.2 ThingSpeak web service Mathwork Inc group operates the ThinkSpeak website. We found this website very easy to use and implement our IoT solutions. Some of the main works that we presented in SWEETLAB.TECH is based on the services that the ThingSpeak.com provides. The cost for their service is presented based on the Annual License on the following link. https://thingspeak.com/prices/thingspeak_academic 1 – 8,333 messages sent per day = Free 8,334 - 91,667 messages sent per day = $250/year 91,668 - 183,333 messages sent per day = $500/year 183,334 - 275,000 messages sent per day = $750/year
46
4.3 Amazon Web Services (AWS) AWS is one of the leading cloud services that are available. We have uses collected the cost information base on the monthly bill of the service. This information is available in the following web pages. https://aws.amazon.com/iot-core/pricing/ https://d1.awsstatic.com/IoT/assets/AWS_IoT_Core_Pricing_Calculator.0097ce19f649b854b9480f633057 3f2e805ca6b7.xlsx
8000 messages sent and received per day = $0.24/month 20,000 messages sent and received per day = $1/month 50,000 messages sent and received per day = $2/month 100,000 messages sent and received per day = $3/month 400,000 messages sent and received per day = $12/month
Figure 33. The cost of different cloud service per number of data sent one a day 4.4 Cost comparison for different web servers As we can see in the figure 33 the price of using different services is jumping from one level to another level based on the number of data per day that IoT sensor packages are sending. If we analyze each of the cloud services, we can see there is a possibility to save money in some situations if we use our deep sleep mode system. The power efficiency would results a 51% data communication reduction. Based on this we can see there are some saving.
47
Table 3. Results of using ThingSpeak web service and energy efficiency code Total Data Send per day
Total Cost Per Month without energy reduction ($)
Data reduction due to energy efficiency
No. of data send with energy efficiency code ($)
Total Cost Per Month without energy reduction ($)
8,640
21
51%
4,406
0
21
25,920
21
51%
13,219
21
0
77,760
21
51%
39,658
21
0
155,520
42
51%
79,315
21
21
274,000
63
51%
139,740
42
21
Cost Reduction ($)
Table 4. Results of using AWS web service and energy efficiency code Total Data Send per day
Total Cost Per Month without energy reduction ($)
Data reduction due to energy efficiency
No. of data send with energy efficiency code ($)
Total Cost Per Month without energy reduction ($)
Cost Reduction ($)
8,640
1
51%
4,406
0
1
25,920
2
51%
13,219
1
1
103,680
12
51%
52,877
3
9
274,000
12
51%
139,740
12
0
395,000
12
51%
201,450
12
0
Table 5. Results of using MS Azure and energy efficiency code Total Data Send per day
Total Cost Per Month without energy reduction ($)
Data reduction due to energy efficiency
No. of data send with energy efficiency code ($)
Total Cost Per Month without energy reduction ($)
Cost Reduction ($)
86,400
25
51%
44,064
25
0
864,000
250
51%
440,640
250
0
8,640,000
2,500
51%
4,406,400
250
2,250
86,400,000
2,500
51%
44,064,000
2,500
0
290,000,000
2,500
51%
147,900,000
2,500
0
However, implementing the edge servers is also expensive and there should be a complete cost analysis to understand the whole effect of having a technoeconomic analysis. For example,
48
right now each Raspberry Pi is around $30-$35. Utilizing it also needs some technician works. And in this research we have not considered this part of costs in the techno-economic analysis. 4.5 In Summary Financial analysis of using different cloud services is presented in this chapter. Results indicate that there is a possibility of saving cost in some level of data transmitting if we use power efficiency code. Since the data that we had for each of these three systems has different maximum amount per day, it is difficult to change to make a comparison with similar data so we analyzed each one based on the maximum data per day that we had cost information. As a result, we can see that AWS is cheap in the systems up to 400K data per day. Microsoft Azure is good for a system a large-scale data sending per day, and we can see in the level of 8,640K data we can save $2,250 per month.
a
49
CHAPTER 5 CONCLUSION AND FUTURE STUDIES 5.1 Conclusion In conclusion, our research is one of the primary research in the area of using IoT and Edge Computing for Environmental Engineering applications. We have shown that different sensors and board can be used to create a sensor package that are useful for the environmental monitoring applications. Each sensor package has its specific capabilities. We have seen that the Huzzah board is a good candidate for environmental IoT sensor package since it can easily connect to WIFI and can be programmed for each sensor application. As an Edge Server, we used Raspberry pi 3 which can be easily programmed and different sensors get connected. We have used power management code and wiring that make sensors go to sleep mood if the conditions are normal. The results which are presented in table 2 shows that we can reduce the amount of data transmission by 50% and increase the duration of operation by 130%. Many of the results and information of this research has been sending in real-time to our website (SWEETLAB.TECH) so we have had a webpage development as well in this research. 5.2 Lessons Learned After this research and based on the results that is presented, some of the main lessons that I have learned are: 1. Applications of IoT in the field of environmental engineering are tremendous. However, many sensors are not yet accurate enough to capture the good quality of the data. There is a big demand for designing specific IoT sensors for specific problems. This can be seen in the research and experiment that we have performed in WSU for TVOC monitoring. The current commercial sensors are not accurate enough to give us some acceptable scientific results.
50
2. Price of producing new IoT sensors are decreasing every day. This inherently means more and more data producer will be connected to the Internet, which means more data collected and will need to be processed in the cloud. As a result, edge computing and its applications are quite favorable to manage this ever-growing of using IoT sensors. Based on our research we found out that using edge server can reduce the volume of data points and increase the duration of sensor operation (power management). So, we can say edge computing is necessary tools for the future of distributed environmental IoT sensors. 3. Power and connectivity management is going to be the main challenge of environmental sensors. Because most of the sensors are going to be installed in remote areas, it is critical to set up robust power management and internet connectivity system. Solar panel and rechargeable batteries are some alternatives for providing power. On the other hand, Long Range (LoRa) for example is a low power wireless platform is the prevailing technology choice for building IoT networks worldwide. 5G network system can open many promising opportunities for environmental IoT sensors. In this research, we could not pursue the use of solar panels our connections systems such as LoRa. However, we used code to manage the power and operation time. 4. Security is a whole subject that needs to be addressed from the very beginning of the IoT setup. Our research at this stage is not sensitive; however if the environmental monitoring of a real system depends on our IoT sensors, we have to consider firm measures that prohibit the marvelous attacks. Personally, since my knowledge about security is still limited, I could not evaluate the sensor package that I have designed in term of a gap for security intrusions.
51
5.3 Some of the Achievements The research resulted in some poster presentation, and provide data for proposal submission. Besides that, we have received some awards in this project. - Presentation 1. Real-time and High-Resolution Monitoring of VOCs at Superfund Hazardous Waste Sites by Using Internet of Things (IoT) Sensor Networks, Poster presentation, WSU, March 2018 2. Stratified Multilayer Algal-biofilm Reclamation Technology (SMART) Coupled with Internet of Things (IoT): A Novel Wastewater-Algae System for Efficient Wastewater Treatment and Sustainable Bioenergy Production, EPA, Washington DC, April 2018 3. Smart Wastewater Treatment: Internet of Things (IoT) and Edge Computing Applications in Environmental Engineering, Michigan Environmental Health Association’s 2018 Annual Education Conference - Awards 1. First place, STEAM Challenge, Awarded $10,000 for Remote Urban Farming Analytics, 11/2017 2. First place, best overall winner, Detroit Industrial Hack, General Electric and Henry Ford Museum, 7/2017 3. Second Place Winner Award in College of Engineering Student Innovation and Design Day, 4/2017 4. Third Place winner Intel IoT Innovators Lab at WSU,
52
- Journal Article One manuscript under preparation for the applications of IoT and Edge Computing in Environmental Engineering field. 5.4 Future Studies After doing this research, some of the main gaps that we found and need to be addressed in future studies are: -
Implementation of sensors in the field and work on the power management and connectivity
-
Security
-
More applications of Edge Computing for power and latency management
53
Appendix A Instructions for assembling the IoT package for Environmental Engineering Applications Ap.1.1 Arduino IDE Installation 1. Download Arduino IDE (Arduino 1.8.4) from https://www.arduino.cc/en/Main/Software Click on Windows Installer 2. Create a folder Arduino in Windows (C:) and unzip Arduino-1.8.4 in there. 3. Connect Arduino board to PC through the USB cable. The green LED will light up. 4. Search ‘Device Manager’ from the Start menu. Look under ‘Ports (COM & LPT)’ and note the port number associated with the board. 5. Open up Arduino application from C:\Arduino\Arduino-1.8.4 Click on Tools > Board and select ‘Intel Edison’. Click on Tools > Port and select the port number noted from ‘Device Manager’. 6. Click on File > Examples > Basics > Blink Click on Upload. If the green LED starts blinking, installation was successful.
Ap.1.2 Grove-Starter Kit 1. Go to https://github.com/Seeed-Studio/Sketchbook_Starter_Kit_for_Arduino and Download ZIP. 2. Extract folder to Desktop or Documents. 3. Open the folder and click on ‘libraries’ folder. 4. Copy folder(s) listed under ‘libraries’ to C:\Users\USER_NAME\AppData\Local\Arduino15\packages\Intel\hardware\i686\1.6.7+1.0\libra ries 5. To test if Grove-Starter Kit works, go to ‘Sketchbook_Starter_Kit_for_Arduino’ folder in Desktop or Documents. 6. Go to any folder such as, Grove_RGB_Backlight_LCD > Autoscroll and open up application NOTE: The sensor must be connected to the board 54
REFERENCES 1.
McPhillips, L.E., et al., Defining Extreme Events: A Cross‐Disciplinary Review. Earth's Future, 2018. 6(3): p. 441-455.
2.
Gardner, G.T. and P.C. Stern, Environmental problems and human behavior. 1996: Allyn & Bacon.
3.
Peiravi, M., et al., Bioelectrochemical treatment of acid mine drainage (AMD) from an abandoned coal mine under aerobic condition. Journal of hazardous materials, 2017. 333: p. 329338.
4.
Peiravi, M., et al., Chemical extraction of rare earth elements from coal ash. Minerals & Metallurgical Processing, 2017. 34(4): p. 170-177.
5.
Vermesan, O. and P. Friess, Internet of things: converging technologies for smart environments and integrated ecosystems. 2013: River Publishers.
6.
Liu, C., K. Wu, and J. Pei, An energy-efficient data collection framework for wireless sensor networks by exploiting spatiotemporal correlation. IEEE transactions on parallel and distributed systems, 2007. 18(7): p. 1010-1023.
7.
Pan, J., et al., An internet of things framework for smart energy in buildings: designs, prototype, and experiments. IEEE Internet of Things Journal, 2015. 2(6): p. 527-537.
8.
Curry, E., et al., IoT-Enhanced User Experience for Smart Water and Energy Management. IEEE Internet Computing, 2018.
9.
Ashton, K., That ‘internet of things’ thing. RFID journal, 2009. 22(7): p. 97-114.
10.
Atzori, L., A. Iera, and G. Morabito, The internet of things: A survey. Computer networks, 2010. 54(15): p. 2787-2805.
11.
CISCO, The Internet of Things, How the Next Evolution of the Internet Is Changing Everything. 2011.
12.
Gershenfeld, N., S. Samouhos, and B. Nordman, Intelligent infrastructure for energy efficiency. Science, 2010. 327(5969): p. 1086-1088. 62
13.
Shafiei Shiva, J., et al. Development of a low-budget, remote, solar powered, and self-operating rain gauge for spatial rainfall real time data monitoring in pristine and urban areas. in AGU Fall Meeting Abstracts. 2016.
14.
Gubbi, J., et al., Internet of Things (IoT): A vision, architectural elements, and future directions. Future Generation Computer Systems, 2013. 29(7): p. 1645-1660.
15.
Hansen, C., et al., Using the National Water Model Forecasts to Plan for and Manage Ecological Flow and Low-Flow during Drought. National Water Center Innovators Program Summer Institute Report 2017, 2017: p. 66.
16.
Moradi-Aliabadi, M. and Y. Huang, Multistage optimization for chemical process sustainability enhancement under uncertainty. ACS Sustainable Chemistry & Engineering, 2016. 4(11): p. 6133-6143.
17.
Aliabadi, M.M. and Y. Huang, Vector-Based Sustainability Analytics: A Methodological Study on System Transition toward Sustainability. Industrial & Engineering Chemistry Research, 2015. 55(12): p. 3239-3252.
18.
Farooq, M.U., et al., A critical analysis on the security concerns of internet of things (IoT). International Journal of Computer Applications, 2015. 111(7).
19.
Wu, D.F., L.Q. Dai, and H.C. Dai. Application of Internet of Thing Technology in EcologicalEnvironmental Protection of Long-Distance Water Diversion Project. in Applied Mechanics and Materials. 2013. Trans Tech Publ.
20.
EPA. AMCO CHEMICAL, OAKLAND, CA, Cleanup Activities. 2018; Available from: https://cumulis.epa.gov/supercpad/SiteProfiles/index.cfm?fuseaction=second.cleanup&id=09053 34#bkground.
21.
EPA. U.S. EPA kicks-off cleanup at West Oakland Superfund site. 2017; Available from: https://www.epa.gov/newsreleases/us-epa-kicks-cleanup-west-oakland-superfund-site.
22.
Manheimer, K. AMCO NPL SITE, Thermal Heating Progress. 2018; Available from: https://response.epa.gov/site/site_profile.aspx?site_id=5215. 63
23.
EPA. Off-Site Residential Air Monitoring, AMCO Chemical Superfund Site. 2018; Available from: https://r9.ercloud.org/amco/Default.aspx.
24.
EPA. AMCO Chemical Superfund Site, Tempreture Contour map, sensors depth 10.63 ft. 2018; Available from: https://goo.gl/iyjwtv.
25.
EPA. AMCO Chemical Superfund Site, Air Monitors System. 2018; Available from: https://goo.gl/xBjf3d.
26.
Sheth, A., P. Anantharam, and C. Henson, Physical-cyber-social computing: An early 21st century approach. IEEE Intelligent Systems, 2013. 28(1): p. 78-82.
27.
Shi, W., et al., Edge computing: Vision and challenges. IEEE Internet of Things Journal, 2016. 3(5): p. 637-646.
28.
Shi, W. and S. Dustdar, The promise of edge computing. Computer, 2016. 49(5): p. 78-81.
29.
Krzanich, B. Data is the new oil in the future of automated driving. 2016 2018]; Available from: https://newsroom.intel.com/editorials/krzanich-the-future-of-automated-driving/.
30.
Varghese, B., et al. Challenges and opportunities in edge computing. in Smart Cloud (SmartCloud), IEEE International Conference on. 2016. IEEE.
31.
Bawden, T. Global warming: Data centres to consume three times as much energy in next decade, experts warn. 2016 [cited 2018; Available from: https://goo.gl/WoHhVn.
32.
DOE, U. Energy 101: Energy Efficient Data Centers. 2017 2018]; Available from: https://goo.gl/SThqEF.
33.
Adafruit. Adafruit CCS811 Air Quality Sensor Breakout - VOC and eCO2. 2018; Available from: https://www.adafruit.com/product/3566.
34.
Adafruit. Adafruit BME680 - Temperature, Humidity, Pressure and Gas Sensor. 2018.
35.
Adafruit, Pixy CMUcam5 Sensor. 2018.
36.
Adafruit. Adafruit Feather 32u4 FONA. 2018.
37.
Adafruit. Adafruit METRO M0 Express - designed for CircuitPython - ATSAMD21G18. 2018.
64
38.
Blyler, J. Top 5 RF Technologies for 5G in the IoT. 2017; Available from: http://www.mwrf.com/systems/top-5-rf-technologies-5g-iot.
39.
Roostaei, J. and Y. Zhang, Spatially Explicit Life Cycle Assessment: Opportunities and challenges of wastewater-based algal biofuels in the United States. Algal Research, 2016.
40.
Nic, N., Disruptive civil technologies: Six technologies with potential impacts on us interests out to 2025. Tech. Rep., 2008.
41.
Roostaei, J. and Y. Zhang, Spatially explicit life cycle assessment: opportunities and challenges of wastewater-based algal biofuels in the United States. Algal Research, 2017. 24: p. 395-402.
42.
Nezhad, M.Z., et al. Safs: A deep feature selection approach for precision medicine. in Bioinformatics and Biomedicine (BIBM), 2016 IEEE International Conference on. 2016. IEEE.
43.
Sadati, N., R.B. Chinnam, and M.Z. Nezhad, Observational data-driven modeling and optimization of manufacturing processes. Expert Systems with Applications, 2018. 93: p. 456464.
44.
Nezhad, M.Z., et al., A Deep Active Survival Analysis Approach for Precision Treatment Recommendations: Application of Prostate Cancer. arXiv preprint arXiv:1804.03280, 2018.
45.
Aguwa, C., M.H. Olya, and L. Monplaisir, Modeling of fuzzy-based voice of customer for business decision analytics. Knowledge-Based Systems, 2017. 125: p. 136-145.
46.
Olya, M.H., B. Shirazi, and H. Fazlollahtabar, Adapted dynamic program to find shortest path in a network having normal probability distribution arc length. Advances in Industrial Engineering and Management, 2013. 2(1): p. 5-10.
47.
Slonecker, E.T. and G.B. Fisher, An evaluation of remote sensing technologies for the detection of fugitive contamination at selected Superfund hazardous waste sites in Pennsylvania. 2014, US Geological Survey.
48.
Green, R.O., et al., Imaging spectroscopy and the airborne visible/infrared imaging spectrometer (AVIRIS). Remote sensing of environment, 1998. 65(3): p. 227-248.
65
49.
Bangalore, A.S., et al., Automated detection of trichloroethylene by Fourier transform infrared remote sensing measurements. Analytical Chemistry, 1997. 69(2): p. 118-129.
a
66
IoT BASED EDGE AND CLOUD COMPUTING FOR SMART ENVIRONMENTAL ENGINEERING APPLICATIONS by JAVAD ROOSTAEI August 2018 Advisor: Dr. Weisong Shi Major: Computer Science Degree: Master of Science Earth’s environment is currently facing many challenges. To protect the environment, we need to gather data, analyze it and make decisions based on that, which usually is expensive and the amount of data needed is substantial. Internet of Things (IoT) is a trend that helps the collecting of data and information to be less expensive and mostly in real-time. This research is one of the primary research that tries to push the application of IoT and Edge Computing sensor technologies in the field of environmental engineering. The aim is to reduce the cost and improve battery life operation and the latency. In this thesis, we reviewed the previous research and presented some of the applications of IoT and Edge computing in our work. Additionally, some machine learning and image processing applications have been developed. Projects that we worked in this thesis are: 1) Algae Wastewater Treatment; 2) Superfund Sites and Landfill Monitoring; and 3) Lake Erie Algal Bloom Monitoring The results indicate that in our sensor package by utilizing energy saver code, we can reduce the amount of data transmission by 50% and increase the duration of operation by 130%. Besides that, techno-economic analysis shows that is a potential for cost reduction in some of the web service applications.
67
AUTOBIOGRAPHICAL STATEMENT Javad Roostaei is a doctoral candidate in Civil and Environmental Engineering and a Master student in Computer Science at Wayne State University in Detroit, Michigan. His area of research is using Internet of Things (IoT), Edge Computing, Cloud Computing, and their applications in Environmental Engineering. Additionally, he has experience in the area of Spatial Analysis, Sustainability, Life Cycle Assessment (LCA), and Algae Biofuels. He has a bachelor's degree in Civil Engineering (Water and Wastewater Engineering) and a master's degree in Civil Engineering (River Engineering Specialty) both from Shahid Beheshti University (SBU), Tehran and he received my second master's degree in Environmental Engineering from Wayne State University. He has five years of professional experience in the consulting engineering companies as a senior Hydraulic Engineer and Project Manager in water network design, ArcGIS, and AutoCAD mapping. In addition, he has published 16 papers in national and international conferences, one journal article (4 journal articles under review), two joint registered patents, and another patent under review for sending to US patents. For more details, please visit his web pages on https://sites.google.com/site/javadroostaeienvironment/home
68