← All Projects

IR Remote Controlled LED Strip

214 viewsFebruary 22, 2026
ArduinoIRLEDRGBRemote Control

Control an RGB LED strip using any IR remote control. Map different remote buttons to colors, brightness levels, and effects. Uses an IR receiver module and MOSFET transistors to drive the LED strip from an Arduino.

Components & Supplies

×1Arduino Uno R3
×1IR Receiver Module (VS1838B)
×1RGB LED Strip (12V, Common Anode)
×3IRLZ44N N-Channel MOSFET
×112V DC Power Supply
×1IR Remote Control

Circuit Connections

ComponentPinPinComponent
ArduinoD2OUTIR Receiver
Arduino5VVCCIR Receiver
ArduinoGNDGNDIR Receiver
ArduinoD3 (PWM)Gate (Red)MOSFET 1
ArduinoD5 (PWM)Gate (Green)MOSFET 2
ArduinoD6 (PWM)Gate (Blue)MOSFET 3

Overview

This project lets you control an RGB LED strip with a standard IR remote (like a TV remote or the small remotes that come with Arduino kits). An IR receiver decodes the remote signals, and the Arduino maps each button code to a specific color or effect.

Three N-channel MOSFETs (one per RGB channel) allow the Arduino to drive the 12V LED strip safely. PWM on pins 3, 5, and 6 provides smooth dimming and color mixing.

arduinoIR LED Controller Sketch
#include <IRremote.h>

const int irPin = 2;
const int redPin = 3;
const int greenPin = 5;
const int bluePin = 6;

int r = 0, g = 0, b = 0;

void setup() {
  Serial.begin(9600);
  IrReceiver.begin(irPin);
  pinMode(redPin, OUTPUT);
  pinMode(greenPin, OUTPUT);
  pinMode(bluePin, OUTPUT);
  Serial.println("IR LED Controller Ready");
}

void setColor(int red, int green, int blue) {
  r = red; g = green; b = blue;
  analogWrite(redPin, r);
  analogWrite(greenPin, g);
  analogWrite(bluePin, b);
}

void loop() {
  if (IrReceiver.decode()) {
    unsigned long code = IrReceiver.decodedIRData.decodedRawData;
    Serial.print("IR Code: 0x");
    Serial.println(code, HEX);

    switch (code) {
      case 0xBA45FF00: setColor(255, 0, 0); break;     // Red
      case 0xB946FF00: setColor(0, 255, 0); break;     // Green
      case 0xB847FF00: setColor(0, 0, 255); break;     // Blue
      case 0xBB44FF00: setColor(255, 255, 255); break; // White
      case 0xBF40FF00: setColor(0, 0, 0); break;       // Off
      case 0xBC43FF00: // Brightness up
        r = min(r + 25, 255);
        g = min(g + 25, 255);
        b = min(b + 25, 255);
        setColor(r, g, b);
        break;
      case 0xF807FF00: // Brightness down
        r = max(r - 25, 0);
        g = max(g - 25, 0);
        b = max(b - 25, 0);
        setColor(r, g, b);
        break;
    }
    IrReceiver.resume();
  }
}