1 Introduction

The frequency of heavy storm events has increased over the last years with Mediterranean tropical-like cyclones, like Zorbas in 2018, Ianos in 2020 and Daniel in 2023, all of which occurred in September and resulted in torrential rainfall and large-scale flooding. Myhre et al. (2019) project that if historical trends continue, the most intense precipitation events observed today are likely to almost double in occurrence for each degree of global temperature rise. According to Fischer at al. (2021), models project not only more intense extremes but also events that break previous records by much larger margins and their probability of occurrence depends on warming rate.

The measurement of rainfall via ground sensors is of paramount importance for hydrological research, basin water balance computations, storm frequency analysis, hydraulic structure design, meteorological radar calibration and flood forecasting (Bournas and Baltas 2023). There is a need for high-quality long-term data with high temporal resolution from a dense network of gauging stations to capture the spatial patterns of precipitation, which among others is necessary for the estimation of future changes in IDF curves (Kourtis and Tsihrintzis 2022). Theochari et al. (2021) describe a methodology which combines a set of spatial criteria to propose suitable locations for such installation of a meteorological station network.

The most common types of automatic gauges for the measurement of rainfall intensity are the tip** bucket rain gauges (TBRs). According to Segovia-Cardozo et al. (2023), TBRs have become one of the most extensively employed rain gauges, due to their simple manufacturing structure, low production cost and energy-saving capacity, being commonly used by national meteorological services, industries and private individuals. They are the most common type of automatic recording gauge and are the main data source used for adjustment of radar rainfall estimates (Ochoa-Rodriguez et al. 2019).

The main sources of measurement biases in TBRs are those caused by wind turbulence and mechanical factors (Segovia-Cardozo et al. 2023). Lanza and Cauteruccio (2021) show that the accuracy of precipitation measurements relies, among others, on the interpretation and adjustment of high-resolution raw data from traditional sensors. Only well-calibrated and bias-corrected instruments show acceptable performance against the reference precipitation. At high intensities, the tip**-bucket rain gauge is known to underestimate rainfall, because of the rain water amount that is lost during the tip** movement of the bucket. The related biases are known as systematic mechanical errors and their effect increases with rainfall intensity (Molini et al. 2005). Duchon and Biddle (2010), based on results from seven events, show that the tip** bucket gauges noticeably underestimated storm event rainfall totals relative to the weighing-bucket gauge when 1-min rain rates exceeded 50 mm/h. They also remark that observable wind induced undercatch by tip** bucket gauges, positioned at ground level, begins when the wind speed at a height of 2 m exceeds 5 m/s.

The objective of this work is the development of comparably low-cost and reliable rain gauges with simple, plug and play operation that could be installed at remote areas with available mobile internet, in order to supplement with rainfall data the existing limited network of hydrological stations. To achieve this target, two experimental TBRs of different diameters, i.e., 20 and 28 cm, along with their data logger were developed by using the electronic boards Arduino UNO and Raspberry Pi. The experimental TBRs were evaluated by comparing their measurements with those of a high-quality recording rain gauge ARG100 and a non-recording rain gauge that provided the accumulated depth of rainfall and was used as reference for quality control. The measurements were made in Athens, Greece, during a storm event with rainfall intensities that reached 15 mm/10min or 90 mm/h.

2 Methodology

2.1 Rain Gauge Construction

Two experimental tip** bucket rain gauges (Fig. 1) were developed; first, a rain gauge with a diameter of 28 cm (RG28) and then a rain gauge with a diameter of 20 cm (RG20). Each rain gauge consisted of the following components:

  1. i.

    A metal cylinder with diameter of 28 cm or 20 cm.

  2. ii.

    A funnel that collects the rainfall water to conduct it to the tip** bucket component.

  3. iii.

    Two buckets made of thermoplastic polymer Acrylonitrile butadiene styrene (ABS), situated at either end of a short balance arm. At the first stages of the project, this mechanism was made of inox steel. Later, the lighter ABS material was used, which is easier to make modifications via 3D printing. Different tip** bucket dimensions (Fig. 1 right) were tested, considering their water volume, as well as the gauge cross-sectional area. Regarding RG28, the bucket width was 2 cm, the height 4 cm and the total length 15 cm.

  4. iv.

    A magnetic reed switch which operates by magnetic field. Every time the balance arm tips, the contact of the magnetic reed switch closes, creating a momentary pulse signal.

  5. v.

    An electronic circuit that consists of an electrolytic capacitor and resistors, connected to the reed switch, so that double values ​​are not erroneously recorded by the data logger when the switch closes.

The typical operation of a tip** bucket rain gauge is described as follows: rainfall is collected by the funnel and is passed to one of the two buckets situated at either end of the balance arm. When the first bucket is full, the balance arm tips, emptying this bucket and positioning the second bucket under the funnel. At each tip, the moving balance arm forces a magnet to pass the magnetic reed switch, causing contact for a fraction of time.

The experimental rain gauges have different resolutions. Each tip of the RG28 corresponds to 0.221 mm of rainfall depth, while each tip of the RG20 corresponds to 0.367 mm of rainfall depth. This is attributed to their different diameters/cross-sectional areas and the tip** bucket volumes.

Fig. 1
figure 1

The experimental rain gauges: RG20 (left), RG28 (middle), and RG28 tip** bucket mechanism (right)

2.2 Data Logger Development

When the contact of the magnetic reed switch closes, the pulse signal reaches the digital input of an Arduino UNO board. A data logger was developed to record the number of pulses per time interval that consisted of an Arduino UNO board, as well as a shield with Real Time Clock and Secure Digital (SD) Card to store the data files. A code was written in C programming language for the recording of the exact time of the switch closure and for the integration on a 10-min time step of the total number of switch closures. The data logger was housed in a watertight box and was placed inside the rain gauge (Fig. 2).

Fig. 2
figure 2

The first data logging system housed in a watertight box

Arduino Uno board consists of the microcontroller ATmega328 which has 32 KB memory, 2 KB of SRAM and 1 KB of EEPROM and has 14 digital input/output pins, 6 analog inputs, a USB connection, and a power jack. It can be powered via the USB connection or with an external power supply. The Arduino Integrated Development Environment (IDE) is a special program running on computer that allows the user to write sketches for the Arduino board. Arduino language is based on Wiring language, a C/C + + variation for microcontrollers of AVR architecture, like ATmega and supports all basic structures of C and some characteristics of C++. The basic library is AVR libc (Stamatopoulos 2015). When uploading the sketch to the board, the code is translated and is passed to the AVR-GCC compiler that makes the final translation into the language understood by the microcontroller (Banzi 2009).

The experimental rain gauges require constant data monitoring and proper hardware and software modifications. The above data logging system has reduced capabilities in data monitoring and networking. For the reading of the recorded files, ​​the user should periodically take the data logger out of the rain gauge and then extract the files of the SD card to a PC. For these reasons, another data logger was developed using the boards of Arduino UNO and Raspberry Pi.

The Raspberry Pi board is a mini-PC with the size of a credit card, runs LINUX software and has high networking capabilities that are useful for remote data access and for the monitoring of its operation. Raspberry Pi 4 Model B provides desktop performance comparable to entry-level x86 PC systems. The key features of this product include a high-performance 64-bit quad-core processor, dual-display support at resolutions up to 4 K, up to 8 GB of RAM, dual-band 2.4/5.0 GHz wireless LAN, Gigabit Ethernet, Bluetooth 5.0 and USB 3.0 connections.

The operation of this data logger (Fig. 3) is the following: The pulse signal from each rain gauge is driven to a separate Arduino UNO board. Then, each Arduino UNO sends this information via the serial port to the Raspberry Pi board. Code in Python3 programming language was written for the collection of the serial data from the two Arduino UNO boards and for their storage in two separate (.txt) files. These files store the instantaneous time data of the switch closure and the cumulative time-integrated data that is the total number of switch closures on 10-min interval.

The data logging system was installed inside a ventilated control box. For the air cooling of the Raspberry Pi board, a fan was placed on the top of the board. This is necessary especially during the summer months. The Raspberry Pi board is connected to the internet via the Ethernet port. The internet connection could also be available via a mobile internet device. The recorded data inside the Raspberry Pi board can be accessed at any time with a remote desktop application that offers remote control and file transfer.

Fig. 3
figure 3

The final data logging system using Arduino UNO and Raspberry Pi electronic boards

2.3 Rain Gauge Installation and Maintenance

Rain gauges should not be located on the tops of buildings due to wind turbulence that might reduce the precipitation catch. Also, the wind-induced errors are greater when the height above the ground surface increases (Gordon USGS, 2003). Despite these rules, the whole equipment was installed at the end of May 2023 on the top of a building (Fig. 4) in Agios Dimitrios Municipality, about 5 km south of Athens city center. The main reason is that its operation, especially at the first stages, requires constant data monitoring and modifications on hardware and software. For the quality control of the experimental TBRs, a cumulative non-recording rain gauge was installed for the measurement of rainfall depth on a daily base. Thus, the installation site should be as close as possible to the user of the station. Another reason was the availability of internet and electric power. For the installation, it was considered that the distance between the rain gauge and any obstruction should be at least twice the height of the obstruction.

Fig. 4
figure 4

Rain gauges installation on the top of a building in Agios Dimitrios Municipality, Athens

The data from the two experimental TBRs were compared with that of a high-quality TBR, model ARG100, Campbell Scientific. The ARG100 rain gauge was adjusted to tip once for each 0.16 mm of rainfall depth and a HOBO event data logger was used to record the instantaneous time data of its switch closure.

The maintenance of the rain gauges includes inspection/cleaning of each funnel once a month, as dust accumulates at the bottom of the funnel, reducing the flow rate or even preventing totally the flow to the buckets. Especially the funnel of the RG20 has a small bottom opening of about 3 mm and this is a drawback, since dust accumulates more often in comparison to the RG28 that has a greater opening. Also, once a month the operation of each TBR is checked by pouring a measured water volume through each gauge and counting the tips.

3 Results and Discussion

On 06-09-2023 the Mediterranean cyclone Daniel caused heavy rainfall and led to large-scale flooding in the region of Thessaly. The cyclone caused an intermittent storm event in the city of Athens with four main time periods of high rainfall intensity (morning, afternoon, evening and night) and was recorded by the three TBRs. The respective accumulated rainfall depths are shown in Table 1.

Table 1 Comparison between the accumulated rainfall depths measured by the TBRs and the non-recording rain gauge. Boldface values indicate cumulative depths

The observed daily cumulative rainfall depths on 06/09/2023-18:00 and 07/09/2023-18:00 were 55.05 and 60.10 mm, respectively. The respective rainfall depths measured by ARG100 were 53.76 and 59.70 mm, which correspond to differences of -2.34% and − 0.37% in relation to the observed cumulative values. The respective rainfall depths measured by RG20 were 51.74 and 53.54 mm, which correspond to differences of -6.01% and − 10.92% in relation to the observed cumulative values. The respective rainfall depth measured by RG28 was zero (it did not operate until 06/09/2023-18:00 due to software-communication problem) and 58.32 mm, which corresponds to a difference of -2.96% in relation to the observed value. Considering the high rainfall intensities of the storm event, the TBRs RG28 and especially ARG100 only slightly underestimated the rainfall depth. In Figs. 5 and 6, the storm hyetographs have been plotted on a 10-min scale and these reveal that the temporal evolution of rainfall measured by RG20 and RG28 is in line with that of ARG100.

Fig. 5
figure 5

Ten-min hyetographs of the 06-09-2023 storm event (from 09:00 to 18:00)

Fig. 6
figure 6

Ten-min hyetographs of the 06-09-2023 storm event [from 06–09 (19:00) to 07–09 (01:00)]

On 10-min scale, variations in the gauge measurements were evaluated considering the ARG100 as reference rain gauge used for comparison. The measured by all TBRs rainfall depths with values over 1 mm/10min are shown in Table 2. They have been sorted in descending order based on ARG100. The maximum 10-min rainfall depths measured by ARG100 were 15.04, 14.24, 12.64 and 11.04 mm. The variations in the measured rainfall depth between ARG100 and RG28 were lower than 6.1%. The exception was in one 10-min interval at low rainfall intensity (0.88 mm vs. 1.12 mm), which may be attributed to software malfunction.

The differences between ARG100 and RG20 exceeded 10% at four time intervals. Two of them occurred at intensities over 9 mm/10min, at about the end of the storm and might be attributed to RG20 semi-clogged funnel due to its relatively small diameter. Modifications to the funnel diameter are necessary, as well as further observations.

Table 2 Comparison on 10-min scale of the rainfall depths measured by ARG100 and the experimental TBRs RG20 and RG28. The largest underestimations are indicated with an asterisk

In the morning of 07-09-2023, the rainfall was characterized by low intensity (the maximum value reached 1.1 mm/10min). Comparison between the rain gauge measurements was not made for low intensities (under 1 mm/10min) due to their different resolution, i.e., for the RG28 each tip of the buckets corresponds to 0.221 mm of rainfall depth, while for the RG20 each tip corresponds to 0.367 mm of rainfall depth. The respective value for ARG100 is 0.16 mm. At low rainfall intensities, all rain gauges should have the same resolution to make a comparison. This will be one of the future targets of the project. Comparison at low rainfall intensities in greater time scale, i.e., between 07:00 and 10:00 of 07-09-2023 showed that the accumulated rainfall depths measured by RG20, RG28 and ARG100 were 4.00, 4.00 and 4.32 mm, respectively. Between 07:00 and 14:00 of the same day, the respective values were 5.1, 5.5 and 6.1 mm.

3.1 Calculation of the Return Period of the 06-09-2023 Storm Event

The return period of the 06-09-2023 storm event was calculated for the rainfall durations of 10 min, 20 min, 30 min, 1 h, 2 h, 3 h, 6 h, 12 and 24 h, using the Intensity-Duration-Frequency (IDF) equation at the station of Helioupolis, which is located at a distance about 2.5 km southeast of the rain gauge installation site. The IDF equation was obtained from the Flood Risk Management Plan of the Attica Water District (Ministry of Environment and Energy 2018). The general expression of the IDF curve is:

$$i\left(d,t\right)= \frac{{\lambda }^{\prime}({\text{T}}^{\kappa } - {\psi }^{\prime})}{{(1 + \text{d}/{\theta }) }^{\eta }}$$

The values of the parameters θ, η, κ, ψ΄ and λ΄ for this meteorological station are 0.124, 0.622, 0.07, 0.881 and 365.3, respectively. For the derivation of this equation the rainfall data of the meteorological station were collected, analyzed and processed for the creation of time series of maximum rainfall depths for the aforementioned rainfall durations, and the IDF curves were developed by fitting the generalized extreme value (GEV) distribution to the observed annual maximum rainfall data for the estimation of the values of the parameters θ, η, κ, ψ΄ and λ΄. The IDF curves for the station of Helioupolis are presented in Fig. 7. For the rainfall durations of 10, 20 and 30 min, the return period was 43, 59 and 45 years, respectively. For greater durations, it was lower than 20 years.

Fig. 7
figure 7

Intensity-duration-frequency (IDF) curves for return periods of 10, 20, 50, 100 and 1000 years for the station of Helioupolis and the respective return period of 06-09-2023 (06Sept23) storm event

3.2 Merits and Limitations

The study treats the problem of the measurement of rainfall via ground sensors, which has been and continues to be the most critical measurement in many hydrological applications; it contributes to the construction of potentially low-cost and reliable rain gauges. The limitations of the study include the rather limited extent of validation of the measurements via the proposed sensors; also, the selected storm event was an extreme one and events of lower return periods need to also be tested.

4 Conclusions

Two experimental tip** bucket rain gauges (RG20 and RG28) were constructed and tested by comparison with an operating tip** bucket rain gauge (ARG100) and daily non-recording rain gauge. The comparison between the rainfall depths measured by ARG100 and the experimental tip** bucket rain gauges RG20 and RG28 showed that RG28 is more accurate in relation to RG20. The differences in total rainfall depths on 06/09/2023-18:00 and 07/09/2023-18:00, measured by RG20, were − 6.01% and − 10.92%, respectively, in relation to the daily non-recording rain gauge values. The differences in the total rainfall depths of the event from 06/09/2023-18:00 until 07/09/2023-18:00 measured by RG28 were − 2.96% in relation to the daily non-recording rain gauge value.

On 10-min scale, the maximum difference in the measured rainfall depth between ARG100 and RG28 was 6.1%. The variations between ARG100 and RG20 were in general low, but at two 10-min intervals of high rainfall intensity towards the end of the storm, they were − 12.2% and − 20.9%. This might be attributed to RG20 semi-clogged funnel due to its relatively small funnel diameter of about 3 mm.

The reliable operation of the TBRs depends on their construction that minimizes the maintenance needs. The greater diameter of RG28 funnel compared to RG20 is an advantage, since it is more difficult for the dust to accumulate and block a part of the flow to the buckets. Additionally, due to critical role of mechanical parts, the inspection of their calibration at regular time intervals is necessary, though the initial calibration has not changed until now. Regarding the data logging system, its continuous operation is also without problems.

In the next stages of this research, except of the modification in the diameter at the bottom of the funnel, the resolution of the RG20 rain gauge will be examined, so that each tip of the buckets corresponds to about 0.2 mm of rainfall depth. Also, an automatic data transfer to an online database could be developed for public access to the measurements, as well as the energy autonomy of the system will be examined by installing a photovoltaic panel with power bank.