3 Color LED Module RGB

  • 3 Color LED Module RGB

Below the corresponding code:


//KY016 3-color LED module
int redpin = 11; // select the pin for the red LED
int bluepin = 10; // select the pin for the blue LED
int greenpin = 9 ;// select the pin for the green LED
int val;
void setup () {
pinMode (redpin, OUTPUT);
pinMode (bluepin, OUTPUT);
pinMode (greenpin, OUTPUT);
Serial.begin (9600);
}
void loop ()
{
for (val = 255; val> 0; val --)
{
analogWrite (11, val);
analogWrite (10, 255-val);
analogWrite (9, 128-val);
delay (10);
Serial.println (val, DEC);
}
for (val = 0; val <255; val ++)
{
analogWrite (11, val);
analogWrite (10, 255-val);
analogWrite (9, 128-val);
delay (10);
Serial.println (val, DEC);
}
}

SCHEMATIC:
Arduino pin 11 --> Pin R module
Arduino pin 10 --> Pin G module
Arduino pin 9 --> Pin B module
Arduino pin GND --> Pin - module
You don't need any resistors, these are already included on the module

Write a review

Please login or register to review

3 Color LED Module RGB

  • Webwinkel Keurmerk en klantebeoordelingen

  • 14 dagen bedenktijd 
  • Verzendkosten voor eigen rekening
  • Product Code: KY-016
  • Availability: 12
  • 2.36€

  • Ex Tax: 1.95€

Similar Products

Laser Receiver

Laser Receiver

Below you can see the corresponding code.an example project for the Laser Receiver.//Author Danny va..

3.50€ Ex Tax: 2.89€

Tilt Switch Sensor Module

Tilt Switch Sensor Module

Below you can see the corresponding code: An example project for the Tilt Switch/* Author: Danny v..

2.29€ Ex Tax: 1.89€

SMD 3 Color RGB Module

SMD 3 Color RGB Module

Below the corresponding code:int redpin = 11; // select the pin for the red LED int bluepin = 10; /..

2.36€ Ex Tax: 1.95€

Reed Switch Module

Reed Switch Module

Below the corresponding code:int Led = 13 ;/ / define LED Interface int buttonpin = 3; / / define t..

2.36€ Ex Tax: 1.95€