The linear regulators converted a lot of energy into heat instead of light, so a new current driver design is in order. The CAT4101 driver is getting replaced by a switching buck regulator to improve efficiency. This change also presented an opportunity to change the voltage source for the system from a recovered ATX PSU providing 12v to a dedicated 36v DC supply.
This voltage was chosen to accommodate the highest forward voltage of 3.8v. A string of 8 LEDs would need 30.4 v. This choice would have quite an impact on the red LEDs if we were still using linear current drivers due to the very large excess voltage. Luckily, a switching current driver doesn’t offer the same limit, so the excess voltage is not a problem.
A linear current driver simply burns the extra energy as heat. A switching buck regulator uses the properties of coils to chop the power in order to provide the configured current by turning the supply on and off very quickly. As a result of non instantaneous changes in current through a coil, the load receives an average current as configured. LEDs can cope with the current swings, but it could be reduced using a filter capacitor parallel to the load.
There are many choices for switching current drivers, but most of them seem to only support up to 30 volts or so. The LM3404 (and LM3404HV) supports up to 42 volts (and 70 volts) input. The switching mosfet is also integrated into the package, so that reduces the cost and complexity of the circuit.
Designing the circuit is much more complex than simply using the CAT4101. Three components and the input and output voltages affect the output current. Ron determines the time that the circuit is conducting. Rsns sets the minimum voltage threshold at which the circuit resumes conducting. These two resistors control the frequency, and an inductor impacts the amount of ripple in the final design. In truth, each of these components has an influence on the appropriate values for the other components. The inductance changes the slope in the on-off cycle, therefore it must fit within some limits and it also drives the amount of ripple in the system.
After a significant amount of time poring over the datasheet and related documents, I put together a calculator to help determine the appropriate component values. The calculator is available on Plunker (I also wanted to try out AngularJS).
I finally understand what I want to accomplish, and a possible way to accomplish it. The components were pretty much as expected, except Rsns was much more expensive than I thought it would be – around 0.50 USD in small quantities. With the components on the way, I put together a little prototype board. Circuit and board were designed in eagle (based directly on the circuit in the datasheet). Since the LEDs will be dimmed via PWM and the current changes are acceptable with LEDs, I did not add a smoothing capacitor to the output. The schematic and board layout contain two inductors because the actual components are different footprints and I wanted to use the same board for multiple tests. I may take a bit more time selecting components next time so I don’t have to add additional components to the schematic for that kind of flexibility. The board was created using toner transfer with a laminator and etched with Muriatic and H2O2. Solder it up, and test it out…
I ran into a few problems while populating the board. First, I somehow didn’t have the right values for Cf and Cin capacitors. I improvised with some through hole components. I don’t know if the electrolytic capacitor used for Cin will stand up to the switching speed. Tests will show if this causes a problem or not. I also thought I didn’t have any 3.3uF capacitors, and couldn’t figure out why I had ordered a pack of 4.7uF capacitors. I guess 3.3 wasn’t available, but 4.7 was; I had planned to substitute those values. That didn’t happen on the first prototype testing board. I went back to my parts bin and retrieved a through hole capacitor to hack into place. Wire it up and test it out. Success! Approximately .8 amps with 1, 2, or 3 LEDs!
If you are interested in seeing the lucky fish that will get this marvel, take a look at Blendini’s home.
Next up – design the actual board that will drive all 5 (or 6) color channels. I still need to figure out what to use for appropriate connectors.