Search This Blog

Thursday 23 April 2020

Water Level Monitor

Water Level Monitor

We've got a rainwater harvesting system that consists of a tank holding rainwater and a pump that supplies toilets and the washing machine. The system came with a mechanical water level meter which is fine, but it requires a trip to a cupboard and some hand pumping. The pumping creates high pressure air which runs in a pipe to the tank. The higher the water level in the tank, the higher the pressure. A pressure gauge in the meter shows the capacity in percentage capacity.

The reading is the height of water in the cylindrical tank. As the cross section of the tank is circular this doesn't quite represent the amount of water in the tank, but it's fairly close.

I started looking at an electrical version a few years ago. Using a pump instead of the mechanical hand operated piston was an obvious way to do this.You could then have a pressure sensor which gives you the same reading as the mechanical system.

The first problem was the pressure involved. The tank is about a meter and a half high and that leads to quite a pressure. The pump needs to generate at least this pressure and the pressure sensor needs to be able to read that pressure. I couldn't find either a pump or a pressure sensor that would work at the pressure I needed.

I left the project for a while, then I came across a cheap blood pressure monitor. This has a pump and a pressure sensor and performs a very similar task to the water level meter I wanted to create. The pressures involved looked promising as well. I dismantled the monitor and extracted the pressure sensor and pump. I reverse engineered the circuit for the sensor and recreated it on an arduino Uno format shield.



You can see the sensor below the IC, it attaches to plastic tubing.The pump drive is a power transistor driven with a PWM signal so I have speed control. If the pump is driven at full speed then it is a bit noisy. Running at a lower speed still gives a high enough air pressure and it's much much quieter.

The final system is mounted in the same cupboard next to the manual meter:



The electronics are in a 3D printed case,  the pump is on 3D printed brackets. The manual meter reads the air pressure when the pump is energised, so you can use it instead of the manual pumping system.

The manual pumping system (below the electronic system) still works exactly as it did before, so there's a backup in case the electronics fails.

The code is set up to energise the pump once an hour, it then stores up to 1000 samples which are offloaded to my laptop using a cron job. I can then graph the samples as needed.





No comments: