Abstract: The system proposed is an advanced solution for weather monitoring that uses IoT to make its real time data easily accessible over a very wide range. The system deals with monitoring weather and climate changes like temperature, humidity, wind speed, moisture, light intensity, UV radiation and even carbon monoxide levels in the air; using multiple sensors. These sensors send the data to the web page and the sensor data is plotted as graphical statistics. The data uploaded to the web page can easily be accessible from anywhere in the world. The data gathered in these web pages can also be used for future references. The project even consists of an app that sends notifications as an effective alert system to warn people about sudden and drastic weather changes. For predicting more complex weather forecast that can’t be done by sensors alone we use an API that analyses the data collected by the sensors and predicts an accurate outcome. This API can be used to access the data anywhere and at any time with relative ease and can also be used to store data for future use. Due to the compact design and fewer moving parts this design requires less maintenance. The components in this project don’t consume much power and can even be powered by solar panels. Compared to other devices that are available in the market the Smart weather monitoring system is cheaper and cost effective. This project can be of great use to meteorological departments, weather stations, aviation and marine industries and even the agricultural industry.
Keyword: Internet of Things (IoT), development boards, embedded systems, Raspberry pi, NodeMCU, ESP8266, Arduino IDE, Ubidots, and API.
1 Introduction:
Present day innovations in technology mainly focus on controlling and monitoring of different devices over wirelessly over the internet such that the internet acts as a medium for communication between all the devices. Most of this technology is focused on efficient monitoring and controlling of different. An efficient environmental monitoring system is required to monitor and assess the weather conditions in case of exceeding the prescribed level of parameters (e.g., noise, CO and radiation levels) and for gathering data for research purposes(amount o rainfall, windspeed etc.).
A system is considered as a smart system when the device equipped with sensors, microcontrollers and various software applications becomes a self-protecting and self-monitoring system.
Event Detection based and Spatial Process Estimation are the two categories to which applications are classified. Initially the sensor devices are deployed in environment to detect the parameters (e.g., Temperature,Humidity, Pressure, LDR, noise, CO and radiation levels etc.) while the data acquisition, computation and controlling action (e.g., the variations in the noise and CO levels with respect to the specified levels). Sensor devices are placed at different locations to collect the data to predict the behavior of a particular area of interest. The main aim of the this paper is to design and implement an efficient monitoring system through which the required parameters are monitored remotely using internet and the data gathered from the sensors are stored in the cloud and to project the estimated trend on the web browser.
A solution for monitoring temperature and CO levels i.e., any parameter value crossing its threshold value ranges, for example CO levels in air in a particular area exceeding the normal levels etc., in the environment using wireless embedded computing system is proposed in this paper. The solution also provides an intelligent remote monitoring for a particular area of interest. In this paper we also present results of collected or sensed data with respect to the normal or specified ranges of particular parameters. The embedded system is an integration of sensor devices, wireless communication which enables the user to remotely access the various parameters and store the data in cloud.
2. Existing systems:
The existing weather monitoring systems generally use weather stations that use multiple instruments such as thermometers, barometers, wind vanes, rain gauge etc. to measure weather and climate changes. Most of these instruments use simple analog technology which is later physically recorded and stored in a data base. This information is later sent to news reporting stations and radio stations where the weather report is given.
Limitations of the existing System:
1. Existing weather monitoring systems that are used in the field generally consist of unconventional and heavy machinery that consists of numerous moving parts that require constant maintenance and need to be manually monitored and changed frequently.
2. Power requirements are one of many major constraints as these instruments are generally sited far from main power supply. This adds to the cost of using such instruments.
3. The use of thermometers to measure external temperature; however accurate is still outdated and constantly needs to be manually checked for any change in temperature.
4. Data that is collected by the instruments needs to be manually transferred from the logger to a laptop or computer via a cable.
5. Existing systems consist of large and heavy instruments that occupy a lot of space hence making it difficult to install them in remote location and places which have limited space.
6. The instruments used in the existing systems are expensive and add up to the already high cost of installation and maintenance.
7. The current system always faces problems such as delay in warning people about bad weather and sudden changes in the forecast.
3. Proposed system:
The system proposed is an advanced solution for weather monitoring that uses IoT to make its real time data easily accessible over a very wide range. The system deals with monitoring weather and climate changes like
-Temperature and humidity by using the dht11 sensor,
-Wind speed using an Anemometer,
- Light intensity using an LDR,
-UV radiation using a GY8511 solar sensor,
- Carbon monoxide levels in the air using MQ135.
Feature and advantages of the proposed sytem:
1. Our proposed ‘Smart weather monitoring system’ unlike conventional weather monitoring instruments is very small and compact allowing it to be installed easily on rooftops.
2. It is light and portable; this advantage allows us to easily carry it to remote location for installation. Due to its design it can be easily be carried by a weather balloon to measure atmospheric changes at high altitudes.
3. The power requirements for our system (sensors and boards) is much less compared to the existing instruments in the market hence enabling us to use solar cells as power supply. This not only cuts down on cost but allows us to leave the monitoring system in remote, areas where power is not easily available, for long periods of time. Addition of solar panels also helps our design be eco-friendly.
4. The sensors used in our product are much cheaper compared to the ones that are used in the existing weather monitoring systems making our design more cost effective.
5. These sensors send the data to a web page and the sensor data is plotted as graphical statistics. The data uploaded to the web page can easily be accessible from anywhere in the world. The data gathered in these web pages can also be used for future references. Unlike the existing system where data has to be physically transferred.
6. Due to the presence of fewer moving parts less amount of maintenance will be needed cutting down on maintenance charges.
7. The product even consists of an app that sends notifications as an effective alert system to warn people about sudden and drastic weather changes. This works as an efficient warning system for bad weather and storms.
8. For predicting more complex weather forecast that can’t be done by sensors alone we use an API with the help of a Raspberry pi that analyses the data collected by the sensors and predicts an accurate outcome. This API can be used to access the data anywhere and at any time with relative ease and can also be used to store data for future use.
4. SYSTEM ARCHITECTURE:
The implemented system consists of an Arduino Uno which is used as a main processing unit for the entire system and all the sensor and devices can be connected with the microcontroller. The sensors can be operated by the microcontroller to retrieve the data from them and it processes the analysis with the sensor data. The processed data can be uploaded and stored in a website to function as a data base using nodemcu and Ubidots.
NodeMCU:
The NodeMCU is an open-source physical computing platform based on a simple micro-controller board, and a development environment for writing software for the board. It can be used to develop interactive objects, taking inputs from a variety of switches and or sensors, controlling a variety of lights, motors, and other physical outputs.
It includes firmware which runs on the ESP8266 Wi-Fi SoC from Espressif Systems, and hardware which is based on the ESP-12 module.
LDR Light-Dependent Resistor:
Light intensity is measured using an LDR. An LDR is a component that has a (variable) resistance that changes with the light intensity that falls upon it. This allows them to be used in light sensing circuits. A light dependent resistor (LDR) is a light-controlled variable resistor. The resistance of this decreases with increasing incident light intensity; in other words, it exhibits photo-conductivity.
CO Sensor:
Carbon Monoxide (CO) sensor, suitable for sening CO concentrations in the air. The MQ-7 can detect CO-gas concentrations anywhere from 20 to 2000ppm.This sensor has a high sensitivity and fast response time. The sensor’s output is an anlog resistance.
DHT11:
The DHT11 is a basic, ultra-low-cost digital temperature and humidity sensor. It uses a capacitive humidity sensor and a thermistor to measure the surrounding air, and spits out a digital signal on the data pin (no analog input pins needed).
ML8511:
ML8511 module is an easy to use ultraviolet light sensor. The ML8511 Sensor works by outputting an analog signal in relation to the amount of detected UV light. This breakout can be very handy in creating devices that warn the user of sunburn or detect the UV index as it relates to weather conditions.
Anemometer:
An anemometer is a device used for measuring the speed of wind, and is also a common weather station instrument.
Dark Sky:
Dark Sky is an open source Internet of Things (IOT) application and API to store and retrieve data from things using the HTTP protocol over the Internet or via a Local Area Network. We interface it with the NodeMCU.
App:
This product also consists of an app which is developed using the MIT app inventor. The main pupose of this app is to provide notifications on weather updates and to act as warning system in case of bad weather. The app will obtain the neessary information through the existing database.
5. Implimentation:
The proposed system can be implimented in a 4- tier model with the functions of each individual modules developed for monitoring the different weather parameters. The tier 1 is the environment, sensor devices in tier 2, sensor data acquisition and decision making in tier 3 and warning notification in tier 4. Here, the tier 1 provides information about the parameters under the region which is to be monitored. Tier 2 deals with the sensor devices with suitable characteristics, features and each of these sensor devices are operated and controlled based on their sensitivity as well as the range of sensing.
In between tier 2 and tier 3 necessary sensing and controlling actions will be taken depending upon the conditions, like fixing the threshold value, periodicity of sensing, messages etc. Based on the data analysis performed in between tier 2 and tier 3 and also from previous experiences the parameter threshold values during critical situations or normal working conditions are determined.
Tier 3 describes about the data acquisition from sensor devices and also includes the decision making. Which specify the condition the data is representing which parameter.
In the proposed model tier 4 deals with the intelligent environment. Which means it will identify the variations in the sensor data and fix the threshold value depending on the identified levels. In this tier sensed data will be processed, stored in the cloud and accordingly the notification will be sent.
Based on the framework we have identified a suitable implementation model that consists of different sensor devices and other modules. In this implementation model we use a NodeMCU for sensing and storing the data in cloud. Inbuilt ADC and Wi-Fi module connects the embedded device to internet. Sensors are connected to NodeMCU board for monitoring, ADC will convert the corresponding sensor reading to its digital value and from that value the corresponding environmental parameter will be evaluated.
The WiFi connection has to be established to transfer sensors data to end user and also send it to the cloud storage for future usage.
6. Simulation Results:
After sensing the data from different sensor devices, which are placed in particular area of interest. The sensed data will be automatically sent to the web server, when a proper connection is established with sever device.
The web server page which will allow us to monitor and control the system. By entering IP address of server which is placed for monitoring we will get the corresponding web page. The web page gives the information of the weather parameters in that particular region, where the system is placed.
The above diagram shows us how the different weather parameters will be displayed on the website with the help of Ubidots.
7. Conclusion:
To implement this we need to deploy the sensor devices in the environment for collecting the data and analysis. By deploying sensor devices in the environment it will record real time data. It can interact with other objects through the network. Then the collected data and analysis results will be available to the end user through the WiFi. The smart way to monitor environment and an efficient, low cost embedded system is presented with different models in this paper.
In the proposed architecture functions of different modules were discussed. The noise and air pollution monitoring system with Internet of Things (IoT) concept experimentally tested for monitoring two parameters. It also sent the sensor parameters to the cloud (Google Spread Sheets). This data will be helpful for future analysis and it can be easily shared to other end users.
This model can be further expanded to monitor the developing cities and industrial zones for pollution monitoring. To protect the public health from pollution, this model provides an efficient and low cost solution for continuous monitoring of environment.
Additions that can be made to improve the system
1. Powering the device using solar panels
2. Suspending the device from a weather balloon so that it can be used to record atmospheric parameters at high altitudes and remote and inaccessible areas.
3. Use of a though exterior cover for the system that will act as a protective cover enabling the device to function in harsh weather conditions.
4. Designing a method to mount the weather monitoring device onto a buoyant platform like a buoy hence enabling the system to measures weather changes over the sea. This data can also be shared to Cargo ships and other nautical industries conducting operations within the area.
5. Using silica gel to prevent condensation on the exterior cover as condensation might affect the sensors readings.
Smart weather monitoring and alert system
Code:
#include <ESP8266WiFi.h>
#include "FirebaseArduino.h"
#include "DHT.h" // including the library of DHT11 temperature and humidity sensor
#define DHTTYPE DHT11 // DHT 11
#include "UbidotsMicroESP8266.h"
#define dht_dpin D1
DHT dht(dht_dpin, DHTTYPE);
#define TOKEN "BBFF-G7HiGt3KJHoqnVYRV11wTeVezt4LiS" //This is for Ubidots Integration
#define FIREBASE_HOST "weathermonitor-ab898.firebaseio.com" //This is the FidrebaseDB URL
#define FIREBASE_AUTH "9hpDXqVtvowYQKa5ouq4i9hX9i9ll81bARDDA2ML"
#define WIFI_SSID "Lel"
#define WIFI_PASSWORD "0zxcvbnm"
Ubidots client(TOKEN);
void setup(void)
{
pinMode(D5,OUTPUT);
pinMode(D4,INPUT);
dht.begin();
Serial.begin(9600);
WiFi.begin(WIFI_SSID, WIFI_PASSWORD);
Serial.print("connecting");
while (WiFi.status() != WL_CONNECTED) {
Serial.print(".");
delay(500);
}
Serial.println();
Serial.print("connected: ");
Serial.println(WiFi.localIP());
Firebase.begin(FIREBASE_HOST, FIREBASE_AUTH);
Serial.println("Humidity and temperature\n\n");
delay(700);
}
void loop() {
float h = dht.readHumidity();
float t = dht.readTemperature();
float duration_f,distance_f;
Firebase.setFloat("Humidity", h);
/* if (Firebase.failed()) {
Serial.print("pushing /Humidity failed:");
Serial.println(Firebase.error());
}*/
Firebase.setFloat("Temperature", t);
//handle error
/*if (Firebase.failed()) {
Serial.print("pushing /Temperature failed:");
Serial.println(Firebase.error());
}
*/
Serial.print("Current humidity = ");
Serial.print(h);
Serial.print("% ");
Serial.print("Temperature = ");
Serial.print(t);
Serial.println("C ");
digitalWrite(D5,0);
delayMicroseconds(2);
digitalWrite(D5,1);
delayMicroseconds(10);
digitalWrite(D5,0);
duration_f=pulseIn(D4,1);
distance_f=duration_f*(0.034/2);
//I've Considered the lenght of the rain gauge is 25 cm
float amtRain=25-distance_f;
Serial.println(amtRain);
Firebase.setFloat("AmountOfRF", amtRain);
// handle error
/*if (Firebase.failed()) {
Serial.print("pushing /AmountOfRF failed:");
Serial.println(Firebase.error());
}
*/
delay(200);
double sensorValue;
sensorValue = analogRead(A0);
double sensor_volt = sensorValue/1024*5.0;
double RS_gas = (5.0-sensor_volt)/sensor_volt;
double R0 = RS_gas/(26+(1/3));
Firebase.setFloat("AmountOfCO", R0);
// handle error
/*if (Firebase.failed()) {
Serial.print("pushing /AmountOfCO failed:");
Serial.println(Firebase.error());
}
*/
Serial.print("CO :");
Serial.print(R0);
Serial.println("*10^(-4) moles ");
delay(1000);
//Uploading to UBIDOTS :
client.add("Temperature", t);
client.add("Humidity", h);
client.add("CO", R0);
client.add("amtRainfall", amtRain);
client.sendAll(true);
}
Code for LDR:
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorValue = analogRead(A0);
float voltage = sensorValue * (5.0 / 1023.0);
Serial.println(voltage);
}