At the moment I am using an IS31FL3218 LED driver (18 channel 1 kHz PWM) to run six RGB LEDs. It works great except after dimming so far the green LED starts to over power the red and blue. I added a PIC that is running a software PWM to drive anode transistors thinking I could use that for a dimmer and raise the cathode duty cycle and even the colors out. It too works good, but around 50% duty cycle and less the PWMs of the PIC and the LED driver overlap wrong and it starts to flicker and such. I could just redesign the anode controller to use a better PIC. I would like to do it different and thought I would see if anyone has any ideas.
What I hope to accomplish is create a group of three PWMs for the cathodes that will increment the anode PWM after every cycle. In other words the Anode will be on x number of 256 cycles of complete cathode PWM cycle (also 256 steps). I can do this already with a couple PICs I have, but I'll end up with 28 pin parts for a 9 pin project. The smaller packages either lack the speed for a software solution, or the hardware to make it possible. Assuming a final frequency of 100 Hz for the LEDs and 65536 total PWM cycles for each cycle it looks like I'll have to be over 6.5 MHz for the cathode PWM.
That covers 24 PWMs. The other six are for separate LED rings that are stand alone PWMs.
A PI Zero currently sends data to the PIC and LED driver through I2C now to alter the LEDs and I would have no problem sticking with I2C. I am trying to stay away from SPI as I have other plans for the PI SPI. The idea of a parallel interface between the Pi and the controller(s) is a possibility (I already have a partial driver programmed).
I have been kind of wanting to learn a bit about FPGAs and thought this might be a good project for one. Write only parallel interface with eight data pins, an address / data pin, and a clock pin. The only problem is I know nothing about making them work... Will have to learn.
I could just use the 28 pin PICs, but in the end it will take six of them. Still not enough speed or hardware to do more than LED one per controller. I'd like to keep the project small.
The Pi is too far away for WS2812 and the like. I had some APA102 types working for a while, but being outside they gave me some issues. The most reliable has been through hole standard RGB.
I'd like to be able to do it all with a single controller. Any thoughts?
What I hope to accomplish is create a group of three PWMs for the cathodes that will increment the anode PWM after every cycle. In other words the Anode will be on x number of 256 cycles of complete cathode PWM cycle (also 256 steps). I can do this already with a couple PICs I have, but I'll end up with 28 pin parts for a 9 pin project. The smaller packages either lack the speed for a software solution, or the hardware to make it possible. Assuming a final frequency of 100 Hz for the LEDs and 65536 total PWM cycles for each cycle it looks like I'll have to be over 6.5 MHz for the cathode PWM.
That covers 24 PWMs. The other six are for separate LED rings that are stand alone PWMs.
A PI Zero currently sends data to the PIC and LED driver through I2C now to alter the LEDs and I would have no problem sticking with I2C. I am trying to stay away from SPI as I have other plans for the PI SPI. The idea of a parallel interface between the Pi and the controller(s) is a possibility (I already have a partial driver programmed).
I have been kind of wanting to learn a bit about FPGAs and thought this might be a good project for one. Write only parallel interface with eight data pins, an address / data pin, and a clock pin. The only problem is I know nothing about making them work... Will have to learn.
I could just use the 28 pin PICs, but in the end it will take six of them. Still not enough speed or hardware to do more than LED one per controller. I'd like to keep the project small.
The Pi is too far away for WS2812 and the like. I had some APA102 types working for a while, but being outside they gave me some issues. The most reliable has been through hole standard RGB.
I'd like to be able to do it all with a single controller. Any thoughts?
Last edited: