Engineers Garage

  • Projects and Tutorials
    • Circuit Design
    • Electronic Projects
      • 8051
      • Arduino
      • ARM
      • AVR
      • PIC
      • Raspberry pi
      • STM32
    • Tutorials
    • Components
  • Articles
    • EG Blogs
    • Insight
    • Invention Stories
    • How to
    • What Is
    • News
      • EE Design News
      • DIY Reviews
      • Guest Post
      • Sponsored Content
  • Forums
    • EDABoard.com
    • Electro-Tech-Online
    • EG Forum Archive
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • EE Resources
    • DesignFast
    • LEAP Awards
    • Oscilloscope Product Finder
    • Video
    • White Papers
    • Webinars
  • EE Learning Center
  • Women in Engineering

IR Remote Controlled Home Appliances Using Arduino

October 10, 2014 By Salman Khan

 

In present times there are many types of Home Automation Systems which are available in the market. Most of these are simple Home Appliances Controlling Systems like DTMF controlled Home Appliances, GSM based Home Appliances Controlling, RF based Home Appliances Controlling. Here we are going to discuss about TV or DVD Remote Control LED Home / Office Appliances Control (Home Automation System) using Arduino Board.

In this project, TSOP (IR Receiver) is connected with Arduino. Arduino receives encoded signal coming from IR Remote and then decodes by using IRremote.h library, which is easily available on internet (Find this library by typing on Google IR remote library for Arduino). After decoding the signal, compare decoded signal with defined value, if the match occurs then perform related function or switching on/off related relay by using digital input/output. Here AC load is used for demonstration. Three Home/Office Appliances are used for demonstration. In which one zero watt bulb indicated by light 1 and second is 100 watt bulb indicated by light 2 and third and last is TV/LCD indicated by TV.  LCD is also interfaced with arduino in this system for displaying the current status of Appliances like TV ON, TV OFF, light 1 ON, light 1 OFF, light 2 ON, light 2 OFF, ALL ON, ALL OFF etc.

 

Image showing IR Remote used for controlling Home Automation System

Fig. 1: Image showing IR Remote used for controlling Home Automation System

Prototype of Arduino based IR Remote controlled Home Automation System

Fig. 2: Prototype of Arduino based IR Remote controlled Home Automation System

Image showing switching a bulb on by IR Remote via Home Automation System

Fig. 3: Image showing switching a bulb on by IR Remote via Home Automation System

Image showing display panel in prototype of Arduino based Home Automation System

Fig. 4: Image showing display panel in prototype of Arduino based Home Automation System

Image showing Relay Circuit used in Arduino based Home Automation System

Fig. 5: Image showing Relay Circuit used in Arduino based Home Automation System

Image of Display Panel of Home Automation System showing switching status of a home appliance

Fig. 6: Image of Display Panel of Home Automation System showing switching status of a home appliance

Image of LED TV controlled by Arduino based Home Automation System

Fig. 7: Image of LED TV controlled by Arduino based Home Automation System

Image showing circuit connections of Arduino based Home Automation System with an LED TV

Fig. 8: Image showing circuit connections of Arduino based Home Automation System with an LED TV

 

Block Diagram

Block Diagram of Arduino based IR Remote controlled Home Automation System

Fig. 9: Block Diagram of Arduino based IR Remote controlled Home Automation System

Circuit Description

It is assumed that the reader has gone through the project how to get started with the arduino and done all the things discussed in it. Circuit of this system is very simple in this TSOP 1738 connected to digital pin 9 of Arduino, which detects 38 KHz IR frequency and relays are connected to digital pin 10, 11, 12 of Arduino for controlling light 1, light 2, TV respectively using ULN 2003 IC is a high-voltage high-current Darlington transistor arrays. Each consists of seven NPN Darlington pairs that feature high-voltage outputs with common-cathode clamp diodes for switching inductive loads and 5 volt relays are used here, which are best suitable for these types of Projects. Light 1 is connected with relay 1, light 2 is connected with relay 2 and TV is connected with relay 3.

Circuit Diagram of TSOP1738 based IR Receiver

Fig. 10: Circuit Diagram of TSOP1738 based IR Receiver

Relay Connection Circuit for DC supply (connect AC supply in place of battery and electrical appliances in place of LED polarity does not effects in AC.)

You can add more Home/Office Appliances with this system by adding some functions in the program. 16×2 LCD’s commands pins RS and EN is directly connected with pin 7 and 6 respectively and  Data pins d4, d5, d6, d7 are connected with 5, 4, 3, 2 pins of Arduino.

Working & Components Used

Working

1.      When we press key 1, this is responsible for tuning on TV/LCD and if we again press this, key is now responsible for tuning off TV.

2.      When we press key 2 this is responsible for tuning on light 1 and if we again press this key it is now light 1 tuned off.

3.      When we press key 3 this is responsible for tuning on light 2 and if we again press this key it is now light 2 tuned off.

Programming

Programming of this project is very easy. Initialize IR Remote library and LCD library. Then define some strings for match or compare. Store IR decoded result and compare this with defined strings. If any match occurs perform related function then enjoy it.

Components Used

1.      Arduino Pro Mini

2.      TSOP 1738

3.      Connecting wires

4.      Power supply

5.      AC appliances

6.      Resisters

7.     Capacitors

8.      IR remote

9.     Relays

10.  ULN2003

Project Source Code

###

#include<LiquidCrystal.h>
#include <IRremote.h>
int RECV_PIN = 9;          // Output pin of TSOP sensor
IRrecv irrecv(RECV_PIN);
decode_results results;

LiquidCrystal lcd(7,6,5,4,3,2);

#define light1 10
#define light2 11
#define TV 12

int temp=0,temp1;

void setup()
{
  lcd.begin(16,2);
  pinMode(light1,OUTPUT);
  pinMode(light2,OUTPUT);
  pinMode(TV,OUTPUT);
  pinMode(13,OUTPUT);
 
 
    lcd.setCursor(0,0);
  lcd.print("  Home/Office   ");
  lcd.setCursor(0,1);
  lcd.print(" Aplliances ctrl");
  delay(2000);
   lcd.setCursor(0,0);
  lcd.print("Using IR Remote ");
  lcd.setCursor(0,1);
  lcd.print("By Saddam Khan  ");
  delay(2000);
  lcd.clear();
  lcd.setCursor(0,0);
  lcd.print("Engineers Garage");
  delay(2000);
 
  irrecv.enableIRIn(); // Start the receiver
}



void loop()
{
  int i,j,k,l,m;
  lcd.clear();
   while(1)
   {
     lcd.setCursor(0,1);
     lcd.print("System Ready  ");
     delay(100);
   if (irrecv.decode(&results))
   {
        digitalWrite(13, HIGH);
    delay(10);
    digitalWrite(13, LOW);
   
    if((results.value)== 33441975)        // on off red button
     {
       if(i%2==0)
       {
        digitalWrite(TV, LOW);
        digitalWrite(light2, LOW);
        digitalWrite(light1, LOW);
        lcd.clear();
          lcd.setCursor(0,0);
          lcd.print("ALL OFF   ");
        delay(10);
       }
       else
       {
        digitalWrite(TV, HIGH);
        digitalWrite(light2, HIGH);
        digitalWrite(light1, HIGH);
        lcd.clear();
          lcd.setCursor(0,0);
          lcd.print("ALL ON   ");
          delay(100);
       }
       i++;
     }
    
    
      if((results.value)== 33444015)    //  key 1
     {
      if(j%2==0)
      {
       digitalWrite(TV, HIGH);
       lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("TV ON");
       delay(10);
      }
     
      else
      {
        digitalWrite(TV, LOW);
        lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("TV OFF");
       delay(10);
      }
      j++;
     }
  
   if((results.value)== 33478695)     //  key  2
     {
      if(k%2==0)
      {
       digitalWrite(light1, HIGH);
       lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("LIGHT 1 ON");
       delay(10);
      }
     
      else
      {
        digitalWrite(light1, LOW);
        lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("LIGHT 1 OFF");
       delay(10);
      }
      k++;
     }
    
      if((results.value)== 33486855)  //  key  3
     {
      if(l%2==0)
      {
       digitalWrite(light2, HIGH);
       lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("LIGHT 2 ON");
       delay(10);
      }
     
      else
      {
        digitalWrite(light2, LOW);
        lcd.clear();
       lcd.setCursor(0,0);
       lcd.print("LIGHT 2 OFF");
       delay(10);
      }
      l++;
     }  
      
irrecv.resume();           // Receive the next value
   }
   }
}
 
###

 


Circuit Diagrams

Circuit-Diagram-Arduino-Based-IR-Remote-Controlled-Home-Automation-System

Project Video

Related Articles Read More >

Wireless distance measurement using ultrasonic sensor
Computerized wireless Pick and Place Robot
Designing an Arduino-based ECG monitor using an AD8232 ECG sensor
Controlling Appliances Wirelessly using RF Technology

Featured Tutorials

  • Screenshot of Raspbian OS on Raspberry Pi RPi Python Programming 03: Raspberry Pi as Linux System
  • Raspberry Pi Models RPI Python Programming 02: Raspberry Pi Models
  • Raspberry Pi 4 RPi Python Programming 01: Introduction to Raspberry Pi 4
  • RPi Python Programming 05: Introduction to Python
  • RPi Python programming 04 RPi Python programming 04: Setting up Raspberry Pi Linux computer
  • Python Basics RPi Python Programming 06: Python basics

Stay Up To Date

Newsletter Signup

EE Training Center Classrooms

“ee

“ee

“ee

“ee

Recent Articles

  • Arduino’s L293D motor driver shield guide
  • NXP launches its first Wi-Fi 6E Tri-Band system-on-chip
  • Nexperia launches industry’s first 80 V RETs for high-voltage bus circuits
  • TDK releases low-profile medical sensors
  • Getting started with Raspberry Pi
...

RSS EDABOARD.com Discussions

  • What the best way to store data of size ( 90,000 * 32) bit (taken from a text file) using VHDL?
  • HSPICE Simulation refuses to match the Spectre Simulation
  • How to draw a helical coil around a rectangular core in Maxwell?
  • Where can I find the description of each layer in TSMC's pdk?
  • Same geometry but slightly different results

RSS Electro-Tech-Online.com Discussions

  • Where has the fun gone?
  • Where can I find a pole pig?
  • Voltage based relay
  • XC8 v2.31 Help: Integer Arithmetic With Numbers Larger Than 32 Bits?
  • new to Ardunio but trying to compile
Engineers Garage
  • Analog IC TIps
  • Connector Tips
  • DesignFast
  • EDABoard Forums
  • EE World Online
  • Electro-Tech-Online Forums
  • Microcontroller Tips
  • Power Electronic Tips
  • Sensor Tips
  • Test and Measurement Tips
  • 5G Technology World
  • About Us
  • Contact Us
  • Advertise

Copyright © 2021 WTWH Media LLC. All Rights Reserved. The material on this site may not be reproduced, distributed, transmitted, cached or otherwise used, except with the prior written permission of WTWH Media
Privacy Policy | Advertising | About Us

Search Engineers Garage

  • Projects and Tutorials
    • Circuit Design
    • Electronic Projects
      • 8051
      • Arduino
      • ARM
      • AVR
      • PIC
      • Raspberry pi
      • STM32
    • Tutorials
    • Components
  • Articles
    • EG Blogs
    • Insight
    • Invention Stories
    • How to
    • What Is
    • News
      • EE Design News
      • DIY Reviews
      • Guest Post
      • Sponsored Content
  • Forums
    • EDABoard.com
    • Electro-Tech-Online
    • EG Forum Archive
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • EE Resources
    • DesignFast
    • LEAP Awards
    • Oscilloscope Product Finder
    • Video
    • White Papers
    • Webinars
  • EE Learning Center
  • Women in Engineering