Thursday, February 16, 2012

Making a Customized Water Level Controller Circuit

This customized ideal water level controller circuit idea was proposed and requested to me by Mr. Bilal Inamdar. The designed circuit is presented here in the article along with the required specs, in  details.
The circuit is exclusively designed and drawn by me.

Here goes the request:

Sorry for mistakes but writing from iPhone so bear in mind
Here is paste from notes 
The perfect automatic water level controller & amp; indicator.

Imp note- English is not my native language so errors are expected. I m using a iPhone to post this note so please bear with me. You can add or delete or modify anything from this note as per you need.

Need of the circuit - Well simply I want add a acrylic sheet bellow my tank which will contain tube lights. In short acrylic ceiling. The tank level can't be observed because of the sheet. This is Also needed for terrace tank 1500 Ltrs to observe level indoors without going outside.

How it will help - It will help in many scenarios like to observe terrace tank level, to observe and operate overhead tank level and to observe underground tank water level and operate the motor. Also it will save precious water from wasting due to overflow (go green). And release the tension caused due to human error ( forgetting to turn the pump on &filling the water also turn off the motor)

Application area :-
Overhead tank
Size - height = 12" width = 36" length = 45"
the tank is used for drinking, washing & bath.
The tank is 7 foot above the flooring.
The tank is kept in the bathroom.
Material of the tank is plastic (or PVC or fiber whatever non conductive)
The tank have three connection
Inlet 1/2", outlet 1/2" and whirlpool (overflow) 1".
The water fills from inlet. The water comes from outlet for use. The overflow connection prevent water overflowing on the tank and channelized it to drainage.
The hole of outlet is lower and the overflow and inlet is higher on the tank (ref height)

Scenario :-
The tank probes and level
|_A probe (overflow)
|__ok level
|_D probe (Medium)
|__low level 
|_B probe
|__verylow level
|_C common probe

As per the scenario I will now explain how the circuit should work

Circuit notes:-
1) Input of the circuit 6v AC/DC (for backup) to 12 AC/DC (for backup)
2) The circuit should mainly work on AC ( my mains is 220-240vac) with use of transformer or adaptor this will avoid probe rusting which occurs due to positive negative stuff. 
3) The dc will drives from 9v battery easily available  or from aa or aaa battery.
4) We have lots of power cut so please consider backup dc solution.
5) the probe used are aluminum wire 6mm. 
6) The resistance of water changes as per location so the circuit must be universal. 
7) There must be a sound which is musical as well as different for very high and very low. It can go bad so ext sound is preferable. A buzzer is not suitable for big room 2000 sqft. 
8) The reset switch must be a normal door bell switch which can be put in existing electric board.
9) There must be atleast 6 led 
Very high, very low, ok, low, mid, motor on/off. The mid must be considered for future expansions.
10) The circuit should indicate led of light gone when there is no AC current.
And switch to dc back. or add two led for indication On AC and On battery.

Circuit functions.
1) Probe B - if the water goes below this a indication led of very low must glow. The motor should start. The alarm should sound. The sound must be unique for very low level.
2) if the reset switch is pressed than the sound must go off everything else remains the same ( circuit armed, led glowing, motor)
3) if the water touch probe B the sound must be killed automatically. The very low indication led turn off the Low indication led turn on nothing else
4) Probe D - if the water touch probe The low indictor turn off. The ok level led turns on
5) Probe A - if the water touches this probe the than
The motor turns off
The ok level led goes off and the very high level led glows. 
The bell/ speaker turns on with different tune for very high. Also if the reset button is pressed in this case than also there must be no other effect rather than killing the sound.

Last but not least the circuit diagram should be expandable to E,F,G etc for very big tank (like mine on terrace)

One more thing I m not able to know how the mid level should be indicated.
Too tired to write more sorry.

my name is Bilal Inamdar
Name of the project (just a suggestion) Perfect Water Tank level automation or perfect tank water level controller.

Parts List for the above customized water level controller diagram:

R1 = 10K,
R2 = 10M,
R3 = 10M,
R4 = 1K,
T1 = BC557,
Diode = 1N4148
Relay = 12 volt, contacts as per pump current rating.
All Nand gates are from IC 4093




Circuit functioning of the above configuration

Assuming the water level to be at point A, the positive potential from point "C" in the tank reaches the input of N1 through water, making the output of N2 go high. This triggers N3, N4, transistor/relay and horn#2.
As the water comes down, below point "A" the gates N3, N4 maintain the situation due to the latching action (feedback from its output to input).
Therefore horn#2 remains switched ON.
However if the upper reset switch is pressed, the latch is reversed and maitained to negative, switching OFF the horn.
In the meantime, since point "B" is also at positive potential, keeps the output of the middle single gate low, keeping the relevant transistor/relay and horn#1  switched OFF.
The output of the lower two gates is high but has no effect on the transistor/relay and horn#1 because of the diode at the base of the transistor.
Now suppose, the level of the water falls below point "B", the positive from point"C" is inhibited and this point now goes logic low via the 10M resistor (correction required in the diagram which is showing 1M).
The output of the middle single gate immediately becomes high and switches ON the transistor/relay and horn#1.
This situation is maintained as long as the water level is below point B.
However horn#1 can be switched OFF by pressing the lower PB, which reverts the latch made from the lower couple of gates N5, N6. The output of the lower two gates becomes low, pulling the base of the transistor to ground via the diode.
The transistor relay switches OFF and hence horn#1.
The situation is maintained until the water level again rises above point B.

Parts List for the above circuit is given in the diagram.




Circuit functioning of the above configuration

Assuming the water level to be at point A, the following things can be observed:
The relevant input pins of the gates are at high logic due to the positive from point "C" coming via the water.
This produces a logic low at the output of the upper right gate, which in turn makes the output of the upper left gate high, switching ON the LED (bright glow, showing the tank is full)
The input pins of the lower right gate is also high, which makes its output low and therefore the LED marked LOW is switched OFF.
However this would have made the lower left gate output high, switching ON the LED marked OK, but due to the diode 1N4148 it keeps its output low so that the "OK" LED remains OFF.
Now suppose the water level falls below point A, the upper two gates reverts their position switching OFF the LED marked HIGH.
No voltage flows through 1N4148 and so the lower left gate switches ON the LED marked "OK"
As the water falls below the point D, the OK LED still glows because the lower right gate still remains unaffected and continues with a low output.
However the moment water level goes below point B, the lower right gate reverts its output because now both its inputs are at logic low.
This switches ON the LED marked LOW and switches OFF the LED marked OK.

Parts List for the above circuit is given in the diagram


IC 4093 PIN-OUT Diagram


Note:
Please remember to ground the input pin of the remaining three gates which are not used.

In all three ICs would be required constituting 16 gates, only 13 will be used and 3 will remain unused, the above precaution must be followed with these unused gates.

All the relevant sensor points coming out from different circuits must be joined together and terminated to the appropriate tank sensor points.

46 comments:

  1. I tried your circuit on bread board but it seems there are some errors

    First good news
    1) the probe C B and D work as specified
    2) the horn 1 work fine test on led in place of buzzer (very low level)
    3) The low level and ok led work down

    Issues
    1) the probe A have errors
    High LED always on
    Horn 2 (tested with led 3mm and R330) always on
    If reset button (push button) is preset the horn 2 goes of led remains as it is
    If probe A enter water nothing happen

    2) The reset switch doesn't work as stated by me. When the button is pressed and released the horn must go off completely until the level reach again
    A)If level A is met horn sound
    B) if reset button is pressed the horn 2 must go off until 5 min or so until the condition is met

    3) the horn 1 have no effect of the PB but the horn 1 is working fien also the led too ( low level)

    Thank you for considering my request I m glad we met. Please take some time to resolve it. I m really waiting to see this work only overflow, horn and reset switch issue ( also high level led)
    2)

    ReplyDelete
    Replies
    1. I've updated the article with explanations, kindly read and understand the functioning.
      The circuit will function exactly as explained and cannot go wrong.

      Delete
    2. Check using a multimeter whether the positive from point C placed at the bottom of the tank is reaching the surface of the water or not, when the tank is full.
      If the positive from point C is unable to pass through all water levels, the circuit may not work.

      Delete
    3. Want to Ask if sensor b have two resistor going to ground ? 1m and 10m as per diagram 2 and 3

      Delete
  2. Okay I will try and report after 2 -3 hr

    ReplyDelete
  3. Is there two resistor on sensor b line ? ( 10m and 1m to ground ) diagram 2 and 3 reference

    ReplyDelete
    Replies
    1. No need, you may use a single resistor in common for all point Bs.

      Delete
  4. I chAnged all the resistor as sAid but the all the problem remains as it is

    ReplyDelete
    Replies
    1. I have changed the water alarm diagram, now it should surely work.

      Delete
  5. Oh man it took me 4 hr to assemble on bread board
    Now I will remove everything and retry from scratch, please please please next time if u change the fig do inform like this ( fig 2 changed replaced resistor and removed etc ) please. I m not a pro but I have a true interest in this. So please don't make fall after so much of your and mien effort. I will report back after 6-8 hr abt the circuit.

    ReplyDelete
    Replies
    1. It took me 2 days of brain storming to design this, but I am not complaining....do it for fun only, don't take it seriously.

      And I'm not getting anything from this it's just what we call in hindi "janta seva"

      means social service.

      OK:-)

      Delete
  6. lol I know I know I doesn't mean to offend you. I was showing my issue of less time and more error rectification.
    I will report abt the circuit later thank you sorry today I could not make it.

    ReplyDelete
  7. HI SWAGATHAM,
    I AM NOT CLEAR IN THE SECOND CIRCUT DIAGRAM,THIS SHOWS N5,N6,N7 ETC. BUT IN IC 4093 HAVING 4 GATES,CAN YOU EXPLAIN PLS. WITH PIN NUMBER.

    ReplyDelete
    Replies
    1. Hi Sharaf,

      To make this circuit you will require many 4093 ICs, and use their gates as per your convenience.
      All gates are identical so you may set them as you want.

      Delete
    2. Now I am cleared the doubt
      Thanks a lot for your prompt replay.
      I really appreciate your support and magnanimity to share your ideas to others.

      Delete
  8. Hi,

    I am a silent viewer for past one year.It is really appreciable to see the circuits publishing monthly and yearly basis and your quick response for every one questions.

    Now i have a question, i need a watel level controller circuit which operates in 6v and if the water tank is full it has to beep an peizo alarm and after few seconds automatically motor should shut off.

    Already I have designed an water level indicator in my home which has an alarm if the water tank is full and it doesnt have motor shut off option after few seconds.

    Can you please help me out.

    ReplyDelete
    Replies
    1. Thanks!

      you may connect a relay driver stage with your indicator output for shutting of the motor, please check this circuit:

      http://homemadecircuitsandschematics.blogspot.in/2012/01/circuit-provided-in-this-article.html

      Delete
    2. Thanks...I have one more problem facing nowadays

      In our apartments i am using a water level indicator which is working fine, if the tank is full it will give an alarm only.Now i am facing problem in our motor,if some one switches off the motor and if they forget to switch off after 45 minutes the motor is stopped automatically due to coil heat and we are not aware since we are staying in other floor and motor is simply on and some one can switch off only if they notice the motor is not working.Is it possible to design a circuit which will switch off the motor after 45 minutes at the same time it has to provide an alarm if the tank is full.
      Can you please suggest how this can be done?

      Delete
    3. I think the following circuit will suit you better:

      http://homemadecircuitsandschematics.blogspot.in/2012/10/making-multi-function-water-level.html

      Delete
  9. Hello Swagatham,
    m appriciate ur innovative ideas... I used ur kit and it works. So my related question is can we do a software for pc or android cell phones? So it can be measure actual water or any liquid quantity and can be controlled through far or remote distance.
    Waiting ur reply...
    Regards,

    Salil Dev.

    ReplyDelete
    Replies
    1. Hello Salil,

      Thanks!

      I don't have much knowledge regarding softwares so it would be difficult for me to go ahead with such projects. However I have published a simple cell phone controlled remote switch which might fulfill your application. here's the link:

      http://homemadecircuitsandschematics.blogspot.in/2012/01/how-to-build-gsm-based-cell-phone.html

      Regards.

      Delete
  10. hi sir swagatam,

    im confused with the relay driver using pnp transistor bc557..
    im using a 12v relay with a resistance of 113 ohms.. i want the relay turn-on when the sensing voltage is zero then if the sense voltage is 5vdc the relay should be turn-off..

    i follow your advise with this but the relay behaved just like an npn driver. meaning if 5vdc is present, the relay is on and when 0 volts, the relay is off also..
    **********************
    You would either require one more transistor to revert the actions or simply replace the NPN transistor in the circuit with a PNP one.
    Use a BC557 in place of the exixting 2N3904 transistor and do the connections exactly as suggested below:
    Keep the 2.2K resistor as it is.
    Remove the 4.7K resistor, it's not required.
    Connect the emitter of the transistor to the POSITIVE of the battery.
    Connect the relay coil across the collector of the transistor and NEGATIVE of the battery.
    CONNECT A DIODE ACROSS THE RELAY COIL, WITH ITS CATHODE CONNECTED TO THE COLLECTOR AND ANODE TO THE GROUND. The diode protects the transistor from the generated back emfs from the relay coil.
    The other diode is not required.
    Connect the battery negative with the ground of the circuit.
    Now as long as a POSITIVE (from the power supply) is applied directly across the base of the transistor and ground, the transistor remains shut off, the moment the POSITIVE supply is removed the transistor gets biased through the 2.2K resistor and activates the relay.***********

    ReplyDelete
    Replies
    1. Hi Unknown,

      Are you using 5v supply for the IC?

      Use a common 12V for the IC and the relay, this will solve the problem.

      If you want the circuit to have a regulated supply, use a 7812 for the entire circuit..not 7805.

      Delete
  11. Hi Friends
    I m not Engineer but want to Learn this..
    How can I make this Auto controller ?
    Please help me
    is it possible for me ?
    please give support
    mukeshtiwari.baroli@gmail.com
    09694157517

    ReplyDelete
  12. Could you please explain more about the sensing probes. Months back i have done a similar project using IC 4049. It was working fine but the problem was with the water sensor & its connections. I used Brass bolts as a sensor. After a few weeks brass bolts started corrosion. This made severe problem with the controller & one night overhead Tank was over flooded & water in ground tank went empty finally damaged the Pump.
    Is there any other replacement for the metallic sensor?

    More over immersing a metallic bolt under water with electric energy will lead to corrosion similar to Galvanic corrosion which will affect the water quality.

    ReplyDelete
    Replies
    1. Try tinning the probes with solder...tin them heavily with solder, tin coating would be unaffected from corrosion.

      Delete
    2. Thanks Sir
      I will try this, mean while i would like to know some other method. Sir could you help me with some thing similar to IR sensing or LDR.

      Delete
    3. I'll try to figure out a suitable circuit and post it.

      Delete
    4. Thankyou sir for your supports, waiting for new circuit

      Delete
  13. how can this work when there is no pull up resistor on the inputs! once the inputs are triggered low due to resistance of the water , it will stay low

    ReplyDelete
    Replies
    1. In the first circuit the inputs are triggered high through the water, not low, because the positive terminal is inserted in the water.

      Delete
  14. Hai swagatam,
    How to add a manual on and manual off switch in this circuit??

    ReplyDelete
    Replies
    1. Hi Sriram,
      connect an SPST switch in series with the relay coil ground line.
      This could be used for toggling the relay OFF anytime.
      put another spst switch across transistor base and ground via a 10k resistor, this could be used to switch ON the relay anytime (but for this the first switch should be ON)

      Delete
  15. Is that necessary to use 12v 400 ohms relay??? Bcoz when I measured the coil of my 12v relay, its showing 178 ohms only...

    ReplyDelete
    Replies
    1. 178 ohms will also do, the driver transistor will dissipate a little more current, that's all...

      Delete
  16. your circuit and blogs are great...your are doin a great work.. :)
    i had set up your circuit and it works perfectly fine when i touch sensor a and sensor b wires together
    but it does not work through water
    i checked the conductivity of water through a battery and led set up and it conducts
    i used a 12V 1A adapter to obtain dc from ac..... dnt know what to do
    pls help me make the circuit working

    ReplyDelete
    Replies
    1. Thanks!
      Did you connect the "C" terminal with positive? this terminal should also go inside the water... also make sure the wires are properly uninsulated from their covers or coatings and cleaned thoroughly.

      Delete
  17. If I want to connect two 12v relay at single transistor means what value transistor I can use instead of BC557??

    ReplyDelete
  18. Hai,
    If the water level reaches the low level means the relay should activate after 5 seconds only. wat i have to do for that?? pls help..

    ReplyDelete
    Replies
    1. hi, connect a diode in between R4 and gateN4 output (anode to R4) and connect a 10uF capacitor across diode anode and positive supply.....

      Delete
    2. Thanks. Can I use 1N4007 diode for that??

      Delete
    3. yes, 1N4007 will do, also increase R4 to 10K.

      Delete
    4. I think the above set up will produce opposite results...do it in the following way:

      connect the diode and the capacitor in series between the base of the transistor and positive supply. anode to positive, cathode to cap positive, cap negative to transistor base
      also connect a 1M resistor parallel to the cap so that it can discharge afterwards.

      Delete
    5. Thanks... I sketched as u said.. check whether the diagram is correct.
      http://imgur.com/XDzARca
      So this will make a relay activate after 5 seconds when the water level reaches below the low level sensor. Am I correct??

      Delete
    6. it's correct but the 1K or the 10uF or both values will need to be increased for achieving 5 seconds, the present values will not produce more than 1/2 second delay...

      Delete

Readers are requested not to include external links while commenting. For consulting a diagram, upload it on Google Drive and provide the link here.


Readers are advised to proceed with the construction of the presented circuits only after understanding the concepts from the core. Not adhering to this can lead to failures and frustrations.