cancel
Showing results for 
Search instead for 
Did you mean: 

vl6180 liquid measure

SVino.1
Associate

I need to measure the level of a transparent liquid of small depth (5-20mm). I try vl6180 or vl6180X. The sensor is located at a height of 30-40mm from the bottom. The sensor does not see the liquid. It shows the distance to the bottom. If you gradually pour liquid into a container, the measured distance does not change. Only if the liquid level reaches 40-60mm does it show that there is something in the tank, but it is wrong (if the distance to the liquid is 30mm, it shows 40-50). I can not use the float. Is it possible to solve this problem?

8 REPLIES 8
John E KVAM
ST Employee

Measuring the depth of water is difficult. Some photons reflect off the top, and some penetrate the water hit the bottom and reflect back. More, as the photons travel through the water they are slowed down quite a bit.

One solution is to make the bottom of your tank very black. That way any photons returned would be from the surface.

Another solution is to place shinny floating objects in the liquid. The photons mostly reflect off the floating objects and give you a good answer.

Sorry I cannot give you a better answer.

  • john


In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.

I understand that part of the photons returns from the bottom. As I understand it, a certain average indicator for returning photons is calculated. Those that bounce off the surface come first. Why not make a conclusion about the distance by the first photons? There is nothing between the microcircuit and water, only air. Can we assume that the first returning photons are reflected, and measure the distance along them? Can I configure the chip?

John E KVAM
ST Employee

The sensor can only average all the photons it gets back. There is no way to separate the 'good' photons from the 'bad' photons on this chip.

Sorry about that.

  • john

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.
FWitt.1
Associate II

@John E KVAM​ 

Hi John,

i just stumbled upon this post having pretty much the same problem. I Found a function inside the Datasheet/Library, used to compensate for Crosstalking when using a glass cover. I had the Idea to use this as a workaround to "seperate the good photons from the bad ones" as Svino.1 suggested about a year ago.

If i understand the function correctly, it makes the chip ignore results from a certain range (range of the glass cover). Wouldnt it be possible to simply set this threshold to lets say 140-150mm and therefore make the chip ignore all those measurements from the bottom of the container whilst still taking readings below that?

Thanks in advance for your valuable time,

Kind regards from Germany,

Felix

John E KVAM
ST Employee

The speed of light is fast - really fast. It takes only 6.7 pico seconds for light to travel 1mm round trip. (A pico second is 1 millionth of one millionth of a second) And it's very unlikely that a couple dollar sensor can make any decision at that speed and separate out the good photons from the bad ones. So we cheat and use statistics.

We get a very general idea of what is going on and use mathematical model to establish what is going on. We can tweak the model a bit to account for the coverglass, but really have no way to do what you are suggesting. If your target is more than 80cm from your 'false target' you can upgrade to the VL53L3. (it's about the same size, but not pin compatible.) But the L3 uses a different method, and it can find multiple targets.

  • john

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.
FWitt.1
Associate II

@John E KVAM​ 

Dear John,

Thanks for the quick response! I already thought so, but wanted to give it a shot anyways. In Our application, the sensor is supposed to measure the waterlevel of our tank (0-15 cm). The sensor itself is placed 1cm above the tank, looking straight onto the water (perpendicular). The real target is therefore 1-16 cm away from the sensor, whilst the false target lies at exactly 16 cm. I fear the VL53L3 is not made for such short distances? Can u recommend any sensor suitable for our application?

Once again, thanks for your time!

Kind regards,

Felix

John E KVAM
ST Employee

so it's the bottom of the tank you are worried about? Can you make the bottom of the tank a very flat black color. Black reflects very few photons and is unlikely to overly influence the result. Another option is to use clear plastic - which the light will mostly go through- and have a very black structure under that.

  • john

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.
FWitt.1
Associate II

Yes, it's the bottom of the tank we are worried about. As you pointed out in the beginning of this discussion, some photons get to the bottom, some dont, and in the end we get a value somewhere in between. I will try using a black coloring at the bottom, but to be honest it's not really an option beyond prototyping since we cant afford to custom paint every tank in production. I am currently designing a floating raft guided by some rods that should be detected without any trouble.

If I find any other solution or workaround, i will let you know, just in case someone else encounters similar issues.

Thank you for the great service, John. Its really appreciated!

Felix