Tyr changing this ...
void fadeInAndOut(uint8_t green, uint8_t yellow, uint8_t blue, uint8_t red, uint8_t wait) {
for(uint8_t b=0; b <255; b++) {
for(uint8_t i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, green*b/255, yellow*b/255, blue*b/255, red*b/255);
}
strip.show();
delay(wait);
};
for(uint8_t b=255; b > 0; b--) {
for(uint8_t i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, green*b/255, yellow*b/255, blue*b/255, red*b/255);
}
strip.show();
delay(wait);
};
};
void fadeInAndOut(uint8_t green, uint8_t blue, uint8_t red, uint8_t wait) {
for(uint8_t b=0; b <255; b++) {
for(uint8_t i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, green*b/255, blue*b/255, red*b/255);
}
strip.show();
delay(wait);
};
for(uint8_t b=255; b > 0; b--) {
for(uint8_t i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, green*b/255, blue*b/255, red*b/255);
}
strip.show();
delay(wait);
};
};
The first 3 parameters of fade in and out are the Green, Blue and Red colors that get sent to setpixel color. There is no yellow. You can set any color by setting the g,b,r of a tri color pixel.
Brian