Testing your Weather Station
With all your sensors connected, it's a good idea to confirm that your Weather Station is recording data and that it is able to upload it to the Oracle database.
Manipulate and measure the sensors
The anemometer and rain gauge can be manipulated as neither will be recording data unless they are physically moved. Spinning the anemometer and tilting the rain gauge back and forth a few times while the next set of instructions are followed will result in some data being logged.
Open up a terminal window (ctrl + alt + t) and then change into the
To start logging sensor data, type the following into the terminal window:
You should see output as shown in the screen capture below.
- Do not worry about the
Data truncatedwarnings. The sensors measure to an unrealistic number of significant figures, so these values are truncated before they are added to the database.
Upload to Oracle
The next step is to test that the software is capable of uploading the data to the online Oracle database. To test this, type the following into the terminal:
You should see output as shown the screen capture below.
Response status: 201message means that a row of the local database on your Raspberry Pi was uploaded to the Oracle database. If you receive a different response code, then check that your Raspberry Pi is connected to the network and that it is capable of communicating through any firewalls or proxy servers your network may be using.
Checking the online database
In your web browser, navigate to the Oracle database and log in:
On your dashboard, click on Weather Measurement to view the latest measurements from your Weather Station.
- It is worth having a play around with the filters and the download options with your data, to see what can be achieved.
Now that you have tested your Weather Station, close up the boxes with the long screws and ensure the grommets are in place.
You can then proceed to the next section, and learn how to install the Weather Station at your school.