Smart filtration system

WST007

Because you want to know how to survive in the wild, building a homemade water filtration system is a useful thing to do. But, to stop the overflow of the water when, use an automation system.

  1. Battery and Connector
  2. Arduino UNO
  3. Motor Driver IC
  4. Water Pump Module
  5. USB Cable
  6. Jumper Wires
  7. Water level sensor
  1. Connect the motor driver to the Arduino UNO board.
    Arduino UNO Motor Driver IC Pump
    Pin 8 In1  
    Pin 9 In2
    Pin 10 En1  
    5 v 5 v  
       A+ Red
      A-  Black
  2. Connect raindrop sensor to Arduino UNO
    Rain Drop Arduino UNO
    A0 A1
    VCC 5 v
    GND GND
  3. Upload the code in Arduino UNO.
  4. Fit the system to filter.
  5. Connect driver IC with battery. 

    int s=A1;
int in1=9;
int in2=8;
int en=10;
void setup() {
  // put your setup code here, to run once:
Serial.begin(9600);
pinMode(in1,OUTPUT);
pinMode(in2,OUTPUT);
pinMode(en,OUTPUT);
pinMode(s,INPUT);
}

void loop() {
  // put your main code here, to run repeatedly:
analogWrite(en,256);
if (analogRead(s)>100){
  digitalWrite(in1,0);
  digitalWrite(in2,0);
}else{
  digitalWrite(in1,1);
  digitalWrite(in2,0);
}
Serial.println(analogRead(s));
}