Monday, 23 April 2018

Hello guys welcome to my page in this we learn how to make arduino piano. Materials needed
Siren
Aurdino
Connecting wires
Keypad

#define c2 8
#define c1 7
#define c0 6
#define r3 5
#define r2 4
#define r1 3
#define r0 2

void setup() {
Serial.begin(9600);
pinMode(c0,INPUT_PULLUP); 
pinMode(c1,INPUT_PULLUP);
pinMode(c2,INPUT_PULLUP);
pinMode(c3,INPUT_PULLUP);
pinMode(r0,OUTPUT);
pinMode(r1,OUTPUT);
pinMode(r2,OUTPUT);
pinMode(r3,OUTPUT);
pinMode(11,OUTPUT);
}

void loop()
{digitalWrite(r0,LOW);
digitalWrite(r1,HIGH);
digitalWrite(r2,HIGH);
digitalWrite(r3,HIGH);
if(digitalRead(c0)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=119;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c1)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=106;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c2)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=94;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c3)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=89;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}

digitalWrite(r0,HIGH);
digitalWrite(r1,LOW);
digitalWrite(r2,HIGH);
digitalWrite(r3,HIGH);
if(digitalRead(c0)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=79;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c1)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=71;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c2)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=63;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c3)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=59;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}

digitalWrite(r0,HIGH);
digitalWrite(r1,HIGH);
digitalWrite(r2,LOW);
digitalWrite(r3,HIGH);
if(digitalRead(c0)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=25;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c1)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=20;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if (digitalRead(c2)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=10;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c3)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=50;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}

digitalWrite(r0,HIGH);
digitalWrite(r1,HIGH);
digitalWrite(r2,HIGH);
digitalWrite(r3,LOW);
if(digitalRead(c0)==LOW){

TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=50;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c1)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=50;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c2)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=50;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
else if(digitalRead(c3)==LOW){
TCCR2A = B01000011;
TCCR2B = B00001110;
OCR2A=50;
delay(100);
TCCR2B=B00001000;
TCCR2A = B00000000;
digitalWrite(11,LOW);}
}

Thursday, 19 April 2018

HOW TO MAKE LINE FOLLOWING ROBOT
It is a machine that follows a line, either a black line on white surface or vise-versa. For Beginners it is usually their first robot to play with. In the following steps you will completely understand the concept of line follower.
Now we are going to build a line follower which will follow black line on a white surface, we will be using two IR sensor pair which will have an IR LED and Photo diode.
WORKING OF IR SENSOR:
Generally IR rays will be reflected by white surface while black surface will absorb IR rays.In the line follower that we are going to build, both the IR sensors will be on the white surface . IR rays will be emitted and reflected back which will be detected by the Photo diode, in this state the IR sensor will send a HIGH digital signal ("1"). similarly when the sensor is on a black surface IR rays will be emitted and will not be reflected back which will be absorbed by the black surface, in this state the IR sensor will send LOW digital signal ("0"). Thus with these digital values 1 and 0 we can easily identify the state of the sensors.

Component required 

1) IC7805 Voltage Regulator - 1
2) L293D Motor Driver - 1
3) IR LED pair - 2
4) 300-500rpm DC Motor - 2
5) Battery 9v-12v - 1
6) Breadboard - 1
7) Chasis - 1
8) Castor wheel - 1
9) Wheels - 2
Give the connections as per the circuit given and place the whole setup on the chasis.
L293D:
The digital signal given to the INPUT 1,2,3 and 4 of L293D will be thrown back to the OUTPUT 1,2,3 and 4 respectively. The INPUT 2 and 3 of L293D is connected to ground which is LOW("0") and the signal from the IR sensors are connected to INPUT 1 and 4. Hence the value of OUTPUT 2 and 3 will be constantly LOW("0") while the value of OUTPUT 1 and 4 will be HIGH("1") when the IR sensor is on the white surface and will be LOW("0") when the sensor is on black surface.
that's it, now you can enjoy your own simple Line follower robot
If u have any doubts feel free to ask 

Wednesday, 18 April 2018

How to make bluBluetoo control home automation
Materials needed
Hc-05 module
Aurdino
Breadboard
Really and etc

Hello gyz in this tutorial i will show how to control home automation using
ARDUINO
RELLAY
BLUETOOTH MODUEL
In this tutorial i will show
- how to connect bluetooth moduel
- how to connect rellay to arduino and 220v ac And how to put them all together.
It is really easy to do the connection and please take care while handling 220v ac.
In the same way you can control your home automation's very easily
Connections
Rx to 3 
Tx to 2
In to 4


Android app

Coding
http://www.mediafire.com/file/01mhq2j8cuqc7n7/RELAY.ino
For 

Thursday, 12 April 2018

Bluetooth controlled car



Hello guys welcome my channel in this vedios we try to make Bluetooth controlled car

Required Components:

Arduino Uno 
Bluetooth Module
L293D Motor Driver
2x Gear Motor
2x Wheel
1x Chasis
A breadboard 
Connecting wires
   Reading of motor:
Programming
________________________________________________________________________________

#include <SoftwareSerial.h>

SoftwareSerial BT(10, 11); //TX, RX respetively
String readdata;

void setup() {
 BT.begin(9600);
 Serial.begin(9600);
  pinMode(3, OUTPUT);
  pinMode(4, OUTPUT);
  pinMode(5, OUTPUT);
  pinMode(6, OUTPUT);

}
//-----------------------------------------------------------------------// 
void loop() {
  while (BT.available()){  //Check if there is an available byte to read
  delay(10); //Delay added to make thing stable
  char c = BT.read(); //Conduct a serial read
  readdata += c; //build the string- "forward", "reverse", "left" and "right"
  } 
  if (readdata.length() > 0) {
    Serial.println(readdata);

  if(readdata == "forward")
  {
    digitalWrite(3, HIGH);
    digitalWrite (4, HIGH);
    digitalWrite(5,LOW);
    digitalWrite(6,LOW);
    delay(100);
  }

  else if(readdata == "reverse")
  {
    digitalWrite(3, LOW);
    digitalWrite(4, LOW);
    digitalWrite(5, HIGH);
    digitalWrite(6,HIGH);
    delay(100);
  }

  else if (readdata == "right")
  {
    digitalWrite (3,HIGH);
    digitalWrite (4,LOW);
    digitalWrite (5,LOW);
    digitalWrite (6,LOW);
    delay (100);
   
  }

 else if ( readdata == "left")
 {
   digitalWrite (3, LOW);
   digitalWrite (4, HIGH);
   digitalWrite (5, LOW);
   digitalWrite (6, LOW);
   delay (100);
 }

 else if (readdata == "stop")
 {
   digitalWrite (3, LOW);
   digitalWrite (4, LOW);
   digitalWrite (5, LOW);
   digitalWrite (6, LOW);
   delay (100);
 }

  


readdata="";}} //Reset the variable
Download Android App from here:Android App