PIC16F628 8 RGB LED Controller
This code is for a simple RGB LED controller for 8 LEDs using a PIC16F628. The pattern is determined by the data in the EEPROM. Upon startup, the controller loads the data into RAM and starts up the sequence. The operation is very simple and so is the wiring. The PIC selects each LED then turns on/off the respective colors then goes to the next LED. Because of persistence of vision, the eye sees the LEDs as all being on at the same time. Currently the max number of display patterns is 20 (because the bank array is 80 bytes and each pattern is 4 bytes).
The microcontroller code can be downloaded here:
- 8RGBRAM.jal (8RGBRAM.hex)


December 23rd, 2006 at 5:37 pm
ola amigo estou a procura de controle de leds rbg com pic 12f629
grato a todos
helio atibaia são paulo brasil
que tenham um feliz natal a todos
January 3rd, 2007 at 5:11 pm
helio – It is very easy to control an RGB LED with a PIC12F629. Please see (for example): http://www.semifluid.com/?p=8
February 10th, 2007 at 11:03 am
Do you know if this is the model used in Led Lights for pools?
Thanx
April 28th, 2007 at 11:16 am
What do you think about using PIC16F628 to control individule circuit board? It seems impossible for me but people from Lunar Accents said they can do it with their program!!!
April 29th, 2007 at 3:34 pm
#4 (Solar) – What do you mean by using a PIC16F628 to control individual circuit boards? If you mean a master and multiple slaves, then yes it would not be a problem. As long as you use a multidrop bus then it would not be difficult to create a system that controls multiple lights. You could even do long-distance control using RS485 converters and wiring.
May 10th, 2007 at 1:45 pm
hi, nice circuit, im building a pov and using one color led, hopefully, your schematic gave me an idea to make a tri color pov toy. do you have the source code in .asm format. thanks
alain
June 22nd, 2007 at 3:05 am
Can someone post a video to this? It seems like the red LEDs stay on and the green and blue chase each other in the .hex example. Is this correct?
November 8th, 2007 at 6:10 pm
What i can do with that Code? The circuit it`s does work self? Were i need That code???Please tell me !!!!!
February 16th, 2008 at 8:34 pm
Just curious what is the voltage required for each LED? Or What is the voltage on each of the pins?
September 19th, 2008 at 1:31 am
I built a backlight for a wall hung LCD clock and used 8 RGB’s. Then i stumbled on this wonderfull circuit, Thank you very much…. It just so happened that I hadf an extra 16f628 and the project works wonderfully. I was wondering if you had any other HEX codes for the non serial version? what I have is 4 RGB’s down each side of the display, i would like to make them all change color at the same time or change in patterns of 4(so 2 RGB’s are the same color at the same time) I’m new to PIC programming so I would appreciate any help. Thank you for your time
April 6th, 2009 at 9:27 am
Hi,
Where can I find the Bank_arrays_ins.jal librairy, for this very cool project?
Thanks
Davidp0
May 9th, 2009 at 10:34 am
Hi..! Can you post the source code with some comments or explanations..I´d like to make others effects. Thx in advance