Hello:
I need some help for use with 12mm Diffused Flat Digital RGB LED Pixels.
1- How can I can keep one LED lit all the time? I need to light on one led at a time when I need it.
2.- How can I turn off all LEDs?
I have seen the code example, but I don't find this information.
More examples code, please?
thank you very much
12mm Diffused Flat Digital RGB LED Pixels (Strand of 25)
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
-
- Posts: 10
- Joined: Tue Jun 05, 2012 3:34 pm
- adafruit_support_bill
- Posts: 88093
- Joined: Sat Feb 07, 2009 10:11 am
Re: 12mm Diffused Flat Digital RGB LED Pixels (Strand of 25)
The pixels are individually addressable. To light one led at a time, call SetPixelColor(pixel, color): where 'pixel' is the number of the pixel you want to light and 'color' is the color you want it to be. To turn a pixel off, set the color to 'black' (see below).
Color is specified using the color(red, green, blue) function: where red, green and blue are numbers between 0 and 255.
color(25,255,255) = white
color(255,0,0) = red
color(0, 255,0) = green
color(0,0,255) = blue
color(0,0,0) = black
Other color mixes are possible. Experiment!
Color is specified using the color(red, green, blue) function: where red, green and blue are numbers between 0 and 255.
color(25,255,255) = white
color(255,0,0) = red
color(0, 255,0) = green
color(0,0,255) = blue
color(0,0,0) = black
Other color mixes are possible. Experiment!
Please be positive and constructive with your questions and comments.