Shop OBEX P1 Docs P2 Docs Learn Events
wh doesn't the order matter, LED and resistor. — Parallax Forums

wh doesn't the order matter, LED and resistor.

Jayguy5000Jayguy5000 Posts: 139
edited 2008-08-18 18:44 in BASIC Stamp
I noticed I can take the 5 volts through a resistor to the LED then to ground OR take the 5 volts to the LED then to the resistor and then to ground. Why does it work either way? doesn't that put 5 volts on the LED first and damage it? I would imagine having the resistor after the LED and before ground would be useless. Im so lost.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Actually I think Im going to add the whiskers to my tank and let it roam, just need to figure out where.

Comments

  • allanlane5allanlane5 Posts: 3,815
    edited 2008-04-01 21:41
    Well, the way voltage and current works is in a "branch". In the case of an LED and resistor in-series combination, that line is one "branch". So V = IR is valid for that "branch" -- meaning it doesn't make a difference if the current 'sees' the resistor first, or the LED first, you're going to get the same current.

    Now, if you took the resistor OUT of the branch, then yes, you'd burn up the LED, so don't do that.
  • Jayguy5000Jayguy5000 Posts: 139
    edited 2008-04-01 21:52
    ok, now lets say we made the voltage bigger and the resistor bigger...would the resistor have to go first or would it still work in this same order no matter how great the voltage as long as the resistor was in the mix to bring the voltage down to what the LED can handle.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Actually I think Im going to add the whiskers to my tank and let it roam, just need to figure out where.
  • allanlane5allanlane5 Posts: 3,815
    edited 2008-04-01 22:02
    Okay, here's the equation.

    1. A resistor is a linear device. This means, the current/voltage curve of the device is a straight line. The slope of this line is the resistance of the resistor.

    2. The LED is a non-linear device. This means, the current/voltage curve of the device is not a "linear" relation, like the resistor. In fact, it looks sort of linear, until you reach 1.4 volts, at which time the voltage stops rising, while the current continues to rise. What this means is, if you TRY to put 5 volts across a single LED, the LED voltage will rise to 1.4 volts, then the current will try to go to infinity (or more than 25 mA, which is the burn-out current of the LED) and the LED will then act like a fuse, and burn out.

    So, we MUST put some linear element in that branch to limit the current through the LED.

    So, ok, we have a branch with an LED, and a resistor in it. When the voltage goes on, the LED will drop its 1.4 volts. So the resistor must 'drop' the rest of the voltage, at a current low enough not to damage the LED.

    So V = IR, means I = V/R. V == 5 volts - 1.4 volts == 3.6 volts that the resistor must 'drop'. If we pick a 470 ohm resistor, 3.6 volts / 470 ohms == .00766 Amps, or 7.66 milliamps through the branch (through the LED, AND through the resistor) -- which is good.

    If we pick a 220 ohm resistor, we get 3.6 volts / 220 ohms == 16 milliamps. Which is okay, but probably 9 milliamps more than we really need to light the LED.

    If we pick a 120 ohm resistor, we get 3.6 volts / 120 == 30 mA, which absolutely WILL burn out the LED.

    *****************************
    Okay, if you make the voltage BIGGER, then still 1.4 volts will be dropped across the LED, so V_Bigger - 1.4 volts / Resistor == the current. Pick a Resistor value to keep "the current" result between 7 and 16 mA, and your LED should be protected.

    And this analysis works, no matter what order the LED and Resistor are placed into the circuit, as long as they're in series with each other.
  • Mike GreenMike Green Posts: 23,101
    edited 2008-04-01 22:52
    Think of electrical current the same as you might think of water current, with a hose representing a wire, an elevated water tank as the battery and ground being literally the ground. A resistor is a constriction (like a partially open valve) in the hose and you can probably come up with something that does a useful task with water flow that takes the place of an LED. Then ask your question again and the answer may seem more intuitive.
  • Adrian SchneiderAdrian Schneider Posts: 92
    edited 2008-04-02 07:36
    physically "current" means "moving charges", negative charges move from negative to positive pole, positive charges move from positive
    to negative pole. In a typical conductor the negative charges are free electrons, positive charges are the positive "holes" left behind by the
    displaced electrons. Both flows occur at the same time. Thus the conception of current flowing "first" through the resistor "and then" through the LED -- or the other way -- is just false.
  • beazleybubbeazleybub Posts: 102
    edited 2008-08-18 18:44
    Think of it as if you had your car stuck in some deep sand.

    It would be just as hard·to move the car forward·as it would be to move the car in reverse.

    The resistance caused by the sand dragging against the bottom of the car would prevent the cars energy from moving the car quickly.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    How can there be·nothing? Nothing is something!
Sign In or Register to comment.