Driving LEDs with a battery pack

Ummm, I'm using a digital multimeter.

Does it mean the voltage is staying rock steady but the current is going crazy?

Reply to
fungus
Loading thread data ...

Well, to be honest, it's probably more my fault than yours. I'm not there looking over your shoulder so I really don't know which set up you were talking about.

If you are using the basic circuit (the one without the extra diode and capacitor I'd suggested), then your currents should be pulsing like mad and so should the voltage across the LEDs. If you are using the suggestion I made, then the voltage should vary a little bit but not much and the current should vary only a little bit, too. So it depends on what you are doing... and what instrumentation you were using.

I'm not an expert on multimeters, though I've designed some simple ammeters and voltmeters in my past (very simple, nothing like these commercial things.) But I believe they generally do averaging. Some of them have the ability to let you select "peak values," so that you can see what the peak is near to. And some support some form of RMS reading, as well (the more expensive ones, more likely than the cheap ones.) But I'd assume you aren't seeing the peak without information to the contrary.

So I guess I don't know what circuit you were using.

If you were using the diode/capacitor thing I added, then 100mA is probably looking pretty bright!! Looks like they are surviving, if so. But it also means you are punching them too hard in that case. I'd increase the base resistor value until you see currents in the

40mA or so range. If you were using the traditional pulsing (previously to the schematic I posted) example, then I just don't know. Maybe your meter is reporting peak... hard to be sure that it wasn't. And if so, I'm not worried about the 100mA. But it really is hard to be sure. Since you have a scope, place a small 1 ohm resistor in series with the six LEDs and scope out the voltage across it. Current will be equal to the voltage you see and you will get to see it in real-time, that way!

Jon

Reply to
Jon Kirwan

The one with the capacitor... (of course!)

A little bit dimmer than one of the LEDs at 20mA.

I don't have 1 ohm, the smallest I have is 4...

With that resistor in there I see a wave which goes flat for a little while (about 20% of the cycle), ramps up to 1V then drops back down to zero. 1V is 250mA peak.

Now, if you take the average of the ramp (ie. 125mA) and take away 20% for the flat part you get 100mA. Coincidence? I think not...! I guess the meter is averaging the value.

Reply to
fungus

I saw the posts. I posted to back you up on your mention in the thread that air core might work, proving, at least for that one, that core saturation was not the issue.

I also posted to point out what your equations show, but that may not be apparent to all, that Vbatt is key. Your detailed posts are too long for some newbies to get the point.

As to the # of turns you asked about, I don't recall for sure, but I don't think it was many. I had some pictures of the thing. I'll see if I can find them, and post if I do.

Ed

Reply to
ehsjr

Ah. My mistake.

Well, it's good to get it documented, I suppose.

The coupling of the two windings is my worry, plus how many windings may be needed to get the frequency in the right range.

Thanks, Jon

Reply to
Jon Kirwan

That doesn't sound good.

Okay.

Okay. At what frequency (rate?) How much time between these things? And what size is the capacitor??

I guess so.

Jon

Reply to
Jon Kirwan

Found the photo I mentioned in my earlier reply. It is not the joule thief circuit, but it uses an air wound coil and demonstrates that core saturation is not required for the boost circuit to work.

19t +---+-------[L1]--------+-------+ | | | | | | | [100R] |+ | + /c | [Batt] +---[100uF]---+---| BC337 | | | | \\e | | +---[4.7K]----+ | [LED] | | | +-----------------------+-------+

The red LED is lit at Vbatt 1.232 volts in the photo. The coil id is ~1/4" and it is 19 turns, about 2 1/2" long.

Ed

Reply to
ehsjr

I don't follow. If the voltage across the base winding is zero, the only base current left is that from the DC bias across the resistor, and presumably that is a lot less than what's required to sustain the peak collector current. So the transistor will rapidly turn off by the same mechanism as in the non-saturating case.

In both modes there will be a period of time when the transistor dissipates, but it's not clear to me which one will be better.

^^^^

This is a problem, because beta varies greatly from one specimen of transistor to another. The data sheet will give you a "typical" value, but it needs to be taken with several large grains of salt.

I suppose it's okay for a hobby project where you can play around with it until you get it right. But even in my hobby projects, I like to be able to calculate things so they're at least roughly right!

Only because you've got a *resistor* in there, which wastes a bit of power. One of the nice things about the plain Joule Thief is that it doesn't waste any power that way.

That's the idea behind the current step-down -- it lets you increase the duty cycle to something much closer to 100% while driving the LEDs at around their optimum current, whatever that is.

So use a bigger bead. Remember that the capacitor is going to take up space, too -- probably a lot more than an extra winding would.

--
Greg
Reply to
greg

It also means you're being rather hard on your LEDs!

As I said, the current you get is rather random...

--
Greg
Reply to
greg

Do you have a reference for this? It's the first time I've ever heard anything about energy being stored "in the gaps", or that iron doesn't store energy as well as other core materials.

I don't think it can be right. According to the calculation I just did on the back of an envelope, the energy required to charge an inductor up to a current I by applying a steady voltage V is given by

E = 0.5*V*L*I^2

So assuming that an iron core gives you more inductance than something else, such as ferrite, then E goes up. If the extra energy isn't stored in the inductor, then where does it *go*?

I suspect the reason iron won't work so well in this application is mainly due to frequency considerations. The magnetic domains in solid iron can't flip around so quickly. It's like putting a bunch of bar magnets together in a row. If you let them touch each other, they cling together strongly. If you keep them separated a bit, they don't attract each other so much and are easier to separate.

--
Greg
Reply to
greg

Yes. Since I've only been studying this recently, I do remember.

I'm looking at the Unitrode Magnetics Design Handbook (I've a paper copy here.) Aka, MAG 100A. Looking it up on the web, I see that it is here:

formatting link

Take a look at chapter 2 (Magnetic Core Characteristics) there. By the time you've read the first two pages, you'll see what I see.

You should quickly see "Energy storage in a transformer core is an undesired parasitic element." And there will be several more items to read, soon. I think this is what is termed "magnetizing energy." Desirable in flybacks. Undesirable in transformers.

Well, please read the text and see if you see what I see. I think it makes sense to me. Quite a bit, actually. So I suppose that's why it doesn't bother me to say it.

It's always been 1/2*I^2*L, agreed.

I am just learning this stuff, so don't take anything I say for much right now. But if what my mind says right now as making sense is right, a counter potential is created so that little or no actual current is able to develop if there is no place for magnetizing energy to be stored. There is always some place for it, though. Tiny gaps in the core, outside the iron core itself in the surrounding air, and so on. In effect, if the core is gapless and near perfect in the sense of not allowing magnetizing energy there, then what happens is that what energy must be stored is stored in the surrounding air and the whole thing acts more like an air core inductor without an iron core, at all. Unless there is a secondary somewhere for the flux to link up with and expend energy.

That's how it looks to me.

Well, I hope my above explanation (an internal mind thing of mine, for now) is about right. It is what I've extracted from the Unitrode book I just recently read through. This is all very new to me, though. So I'm still putting stuff in my head about it.

Well, that isn't why I think so (frequency limits.) I think it is because there are far fewer places to tuck away energy. The secondary (base winding) certainly counts as a place. So does the surrounding air. But it really makes a mess of things, if I've got it right.

Jon

Reply to
Jon Kirwan

What happens is the primary (which is the collector winding, for talking purposes) must go through zero volts on the way over to driving the LED (which requires a reversal, so you are certain that this happens if there is no other reason you are certain about it -- and there are other reasons to know.) When it is zero volts across the primary, it is also zero volts across the secondary (the base winding.) That's because there are no flux changes to induce one, anymore, right at the point where the current hits a peak value and before it starts declining when the LED is hit.

When the base winding (secondary) is at zero volts across, it doesn't add anything anymore to the battery voltage. But it doesn't subtract yet, either. So the battery alone is "seen." Since it is the case that earlier while the BJT is on and approximately one battery voltage is across the primary (collector winding), the flux is changing and linked to the secondary, inducing approximately one battery voltage there (in aiding fashion.) So a little earlier, there was the battery itself PLUS the aiding base winding, yielding approximately two battery voltages which drive through the resistor. When the situation takes place that there is zero volts across the base winding, then there is still one battery voltage left. That's the "1/2" I mentioned.

Yes. The way I look at it is that the beta only applies at some point during the cross-over. You can either choose to degrade the beta or else degrade the effective base current. I chose to do the latter in my calculations and keep the beta, because I can look it up in the datasheet.

Look, I can walk you through the exact details (it's iterative in the sense that it takes two or three passes through the datasheet to nail the exact values by hand.) If you want, and go grab up a copy of the On-Semi datasheet for the PN2222, I'll let you pick a situation and we'll walk through it in detail so that you see what I see. Then, if you have LTSpice handy, we can plug in the exact circuit there and you and I will each see that our hand calculations nail down exactly what we see in LTSpice, which is far, far more sophisticated.

The equations work pretty well. Been there, done that.

Me, too. This isn't a case where I white-washed. I both understand the theory AND why the practical details work out. Well, except that I'm still learning about core materials.

No, you can remove the resistor. As I said, I was just adding it for kicks. It is NOT at all necessary. What happens is that the load pulls some current while the transistor is ON and the freewheeling diode is OFF. As it does, the capacitor droops a little, (I/C)*dt. But then the BJT goes OFF, the freewheeling diode goes ON, and the energy is dumped onto the cap. You can see that it is easy to select any C value you want to match the dV you want to limit to. The resistor doesn't really matter, at all. I just put it in for playing around.

Jon

Reply to
Jon Kirwan

Sorry, I should have added something else. The effective inductance goes very close to zero if there is no place to put energy. This can allow an I that you'd imagine as worthy of some energy storage when, in fact, the L just went effectively close to nil.

The key here is that 1/2*I^2*L is always true. But there must be a place to put the energy, too. If there is no place to put it, either there is no I or else there is no L. One of the two, or both, stay low enough to match up with the magnetizing energy being stored. L isn't quite the fixed value you may imagine it is.

Jon

Reply to
Jon Kirwan

where are you getting this from? it sure doesn't sounde like the joule thief blocking oscillator layout.

collector winding is always +ve (much of the time by only V_CEsat), base winding goes negative at transistor turn-off

When it is zero volts across

Reply to
Jasen Betts

This is the wave without capacitor:

formatting link

This is the with capacitor:

formatting link

The frequency is 60kHz and it's about 1V amplitude with a 4 ohm resistor (would be four volts with a 1 ohm). The capacitor is 470uF (the smallest one I had with decent legs on it)..

Weirdly it seems to have changed since yesterday. Yesterday the "down" part of the wave with capacitor was completely horizontal at zero volts.

What's changed? Well, I tried removing LEDs to see what would happen (100mA should be ok for five, and a little bit over for four). One of them died and another one didn't look too healthy afterwards so I changed it.

If the wave was different then maybe they were already damaged. 100mA average certainly seems to indicate we're really abusing the LEDs..

Reply to
fungus

This makes no sense at all to me. Surely the capacitor should be smoothing that out and taking up the slack when there's no current coming through from the rest of the circuit.

The voltage across the LED chain is a series of narrow spikes without the capacitor. With the capacitor it's a perfectly flat DC voltage as you would expect. How can the current be varying from zero to 250mA?

Reply to
fungus

I don't think so. My post did not make the point clear, so the mistake is mine, not yours.

Yes! :-) I like it, and I assume others do, too. But I've talked with some newbies who glaze over when there is too much detail for them. I think that is why the series of books "xyz for Dummies" is successful. They allow a newcomer to the subject to "gear up" slowly. Those books are not for everyone, of course.

Somebody else posted about winding an aircore with bifilar to get the coupling. Way back when I was messing with these things, I wound some ferrites with bifilar, noted the results, then re-wound with single to compare. Of course, all I got was 1:1 with the bifilar. And in any event, I don't have the notes and no recollection of the results. :-( And I didn't do a bifilar aircore. I did do an aircore transformer - 2 complete coils where the id of one was just a little greater than the od of the other - but again I don't recall the results. I know I was experimenting with varying the coupling by moving the smaller coil farther into or out of the larger coil's inside diameter. Again, whatever notes I had are gone.

Ed

Reply to
ehsjr

Can you post a schematic of your setup, and indicate where you are attaching the scope probe and ground clip?

On another point you mentioned earlier, using a DMM to measure the output voltage or current may give you meaningless readings. It simply may be incapable of accurate readings, given the waveshape it is "seeing". Your use of the scope for making measurements on this circuit is the right approach.

Ed

Reply to
ehsjr

Hehe. No, it's my mistake! (We can go back and forth with this. ;)

Cripes, I'm one who also sometimes just glazes over with too much detail. I started reading the Unitrode book in earnest about a month ago or so when I first posted in sci.electronics.design about a transformer I wanted to use for a rocket launcher idea. I knew almost nothing about magnetics in electronics design at that point because the few times I'd tried to glance over detailed material it seemed 'difficult.' I mean, it actually is kind-of, for exactly the reasons that John Larkin recently mentioned that inductors are pretty inferior by comparison with other electronic parts -- there is a complex reality to grasp of many different and yet also important factors, none of which can really be ignored to get it right. With capacitors, for example, yes there is reality there too but the unwanted ones are in pretty good control for the most part and a more simplified view works well with them.

Thanks, Ed. I wondered how air-core versions might be done well. I haven't any bifilar wire here, that I'm aware of, so I need to go get some samples and look at them and try them out, now, along with winding air cores like you suggest above, too. Just to see what the results actually _can_ be.

I just wound myself four separate transformers, late last night. So I'm motivated to learn more and try my hand so that I can learn to be better, later, at this stuff. It's an important nook that I've skipped over all these years.

Jon

Reply to
Jon Kirwan

It's the 'mental theory' I used to develop accurate equations to estimate behavior I observe, drawn from my understanding of theoretical books I've also read.

However, you need to the fuller context (which is in my other posts) to understand that part. I wasn't saying this is what occurs for any length of time. It is only for an instanteous moment during a transitition. I was just trying to explain the "1/2" I'd earlier written. It's not how I see the operation, generally, though.

But I think I agree with you, Jason. The collector winding, for most of the time, remains with the entire battery voltage across it (less the gradually and slowly rising Vce of the BJT.) And indeed the base winding goes negative at BJT turn-off. I said that in earlier posts. You need to read those, as well, to see the fuller context.

Jon

Reply to
Jon Kirwan

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.