Water Flow Sensor

Sensors play a very crucial role in today’s automatic systems. Being a small, low cost and reliable device, sensors are easy to embed with larger electronics. Today we can find various types of sensors in the market. With the advance in technology, sensors are also evolved in their functioning and size. From the early size of cm units, size of sensors has shrunk to the scale of nm. Sensors have also solved many challenges of electronic and electrical engineering such as finding the intensity of ambient light, determining the temperature in the furnace, calculating humidity of surrounding, etc…. Water flow sensor gives an amazing solution for measuring the flow rate of liquids.

 

 

What is Water Flow Sensor?

Huge industrial plants, commercial and residential buildings require a large amount of water supply. The public water supply system is used to meet this requirement. To monitor the amount of water being supplied and used, the rate of flow of water has to be measured. Water flow sensors are used for this purpose.

Working Principle

Water flow sensor consists of a plastic valve from which water can pass. A water rotor along with a Hall Effect sensor is present the sense and measure the water flow.

When water flows through the valve it rotates the rotor. By this, the change can be observed in the speed of the motor. This change is calculated as output as a pulse signal by the Hall Effect sensor. Thus, the rate of flow of water can be measured.

The main working principle behind the working of this sensor is the Hall Effect. According to this principle, in this sensor, a voltage difference is induced in the conductor due to the rotation of the rotor. This induced voltage difference is transverse to the electric current. When the moving fan is rotated due to the flow of water, it rotates the rotor which induces the voltage. This induced voltage is measured by the Hall Effect sensor and displayed on the LCD display.

Features

  • Compact, Easy to Install
  • High Sealing Performance
  • High Quality Hall Effect Sensor


Specifications

  • Working Voltage: DC 4.5V
  • Working Current: 15mA (DC 5V)
  • Working Voltage: DC 5V~24V
  • Flow Rate Range: 1~30L/min
  • Load Capacity: ?10mA (DC 5V)
  • Operating Temperature: 80?
  • Liquid Temperature: 120?
  • Operating Humidity: 35%~90%RH
  • Water Pressure: ?1.75MPa
  • Storage Temperature: -25~+ 80?
  • Storage Humidity: 25%~95%RH

 

Interfacing with Arduino

Code:

byte statusLed    = 13;

byte sensorInterrupt = 0; 

byte sensorPin       = 2;

float calibrationFactor = 4.5;

volatile byte pulseCount; 

float flowRate;

unsigned int flowMilliLitres;

unsigned long totalMilliLitres;

unsigned long oldTime;

void setup()

{  Serial.begin(9600);

pinMode(statusLed, OUTPUT);

  digitalWrite(statusLed, HIGH);  // We have an active-low LED attached

  pinMode(sensorPin, INPUT);

  digitalWrite(sensorPin, HIGH);

  pulseCount        = 0;

  flowRate          = 0.0;

  flowMilliLitres   = 0;

  totalMilliLitres  = 0;

  oldTime           = 0;

  attachInterrupt(sensorInterrupt, pulseCounter, FALLING);

}

void loop()

{

      if((millis() – oldTime) > 1000)    // Only process counters once per second

  {

    detachInterrupt(sensorInterrupt);

flowRate = ((1000.0 / (millis() – oldTime)) * pulseCount) / calibrationFactor;

  oldTime = millis();

      flowMilliLitres = (flowRate / 60) * 1000;

   totalMilliLitres += flowMilliLitres;

    unsigned int frac;

   Serial.print(“Flow rate: “);

    Serial.print(int(flowRate));  // Print the integer part of the variable

    Serial.print(“L/min”);

    Serial.print(“\t”);

 Serial.print(“Output Liquid Quantity: “);       

    Serial.print(totalMilliLitres);

    Serial.println(“mL”);

    Serial.print(“\t”);                 // Print tab spac

          Serial.print(totalMilliLitres/1000);

          Serial.print(“L”);

pulseCount = 0;   

attachInterrupt(sensorInterrupt, pulseCounter, FALLING);

  }

}

void pulseCounter()

Advantages:

  • Unobstructed flow
  • No moving parts.
  • No additional pressure drop.
  • Favorable choice of materials for chemically aggressive liquids.
  • Linear relationship between flowrate and measured variable.
  • Low maintenance.
  • Operates in both flowdirections (forward and reverse)

 

 

Disadvantages:

  • For liquids only
  • Lower conductivity limit 0.05 μS/cm
  • Gas inclusions cause error

Reference:

https://www.electroschematics.com/working-with-water-flow-sensors-arduino/

https://automationforum.co/advantages-and-disadvantages-of-flowmeters/

https://maker.pro/arduino/tutorial/how-to-interface-arduino-with-flow-rate-sensor-to-measure-liquid

https://create.arduino.cc/projecthub/rayatedarshan/water-flow-sensor-measure-on-16×2-lcd-display-7f3ee2

WhatsApp us whatsapp