Wiring LED's to typical batteries?

So, after brainstorming about my son’s robot halloween costume, I thought it would be cool to put a few LED’s on it. I was under the impression that I could just wire one to a watch battery or somesuch, and all would be well. I only need it to last for a few hours tomorrow night (we are doing our ToT’ing on Thursday).

The problem is that it wasn’t nearly that easy.

I need a quick and dirty tip on how many AA or AAA batteries I am going to need to connect to these LED’s.

The information on the back says:

Supply Voltage: 5VDC
Forward Current: 80mA
Reverse Voltage: 0.4VDC

5mm blinking Red LED

5 volt * 20mA * 4.0mcd

I’ve got an pack of 2 green LED’s with different values

Forward (supply) voltage: 2.1 typ 2.8 max

2.1 Volt * 30mA * 630mcd
I’m stymied. HALP!!!

Use 9v batteries.

Then, for #1, which takes 5v @ 80mA, use Ohm’s law to determine the dropping resistor value:
V = IR
V = 9v-5v= 4v
I = .08A

R = V/I = 4v/.08 = 50Ω

Same for LED #2, but that’s 20mA, so
V = IR

R = V/I = 4/.02 = 200Ω

Same for LED #3

R = V/I = (9-2.1)/.03 = 230Ω

what beowulff said. And you need a current limiting resistor in the circuit if you want the LEDs to last more than a few minutes.

some of those cheaper keychain flashlights use coin cells (typically a pair of CR2016s) and rely on the cells’ internal resistance to limit current.

Putting a resistor in series with a flashing LED isn’t the proper way to limit current, because they have a built-in chip which flashes the LED and when it is off very little current is drawn, so it sees the full supply voltage, possibly damaging it; in your case, it appears that it is intended for 5 volts only (some will specify a range); you want a 5.1 volt zener diode across the LED, or perhaps a 3.9 volt zener in series (no resistor needed). Not that it really matters at this point, I guess, given the time.

Also, for the two green LEDs, it would have been better to put them in series, with a 160 ohm resistor, then they would draw only half the total current. In fact, if you had four green LEDs, you could have been fancy and put them in parallel with each other (91 or 100 ohm resistor in series with each LED, then each resistor+LED combination in parallel) and then put that in series with the 5 volt, 80 mA LED, so current draw would be 80 mA total, with only about 2 volts “lost” across the resistors (note that you wouldn’t want to do this with two flashing LEDs since they will interfere with each other, but you could put ordinary LEDs in series).

Or… just use a 7805 and be done with it. :slight_smile: $2 at RadioShack, or $0.35 from Jameco.

you need a present restricting resistor in the routine if you want the LEDs to last more than a few minutes.
some of those less expensive key chain lights use money tissues (typically a couple of CR2016s) and depend on the cells’ inner level of ability to resist restrict present.