Help selecting underwater short distance sensor (mm milimeters)

Hello, everyone.

I have been working on an arduino project to measure short distance underwater. My first goal is to measure the liquid level on the tank, but my final goal is to measure density of the liquid using a slightly different set-up. For that reason, I have to inform that I understand that there are other means to measure liquid level, but I am foccused on this set-up.

What I do need is some help to select sensors that can help me to achieve that.

I have made a drawing to try and explain the two different set-ups I have in mind, so you can look the attached figure to see it.

In summary, the set-up consists of a buoy that will float vertically according to the liquid level, being guided by a small shaft to maintain its horizontal position. The sensor will be in a water-tight box in a fixed position.

The first set up (left on the figure) is the one I am more comfortable with, where the buoy will float vertically, and the difference in position will be measured by the fixed-point sensor. I am thinking a linear hall sensor.

The second set-up (right on the figure) consists of the buoy floating vertically, but the sensor is some sort of capacitance sensor, where the vertical position of the buoy will be detected by the vertical sensor.

So, speaking of actual numbers here. I need to measure between 10 mm and 100 mm, but these I can actually try to optimize for shorter range (possibly between 10 and 50 mm will be OK). The important part is the sensibility, that needs to be at least 1 mm.

Some importants notes I think are worh to write here:

  1. I did buy a hall sensor A3144, but I cannot make it measure linear distance, only switch (basically 0 or 1 digital, 4 or 1023 analog). The seller sold me as a linear hall sensor, I am doing something wrong?

  2. Ultrasonic meters - I made some searches and specially on water (higher sound speed) I won't be able to achieve the 1 mm resolution... or am I wrong?

  3. Laser meters... these theoretically should work, but I cannot find any that gets me the required resolution.

Thanks in advance for everyone that will try and hopefully help me :slight_smile:

How to post images so we don't have to download them and everyone can see them.
How to post an image.
Another page on posting images.

I don't think any of those ideas are workable.

A linear Hall sensor would give reasonably accurate measurements only in a linear gradient magnetic field, which is probably impossible to produce in that situation.

Underwater ultrasonic transducers are expensive and require specialized, high voltage electronics. I've never heard of one for short ranges.

Laser distance sensors would be a possibility, but must be rated for long term immersion in water.

Liquid density can be measured by a refractometer.

jremington:
I don't think any of those ideas are workable.

A linear Hall sensor would work only for a uniform magnetic field, which is probably impossible to produce in that situation.

Underwater ultrasonic transducers are expensive and require specialized, high voltage electronics. I've never heard of one for short ranges.

Laser distance sensors would be a possibility, but must be rated for long term immersion in water.

Liquid density can be measured by a refractometer.

Thanks @jremington! From what I read on linear hall sensors, people got results on distance measurement using a magnet and a hall sensor, but I could not find many info on how accurate that was (probably not that accurate).

I do use refractometers to measure density, but was looking for an automated set-up...

You can't make an automated refractometer?

aarg:
You can't make an automated refractometer?

I don't want to say is not possible, but I don't think I am capable of doing it. Even though I understand the principle of measurement used in refractometers, the necessary hardware and coding are way beyond what I am capable of doing by my own.

amirjscheid:
I don't want to say is not possible, but I don't think I am capable of doing it. Even though I understand the principle of measurement used in refractometers, the necessary hardware and coding are way beyond what I am capable of doing by my own.

Is this project important enough to you for you to spend the time and effort to bring your capabilities up to the level necessary?

Paul

Paul_KD7HB:
Is this project important enough to you for you to spend the time and effort to bring your capabilities up to the level necessary?

Paul

No, it's just a personal challenge.... would not want it to take too much of my time (or money hehe)

There do exist automated, electronic refractometers but they aren't cheap.

I think you could make a crude one by passing a laser beam through a liquid sample, and have a detector array measure the bend angle.

Consider experimenting with a retroreflective distance sensor, like one of these. With a fixed distance to a reflector, changes in the refractive index should mimic changes in distance.

A modified lowly HC-SR04 "...seems to work well, returning stable results and showing changes less than 1 mm." From: HC-SR04 | David Pilling The HC is not suitable for long-term use in a high humidity environment, but it would be ok for experimentation.

Also, if you can attach a sensor to the bottom of your tank, and if your tank is a suitable material and depth, you could try the relatively inexpensive DS1603L.

The DS1603L datasheet and a library by @wvmarle can be found here: How to read serial data from Non-contact Ultrasonic liquid level sensor - Sensors - Arduino Forum

Judging from the datasheet (and the HC write-up), I'm not optimistic that the DS1603L will satisfy your precision ("sensibility") requirement, but with stable conditions and oversampling+decimation, maybe it would get you close enough.

DaveEvans:
A modified lowly HC-SR04 "...seems to work well, returning stable results and showing changes less than 1 mm." From: HC-SR04 | David Pilling The HC is not suitable for long-term use in a high humidity environment, but it would be ok for experimentation.

Also, if you can attach a sensor to the bottom of your tank, and if your tank is a suitable material and depth, you could try the relatively inexpensive DS1603L.

The DS1603L datasheet and a library by @wvmarle can be found here: How to read serial data from Non-contact Ultrasonic liquid level sensor - Sensors - Arduino Forum

Judging from the datasheet (and the HC write-up), I'm not optimistic that the DS1603L will satisfy your precision ("sensibility") requirement, but with stable conditions and oversampling+decimation, maybe it would get you close enough.

Thank you, Dave. From what I read there, he uses the sensor above the liquid level, but that might be something I can adapt as well.

jremington:
There do exist automated, electronic refractometers but they aren't cheap.

I think you could make a crude one by passing a laser beam through a liquid sample, and have a detector array measure the bend angle.

Consider experimenting with a retroreflective distance sensor, like one of these. With a fixed distance to a reflector, changes in the refractive index should mimic changes in distance.

Making a crude refractometer does seem like an interresting challenge, and I will definitely keep this idea in my mind!

What I came across recently and forgot to mention is to use a digital caliper to measure the relative distance. I will buy one and try to figure out if I can make the ruler/sensor to work from distance to each other (2-5 mm just to get rid of the friction) and if the measurements can handle some "bouncing" of the ruler.