RGB LED HELP!

Hi

I help with the programming for an RGB led.
The problem is, unlike other LED's I have seen, it only has two prongs....... so i have no idea how to program each individual colour. I know it is an RGB because when its at maximun voltage, it flashes all these colours by itself, so Im a little confused.

2 lead RGB LED's dont exist. you would have to have an led with 4 leads for it to be a RGB LED. one lead for each color and a common anode or cathode. Unfortunatly you have a single color LED.

Or possibly a two-color LED, I think they make for instance red and green LEDs in one package connected in reverse parallel.

Well my LED has two pins, and uses three colours....... which is why Im so confused

2 lead RGB LED's dont exist.

But they do on ebay.
Not controllable RGB LEDs, but LEDs with built-in blinker ICs.

CameoCream:
Well my LED has two pins, and uses three colours....... which is why Im so confused

Perhaps you have a datasheet or a link to the part that you could share. There are literally millions of different LEDs out there, so it's pointless speculating about which one this happens to be.

No I don't sorry. U just needed an RGB for Uni, and they gave me that one....... so I dunno. I think I'll buy a proper one to save myself the time.

U just needed an RGB for Uni, and they gave me that one

So if they are expecting you to control it with an arduino all you can do is turn it on or off. I think either your Uni made a mistake, or they are idiots.

I know this is an old thread but I just wanted to point out that the previous posters are incorrect in that there are multicolored LEDs with only 2 leads.

bobbintb:
I know this is an old thread but I just wanted to point out that the previous posters are incorrect in that there are multicolored LEDs with only 2 leads.

Care to point one out? Specifically what the original poster wanted, an RGB LED.

I would assume that the OP wanted to do something besides watch it flash?..?
Unfortunately ALL the 2 wire RGB LED''s DO IS FLASH... Great attention getters though, nice for overcurrent alarms.

Bob

You'll also find a lot of "phototransistors" with only 2 leads, on ebay.

michinyon:
You'll also find a lot of "phototransistors" with only 2 leads, on ebay.

What relevance is that? Most photo transistors only have two wires.

How can you have a transistor with only 2 wires ? Transistors have 3.

I suspect that these alleged 2-wire transistors, are actually diodes.

Because the base is not brought out but is just recieving a photo current. Photo diodes work and are connected in your circuit a diffrent way.

I can remember seeing just what the OP was talking about years ago, probably like 10 years ago. They are multicolored LEDs along with a bit of logic that makes them blink, sometimes in different patterns. You can't do anything but turn them on or off though since they only have power leads. I don't think you even need a resistor.

And as mike says, photransistors don't need the base lead. That's what the window is for. One kinda interesting (I think anyway) thing about phototransistors is that you can use an NPN on top of the load without worrying about supplying the correct voltage to the base. The light will turn it on anyway.

For as long as I have been in this industry I have wondered about the photo-transistor emitter follower quandary or the absolute requirement of the base bias to exceed the emitter voltage. Only answer I could figure was that it was the energy of the photon that was the deciding factor... Still doesn't quite add up however.

Bob

Docedison:
For as long as I have been in this industry I have wondered about the photo-transistor emitter follower quandary or the absolute requirement of the base bias to exceed the emitter voltage. Only answer I could figure was that it was the energy of the photon that was the deciding factor... Still doesn't quite add up however.

Bob

No it is not that.
In an emitter follower the base current is supplied by the same circuit as the transistor is connected to. Therefore the base has to be referenced at 0.7V higher that what you want the emitter to be.
With a photo transistor the photons create the electron hole pairs in the base causing the current to flow. Therefore that current is not subject to the reference voltage of the emitter. In effect the injected current is floating and therefore the voltage the emitter can reach is not limited by the voltage on the base because there is no voltage causing that current flow.

You should search on Google: “RGB LED fade algorithm”.
I tried to experiment with the RGB myself but didn’t relise that its so much more difficult than i thought it would be.