Axiometa
RGB LED
RGB LED
SKU:AX22-0006
Low stock: 5 left
Regular price
$2.49
Regular price
Sale price
$2.49
Unit price
per
Taxes included.
Shipping calculated at checkout.
Couldn't load pickup availability

Technical Details
Pinout
Arduino Example Snippet
// Pin numbers for the RGB LED
const int redPin = 8;
const int greenPin = 15;
const int bluePin = 45;
void setup() {
// Initialize the RGB LED pins as outputs
pinMode(redPin, OUTPUT);
pinMode(greenPin, OUTPUT);
pinMode(bluePin, OUTPUT);
}
void loop() {
// Fade in and out red
for (int i = 0; i <= 255; i++) {
analogWrite(redPin, i);
delay(10);
}
for (int i = 255; i >= 0; i--) {
analogWrite(redPin, i);
delay(10);
}
// Fade in and out green
for (int i = 0; i <= 255; i++) {
analogWrite(greenPin, i);
delay(10);
}
for (int i = 255; i >= 0; i--) {
analogWrite(greenPin, i);
delay(10);
}
// Fade in and out blue
for (int i = 0; i <= 255; i++) {
analogWrite(bluePin, i);
delay(10);
}
for (int i = 255; i >= 0; i--) {
analogWrite(bluePin, i);
delay(10);
}
// Fade through a range of colors
for (int i = 0; i <= 255; i++) {
analogWrite(redPin, i);
analogWrite(greenPin, 255 - i);
analogWrite(bluePin, i / 2);
delay(10);
}
for (int i = 255; i >= 0; i--) {
analogWrite(redPin, i);
analogWrite(greenPin, 255 - i);
analogWrite(bluePin, i / 2);
delay(10);
}
}