Java JavaScript C++ Other
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
commons-configuration
configuration-war
forecast-war
src
touch-war
twitter-war
weatherpi-common
weatherpi-core
weatherpi-esp8266/thing
weatherpi-war
zambretti
.gitignore
README.md
pom.xml

README.md

WeatherPi WeatherPi

WeatherPi is a JEE based project. The used application server is a WildFly running on a RaspberryPi. There are different components delivering sensor data. The sensor data is collected, processed and stored into a database.

There is another RaspberryPi with a connected touch screen displaying the sensor data.

All outdoor sensors are connected to different ESP8266 WiFi modules.

Forecast data is retrieved from ForecastIO and actual data is pushed to twitter.

Sensors

The list of actually implemented sensors.

Birdhouse:

Anemometer

MQTT

The Birdhouse and the Anemometer are publishing their sensor data via MQTT to a local installed Mosquitto broker. Here are some instructions for the installation of the Mosquitto MQTT Server on the RaspberryPi. The published messages are JSON encoded, this makes it easy to convert them to Java or JavaScript objects.

{
    "sensor": "DHT22",
    "place": "BIRDHOUSE",
    "type": "TEMPERATURE",
    "temperature": 4.7000,
    "time": 1502381794
}

The time parameter is optional, if no present, the actual time will be used.

Database

The sensor data is written to a MySQL database for later processing of the data.

Data Display

One RaspberryPi with a connected 7'' touch screen is used to display the data. Therefore, Chrome is started in Kiosk mode.

The user interface is touch enabled and optimized for the sreen resolution of the original RaspberryPi touch screen. Live data is published via WebSockets and forecast data is used from ForecastIO. It is also possible to display historical data for the temperature, humidity, pressure and the wind speed. There are three ranges, back one day, one week ore one month. The display is updated continuously.

Twitter

Actual weather data is pushed via the Twitter REST API. This is done using the Twitter4J library. Every three hours, the actual temperature, humidity and pressure is posted, every hour the pressure tendency and the actual wind speed and once a day a climatological classification of the last day.

ForecastIO

Reading weather forecast from ForecastIO using their API. The data is queried each hour and cached internally. The icons used for displaying some weather informations are from Adam Whitcroft

Deployment View

A description of the software and hardware components.