/*
RGB / PWM Demo
*/
const int RGB_PINS[] = {11, 10, 9};
void setup() {
Serial.begin(9600);
for (int i = 0; i < 3; i++) {
pinMode(RGB_PINS[i], OUTPUT);
}
}
void loop() {
for (int color = 0; color < 3; color++) {
for (int count = 0; count < 256; count++) {
analogWrite(RGB_PINS[color], count);
delay(10);
}
analogWrite(RGB_PINS[color], 0);
}
}