Switched mode constant current supply, huge spikes - Page 1
Forum section: electronics / projects

author: allanw
author_rank: Frequent Contributor
timestamp: October 23, 2010, 07:21:29 pm
content: ah crud, accidentally hit submit. I'm reposting better images.I'm designing a buck converter using the HV9918 IC to drive some high current LED's.I'm seeing some huge spikes at high bandwidth in the current waveform. Does anyone know where they're coming from?These waveforms are across a 1.7 ohm current sense resistor. So the current in A is approximately 60% of whatever amplitude is shown in the pictures. The average current is about 250mA. I'm driving a 6.8V zener diode.In all these pictures the bottom flat trace shows the 0V level for the top trace.The switching frequency is about 1MHz. There are huge spikes that are 700mA peak-to-peak!Zoomed in. Those sine waves are about 300MHz. My scope is a 2465B 400MHz and I'm using a 400MHz probe measuring across the sense resistor with the ground lead.With bandwidth limit of 20MHz on the scope, the current ripple looks much more reasonable. Only 30mA ish.Should I even worry about it? Will the LED's "see" this high frequency current spike if a 20MHz scope doesn't?

author: jahonen
author_rank: Super Contributor
timestamp: October 23, 2010, 07:33:01 pm
content: It might be a measurement artifact. Did you use the long ground clip during measurement, if yes, then throw it away, connect the ground from the tip sleeve of the scope probe and measure again? Big spikes voltage spikes are usually result of (relatively) large inductance in current path.Regards,Janne

author: allanw
author_rank: Frequent Contributor
timestamp: October 23, 2010, 07:44:10 pm
content: Sorry, I must've accidentally hit submit before finishing up my post.My test setup has long alligator clips going from the board to the zener diode, then another set of alligator clips connecting a current sense resistor in series with it. Could that be the cause of the inductance? In my final application I intend for the LED's to be connected by a cable to this driver board anyway.Could it be because the output capacitor for smoothing the current is located at the driver board, not at the load? Would putting it at the load fix it?

author: allanw
author_rank: Frequent Contributor
timestamp: October 23, 2010, 08:27:12 pm
content: I still see it even when probing the sense resistor and using touching the ground sleeve against the other end of the resistor (through hole).I'm going to try to connect the sense resistor closer to the load and see what happens.

author: allanw
author_rank: Frequent Contributor
timestamp: October 23, 2010, 10:56:08 pm
content: I just verified this using a 600MHz 5GS/s digital scope: I used the ground sleeve directly touching one end of the through hole current sense resistor and the probe tip attached to the other end.

author: jahonen
author_rank: Super Contributor
timestamp: October 24, 2010, 07:29:49 am
content: Well, it looks like that the switching operation is sufficiently fast to excite parasitic resonances of your power feed loop. Are you using a proper PCB for the chip or do you have some kind of a breadboard design?Edit:Your current probably does not have wild spikes in reality, but instead the ground noise disturbs the measurement. I bet that you can see the bursts just by short circuiting the probe at tip and then touching with it to circuit ground?I recently experienced similar behavior on a step-down converter, creating similar EMI bursts in switching instants. I could reduce that substantially by reducing the loop area (i.e. inductance) between IC and input bypass. Also, use SMD ceramic capacitor for input bypass.Regards,Janne

author: saturation
author_rank: Super Contributor
timestamp: October 24, 2010, 12:02:14 pm
content: Interesting problem, but not easy to solve via the Internet. Given the spikes regularity, its definitely a circuit generated issue being fed into the output that isn't being sufficiently dampened. Have you tried increasing the input bypass capacitance, as Janne suggest?

author: allanw
author_rank: Frequent Contributor
timestamp: October 24, 2010, 06:01:16 pm
content: I experimented with the input bypass caps. I tried 0.1uF, 1.0uF, and 4.7uF ceramic X7R caps.I found that the spikes were the smallest with the 1.0uF caps and they were slightly smaller when I stacked two of them in parallel. This sort of makes sense since the smaller value caps are better for bypassing high frequency.I've tried measuring with the ground sleeve touching one end of the resistor and the probe tip on the other, but it still looks exactly the same.I think I'll try a 22uH inductor instead and see what happens. If that doesn't fix it I'll probably just ignore the problem since it hopefully won't actually affect the LED's. For reference, here's my layout:And schematic:

author: jahonen
author_rank: Super Contributor
timestamp: October 24, 2010, 06:17:23 pm
content: It does not affect leds but I bet that radio reception will be seriously hampered around the oscillation frequency you measured (EMI problem).In previous post I meant that can you still see the bursts if you short circuit the probe tightly and then touching the circuit ground, with this short circuited probe? (classical symptom of serious EMI problem if oscillations are still present).To cure that, you might try inserting some ferrites to power input and led wires to contain the current loops at higher frequencies.Regards,Janne

author: Zero999
author_rank: Super Contributor
timestamp: October 24, 2010, 06:52:09 pm
content: Try putting a smaller inductor (lower value and higher self resonant frequency) in series with the L1 and a ferrite bead in series with the power supply.

author: allanw
author_rank: Frequent Contributor
timestamp: October 24, 2010, 07:27:16 pm
content: Quote from: jahonen on October 24, 2010, 06:17:23 pmIt's definitely radiating. I formed a loop with the scope probe and could pick up the spikes from over a meter away, over 100mV in amplitude.

author: NiHaoMike
author_rank: Super Contributor
timestamp: October 24, 2010, 10:21:10 pm
content: Try adding a snubber.

author: allanw
author_rank: Frequent Contributor
timestamp: October 24, 2010, 10:59:11 pm
content: I placed a capacitor across the current sense resistor, which also reduces the switching frequency.With a 0.5uF cap, there's still a spike but it's very small. Now my ripple voltage is 240mV, with spike 336mV. Previously my ripple voltage was 23mV and the spike was 500mV. The switching frequency went from 1.7MHz to 633kHz.With 1uF cap, the spike is entirely gone but the ripple is 340mV.I'm going to order some bigger value inductors and see what that'll do.

author: Zero999
author_rank: Super Contributor
timestamp: October 25, 2010, 05:20:31 pm
content: I'm not sure if a larger inductor is the solution.In theory, a larger inductor will mean less current ripple for the same switching frequency but the parasitic capacitance, which is causing your problem, will also be higher.

author: allanw
author_rank: Frequent Contributor
timestamp: October 25, 2010, 05:47:02 pm
content: It seemed like lowering the switching frequency by adding a capacitor in parallel with the current sense resistor killed the spikes entirely. Since the IC operates based on hysteresis, increasing the inductor value will decrease the switching frequency. I'm hoping that will fix it. If not, I'll just keep the capacitor across the current sense.

author: TechGuy
author_rank: Regular Contributor
timestamp: October 26, 2010, 01:48:15 am
content: Quote from: allanw on October 23, 2010, 07:21:29 pmThe spikes are caused by inductance leakage in the inductor. It rings (oscillates) because of the diodes (google switching diode ringing). You can attenuate the ringing by connecting small bypass caps across each LED in the LED chain (try something low like 1 nf ceramic cap) and the reverse recovery diode.I also recommend adding a CLC filter from your voltage source (Vin). Consider that the power supply might also introduce some switching noise from the SMPS that you're using. Since the Buck regulator switching might create an unstable feedback loop with the power supplier regulation circuitry. The CLC filter should attentuate the voltage spikes a bit. Although there are limits, because of the design. For smooth output, the load (in this case LEDs) need to be on the other side of the inductor so the that the switching noise is blocked by the inductor, and attenuated by a output capacitor. By putting the load on the high side, it experiences all of the switching noise. I suppose that load noise was not considered in this design. Voltage spikes could be a problem if the spike voltage exceeds the LED breakdown voltage. If your driving expensive LEDs I would look at other constant current drivers for your application. FWIW: I am not too impressed by SuperTex designsTake a look at:http://www.fairchildsemi.com/ds/FA/FAN5608.pdfThis design puts the load on the low side of the inductor.

author: allanw
author_rank: Frequent Contributor
timestamp: October 26, 2010, 02:12:12 am
content: Drats, I've invested a lot of time in figuring out this Supertex driver.I picked them since they were only $1.2 each, compared to other LED drivers that are $3 - $4. This is important because I want to drive RGB LED's independently. Perhaps I got what I paid for, but I think it's promising that the spikes went away by sprinkling some capacitors into the design. Once I get the larger inductors I'll play around and see what combination works best.I did consider other drivers like LM3404, NCP3065 but they weren't as flexible as this driver, since they wouldn't work well across a wide input/output voltage range.In the end my intent is to sell low-cost Arduino shields with these drivers. Hopefully I'll be able to do it without having to pretend like these spikes don't exist

author: Zero999
author_rank: Super Contributor
timestamp: October 26, 2010, 05:35:39 pm
content: A CLC filter is a good idea but make sure you select the component value carefully.I don't see how using a more expensive controller would help.

author: jahonen
author_rank: Super Contributor
timestamp: October 26, 2010, 05:49:14 pm
content: For most of these kinds of problems, the key is to make acquaintance with Mr. Maxwell and trick him to do what you want to doOne really can't change laws of electromagnetism, despite of persistent hard efforts of sales department people.Seriously speaking, it usually boils down to PCB layout and somewhat component selection. These MHz switchers should definitely be considered as UHF devices, not DC at all.Regards,Janne

author: TechGuy
author_rank: Regular Contributor
timestamp: October 26, 2010, 07:20:05 pm
content: Quote from: allanw on October 26, 2010, 02:12:12 amIf you need to drive an LED array look for multichannel LED drivers:http://www.st.com/stonline/books/pdf/docs/12568.pdfAlthough it appears the bulk of these are linear constant current drivers, instead of switch mode. You didn't mention your LED current requirements so I don't know if these linear LED drivers will work for your applicationFor low voltage drivers, you can use a Buck step down regulator to drop the voltage, For instance the LM2576HV-Adj (3A adjustable Buck Regulator up 60V input). There is also a 5A monolithic version too perhaps LM2577HV (I forget the part number). If you go to the national power conversion webpage they have automatic part selector, where you input your Vin range, Vout and Current and it will pull together a list of components. They have Buck regulators that can handle > 10A, but they usually require external switching components (ie MOSFETs).

author: sallz0r
author_rank: Newbie
timestamp: December 08, 2010, 11:56:56 am
content: Sorry to drag up an old thread, but I'm curious what happened with this....Quote from: allanw on October 26, 2010, 02:12:12 amWhat value inductors did you try? Did they make any difference? Did you end up figuring out the problem? :-)

author: allanw
author_rank: Frequent Contributor
timestamp: December 08, 2010, 12:28:57 pm
content: Tried out bigger inductors. They didn't make the problem any better, just lowered the switching frequency.Then I thought it could be the Schottky diodes letting reverse current through, so I bought a few different ones to try out, but I never got the time. I'll probably do it again over winter break.

author: sallz0r
author_rank: Newbie
timestamp: December 09, 2010, 01:29:40 pm
content: Quote from: allanw on December 08, 2010, 12:28:57 pmFascinating... I'm not as familiar with how it all works to make any meaningful contribution, but I'm very interested to see where this is going. I'm looking at making lots of constant-current LED drivers myself, and these Supertex drivers look like they'll be perfect.[as an aside: I'm not net-stalking you, I sware. ;-) I've just started down this path ever since you said you were using the HV9918 on your youtube video, and I'm looking to see how well (or not) they work.] :-)(Speaking of which, can anyone suggest any solid foundation reading that I could use to understand how circuits like these work? I have a basic understanding, but a lot of the stuff at higher frequencies just doesn't make sense....)