RGB Full Color Module

  • Product Code: KY-009
  • Location: FD3-03
  • Availability: In Stock
  • R12.95 (price excl. VAT)


RGB Full Color Module

The KY-009 is a small breadboard friendly RGB LED module mounted on a small PCB making it very versatile. Using Arduino PWM function almost any color can be created. Limiting resistors are required when connecting to Arduino pins.

Quick Spec

  • Operating voltage: 5V
  • LED drive mode: Common Cathode
  • Max current: 20mA

Limiting Resistors for each Color

  • R - Red : 180 Ohm resistor
  • G - Green : 100 Ohm resistor
  • B - Blue : 100 Ohm resistor

Arduino Code Example


int redPin = 11;
int greenPin = 10;
int bluePin = 9;
 
//uncomment this line if using a Common Anode LED
//#define COMMON_ANODE
 
void setup()
{
  pinMode(redPin, OUTPUT);
  pinMode(greenPin, OUTPUT);
  pinMode(bluePin, OUTPUT);  
}
 
void loop()
{
  setColor(255, 0, 0);  // red
  delay(1000);
  setColor(0, 255, 0);  // green
  delay(1000);
  setColor(0, 0, 255);  // blue
  delay(1000);
  setColor(255, 255, 0);  // yellow
  delay(1000);  
  setColor(80, 0, 80);  // purple
  delay(1000);
  setColor(0, 255, 255);  // aqua
  delay(1000);
}
 
void setColor(int red, int green, int blue)
{
  #ifdef COMMON_ANODE
    red = 255 - red;
    green = 255 - green;
    blue = 255 - blue;
  #endif
  analogWrite(redPin, red);
  analogWrite(greenPin, green);
  analogWrite(bluePin, blue);  
}

Shipping List

  • 1 x RGB Module

Tags: RGB Full Color Module