Design and Implementation of Portable Outdoor Air Quality Measurement System using Arduino

Received Oct 6, 2017 Revised Nov 13, 2017 Accepted Dec 2, 2017 Recently, there is increasing public awareness of the real time air quality due to air pollution can cause severe effects to human health and environments. The Air Pollutant Index (API) in Malaysia is measured by Department of Environment (DOE) using stationary and expensive monitoring station called Continuous Air Quality Monitoring stations (CAQMs) that are only placed in areas that have high population densities and high industrial activities. Moreover, Malaysia did not include particulate matter with the size of less than 2.5μm (PM2.5) in the API measurement system. In this paper, we present a cost effective and portable air quality measurement system using Arduino Uno microcontroller and four low cost sensors. This device allows people to measure API in any place they want. It is capable to measure the concentration of carbon monoxide (CO), ground level ozone (O3) and particulate matters (PM10 & PM2.5) in the air and convert the readings to API value. This system has been tested by comparing the API measured from this device to the current API measured by DOE at several locations. Based on the results from the experiment, this air quality measurement system is proved to be reliable and efficient. Keyword:


INTRODUCTION
It is very important nowadays for people to be aware of the current air quality around them. They should know whether they are breathing clean air or polluted air. This is because air pollution ranked fourth in risk factor for death worldwide. In 2013, researchers from UBC stated that about 3 million people in Asia died of illness associated to air pollution [1]. Air pollution can cause severe health effects such as respiratory infections and cardiovascular diseases, as mentioned in [2] which has measured air pollution using PM 2.5 and PM 10 sensors in 190 cities in China. Besides, air pollution also give adverse effect to the environment that eventually resulted in global warming and climate change. Malaysia uses Air Pollutant Index (API) to determine the air quality [3]. Different countries have different quality indices for example, United States and China uses Air Quality Index (AQI), Canada and Hong Kong uses Air Quality Health Index (AQHI), Singapore uses Pollutant Standards Index (PSI) and Europe uses Common Air Quality Index (CAQI) [4]. Most of the countries in the world has regulated six criteria pollutants, including Carbon Monoxide (CO), Ozone (O 3 ), Nitrogen Dioxide (NO 2 ), Sulfur Dioxide (SO 2 ), Lead (Pb), and particulate matter (PM) with the size of less than 10µm (PM 10 ) and 2.5µm (PM 2.5 ) [5].
Air  The current monitoring stations in Malaysia have not included PM 2.5 readings in the API measurements. Most of countries like Singapore, Indonesia, South Korea and others have already included PM 2.5 in their API measurement system since it is more harmful than PM 10 . The CAQMs are placed mainly in locations with high population densities and high industrial activities. Due to that, certain areas with no monitoring stations can only depend on the API value of the nearby location, which can be less accurate.
Recent haze incidents in Southeast Asia [6] has shown the important and urgency of developing a portable and low-cost air quality monitoring device. In this paper, we designed and implemented an outdoor air quality measurement system on Arduino which can estimate the API value of any location. The system is cost effective, portable and can display the result in real-time. Furthermore, the device can measure the concentration of pollutants and can transmit the result wirelessly to a server.
The objective of this paper is to develop a portable outdoor air quality measurement system using Arduino with low cost sensors. First, related works will be presented in Section 2. Section 3 discusses the API calculations. Next, the proposed hardware and software design will be described in Section 4. Section 5 evaluates the system implementation, experimental setup, and experiments with validation. Section 6 concludes this paper.

RELATED WORKS
Many researches have been conducted on device development for air quality measurement system. This section will highlight the critical review of previous works.
In [7], a mobile sensing system called "GasMobile" for participatory air quality monitoring has been implemented. The concept of this system is to use participation from the citizen to collect the air quality measurement around them using their smartphones since the concentration of air pollution is varied in location. The monitoring system consist of a sensor and software that is compatible with Android. The measurement will be uploaded to the server by the user itself. This system is tested using a low-cost ozone sensor that is connected to the phone via USB host mode and it is powered by a battery pack. It is set to automatic mode so that it will be automatically measures the air quality every two seconds. GasMobile gives high data accuracy because the sensor calibration is always up-to-date by utilizing the readings of sensor near the reference monitoring station. However, this system utilize only one type of gas sensor to measure the air quality.
An environmental monitoring device which measures air quality, weather and earthquake using Raspberry Pi (RPi) has been proposed in [8]. This monitoring device is designed so that it can be remotely accesses through Internet of Things (IoT) platform. Readings from the sensors can be obtained on the IoT platform software called "Xively" and it can be accessed by anyone via the website. The device is tested and proved functioning correctly and accurately. The only drawbacks of this monitoring device is that the power consumption of RPi is very limited. Moreover, components must be carefully chosen to prevent damages to the device. Recently, the measurement of CO 2 emissions from industrial was developed in [9]. The used an Arduino system connected to SCADA. However, they only limited their application to CO 2 measurement only. In [10], they have proposed two cost effective approaches to measure the air quality fine-grained air quality in real time. One is to be deployed in the public transportation such as bus and train and the other one is personal sensing device for cars. For public transportation, a custom made mobile sensing box that consists of Arduino as microcontroller, CO and PM sensor, GPS receiver and a modem is used while for cars, personal sensing device (PSD) NODE that consist of CO sensor is used. The data obtained from both of the method will be geo tagged and uploaded to the server. A web portal is provided to view the real-time air pollution. Both of the devices are experimented under the same conditions and the readings of air pollution levels from both of the device are similar. However, the air quality measurement data is limited to areas that only covered by those transportation.
A solar powered low cost real-time wireless ambient air quality monitoring system for schools have been proposed in [11]. The air quality data is obtained from several sensor nodes that implement Arduino as microcontroller. The data are wirelessly transmitted using ZigBee mesh network to the school"s computer. The sensor node consist of CO sensor, NO2 sensor, PM sensor, humidity sensor and temperature sensors. The air quality monitoring system is positioned in several places around the school. The data acquire from each monitoring system will be sent to the gateway via router and it is integrated into a database. From the experiment conducted, the performance of this sensor nodes is favourable. The air quality can be viewed in real-time, however, only computers with the same network can get access to the measurement.
In [12], a portable and low power consumption sensor that can measure the concentration of PM 2.5 has been developed. The sensor is based on light scattering. The particles is detected by light scattering signal that is sensed by the photo diode. The prototype of this sensor has been tested with smokes from a cigarette and the sensor has shown great potential for an accurate device. This device is made specially to measure the concentration of PM 2.5 .
A sensor for public bicycle has been developed in [13] to monitor the air quality in the city. The devices consist of single chip processor, GPS receiver, Bluetooth interface, exhaust gas sensor and PM sensor. When a user rents the public bicycle, the sensor device will start to collect the air pollution data and these data will be stored in a SD card. Once the user have finish renting the bicycle, the data from the device on bicycle will be uploaded to the data centre via Bluetooth interface. The device has been demonstrated in two environment; outdoor and indoor. The result obtained indicates that this method is very effective to monitor the air quality. However, the area of measurement do not have wide coverage arguably and somewhat random since it only depends on the bicycle user.
In [14], an automatic air quality monitoring system has been proposed based on wireless sensor network (WSN) technology that integrates with Global System for Mobile Communication (GSM). The system includes signal processing module and a sensor node that consists of CO sensor and a gateway. The gateway will transmit the data collected by the sensor nodes to the control centre via Short Message Service (SMS) that is provided by GSM. The main drawbacks of this monitoring system is the sensor nodes consist of only one air quality sensor which is CO sensor.
A low cost air quality monitoring using self-powered device has been implemented in [15]. The device measures the concentrations of CO, PM and O3 and it can be operated off-grid using battery or solar panel. Redboard Arduino clone is used as micro-controller and GSM module is included so that sensing data can be transferred wirelessly to server for storing the result and to map the real-time result using a software. The device is tested for seven days and the result collected fit the trends of current air quality in the area. However, the device only measures the concentration of pollutant and did not evaluate the air pollutant index.
A vehicular air pollution monitoring system using IoT has been introduced in [16]. The system consists of Radio Frequency Identification (RFID) reader with CO 2 sensor and sulfur oxides (SO x ) sensor that are integrated along with Arduino microcontroller. The monitoring system will be place at roadsides and it will detect vehicles that have been inserted with RFID cards. When a vehicles passes by the monitoring device, the RFID reader will detect the vehicle and sensors will be activated to measure the air quality produced by the vehicles. If the vehicle exceeded air quality level that have been set, a warning message will be sent to the vehicle"s owner using IoT application. The system is experimented with different types of vehicle and the performance is verified as successful. However, in order to implement this monitoring system, RFID card must be inserted in vehicles or else the monitoring system will not be able to measure the air quality.
In [17], they presented a smart sensor system for air quality monitoring. The system consist of a microprocessor, PM 2.5 sensor, CO 2 sensor, CO sensor, hazard gas detector and VOC sensor. When an individual wants to measure the air quality using the device, he can run the application on his smartphone. The sensor will start measuring the air quality and transmit the data back to the smartphone via Bluetooth. The data can be uploaded to the server with the information of GPS location, date and time. However, the real-time air quality information of a place can only be obtained if the user submit the readings. 283 A cooperative sensing system for air quality monitoring called "uSense" has been proposed in [18]. uSense consist of CO sensor, CO 2 sensor, NO 2 sensor, O 3 sensor and VOC sensor. The sensors will measure the concentration of pollutants and send the data to uSense server via Wi-Fi. The server will store the sensing data into database and the data can be accessed by all uSense user in the website. This device is tested and sensor are proven to work correctly and accurately. However, only Wi-Fi connectivity is available since this device is intended to measure air quality outside homes. Therefore, to deploy this device, a Wi-Fi access point is essential.
Most of the researchers have designed their air quality monitoring system with wireless sensor network. The data measured from the device will transmit wirelessly to the server so that the result can be monitor by everyone. For this research, the system will only display the current API value and store it in a memory card for data logging.
Previous researches have designed a low cost or cost effective device using sensors and microcontrollers that are easily available in the markets. In addition, most of the air quality measurement system did not include all six pollutants sensors and only measure the main pollutants in the area such as O 3 , CO and PM. This will be similar to this study as the air quality measurement system will only include three sensors that measure dominant air pollutants in Malaysia.

AIR POLLUTION INDEX (API) CALCULATION
API is established to provide the public with information that is easy to understand about the air pollution level. API in Malaysia is calculated based on the new Ambient Air Quality Standards in Malaysia. It is developed to follow the Pollutant Standard Index (PSI) system that has been regulated by United States Environmental Protection Agency (USEPA). The new standard added one new pollutant which is particulate matter with the size of less than 2.5µm (PM 2.5 ) to the existing pollutants which are Carbon Monoxide (CO), Ozone (O 3 ), Nitrogen Dioxide (NO 2 ), Sulfur Dioxide (SO 2 ) and particulate matter with the size of less than 10µm (PM 10 ). Although PM 2.5 is included in the new Ambient Air Quality Standards, the existing monitoring stations in Malaysia did not have the equipment to measure the pollutant yet. Table 1 shows the API values and its indication.

PROPOSED AIR QUALITY MONITORING SYSTEM
The air quality measurement system is designed using low cost sensors and microcontroller. It is compact and portable making it easy to measure air quality in any place. It is capable to measure the concentration of four types of pollutant which are CO, O 3 , PM 10 and PM 2.5 .

Hardware Design
The air quality measurement system as shown in Figure 2 consists of Arduino Uno, CO sensor, O 3 sensor, PM 10 sensor, PM 2.5 sensor, 16x2 LCD display and SD card reader. GPS module and RTC module could be added as well. The sensors will measure the pollutant concentration and convert the value to sub-API value. The subAPI value of each pollutants and the API value are displayed and stored for data logging.  This device utilizes Arduino Uno as the microcontroller due to its low cost compared to others, such as Raspberry Pi and BeagleBone [19]. Arduino Uno is the basic and most used board in the all Arduino boards. It consists of 14 digital input/output (I/O) pins and 6 analog input pins which is sufficient for all components in this device. In addition, it utilizes SD card module for data logging, and 16x2 LCD display. This system could be extended by various modules compatible with Arduino, such as Ethernet shield, GSM/GPRS shield, GPS logger shield, RTC shield, etc. To measure the concentration of CO, MQ-9 gas sensor is used as shown in Figure 3(a). It can detect CO concentration from 10ppm to 100 ppm. To measure the concentration of ground level ozone, MQ-131 sensor is used, as shown in Figure 3(b). It can detect O 3 within ranges from 10ppb to 2ppm. Shinyei PPD42NS optical dust sensor is used to measure the concentration of PM 2.5 as shown in Figure 2(c). It can detect particles with the minimum size of one micrometre. Sharp GP2Y1010AUF compact optical dust sensor is used to measure the concentration of PM 10 , as shown in Figure 3(d). This sensor detects all particles in the air. The sub-API values of each pollutant and API value are displayed through 16x2 LCD display and also stored in SD card for data logging. This device is powered by 5V external power supply and/or battery with charger module.

Software Design
The air quality measurement system is programmed according to the flowchart shown in Figure 3 using Arduino Integrated Environment (IDE). The program is divided into four major parts, data collection, data conversion, data comparison, and data classification.
In data collection, each sensor will measure the concentration of pollutants. For MQ-9 and MQ-131 sensor, these sensors will return analog values and for Shinyei PPD42NS and Sharp GP2Y1010AUF, it return digital values. In data conversion, both analog and digital value obtained from the measurement will be converted to each of the pollutant concentration unit which are ppm for CO and O 3 , and µg/m 3 for PM based on the sensor"s data sheet. The concentration of each pollutants will be used to calculate the sub API value of each pollutants using Equation (1) to Equation (3). In data comparison, the four sub API value will be compared with each other and the highest sub-API among all pollutant will be the API value.In data classification, the API value is classified into the API indication in Table I. The system is set to measure the API value every five minutes. Figure 4 shows the flowchart of Air Quality Measurement System.

RESULTS AND DISCUSSION
In this section, the actual device implementation will be presented, CO, PM, and O 3 experimental setup will be discussed, as well as the results and analysis.

System Implementation
The actual system implementation is shown in Figure 5. As it is intended for outdoor air quality measurement, portable battery was used with proper enclosing box.

Experimental Setup
Before we tested the overall system, we conducted several experiments to evaluate each sensors, i.e. two CO sensors, two PM sensors, and one O 3 sensor. The experimental setup for each sensor are shown in Figure 6, Figure 7, and Figure 8, respectively.
Two type sensors are used: MQ7 and MQ9 sensor. Two experiments are conducted for CO sensor in two different sources of CO which are smoke from a cigarette and emission from a car exhaust. PM 10 and PM 2.5 sensors were both tested together in a same condition. Powder will be used as the dust source and a fan was directed towards the powder to make sure it spread in the container. As shown in Figure 8, to detect O 3 , an experiment is conducted at two different times. One experiment is conducted in the morning and another one is conducted in the afternoon. The sensor is placed near a bus stop beside a road that have light traffic.
To test the air quality measurement system, the device is placed in three different locations to measure the current air quality. The result of the experiment is compared with the API value measured by CAQMs in Batu Muda at the same time of the experiment. Figure 9 shows the experiment setup at the three different locations, i.e. hostel, faculty, and roadside.

API Results
The result of the experiment is compared with the current API value measured by CAQMs in Batu Muda at the same time of the experiment. The subAPI is plotted every five minutes for an hour for each  It can be observed from Figure 10 that subAPIs of PM 10 are the highest among all pollutants in all locations. SubAPI of PM 2.5 remains low in all three locations. This is due to the fact that PM 2.5 measured very small particles and it could only be detected when the air pollution is very severe. As shown in Figure 10(a) and Figure 10 Based on Table 2, each locations indicates different API than the value measured by nearby CAQMs. The API value from the experiment at the roadside is so much higher than the API value indicates by CAQMs. This is because there are more pollutants at the roadside compared to other locations due to the emission from vehicles. The system is validated with the CAQMs at Batu Muda by conducting the same experiment as Figure 5 (a), (b) and (c). The percentage of error is found to be 14%. Nevertheless, the sub-API of each location match with the current surroundings of the experiment location. From this experiment, it can be concluded that different places have different API value even though they are nearby to each other.  10 and PM 2.5 sensor. This system is cost effective and portable compared to the existing monitoring stations which are stationary and costly. It is convenient to be used by people of all ages and also can be used anytime and anywhere. Our validation with Batu Muda CAQMS showed that our developed system are in par with the CAQMS with an error around 14%. Moreover, this system is also capable to measure the concentration of PM 2.5 and evaluate the sub-API value which the current monitoring stations in Malaysia are not able to do so yet. Therefore, this air quality measurement system can contribute to the development of the current API measurement system in Malaysia. Future works include a proper sensor calibration to lower the percentage of experimental error of the system, and addition of other Arduino shields to extend the functionalities of the developed system.