Monitoring water levels with a Parallax Ping sensor

arduino_parallax_ping_water_level_sensor

When you need a mechanism to detect the water level within a container or tank, you have several different options. Most people opt for a simple float or probe that sits in the water, while others use optics to sense when the water is reaching an undesired level.

This device built by [Danilo Abbasciano] uses a Parallax Ping sensor instead. If the sensor is placed at the top of a well, cistern, or other water container, it can accurately calculate the height and volume of the fluid inside. This is done by using the Ping’s readings in conjunction with a few values already known to the user, namely the dimensions of the container.

In his implementation, the readings are relayed to a simple LCD panel for easy viewing, and a small piezo speaker is used to sound an alarm when the water level reaches a predefined threshold. This sort of measuring device can be quite useful in situations where a contact-based sensor would be subject to chemicals and corrosion, or where contamination is a concern.

Comments

  1. David Dean says:

    I’ve got a neat spectra symbol magnetopot here that would be perfect for that. I got it for an application it wasn’t good for and still haven’t found a proper use for it. :/

  2. Pete says:

    I wonder how the Ping sensor responds to other sources of ultrasonic frequencies. The reason I ask is I recently made some bat detectors; ultrasonic frequency dividers. I could hear ultrasonic components to water running out of a faucet. I am curious about noise immunity I guess and didn’t see any in the software.

  3. fartface says:

    MY favorite is either capactive, by applying two strips of copper or aluminum tape to the outside of the tank (if non metallic) or drilling holes and putting in bolts that I use for level sensing.

    I.E. the way the RV industry has done it for the past 6000 years.

    the sonic level works GREAT if your tank is large enough. the rain barrel I have for watering is too small and it get a lot of echos when below 1/2 full so the readings get all wierd.

    so I resorted to drilling 8 holes and using stainless steel screws through the side with RTV sealant. easier to detect without any processor.

    Although I’m going to try just heating the screws and pushing them through too small holes to use the plastic of the barrel next time to seal the sensors.

    IF you have a bigger tank, this sonar thing works great. like for a septic tank so you know its full before the lawn is covered in turds and urine.

  4. palako says:

    Combined with the equivalent light ping device, which would bounce in the floor of the well/container rather than the surface of the water), you wouldn’t even need to know the dimensions of the container. That would make for a pretty useful handheld device.

  5. NicodemusBC says:

    I have a switch relay system for automatic top off that uses a tube with reed switches in it and a floating collar with a magnet embedded in it. It’s all plastic and fish safe but a version could be made with multiple reed switches that’d be readily by a micro-controller.

  6. kfreburger says:

    The same technique was used in this project: http://www.cocoontech.com/forums/index.php?showtopic=4666

  7. sc0rch3d says:

    i would think this is an excellent replacement to current toilet mechanisms.

    • Willy says:

      Toilet mechanisms don’t use electricity thus more cost effective.

      Why would you want to use something like this? If something in the code or the sensor went hay-wire you’d have a flooded bathroom…

  8. fm2f90x says:

    How does the sensor stand up to the water vapour? A cistern could be somewhat damp and I’d hate to replace the sensor every couple of months or however long it would last.

  9. Mykie says:

    But how long will the ultrasonic sensor last in the humid environment?
    Also, this guy should learn how to spell wather.

  10. Macpod says:

    I wonder how well this works for agitated water or water that is moving (i.e. through a tunnel if monitoring at a cross-section)

    • Leithoa says:

      There are a few tools out there that utility companies use to measure fluid flow of storm water or sewer pipes. This technology is also useful for stream gauging/profiling. You need a fairly quick processor to do it but they track undissolved particles in the water and compare it to the depth to get flow rate/volume and stream bed profile.

      In pipe or culvert you already know the cross section so height above the base is all you need to get the rest of the data.

  11. DooWeeNo says:

    Wells can be hundred of feet deep. This will not work on those.

  12. Sean says:

    For about $80, you can get one of these:

    Rain Alert

  13. bovine says:

    The Practical Arduino book did tank depth measurement by placing a pressure sensor at the bottom of the tank.

    http://www.practicalarduino.com/projects/water-tank-depth-sensor

  14. groogs says:

    I’ve actually installed commercial versions of this in cisterns for monitoring water levels (and then driving control and warning systems).

    They are very accurate, and as far as I know are still in use after a few years. The one I used had a control box that provided 4-20mA signal, and connected via RG-6 to the actual sensor in the cistern. There were a couple different sensors you could use: one was rated for something like 4″ to 8′ with a 15 degree cone, and the other was 12″ to 12′ with a 12 degree cone. The cone angle dictated the width you needed at different heights, so basically, the taller tank you wanted to measure, the wider it had to be. You could also mount the sensor in a narrow riser so you could measure right up to the top of the tank.

    I suspect these sensors would work much the same way. Ideally though to make it more ruggedized, the electronics would be remotely mounted in a dry area.

  15. tim says:

    Too bad this won’t work in a fueltank. Does anyone have an idea how to mesaure the level of a fuel tank electronicly (without a floater)

    Tim

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 96,699 other followers