Go Down

Topic: Pin 13 LED always on (Read 5 times) previous topic - next topic

blablatros

Thanks for replies.

@Nick - I too am measuring around 0.7V on pin 13.

@Woody - That is exactly what I did, and it does work. I just assumed that the LED would be turned off unless explicitly set to HIGH.

@Nick - putting
Code: [Select]
digitalWrite(13, LOW) in the loop without
Code: [Select]
pinMode(13, OUTPUT) in the setup does not change anything - the LED stays lit.

However, putting just
Code: [Select]
pinMode(13, OUTPUT) in the setup, and nothing else in the loop works - LED is turned off.

So, it seems that it is normal for pin 13 LED to be dimly lit. I just did not perceive it as dim - it is almost as bright as ON, TX or RX LEDs. I do not see any difference when lighting it with 5V (pin 13 set as OUTPUT and set to HIGH) or 0.7V (pin 13 in its default INPUT state).


Nick Gammon


I am able to switch it off by adding the DigitalWrite(13, LOW) in the example sketch.



@Nick - putting
Code: [Select]
digitalWrite(13, LOW) in the loop without
Code: [Select]
pinMode(13, OUTPUT) in the setup does not change anything - the LED stays lit.


Your earlier post suggested that doing the digitalWrite(13, LOW) was all that was needed.

blablatros

Sorry, I realize now that I haven't specified in my first post that I also put
Code: [Select]
pinMode(13, OUTPUT) in the setup.

---

I measured the voltage at pin 13 again, and now I am getting around 1.4V instead of previously measured 0.7V. Plugging the meter does not extinguish the LED as it did earlier, it just make it dimmer. Now I am puzzled...

BradBouton

I know this is an old topic but just encase anyone else is experiencing similar problems(This just happened on my uno last night).  I found that the UNO and other boards have an internal pull-up resistor that is disconnected by default.  If you take your finger, place it on the solder joints(on bottom of board obviously) and try to bridge the joint of pin13 and ground(may have to rub your finger around), you should begin to see some reaction from the LED if it doesn't just turn off completely.  This is where things get strange....  After observing this problem I decided to place some solder to try and permanently bridge the pin to ground.  The LED then became totally unresponsive.  I then un soldered the junction and believe it or not, after removing the solder I just put on, the board now seems to be working totally fine(which is very strange to me because I assumed it had to do with the pull up resistor being engaged, but it appears the solder could have just fallen out?????!!?!?!?!?!  Not sure)  Anyways that is how I was able to fix the problem.   Or at least it that is how it appears to be.  I haven't droped an meter on it yet but I will shortly and report my findings.

Nick Gammon

On newer Unos the LED is driven by an op-amp (LM358) which may turn on if the output is left floating.

Go Up