Write a Review (requires login)
This is a fun little board. You’ll need a minimum of three connections to make it work. I’ve tested it at 3.3VDC and 5VDC with success. Apply the +V to the VCC pin, ground the D0 thru D7 pin of the LED you wish to light, and ground the color pin (R)ed, (B)lue, (G)reen to choose the color. You can light all eight LEDs by grounding all Dx pins and choose all three colors by grounding all three color pins. The only error I’ve found with the board is the markings for the color pins for (B)lue and (G)reen are reversed. Perhaps this is why they were sold as surplus?
This is a very cool module! Here's complete code for exercising the LEDs. As noted, this module will work with either 3.3V or 5 V power.
/* Uses the CAT # WLM-1 RGB 8-LED board from
allelectronics.com. This code blinks R, G, B
at 1-s intervals on each LED from left to right,
with connections to pins D0 -> D7.
Note that at least for UNOs and compatibles,
you can't use Serial.print() functions in any code
that sets D0 and D1 as output because those pins
are reserved for serial TX/RX with hardware UART.
You can turn one, two, or three colors on
simultaneously with each LED, but the colors don't
blend very well, like they would with a diffuse
housing RGB LED. This means that you can't make a
convincing red-yellow-green display, for example.
Will work with 3.3V or 5V power.
R to pin D8, G to pin D9, B to pin D10,
*/
int i,j;
long int delayTime=1000L;
void setup() {
for (i=0; i<=10; i++) {
pinMode(i,OUTPUT); // mode as "output"
// initially all LEDs and their color controllers are "off"
digitalWrite(i,HIGH);
}
}
void loop() {
for (i=0; i<=7; i++) {
digitalWrite(i,LOW);;
for (j=8; j<=10; j++) {
digitalWrite(j,LOW); delay(delayTime);
digitalWrite(j,HIGH);
}
digitalWrite(i,HIGH);
}
}