Intro: Meten Aan Water: Rain Intensity Meter
This device is created to measure rainfall intensity. There are many ways to measure the amount rainfall. However, if rainfall intensity is the desired information, most measurement devices are very expensive. This device is a cheap and easy to build solution to collect data about the rainfall intensity. Data is collected through a photon and divided in 4 categories: no rain, light rain, moderate rain & heavy rain. This instructable is written to reproduce the measurement device.
Step 1: Materials & Tools
- 1 Photon
- 1 Pressure sensor
- 1 Adjustable resistance
- 1 Button switch
- 10 Wires
- 2 LR44 batteries
- 7 Slates with measurements of approximately: 2cm × 30cm × 5cm
- 1 Milk carton
- 1 Small flexible tube with a length of 25 cm and an inside diameter of approximately 0.5cm
- 1 Funnel: diameter of 18 cm
- 1 hammer
- 1 basket of nails (30mm)
- 1 saw
Step 2: Frame
Attach two slates to each other to create a cross (X). Saw off two pieces of 2cm × 2cm × 5cm of one slate and nail them to opposite ends of the cross to stabilise it. Attach 4 slates in the middle of the cross (with the 2cm × 5cm side stuck to the cross) so that they form a shaft in which the milk carton fits (slates +/- 10 cm apart). The carton should be stabilized by the shaft, but not get stuck. Then saw off another piece of the sawed slate and attach it between two of the shaft sides. Finally add one LR44 battery on top of the last piece. In the end the frame should look like figure 1 (each slate is a different colour, for simplification).
Step 3: Collection Bin
Cut off the lower part of the milk carton approximately 15 cm from the bottom. Then make a hole in which the tube fits, slightly to the side. Glue the tube through the hole so that one end rests on the bottom of the milk carton and make sure the hole does not leak. Finally glue a LR44 battery on the bottom of the bin, so that the battery rests on the other battery if the bin is placed in the shaft. Figure 2 shows the result.
Step 4: Photon & Breadboard
Place the photon on the top of the Breadboard.
One wire go from 3V3 (j1) to the plus line.
One wire from ground (c2) to the minus line.
One wire from D0 (j12) to g22.
Put one button switch over e-f22& e-f24.
Put one adjustable resistance over c-e18 & c-e20 and twist it halfway.
One wire from b20 to the minus line.
One wire from b19 to b26.
One wire from e26 to the sensor (solder).
One wire from e27 to the sensor (solder).
One wire from a26 to A0 (c12).
One wire from d27 to plus.
One wire from c24 to min.
If the device is constructed as described above (like figure 3), place the sensor between the two LR44 batteries and tape it stuck to the small slate in between the shaft.
Step 5: Funnel
If the previous parts are in place, glue on the funnel on top to increase the catchment area of the device
Step 6: Script
To run the measuring device, a script needs to be written and activated on the photon. Wright the following C script on build.particle.io and flash it on your photon (see figure):
In the figure, the script is represented. It is not obliged to understand the full script, but beneath is a brief description what every part stands for.
In the first part, the variables of the script are given. Where int represents an integer, float stands for a digit with decimals.
The second part void setup, the void represents a function. This is the setup part, whereat is explained what pin on the Breadboard is used to get information.
After this part, the median is stated. The median is taken of a few measurements, to get rid of the high or low peaks. In this script, the median is taken for 5 measurements.
Void loop is the next function. The loop represents a function which repeats after a while. The if means that under a certain condition, the inner part is continued.
Next, the different measurements are stored. With the different stored digits, the median can be calculated.
Also the calculations for the rainIntensity are presented. These calculations are needed e.g. because the pressure is measured, which needs to be converted to a rain intensity.
At the end, the results are published.
It is, again, not obliged to fully understand the codes. The script can be copied. To get the script, the following link must be opened: https://build.particle.io/build Please, press Create new app. You will get an empty sheet. In here, the script needs to be pasted. To be sure the copy-paste went well, please verify the script. The program will search for any mistakes. If there are mistakes, please contact us. If there are no mistakes, flash the system.
Before the system can be used in practice, please calibrate the system. Pour an amount of water in the basket, and put the begin (no water in the bin) and end (the bin colmpletely full) terms, read from the device, in the script at the places: int begin and int end. This calibration need to be done 3 times. Also change the '400' on line 108 to the total amount of mL that the bin can hold. After this, flash the system again. Now the device is working, and it can be used for actual rain measurement.