leds and bs2
rr
Posts: 63
is it bad to run 2 leds of of one pin on a bs2? i know it might be an issue with the 20ma limit.
do the leds just take what they can get or will it damage the board?
can i exchange a resistor for another led.
i am looking for more powerfull light source that i can control with a digital (solid state) potentiometer
do the leds just take what they can get or will it damage the board?
can i exchange a resistor for another led.
i am looking for more powerfull light source that i can control with a digital (solid state) potentiometer
Comments
And you bring up a good point about exceeding the 20 mA limit of the BS2. If memory serves me correctly.
There is a very simply solution however. Use a 2n304 transistor in an emitter follower configuration. This will reduce the BS2 output current on the particular output pin to less than one milliamp.
Selection of the current limiting resistor is done with ohms law.....R = V/I
The value of V is the stamp output voltage when high (5v) minus the base emitter voltage drop (~0.6) minus the SUM of the forward voltage of each LED.
Example.....If you want 20 mA through both LEDs, and assume the forward voltage of each LED is ~ 1.8 volts, then V = 5 - 0.6 - 3.6 = 0.8 volts
0.8 volts divided by 20 mA = 40 ohms (0.8/0.02 = 40)
See attached diagram
Post Edited (KenM) : 1/3/2005 2:16:50 AM GMT
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Dallas, TX· USA
For stamp protection in case of a short to ground on the base lead, yes, a resistor is needed. For function, a resistor is not needed.
Looking back at some data I took for an emitter follower configuration, I offer the following:
Collector connected to 5 volts (measured 5.11)
Base connected directly to 5 volts (measured 5.11)
Emitter has one LED and a 100 ohm resistor connected in series to ground
Emitter voltage measured 4.41 volts
Emitter current measured 22.7 mA
Base current measured 105 uA
hfe of the 2n3904 calculates to 216 at this current and room temperature, which is a reasonable hfe for a 2n3904
Post Edited (KenM) : 1/2/2005 4:11:36 PM GMT
Jon didn't say a resistor was needed for proper function. Perhaps he should have said for protection, a resistor is a good idea.
In any event, for the original poster's education, an LED is a neat device.· When powered, it drops about 1.4 volts across itself, but it will take all the current available -- even to its own destruction.· So you MUST have a current limiting resistor in there with the LED.· Typical 'good' lit currents is 10 mA, but there are ultra-efficient LED's that work on 3 mA.· 30 mA will burn out most LED's if held on for more than 10 mSec.
Now, a BS2 will drive ONE pin to 20 mA, but that's about it.· If you really want bright LED's that won't destroy your BS2, you should use one of the external driver circuits mentioned above.
Post Edited (allanlane5) : 1/3/2005 2:51:12 PM GMT
Typically for high brightness LEDs you'll find two different ranges of forward voltage (at 20mA).
For Reds and Ambers (AlInGaP technology), a·typical Vf is in the range of 1.7 to 2.3 V.
For·Greens, Blues·and·Whites (InGaN technology), a·typical Vf is in the range of·3.3 to·4.0 V.
Check the spec sheets for your chosen LEDs.· Brightness and color vary and most manufacturers use a binning scheme to group LEDs of similar properties.· Stuff you buy on ebay is all over the place.
BTW white LEDs are created by coating a blue LED die with phosphor.· Some manufacturers will supply a spec sheet for a blue LED when you ask for white.
Chris Isaacson