กลับไปหน้ารวมไฟล์
ir-remote-controlled-led-chaser-using-arduino-64b304-en.md

Here I am presenting one more LED chaser.

You might ask “one more LED chaser! Why? Is there anything new or interesting?”

My answer is “Yes”. As a title suggests, it’s not just simple micro controller based LED chaser but its IR remote controlled LED chaser.Means the LED chasing effects can be changed by remote control. Not only that but the blinking rate of LEDs can be also increased or decreased to make chasing effect faster or slower using remote.

The project given here, demonstrates how to generate different chasing effect on different color LEDs using IR remote (like TV, DVD, AC, STB etc) with the help of Arduino. Also it varies speed of chasing effect using remote. The project uses normal set top box (STB) IR remote, TSOP IR sensor, different color LEDs (red, green, blue, yellow, white) and an Arduino UNO board. Anyone can use any type of IR remote. Just he has to change the remote codes in the Arduino sketch (program) for the remote. This procedure is also described here while explaining the operation. So let us see how this is done. First see the circuit diagram followed by its description and operation.

Circuit description:

As shown in figure, there are very few components in circuit like different colour LEDs, resistors, IR sensor TSOP1738 and the main is the Arduino UNO board.

· The sensor TSOP1738 has 3 terminals (1) Vcc (2) Gnd and (3) output. Its Vcc terminal is given 5 V from board and Gnd terminal is connected to ground of board. Sensor output is connected digital input pin 2 and 3 of arduino board.Pin 2 of Arduino board is used as interrupt pin and pin 3 is used to receive IR remote code. When code is received by sensor pin 2 generates an interrupt

· Digital pins 4 to 13 of board are connected to anodes of different colour LEDs through current limiting resistors of 470Ω. The cathodes of all LEDs are shorted to board ground

· The stepper motor and ULN2003A chip is given external 5 V supply

Circuit operation:

First we have to decide, which are the different buttons of IR remote, that we will use to generate different chasing effects and vary it sspeed. We want to perform following actions

1. Generate 5 different types of chasing effects. Like generate 1st effect when button 1 is pressed and likewise

2. Increase/ decrease chasing effect speed

I have used set top box (STB) remote that has many buttons like 0-9 digit buttons, volume control buttons, channel up/down buttons, arrow key buttons etc. From all these buttons I have selected following 7 buttons for different operations

Digit 1 - Generate effect 1

Digit 2 - Generate effect 2

Digit 3 - Generate effect 3

Digit 4 - Generate effect 4

Digit 55- Generate effect 1

Volume UP - increase chasing effect speed

Volume down - decrease chasing effect speed

That means when any digit button between 1 to 5 is pressed, the LEDs start displaying different chasing effect. The volume up button will decrease LED blinking delay so chasing effect speed becomes faster and volume down button will increase LED blinking delay so chasing effect speed becomes slower.

After deciding the buttons, next is to decode the codes of these buttons. As we know when any button is pressed from remote, it will send one code and based on this code the action is performed. So to decode these codes I have used IR remote library for arduino, readily available on internet.

So download the library and use example to decode the codes of remote buttons. Upload the program into arduino micro controller and connect IR sensor as shown in figure. Now point the remote control towards IR sensor and press the button. Open serial monitor and you can observe the code of pressed button in form of numbers. Note down the codes of required buttons like I have noted the codes as per following table

Digit 1 : 2210

Digit 2 : 6308

Digit 3 : 2215

Digit 4 : 6312

Digit 5 : 2219

Volume UP : 6338

Volume down :6292

In the arduino sketch above codes are used corresponding to button pressed to perform action as per previous table. Now let us see the actual operation.

There are five different chasing effects

Effect 1: one by one all LEDs will turn ON from left to right and again they will be turned OFF from right to left

Effect 2: one by one all LEDs will blink from left to right and again from right to left

Effect 3: two LEDs at a time will blink from left to right and again from right to left

Effect 4 – Water Fall: one by one LEDs will turn ON from both ends and reaches to center and then turns OFF from center to both ends. This kind of effect looks like water fall

Effect 5 – Fountain: one by one LEDs will turn ON from center and reaches to both ends and then turns OFF from both ends to again center. This kind of effect looks like fountain

IR Remote controlled LED chaser using arduino video 1

IR Remote controlled LED chaser using arduino video 2

· The arduino board is given supply through USB

· Initially LEDs are OFF the message is displayed on serial monitor of arduino IDE as “IRremote controlled LED chaser”. The Arduino will wait for an interrupt from IR sensor

· Now when digit 1 button is pressed from remote, IR sensor receives code and pin 2 generates interrupt

· The Arduino jumps to ISR (interrupt service routine) and decodes the code for pressed button

· When it gets code for button 1 it will start generating chasing effect 1 on LEDs and again waits for any new button pressed from remote

· Similarly when any of the digit button is pressed the Arduino will decode and get the code from ISR and start generating any of the 5 chasing effects

· When volume up button is pressed, the delay applied between LED blinking is decreased. So LED blinks at faster rate - that means chasing effect speed increases and the message is displayed on serial monitor as “blinking speed increased

· Similarly when volume down button is pressed, the delay applied between LED blinking is increased. So LED blinks at slower rate and the message is displayed on serial monitor as “blinking speed decreased

· After increasing or decreasing the speed again when any button 1 to 5 is pressed the chasing effect becomes slower or faster

· The LED blinking delay is changed in step of 25 mili second (ms) from 50 ms to 200ms

Softwareprogram:

Complete functionality of project is because of the program downloaded into arduino board micro controller ATMega328. The program is the soul of the project. The program (also known as sketch) is written and compiled in arduino IDE software tool. And it is burn (embedded) into ATMega328 using built in software programmer tool AVRISP MK-II through USB port

EXPANDED TECHNICAL DETAILS

Infrared Protocol Decoding

This project enables remote, wireless control of complex lighting patterns using a standard TV remote.

  • Protocol Capture: Uses a 38kHz IR Receiver (TSOP1838). The Arduino utilizes the IRremote library to capture the 32-bit hex code unique to each remote button (e.g., 0xFF30CF for the "1" key).
  • Interactive Animation Engine: Each remote button is mapped to a different "Chaser" animation—such as "Knight Rider," "Breathing," or "Police Flash"—storing the state in a variable so the pattern persists after the button is released.

Hardware Safety

  • Logic Isolation: The IR receiver is isolated from the high-power LED driver stage, ensuring that the sensitive decoder logic is not affected by electrical noise from the flickering LEDs.

ข้อมูล Frontmatter ดั้งเดิม

title: "IR Remote Controlled LED Chaser Using Arduino"
description: "The project given here, demonstrates how to generate different chasing effect on different colour LEDs using IR remote (any remote)."
author: "ambhatt"
category: ""
tags:
  - "ir sensor"
  - "ir remote"
  - "led"
  - "arduino"
  - "chaser"
views: 2886
likes: 0
price: 2450
difficulty: "Easy"
components:
  - "1x Arduino UNO"
  - "1x Thermopile IR Sensor, TS105-10L5.5mm"
  - "1x 5 mm LED: Green"
  - "1x Breadboard, 270 Pin"
  - "1x 5 mm LED: Red"
tools: []
apps:
  - "1x Arduino IDE"
downloadableFiles: []
documentationLinks: []
passwordHash: "fdec80a6182fd3199df01a48ee04a29c3e631fa515b1b312d0f15cb95ba0e167"
encryptedPayload: "U2FsdGVkX19UJuYZyKlM1YLB/3BYiKp6RvpwsIQgx6nRyoFvC3Y+WqQYpFKXfwaMyM0V67W9Tpo0udWdrDyROHVhlgh+J2fLm2shwFaaFfw="
seoDescription: "Build an IR Remote Controlled LED Chaser using Arduino to create various chasing effects on LEDs."
videoLinks:
  - "https://www.youtube.com/embed/sGPQ7VQWYlk"
  - "https://www.youtube.com/embed/uvtuPkddxkQ"
heroImage: "https://cdn.jsdelivr.net/gh/bigboxthailand/arduino-assets@main/images/projects/ir-remote-controlled-led-chaser-using-arduino-64b304_cover.jpg"
lang: "en"