Raspberry Pi Pumps Water

Raspberry Pi Pumps Water at Magnolia Village

Magnolia Village is a new residential development which sprung up the last few years in  Paulesti, Romania

A few years ago this was only a crop field. Today over 50 houses are ready and many more under construction. Electricity and gas was brought from far away. Sewer and water were provided on site.

For the water supply, a well was dug at 120m. A Wilo pump was submersed at 60m and water was stored in a 200 m.c. tank.

From the water tank, a pair of Wilo pumps are pushing water into the distribution pipes for the first 1,000 inhabitants.
Raspberry Pi Pumps Water

One pump is active at any time, and the second one is for backup. If the active pump fails, the backup pump takes over. Once a week the two pumps are switched, to age equally. This seems to be the perfect task for a Raspberry Pi aided by a HOME-Automation IO Card


An industrial panel was used to house all the components.

Raspberry Pi Control Panel

The HOME-Automation IO Card (1) piggy-backed on Raspberry Pi was installed using a DIN-Rail adapter.

A Break-out card (2) was added to connect the MEGA-IO Terminals. A rack-mount, industrial power supply
(3), was used to provide 12V for the external relays, and a rack-mount 5V power supply (4) for powering the Raspberry Pi and the Home Automation Card.

The programmable timer (5), the time-delay relay (6) and the relay (7) are switching the pumps once a week. The task could have been given to the Raspberry Pi software, but we prefered to handle it in hardware. However, any remote operator can trigger a pump switch manually from the browser. The heavy duty power switching is handled by the power relay (8). The Normal Open output of the relays drive the opto-isolated inputs of the Home Automation card.

(9). Each of the three pumps has two output signals: ON and FAIL. The signals are routed through the terminal block (10) to the relays

The default http page of the Raspberry Pi web server displays the status of the three pumps, and a button for switching pumps 1 and 2. In this start-up screen all pumps are off.
browser interface 1

The active pump cycles on and off automatically, to maintain the preset pressure in the distribution pipes. The pump status is shown immediately in the browser:
browser interface 2

Pressing the arrows image shuts down the active pump and starts up the backup. The change can also be forced once a week by the timer. The browser images change accordingly.
browser interface 3
In a pump fails, the error signal triggers a change in the browser image, and can also be used to send an email or a text message to the operator.
browser interface 4

The submersible pump is controlled by the level indicator in the storage tank. When the water level falls bellow the preset limit, the pump turns on.

browser interface 5

Raspberry Pi Pumps Water to 2000 inhabitants

Leave a Reply