Table of contents
- Project overview
- Resources and going further
Project concerns weather station built in client-server architecture.
Client is any module with one or more sensors sending data to a server.
Server is responsible for collecting data, making any aggregation, presenting results, plots etc.
Weather station is divided into two modules, each with its own sensors set. Explanation for this is that
- I wanted to complicate a little bit a project.
- This give me a possibility to arrange sensors in different locations.
- Many sensors means many external libraries which in turn means high memory consumption and in consequence Arduino becames unstable. In such a case you have to run some of sensors on one Arduino while others on the other(s) Arduino(s).
To complete modules (clients) side we need
- Breadboard x 2 (one for each module)
- DS18B20 1-Wire temperature sensor x 2
- Resistor 4.7kOhm (to use with DS18B20)
- DHT21 (AM2301) (humidity and temperature sensor)
- Resistor 1kOhm (to use with DHT21)
- Sparkfun MPL3115A2 pressure (and temperature) sensor
- Resistor 330Ohm x 2 (to use with MPL3115A2 in line to limit 5V signals on I2C lines)
- Arduino Ethernet Shield (you need two, if you want to have both two modules at once)
- Arduino Uno Board (you need two, if you want to have both two modules at once)
To complete server side we need any computer connected to the same network with web server and PHP. In my case it is Raspberry Pi 3 B with Raspbian + Apache + PHP 7.0
First module is intended to collect data from DS18B20 temperature sensor(s) as well as from one DHT21 temperature and humidity sensor.
Second module is intended to collect data from MPL3115A2 pressure sensor. This sensor can be also used to collect temperature data.
Hierarchy of folders
- Data, instead of text file, can be logged in database. You can chooses relational one, like MySQL or PostgreSQL or even better one of NoSQL, like CouchDB.
- Instead of Ethernet module, WiFi or even GSM module can be used.
- Web interface may be improved to enable multiuser access with logins, passwords and rights to see only dedicated piece of data / sensors.
- Replace Arduino Uno with smaller, for example Arduino Nano
- Replace Arduino Ethernet Shield with smaller, ENC28J60 for example
Resources and going further