Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

LIQUID FLOW METER with SIMPLE SPECTROMETER DESIGN help

Status
Not open for further replies.

cagabit

Newbie level 4
Joined
Nov 4, 2014
Messages
7
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
137
I am stuck at and seeking different ways of thinking or knowledge sources, any help appreciated.

I am trying to design a liquid flow meter circuit using lines of IR led – Photodiode couples, driving and reading the output with uP. At first I am trying to get a stable reading of the height of the liquid, inside a rectangular cross-sectioned pipe, which the IR lines reside on.

Some specs:
- measure mass / volume of opaque liquids without interfering (no touching mechanical parts etc.)
- while on the flow, the max flow rate is 15 lt/min
- the liquid has air bubbles from small to big (this changes everything!)
- the liquid is same but some contents ( most important is fat ) changes dynamically throughout the flow
- no important levels of pressure or heat, no hazardous or special requirement liquid will flow

So basically; after all calculations if I put the liquid, half the height of the pipe I should read %50, if it is full I should read %100. I used some levels of calibration and calculation which explained below but the error is not as low as I expected. I cannot measure this precisely now because the height is about 12 millimeters, but at least when it is full I should read %100 every time! Now I have something between %95-105. Basic technology used here is spectrometer I guess, but a simpler and less precise model of it.

If I can manage to decrease the error, I will pass to liquid flow tests, which I will read many samples of 2 lines of IR light, which the liquid passes and try to find the velocity (calculating time between 2 lines which the liquid passes) and the instant height of the liquid (which leads me to the instant area of liquid passing).
Tried to write as brief as possible, I can go details if you lead me to the title.
Best wishes,



CALIBRATION & CALCULATION routines:
(Each line of IR line (with IR led and Photodiode) is called as channel-ch , so we have ch0 and ch1 )
• Ch differences Calibration:
(every ch reads of the same liquid with some differences )
At start read 100 samples, take average for each ch and choose ch0 as the reference channel, calculate a constant K1 for the ch1 which converts the reading of ch1 in terms of ch0:

Vref_ch
------------------ = K1
Vsample_ch

I will use this K1 for every measure coming from ch1 to calibrate it.

• Temp calibration
(Although I used a constant current driver for the LEDs, by temp and other affects the light power changes, in order to compensate this there is another IR line just near the pipe but without transferring any IR light only empty air is between the LED and the PD. When the other IR lines on the pipe will be sampled, this AIR line is also sampled and the reading is used to calibrate these differences that LEDs creates)

Like the ch calibration the AIR ch reading at the beginning is taken as a constant and on every sample the new AIR ch reading is used to calibrate the liquid IR ch readings:

Vref_air (constant taken at start)
------------------------------------------- = Ka
Vsample_air

I will also use this Ka for every measure coming from both ch0 and ch1 to calibrate them.

• Beer-lambert law
When the pipe is empty, because of the plastic, air etc. the reading is not 0, it is again an attenuation value. Also when the pipe has some level of liquid this empty value should be subtracted. But because of some other factors which can’t be measured or calculated, you cannot directly subtract these values but according to beer-lambert you can use the ratio of the values to cancel these effects. So I read the EMPTY values of the ch0 and ch1, calibrate and store the value which is demoted Vempty. In order to calculate the height of the liquid also the FULL value should be read and stored. At the start I also coded a calibration part which you have to make the pipe FULL of the liquid you want to measure, which we can have the Vfull and save.
After these start routines with each sample read I have to calculate this formula : ( which I am not sure %100 )

Attenuation = A

Aempty - Asample
------------------------ = height of the L
Aempty - Afull


Attenuation = -log (Vinput / Vout)


log ( Vempty / Vsample )
--------------------------- * 100 = Height of L %
log ( Vempty / Vfull )
 

I fear you didn't manage to explain the basic measurement principle which you want to implement.

Part of your desription seems to refer to accidental variations of liquid transparency respectively turbidity. If so, there would be strict requirements for particle size, optical resolution, measurement speed etc. which aren't addresses at all. Also the relation to "spectrometer" respectively wavelength dispersive measurements isn't clear.

I know that similar measurement methods have been implemented with lasers. At present I can hardly imagine a solution with IR leds.
 

You can be right, subject is deep I tried to be brief.

Big picture is to measure the volume of the liquid while flowing, without any interfering parts inside but the liquid has variety size bubbles inside and since this solution will be used on many stations cost is very important, cant use professional industrial measurement devices. Only positive point is that the liquid is same but the concentration is changing.

Your right about the spectrometer subject, I tried only to refer to the subject because I believed this is where the basics are coming from, of course there is no wavelength matching in this project. Here is a circuit explaining what i mean : ( but trying to measure non-flowing liquid first, this is only useful then )

https://www.analog.com/en/circuits-from-the-lab/cn0312/vc.html
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top