Vous êtes sur la page 1sur 8

A Zigbee Based Smart Sensing Platform for Monitoring Environmental Parameters

M. Haefke*, S. C. Mukhopadhyay! and H. Ewald* * University of Rostock, Rostock, Germany !School of Engineering and Advance Technology Massey University, Palmerston North, New Zealand.
Abstract: The ability to monitor environmental conditions is crucial to research in fields ranging from climate variability to agriculture and zoology. Being able to document baseline and changing environmental parameters over time is increasingly essential important and researchers are relying more and more on unattended weather stations for this propose. A Zigbee Based Smart Sensing Platform for Monitoring Environmental Parameters has been designed and developed. The smart weather station consists of SiLab C8051F020 microcontroller based measuring units which collect the value of the temperature, relative humidity, pressure and sunlight. These units send their data wireless to a central station, which collects the data, stores and displays them into a database. The facility of adding a few more sensors and a few more stations has been provided. Keywords: Zigbee, Smart Sensing, Environmental monitoring, wireless sensor network, weather station, temperature measurement, pressure measurement, humidity measurement, light measurement. 1. Introduction Human beings are meteor-sensitive. We feel good, when the sun shines and get melancholic if the sky is grey. The emotion is connected to weather conditions, experiences memories and is one of the most discussed aspects of our live. The Greeks were the first meteorologists (7th century B.C.). Thales of Miletus associated weather with movement of the stars and planets [1]. Since then humans always tried to forecast the weather, to plan sowing and harvesting of plants, to decide how to dress and to plan their outdoor activities. In the past these forecasts were made by high educated man with a big knowledge and experience later instruments were designed to measure the actual situation, beginning with the first thermometer invented by Galileo in 1593[1]. Since the 1940s forecasts for the weather are computer calculated models, using the previous data of weather stations on the ground collected manually by persons operating this stations, satellite pictures and offshore data collected by measurement buoy. The weather observing is getting more and more automatic, because the manual collection data are not continuously and the variation caused by wrong reading can change the whole forecast in addition the use of a wireless stand alone station can reduce the cost of maintaining the weather station, reduce the risk of losing data and can be placed at critical locations, without endanger an observer. There are several different producers of weather stations, with all kind of sensors. These stations can be wireless or connected with a wire to a Server storing the data and make it possible to access them [2][3]. These Stations can only be operated with the given software which makes it difficult to access the data and use them for different purposes, additionally these stations are very expensive. Therefore, this research motivates to develop a weather station that has the following characteristics: Usage of low cost equipment Flexible data-handling to use the data for different purpose Sensors should be as accurate as possible Wireless connection to get the data from different sensors and to make the set up as easy as possible A possible number of at least 6 different stations per central station to make a comparison possible The present paper describes the development of a wireless weather station measuring temperature, humidity, pressure and light intensity. 2. The importance of environmental parameters Modern weather forecasts are a result of a computer calculated model, which uses a mesh of weather stations, weather balloons and satellites around the world. Based on the actual conditions and long time

978-1-4244-7935-1/11/$26.00 2011 IEEE

datasets it is possible to make a relative correct outlook for the next few days. The data of the sensors have to be exact with the lowest accuracy possible to get an exact forecast [4]. Additional to the accuracy the number of stations has to be very high so that the mesh cells are very small. Modern forecast systems use a resolution of one station per 32km [5]. A lower resolution is difficult to produce, because the costs per weather station are very high. But to improve the simulations a smaller grid size would be necessary [6]. The weather data is also necessary of other purposes. For example in agriculture it is necessary to know the past and actual conditions on the fields to plan the use of fertilizer, aerial spraying, watering or harvest or in zoology, the population of insects and bigger animals is directly corresponding to the former weather condition which makes these data necessary for research and fight against upcoming pests [7]. 3. Measurement of Environmental parameters There are several important values to be measured. The most important weather element is the temperature. It is an element to which human life, and also plant and animal life is sensitive. The temperature is measured by different types of thermometers classified in four groups: Liquid in glass thermometers Deformation thermometers Liquid in metal thermometers Electrical thermometers For an automatic weather station only the electrical thermometers can be used because all of the other thermometers need personal to read the temperature from the scale. The second value to be measured is the pressure. The pressure is measured in kPa and is a value of the weight of the air above the sensor. As a result of the airs constant and complex movements and the changes in its temperature and its water vapour content, the weight of the air above a fixed point is continually changing. Therefore the pressure is never constant for long and is an important feature of the weather by reason of the relations to other weather changes. The instrument to get the air pressure is a Barometer. Barometers can be divided in 3 groups: Mercury Barometers Aneroid Barometers Digital Barometers For an automatic weather station again only the digital instrument can be used. Because the pressure is addicted to different environmental conditions four corrections are necessary to make a barometer reading comparable with other readings of other places [8].

Temperature correction as a convention all pressure readings are scaled to 0C 1. Gravity correction the force of gravity varies over the earths surface because the earth is not a perfect sphere (the equatorial diameter is 43km greater than its polar diameter). 2. Instrumental error correction like all sensors, even barometers have an internal error, which has to be corrected by comparing the value with the exact value given by a reference. 3. Altitude correction all barometer readings are reduced to sea-level for the purpose of comparison In New Zealand the error caused by the gravitydifferences is minimal so that if the measurement is correct only a temperature and an altitude correction are necessary. The most variable gas in the atmosphere is the water vapour, measured by the humidity. For zero up to 4% of the volume is water. Its extremely important to mans existence on the earth and constitutes one of the primary elements of weather. It not only contributes to the heating and cooling of the earths surface but is directly related to the distribution and extent of precipitation over the earth [1]. There are different ways to make the amount of water in the air comparable. The first is to measure the absolute Humidity that means the actual mass of water vapour in a given volume of air, for example 3 grams of water in a cubic meter of air. The second and most common way is the Relative Humidity. It is the percentage of water vapour present in the air comparison with saturation conditions. Relative humidity UR (in per cent) of moist air is defined:

Where r is the actual amount of water vapour in the air and rw the maximum capacity of vapour the air can hold, before it starts to condensate [8]. This factor depends on the temperature and can be seen in Figure 1. If the relative humidity reaches 100% the air is saturated with water and some of the water vapour becomes liquid, this is also called the Dew Point [1].

60.0

Saturation Water Vapor in g/m

50.0 40.0 30.0 20.0 10.0 0.0 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40

Temperatur in C Figure 1: Saturation of water in Air at Sea level

Almost all weather aspects can be traced back to the amount of solar radiation that reaches the surface of the earth. Therefore the sunlight should be measured as well. The light intensity changes with the seasons. In the summer is the time with the highest amount because the sun has its greatest noon elevation. The sunlight can be measured in different ways. One way is to measure the energy brought by the sun to a specific area on the earth-surface, on all wavelength (in W/m2) and the other way is to get the intensity of illumination for a specific wavelength (in lux). In this paper the light according to the visual perception (the illumination) is measured. 4. Description of the developed System The developed system is based on a Microcontroller, communicating with a central station (Figure 2). The Microcontroller is connected to different sensors, which giving analog voltage signals. These signals are measured and translated into the responding value. All of these values are send trough the XBee Module to a base station, which stores the data into an Access Database. The Values can then be displayed in the GUI running on a computer.

Figure 2: Block diagram of developed System

4.1. Microcontroller C8051F020 The Microcontroller C8051F020 is the programmed using C language for the operation of the abovementioned tasks in this project. The Microcontroller is produced by the Silicon Laboratories, Inc. [9][10]. To operate the chip a study of the architecture was necessary. The functioning of the microcontroller, stated below: - The C8051F020 device is a fully integrated mixed-signal System-on-a-Chip MCU with 64 digital I/O pins - High-Speed pipelined 8051-compatible CIP51 microcontroller core (up to 25 MIPS) - In-system, full-speed, non-intrusive debug interface (on-chip) - True 12-bit (C8051F020) or 10-bit 100 ksps 8channel ADC with analog multiplexer - True 8-bit ADC 500 ksps 8-channel ADC with analog multiplexer - Two 12-bit DACs with programmable update scheduling - 64k bytes of in-system programmable FLASH memory - 4352 (4096 + 256) bytes of on-chip RAM - External Data Memory Interface with 64k byte address space - SPI, SMBus/I2C, and (2) UART serial interfaces implemented in hardware - Five general purpose 16-bit Timers - Programmable Counter/Timer Array with five capture/compare modules - On-chip Watchdog Timer, VDD Monitor, and Temperature Sensor

4.2. Temperature Measurement The temperature, as the most important weather info can be measured in different ways. There electrical sensors with different type of measurement, such as change of resistance or thermo elements. There are also integrated circuits, which give different output signals, such as serial data or analog values.
Figure 5: Daily temperature in C change captured by DS600

4.3. Humidity Measurement The Humidity is measured with and integrated circuit, the HIH-4010 produced by Honeywell International Inc. Like the temperature sensor, the Humidity sensor gives an analog output, which is measured by the 12Bit ADC of the C8051F020 (Figure 6).

Figure 3: Circuit of temperature sensor DS600

The temperature in this project is measured with an integrated circuit, the DS600 temperature sensor produced by MAXIM - Dallas Semiconductor The Sensor gives an analog output depending on the measured temperature. This voltage has to be measured by the microcontroller using a 12bit Analog-to-Digital converter (ADC). The IC has an accuracy of 0.5C and a linear output with 6.45mV/C and an offset of 509mV (Figure )[11].

Figure 6: Humidity measuring circuit

The Humidity sensor has and accuracy of 3.4% relative Humidity [12]. To get the Humidity from the analog input the formulas (3) and (4) are needed. (3)
-

(4)

Figure 4: DS600 Output characteristic

The calculated Humidity (H) needs to be temperature corrected (5). The temperature (T) is given by the DS600 sensor.
-

The Output of the ADC has to be converted into the right value. The ADC-value is first compared with the Reference Voltage of 2.4V (1) and then with the characteristic of the DS 600 to get the Value for the Temperature (T) (2). (1)
-

(5)

The daily trend of the humidity can be seen in Figure 7.

(2)

The captured Temperature can be seen in Figure 5.

(6) (7)

The daily change of the light intensity can be seen in Figure 10.

Figure 7: Daily Humidity change captured with HIH-4010

4.4. Light Intensity Measurement A value which is very important for the development of plants and which influences the well-being of human beings is the light-strength. For that purpose a light measurement circuit (Figure 8) with a Photodiode has been used to measure the light intensity. The photo diode BPW21 has a color-correction filter, giving an approximation to the spectral response of the human eye [13] .

Figure 10: Daily light intensity captured with BPW21

4.5. Pressure Measurement The weather is directly connected to the airpressure. Low pressure is associated with bad weather and a rapid change of the pressure means a drastic change in weather, for example and upcoming storm can be forecasted by looking at the last hours of pressure measurement. The Pressure was measured with the integrated circuit MPX-4100 build by Motorola. The used circuit can be seen in Figure 11. The circuit needs a 5V power supply and the output to the ADC is between 0 and 5 V what makes a voltage divider necessary.

Figure 8: Light measurement circuit

Figure 11: Pressure measurement circuit

The pressure can be calculated with Formula (8) and (9) [14]. (8)

Figure 9. Short Circuit Current vs. Illuminance

To convert the measured ADC-Value into the illumination the formulas (6) and (7) are used.

(9) To make the pressure comparable with other the pressure has to be correct. The Sensor makes an internal temperature correction, so that there is only the height correction to be done. If you look at a infinite thin layer of air with the height dh in these thin layer the density is constant. If the density is constant the pressure dp changes like in fluids: From this it follows that the height is: (11) 4.6. Communication To save the data measured by the sensors it was necessary to build a network between the sensors and to set up a computer receiving and storing the values. For the communication ZigBee modules were used. These provide a wide range and a couple of low power modes, which could be used to reduce the current consumption of the circuit. In addition the network-setup is easy and fast, so that an extension of new Stations is possible without problems. (10)
Figure 13: Air-Pressure change captured with MPX-4100

If the temperature in every height is constant and the air mass is also the same we can say, by using , that the Boyles law: and (12)

If you set this in the formula for the height (11) and integrate the equation over the whole height you get: (13)

4.6.1.XBee Modul These Modules provide a possibility to build an easy to configure Network, with a high datarate up to 230400 Baud/s. They come in a preconfigured mode and establish the communication automatically. In addition they are powered by 2.7 to 3,3V and can be connected to the C8051F020 without any additional power-supply circuit [10][15]. 4.6.2.Electrical Connection To connect the XBee module to the Microcontroller only 4 wires are necessary. The Power-Supply (3.3V), Ground and TX and RX of the Microcontroller are connected to VCC, GND, DIN and DOUT of the XBee module (Figure 14).

By transpose this formula to p(h) you get the barometric formula


-

(14) and a pressure of

With the density of

you get the air pressure depending on the altitude (Figure 12).
1050 1000

Air-Pressure in hPa

950 900 850 800 750 700 650 600 0 100 200 300 400 500 600 700 800 900 1000 1100 1200 1300 1400 1500 1600 1700

Height above Sea-Level in m Figure 12: Air-Pressure addicted to altitude

The corrected air pressure captured over 24h hours can be seen in Figure 13.

Figure 14: Electrical connection of XBee Modul with Microcontroller

(the address and sensors) and saved in an Access Database. In this stage the GUI also tests the data for correctness. The Database contains a Table in which the different Settings for the sensors are stored. That makes it possible to attach different sensors and to change the position of the sensor data in the send string (4.6.4 Communication Protocol). It is also possible to make a calibration for each sensor, for example to get the dot in the temperature. To get the right value of the sensor the send data must be divided by 100 but in the reality this value may diversify to get the right value. In the GUI it is possible to display whether one or multiple sensors (Figure 16) to give the user the chance to show different graphs and to compare different stations.

4.6.3.Configuration and Setup To configure the XBee Modules, the provided software X-CTU is used. To set up a network the following conditions have to be fulfilled: Each network needs one Coordinator and several End-Devices All modules have to have the same firmware and PAN-ID If everything is setup correct, the coordinator establishes a connection to the End-Devices automatically. The Coordinator sends Broadcast Commands, and the End-Devices can send to Coordinator only. Although a Mesh-Network is possible, where the End-Devices act like a Router and forward data from devices which are out of the range from the Coordinator. 4.6.4.Communication Protocol The transmission of the XBee Modules doesnt provide a checksum or any other possibility to verify the correctness of the received data. To avoid corrupted data and to see which station was sending the data an own communication protocol is needed. The send string for the weather stations contained 27 characters (Figure 15). The first three chars are the name of the station, then each divided by a minus the sensor data.

Figure 16: GUI showing all 4 Sensors of one Weather Station

5. Outcome and Analysis Six prototype weather stations (Figure 17) have been fabricated and successfully tested over more than 24 hours.

Figure 17: Developed Weather Station connected to the C8051F020 Microcontroller Figure 15: Data Communication Protocol

Each Station sends their data every 2 seconds to the coordinator. Where the data has to be collected and tested for correctness. 4.7. GUI The Graphical User Interface was programmed in C# and captures the serial communication. The string received as serial Data is split into 5 parts

The weather data captured by the sensors correspond directly to the data that are given by non-electrical sensing elements, like thermometers, barometers and hygrometers. The data show, that there are some problems to be solved, for example is the humidity and the pressure sensor very sensitive to direct sunshine, so that a casing is needed that is impervious to light. For the correctness of the data is necessary that the position of the sensor is chosen well. The Influence

of for example machines which expose heat has to be reduced. The sensors consume less than 10mA while measuring. The biggest amount of energy is used for the wireless communication (35mA while sending). The usage of the XBee module sleep mode and reducing the communication time is essential to reduce power consumption. Nonetheless a battery powered weather station can be build. The usage of solar or wind-turbine power is also conceivable. 6. Conclusion and Future Work In this paper we have propose a environmental monitoring system with a mesh network structure controlled by a central station. The different stations are equipped with temperature-, relative humidity-, pressure- and sunlight-sensors. Initial component testing of sensor performance has reflected good results in sensing and radio communication. The outcome provides a variable platform for different sensors to measure necessary values. Further development on downsizing the system, using alternative energy sources and analysis of the measured data is scheduled next. 7. References [1] Farrand, John. Weather. New York, 1990. [2] Columbia-Weather. Pegasus EX Portable Weather Station - Columbia Weather Systems, Inc. http://www.columbiaweather.com/Pegasus EX-Brochure.pdf (accessed June 3, 2010). [3] Irox. Irox - Produkte - PRO-X2 USB. http://www.irox.com/data_access/irox/dow nloads/bedienungsanleitungen/PRO_X2_e. pdf (accessed June 3, 2010). [4] Beniston, Martin. From Turbulence to Climate: Numerical Investigations of the Atmosphere with a Hierarchy of Models. Berlin: Springer, 1998. [5] Kalnay, Eugenia. Atmospheric Modeling, Data Assimilation and Predictability. Cambridge: Cambridge University Press, 2003. [6] Pielke, Roger A. Mesoscale meteorological modeling. San Diego: Academic Press, 2002. [7] Prodata. Agriculture. Prodata Weather systems. http://www.weatherstations.co.uk/agricultu re.htm (accessed June 3, 2010). [8] Blair, Thomas A., and Robert C. Fite. Weather Elements. Englewood Cliffs, N.J.: Prentice-Hall, 1965. [9] Silicon-Labs. C8051F020 Datasheet pdf Mixed-Signal 64KB ISP FLASH MCU. DatasheetCatalog.org. http://www.datasheetcatalog.org/datasheet

s2/43/4308973_1.pdf (accessed June 6, 2010). [10]Gupta, Sen Gourab, and Tin Chew Moi. Embedded Programming with FieldProgrammable Mixed-Signal Controllers. 2005. [11]Products, Maxim Integrated. DS600 0.5 Accurate Analog-Output Temperature Sensor. Analog, linear, and mixed-signal devices from Maxim/Dallas Semiconductor. http://datasheets.maximic.com/en/ds/DS600.pdf (accessed Juni 6, 2010). [12]Honeywell. HIH-4010/4020/4021 Series Humidity Sensors. Honeywell Sensing and Control. http://sensing.honeywell.com/index.cfm/ci _id/142534/la_id/1/document/1/re_id/0 (accessed Juni 2, 2010). [13]Siemens. BPW21 Datasheet pdf - Silicon Photodiode for the visible spectral range. DatasheetCatalog.org. http://www.datasheetcatalog.org/datasheet/ siemens/BPW21.pdf (accessed June 6, 2010). [14]Motorola. MPX4100 Datasheet pdf INTEGRATED PRESSURE SENSOR 20 to 105 kPa. DatasheetCatalog.com. http://www.datasheetcatalog.org/datasheet/ motorola/MPX4100AS.pdf (accessed June 2, 2010). [15]Digi. XBee & XBee-PRO 802.15.4 OEM RF Modules - Digi International. http://ftp1.digi.com/support/documentation /90000982_B.pdf (accessed June 6, 2010).

Vous aimerez peut-être aussi