Wet & Dry Waste Smart Dustbin for House | Best science Project | Harish Projects

Image
 Watch Full Detailed video 👇🏻 Diagram in Video👆 //Arduino Code// //YouTube: Harish Projects //Order Electronic Parts & Project kit:  HarishProjects.com // #include <Servo.h> Servo servo1; const int trigPin = 12; const int echoPin = 11; long duration; int distance=0; int potPin = A0; //input pin int soil=0; int fsoil; void setup()  {   Serial.begin(9600); //Serial.print("Humidity"); pinMode(trigPin, OUTPUT);  pinMode(echoPin, INPUT);  servo1.attach(8); } void loop()  { //YouTube: Harish Projects //Order Electronic Parts & Project kit:  HarishProjects.com //      int soil=0;   for(int i=0;i<2;i++)   { digitalWrite(trigPin, LOW); delayMicroseconds(7); digitalWrite(trigPin, HIGH); delayMicroseconds(10); digitalWrite(trigPin, LOW); delayMicroseconds(10); duration = pulseIn(echoPin, HIGH); distance= duration*0.034/2+distance; delay(10);   }   distance=distance/2;   Serial.println(distance); if ...

How to make Phone control RC car using Arduino #phoneControlCar

                                    https://www.youtube.com/watch?v=EYlIB1PQ8R0&t=131s




                                                   ......................ARDUINO CODE.................


char  t;
 
void setup() {
pinMode(13,OUTPUT);   //left motors forward
pinMode(12,OUTPUT);   //left motors reverse
pinMode(11,OUTPUT);   //right motors forward
pinMode(10,OUTPUT);   //right motors reverse
pinMode(9,OUTPUT);   //Led
Serial.begin(9600);
 
}
 
void loop() {
if(Serial.available()){
  t = Serial.read();
  Serial.println(t);
}
 
if(t == 'F'){            //move forward(all motors rotate in forward direction)
  digitalWrite(13,HIGH);
  digitalWrite(11,HIGH);
}
 
else if(t == 'B'){      //move reverse (all motors rotate in reverse direction)
  digitalWrite(12,HIGH);
  digitalWrite(10,HIGH);
}
 
else if(t == 'L'){      //turn right (left side motors rotate in forward direction, right side motors doesn't rotate)
  digitalWrite(11,HIGH);
}
 
else if(t == 'R'){      //turn left (right side motors rotate in forward direction, left side motors doesn't rotate)
  digitalWrite(13,HIGH);
}

else if(t == 'W'){    //turn led on or off)
  digitalWrite(9,HIGH);
}
else if(t == 'w'){
  digitalWrite(9,LOW);
}
 
else if(t == 'S'){      //STOP (all motors stop)
  digitalWrite(13,LOW);
  digitalWrite(12,LOW);
  digitalWrite(11,LOW);
  digitalWrite(10,LOW);
}
delay(100);
}

Comments

Unknown said…
I am in great problem you helped in that thank you bhaiya
Ajay said…
How to pair hc5 with phone&app name please
Unknown said…
I'm unable to find circuit drawing of river cleaner boat.
User said…
I can't find the code for river cleaning boat
sachin said…
I want purchase
Give u r number
lufi said…
Hi bhai,
I copy and paste but the tools is hide the port what i can do next step? pls guide me thanks.asap
luffy-san said…
bhaiya i am not getting the appliction of the app jrobot aurdino rc control.....plz help me
luffy-san said…
char t;

void setup() {
pinMode(13,OUTPUT); //left motors forward
pinMode(12,OUTPUT); //left motors reverse
pinMode(11,OUTPUT); //right motors forward
pinMode(10,OUTPUT); //right motors reverse
pinMode(9,OUTPUT); //Led
Serial.begin(9600);

}

void loop() {
if(Serial.available()){
t = Serial.read();
Serial.println(t);
}

if(t == 'F'){ //move forward(all motors rotate in forward direction)
digitalWrite(13,HIGH);
digitalWrite(11,HIGH);
}

else if(t == 'B'){ //move reverse (all motors rotate in reverse direction)
digitalWrite(12,HIGH);
digitalWrite(10,HIGH);
}

else if(t == 'L'){ //turn right (left side motors rotate in forward direction, right side motors doesn't rotate)
digitalWrite(11,HIGH);
}

else if(t == 'R'){ //turn left (right side motors rotate in forward direction, left side motors doesn't rotate)
digitalWrite(13,HIGH);
}

else if(t == 'W'){ //turn led on or off)
digitalWrite(9,HIGH);
}
else if(t == 'w'){
digitalWrite(9,LOW);
}

else if(t == 'S'){ //STOP (all motors stop)
digitalWrite(13,LOW);
digitalWrite(12,LOW);
digitalWrite(11,LOW);
digitalWrite(10,LOW);
}
delay(100);
}

Popular posts from this blog

Smart Bridge - Automatic Hight increase when flooding | Best science Project

Inspire Award Project | Train accident Prevention project | Best science Project / Harish Projects