Electrons when moving through a wire lose energy as they move. Usually they lose this energy in the form of heat, P=I^2 R power, energy lost per second is equal to thr current squared times resistance. This is exactly how a resistive space heater heats a room. We also use this to make an incandescent bulb, we just trap that heat in until the filament is so hot that it glows with black body radiation. This is the same phenomenon that makes stars glow the color they are, and makes metal being forged by a blacksmith glow red hot, and makes lava glow as well. (See black body radiation)
This process produces a lot of heat that isn’t turned into light, and therefore isn’t useful to us, which led to fluorescent bulbs. What happens there is the current flowing into a bulb excites the electrons orbiting the atoms making up the gas inside the bulb, and when those electrons drop back down to the ground state, they release the energy they gained in the form of a photon, there’s usually some sort of phosphorescent material on the glass itself to spread out the wavelengths of light being produced, because the gas in the bulb will only produce very specific wavelengths of light. This is also how neon signs work, to get different colors, just change the gas in the bulb, neon signs containing only actual neon will always be orange. And this is also the same phenomenon that determines the color of lightning. (See fluorescence)
LEDs function in a similar way to fluorescent bulbs, but without the gas. The silicon in the LED is set up in such a way that electron passing through it have to pass through an opposing electric field, which means they have to lose energy as they pass through. That amount of energy is what determines the color of an LED. White LEDs also usually have a similar phosphorescent coat to change the wavelengths of light actually emitted, but also can have many different LEDs inside of them emitting different colors to make white.
This is where you can stop reading if I sufficiently answered you question, but I gonna keep going if you’re interested.
If you’re interested in the physics/math, voltage is electrical potential, measured in volts (V), which are Joules (energy) per Coulomb (charge) (J/C). This means if you have the voltage, you can determine the potential energy a battery has E=Vq (q being charge). And the color of the photon is determined by the energy E=hf (h being Planck’s constant and f being frequency) and since every electron passing through produces a photon, we know that hf=Ve (e being the elementry charge, the charge of an electron). Therefore, the color of an LED is determined by the voltage drop across it, and we know this voltage drop cannot change because the color of an LED doesn’t change (only V and f are variables in the equation). This is actually quite unique, because in a circuit, every voltage drop across a load must add up to the voltage of the power source. If I have a 12V battery, and a 1MΩ resistor, the voltage drop must be 12V across that resistor, but if I have 2 of those resistors in series, the voltage drop will be 6V across each one. If I hook a 3V LED to the battery, it will burn it out because of the absurd amount of current coming from that battery, because the remaining 9V of voltage drop has to happen across the wires, which have so little resistance (0Ω for our purposes, even though they aren’t superconductors). However, if I have 4 of those 3V LEDs in series, it will work fine because we have the 12V drop happening with no issues. Also, if you have too little voltage, it simply will not turn on the LEDs at all.
Latest Answers