How's Your Water Level? Build a Wireless Depth Detector

Here's how to build a wireless water depth detector based off of an Arduino Nano. This project is perfect for anyone looking for a DIY method of monitoring water levels in aquariums, pools, decorative ponds and more with up to 0.05-inch accuracy.

Based on dual BMP280 pressure sensors and a KY-013, water, temperature sensor this project is intended for monitoring evaporative and decorative ponds, creeks or wells. The functionality could also find use in aquariums, hot tubs, or pools. The dual sensor implementation provides accuracy resolution down to ~0.05 inches of water with 0.8% variation per measurement.

 

Referring to the schematic, the Ardurino based controller is also fitted to an HC12 serial link to provide remoted monitoring

PARTS LIST:

Generic Name

Description

Quantity DigiKey Part Number

Arduino Nano

  1

1050-1001-ND

10K resistor

  6
CF14JT10K0CT-ND

4.7K resistor

  2
CF14JT4K70CT-ND

510 resistor

  2  

5.1K resistor

     

22uf 25V Pw CAP

  1 565-4782-ND

1N4001 Diode

  1
1N4001-TPMSCT-ND

HC12 Serial Transceiver

  1  

BMP280 Pa Sensor

  2

828-1064-1-ND

0.1" Row Connectors

 

  23  

0.1" Header pins

  18 277-1753-ND

Screw Terminal pins

4 position

1  

5mm Barrel Power Conn 

Specific, dependent on mating male plug 1
EJ501A-ND*

1N4148 Diode

  2 1N4148FS-ND
White LED   2
C503B-RCN-CW0Z0AA1-ND

Button Switch

Momentary

1

 

KY-013Temp Sensor

req code change(non Stock substitute) 1

DS18B20-ND*

       

 

BUILD INSTRUCTIONS:

The coded processes monitor both the barometric and sensor pressures, allows for a base level configuration, high and low set points, and facilitates an LED display with trips points and a a related alarm with override.

Both the barometer re-test and wireless report can be independently scheduled in durations of 1 to 655535 seconds.

Using the BMP280 sensors together allows for water level measurement accurate down to fractions of an inch and has the happy bonus of cost less than $2. The second sensor (S1) adjusts for atmospheric barometric pressure variation.

Using the "SparkFunBME280.h" library functions and services produces readings for temperature, absolute pressure, and an altitude reading from the pressure and temperature measurements done on the sensors. Altitude is not used in this application.

The HC12 is a hundred-channel, 433-MHz based, serial transceiver link and is configured to produce the maximum of 20dBm transmit power. It's configurable for a number of scenarios and provides up to 1000m for a reasonable $4-5. This wireless link is shared with the Arduino Nano’s serial USB.

A series of operational parameters, shown below, may be then configured and updated, as required, over either of these links. Any non numeric entry evokes the 4 parameter, System parameters list shown.

The report, shown below, is then available as parameter 2 , on other the connected USB port or on a remote receiver terminal configured with same channel and rate settings.

Bluetooth may also be configured onto the project, although with the controller at about 70% and memory is 46% used, additional coding for a WIFI link and interface could get the data to a Thingspeak or other Internet accessible resource. The schematic reserved pins 8 and 9 pins for an 8266 based WiFI. The code, while available, is not included in the app.

The Operational parameter list, taken from the System list, parameter 3, provides a series of variables that are maintained in EEPROM and

Comments

Looking back at the submission I discovered the image of the HC12 serial translator was missing 4.7k pull up resistor on the base collector junction. I hadn't used this approach in my prototype. Should readers have any question or require any other information the author can be reached at: [email protected]

Thanks, William, for a cool project. Good explanation of how it works, too. Was it intentional that there is no download of the construction details or for the code? I seem to recall most of the other Gadget Freak articles included download links.

I can and will provide anything you need eg: the Arduino ino code and any other documentation. This of course was included with submission and sometimes gets lost or is added separately .. and get lost.

Do you have any details of how the BMP280 gets physically interfaced to the water? The datasheet has the statement -- "Liquids shall not come into direct contact with the device" ...

Since the trapped air in the column will compress, won't you actually be measuring the depth of the trapped air bubble rather than the end of the tube?

I think if the tube is open on the bottom and sealed, the air will compress in relationship to the water submergence. So the change in the differential between the P/T looking at the ambient baro-pressure and the one sealed up in the sample tube will equal the water depth above the end point of the tube.

David, I wonder how well the sensors will hold up to ozone? I have a drinking water water tank which I would like to monitor and the water is sterilized by an ozone generator. One thing I learned is drinking water is tough - it has to work 24/7/365 or life gets rough real fast!

William may have some comments -- it sounds like he has had these in operation and may know about reliability over time. You might be able to protect the sensor volume with some kind of air permeable filter (like activated carbon) that would allow the pressure changes to register, but filter out any free ozone.

Pages

Add new comment

By submitting this form, you accept the Mollom privacy policy.