loading

IR Remote Control for 12 home appliancescan be easilly made using a TSOP 1738 IR receiver, some 5V relay and a Arduino Board.

By using this circuit you can easily control your home applinces using your TV, DVD Player remote control.

Step 1: To Get Remote Control Switches Codes

Just make the connection as it is shown in above pictures. and upload the arduino code. and when you press any button then in serial monitor window you can see the HAX value and a number value. you can either choose HAX value for you next procedure or the number value.

Step 2: Code to Get HAX/number Value

#include<IRremote.h>

int RECV_PIN = 11;

IRrecv irrecv(RECV_PIN);

decode_results results;

void setup()

{

Serial.begin(9600);

irrecv.enableIRIn(); // Start the receiver

}

void loop() {

if (irrecv.decode(&results))

{

unsigned int value = results.value;

Serial.println(value);

Serial.println(results.value, HEX);

delay(250);

irrecv.resume(); // Receive the next value

}

}

Step 3: Try With Some LED's First

Now you are ready with your codes/values. now select your those key/ switches in remote which is not currently in use. Take the values of those keys and according to your preference put it in next coming code at the place of mine. and upload the code to arduino.

First you try with 3 LED's and check is it working properly
or not. If it is working then go with the next pictures.

Step 4: Code for LED's

#include

int RECV_PIN = 11; // the pin where you connect the output pin of TSOP4838

int led1 = 2;

int led2 = 5;

int led3 = 8;

int itsONled[] = {0,0,0,0};

/* the initial state of LEDs is OFF (zero)

the first zero must remain zero but you can

change the others to 1's if you want a certain

led to light when the board is powered */

#define code1 32895 // code received from button A

#define code2 16575 // code received from button B

IRrecv irrecv(RECV_PIN);

decode_results results;

void setup()

{

Serial.begin(9600); // you can comment this line

irrecv.enableIRIn(); // Start the receiver

pinMode(led1, OUTPUT);

pinMode(led2, OUTPUT);

pinMode(led3, OUTPUT);

}

void loop() {

if (irrecv.decode(&results)) {

unsigned int value = results.value;

switch(value) {

case code1:

if(itsONled[1] == 1) { // if first led is on then

digitalWrite(led1, LOW); // turn it off when button is pressed

itsONled[1] = 0; // and set its state as off

} else { // else if first led is off

digitalWrite(led1, HIGH); // turn it on when the button is pressed

itsONled[1] = 1; // and set its state as on

}

break;

case code2:

if(itsONled[2] == 1) {

digitalWrite(led2, LOW);

itsONled[2] = 0;

} else {

digitalWrite(led2, HIGH);

itsONled[2] = 1;

}

break;

default :

if(itsONled[3] == 1) {

digitalWrite(led3, LOW);

itsONled[3] = 0;

} else {

digitalWrite(led3, HIGH);

itsONled[3] = 1;

}

break;

}

Serial.println(value); // you can comment this line

delay(250);

irrecv.resume(); // Receive the next value

}

}

Step 5: LAST PART

If you are successful in LED's part then you are ready for applying on your home appliances.

Here i have selected only two home appliances and a LED for ERROR showing.

we don't need to change the code for the relay part

THINGS NEEDED TO MAKE THIS PROJECT:-

1. Arduino board

2. 5V Relays as much you need

3. IN4007 Diode in number of Relays

4. TSOP 1738 IR Receiver

5. 1 LED or 1 Buzzer with 100Ohm resistor

I will upload my working project in some days as I'm working on PCB Layout. I made this project but it is too messy.

<p>This is a very cheap Project. You can make it.</p>
<p>This is great</p>
<p>thanks buddy.. hope you made it..</p>

About This Instructable

20,956views

36favorites

License:

Bio: I have some interest in electronic. you can find me at https://www.facebook.com/theTechWorks
More by Sandy65:How to Make Mobile Phone Wall Charging Holder How to Make Your Own Homemade Arduino Uno R3 How to Make Relay Circuit Board For Arduino 
Add instructable to: