Re: RGB LED



Rich Grise wrote:
On Mon, 12 Jun 2006 15:10:04 -0700, beananimal wrote:


beananimal wrote:
Rich Grise wrote:
On Mon, 12 Jun 2006 09:25:41 -0700, beananimal wrote:

I should have posted the link to the circuit

http://i67.photobucket.com/albums/h304/beananimal/circuit.jpg

beananimal wrote:
I am in need of an indicator circuit that uses an ON-OFF-ON toggle
switch to control the state of an common cathode RGB LED. THe circuit
will be used to build an indicator panel for a DIY automation project
that shows that state of the Hand Off Automatic (toggle) switch.

I have a somewhat working circuit using an PNP transistor. The ON-ON
part works perfectly by toggling the Green and Blue anodes. However
the OFF state, where the RED LED is to be lit, does not work as well.
The G and B leds continue to stay dimly lit.

I came up with this circuit through trial and error. I would like to
know what I have done wrong and how to make the circuit (or a new
circuit) work as "expected":

Switch "ON-1" GREEN lit
Switch "OFF" RED lit
Switch "ON-2" BLUE lit


I'm redrawing that, with mods - use a fixed font, like courier:

on
o----------+----------------- Blue anode
+12 --+--o off |
| o----+-----|----------------- Green anode
[D] on | |
|k | |
| | |
\e [D] [D] <- any signal diodes, e.g. 1N4148
>| |k |k
|--------+-----+
/| |
/ [47k]
| |
| GND
Red Anode

I'd pull down the base of the tranny to turn it on to make the red
one come on, then essentially short the base to +12 to turn the tranny
off for green or blue. I've added the diode in series with the emitter
to be sure that it gets turned off fairly decisively. The two diodes
are called "steering diodes" or an "or" gate. In this case, I guess
more of a 'nor'. :-)

Hope This Helps!
Rich

Thanks Rich,

I tried using diodes in a similar fashion but they didn't work (likely
because I neglected to add 47K resistor. I am eager to try your
proposed circuit and like it's simplicity. I messed around with
using a second transistor to ensure a complete turn off.. but did not
like the complexity (not to mention I was more or less just guessing at
component values).

I am very familair with gates and logic, just not how to construct them
from discrete components :)

Is the 3rd diode (the one on the emitter) to keep the voltage drop
equal in reference to the base?

Also, can a single diode (1n4148 or similar) be used to connect to
several emitters (to keep component count and board space to a
minimum?. If the avg LED current is 20ma, then I would think that 8
emitters could be tied to a single 1n4148 rated at 200ma? The
indicators will be in 3 banks of 8 (for a total of 24 switches).

Thanks again for your help!

No, the diodes have to be per switch, assuming you want each set of
three to be independent from the others.

If you want to know if _any_ of the "green" switches is closed,
however, (and leave the rest as is) then yes, you'd use a diode
for each switch, in addition to the "local" one, and tie all of
their emitters together at the "any one or more" node, which is
again, called an "or" gate.

The reason for the diode in the emitter lead is to bias the emitter up by
.7V so that when the switch is closed, the base would be reverse biased.
Without that, the transistor could still leak if it had only the diode
from emitter to base, i.e., there'd be one diode drop, and the e-b
junction would be biased right at the knee.

I also assume that your omission of dropping resistors in your schematic
means that you've either already accounted for them or the LED(s) has(have)
their own current-limiting built in.

Thanks!
Rich

Rich

I think I understand what is going in here. I can see that the
"steering" diodes are driving the base high when the switch is in an ON
state and thus preventing the transistor from conducting. I also see
that they prevent the current from traveling back to the opposite LED
on the switch. I also understand why the RED led lights when the
switch is in the off position becasue the transistors base is pulled
low relative to the Emitter via the 47K pulldown. Even after your
edxplanation the emitter diode puzzles me somewhat (excuse my ignorance
but I am 100% self taught when it comes to electronics).

After reading what your wrote several times, I am starting become
confused :)

The voltage drop across the emitter is .7 volt, so lets say 11.3 volts
to the emitter at all times. When the switch is closed, 12V travels to
the anode of an LED and through a steering diode to the base of the
transistor (where it is 11.7 volts due to the drop across the diode).
Wouldnt this make the Base and Emitter the same? I would have though

With regards to the current limiting, yes I have been placing a current
limiting resistor at the cathode of each LED (thats what that 1K
resistor at the cathode was for). I am aware that each of the 3
internal LEDs in the package draws a slightly different current, but in
this case I am using a fairly large value to keep ALL of them somewhat
dim and because only 1 is lit at a time I assumed the resistor at the
cathode would be fine, instead of a single unit at each anode. Am I
missing something here as well?

I had assumed that providing 12V to all of the switches and then using
a single diode to feed all of the emitters would provide the same
thing.

I have drawn (I think) what you have proposed in circuit3
http://i67.photobucket.com/albums/h304/beananimal/circuit3.jpg

And what I had thought would work in circuit4
http://i67.photobucket.com/albums/h304/beananimal/circuit4.jpg

As you can see each RGB LED is to indicate the state of ONLY the switch
it is associated with.

I am learning... but it is taking the patience of people like yourself.
Thank you for all of the help. Please feel free to give up any time,
as I fear that my lack of knowledge may be making this a frustrating
use of your time.

.



Relevant Pages

  • Re: About some parts on logical circuits
    ... in between you have resistors and LEDs. ... That is somewhat analogous to connecting to the emitter vs collector. ... The base current simply turns on the switch. ...
    (alt.guitar.amps)
  • Re: RGB LED
    ... that shows that state of the Hand Off Automatic switch. ... The G and B leds continue to stay dimly lit. ... Is the 3rd diode (the one on the emitter) to keep the voltage drop ...
    (sci.electronics.design)
  • Re: RGB LED
    ... the transistor could still leak if it had only ... the diode from emitter to base, i.e., there'd be one diode drop, and ... "steering" diodes are driving the base high when the switch is in an ON ... relative to the Emitter via the 47K pulldown. ...
    (sci.electronics.design)
  • Re: RGB LED
    ... that shows that state of the Hand Off Automatic switch. ... I have a somewhat working circuit using an PNP transistor. ... Is the 3rd diode (the one on the emitter) to keep the voltage drop ...
    (sci.electronics.design)
  • Re: RGB LED
    ... the transistor could still leak if it had only ... the diode from emitter to base, i.e., there'd be one diode drop, and ... "steering" diodes are driving the base high when the switch is in an ON ... relative to the Emitter via the 47K pulldown. ...
    (sci.electronics.design)

Quantcast