14

This question mentioned that pin 13 has a built-in resistor for the LED that comes standard on most Arduino units. A friend of mine told me that because there's already a resistor on the pin, I don't have to put one on when I plug an external LED into the pin.

This doesn't sit right with me, as I read all over the place that it's very bad to plug in an LED without a current-limiting resistor. I can't find where pin 13 is on the circuit diagram (still getting used to reading those), so I don't know how the built-in resistor is wired.

Question-in-short: Do I need a current-limiting resistor when using pin 13 for a (small) LED?

EDIT: As Polar pointed out below, a single resistor would do the trick. However, I'm really curious as to the positioning of this single (built-in) resistor. If it's in series with the header for P13, then it should limit current. If it's in parallel, I don't think so. However, my electronics knowledge isn't that vast, so I could be mistaken...

apnorton
  • 1,251
  • 3
  • 13
  • 27

2 Answers2

11

If you examine the schematics for any of the Arduino boards (other than the Arduino NG Revision C, which does not have an on-board user LED), e.g. the one for the Arduino Uno, the pin has a resistor and then the LED wired off it to ground, in parallel to the actual output pin header.

Crop from schematic

Thus, if you do not use a separate resistor in series to your own LED, there is a fair chance of damaging your LED.

Thus, yes you do need a resistor for your external LED.

Anindo Ghosh
  • 50,188
  • 8
  • 103
  • 200
  • 3
    nice diagram usage! –  Apr 10 '13 at 23:21
  • I hooked it up to a multimeter, no load, and it read 4.93v, no load. That is weird. The Arduino site also has a resistor. I had a book that said it was okay to do it just with pin 13. Never knew that. Oops. I am going to retry with a LED hooked up tomorrow. – Anonymous Penguin Apr 11 '13 at 01:46
  • @AnnonomusPerson - 4.93V sounds about right. Incidentally, you *do* have a load - the built in resistor. Measure the 5V output while you're at it. Most voltage regulators are typically only specified to be within 1-5% (it depends on the specific part) of the voltage they're specified for. – Connor Wolf Apr 12 '13 at 04:06
  • please note the latest UNO (R3) use a transitor to light up the led, so new user wont get strange result while using the pin for read/write – Lesto Mar 12 '14 at 22:26
10

Only the very early boards had a resistor on pin 13. The numerous tutorials out that there that still claim pin 13 has a resistor are just flat out wrong. No recent (well over 2 years now) Arduino has a built-in resistor on Pin 13.

Question-in-short: Do I need a current-limiting resistor when using pin 13 for a (small) LED?

ALL LEDs, regardless of size, require some form of current limiting. When the forward voltage of the LED is applied, it turns into a short circuit. A LED only drops its forward voltage. So if the forward voltage is 3volts and the I/O pin or supply provides 5volts, something else needs to drop the remaining 2volts.

A series resistor will drop the rest of the supply (or pin) voltage and limit the current running through the LED.

For higher power LEDs you would probably want to use a constant current supply so that the series resistor isn't just wasting power.

baldengineer
  • 2,021
  • 10
  • 13
  • All Uno R3's had an on board LED with a resistor. All Nanos and Pro Minis also have an on board led with a resistor. Even the clones. There are also resistors on Tx and Rx LEDs. Even in 2013. You coud also drive a LED without a resistor from the reset pin on the reset as well if you (were brave enough to) make it I/O and have a high voltage programmer to recover. – mckenzm Apr 26 '23 at 22:43
  • @mckenzm Yes, there are resistors for the ONBOARD LEDs. The external pins do not have a series resistor. So if you connect an external LED to pin 13 (or any other pin), you must include a current limiting resistor. – baldengineer Apr 28 '23 at 02:00