LED still glowing if Pin is Off
Posted: Mon Feb 27, 2017 1:59 am
Hi Guys,
i have a problem with my new ESP8266 E12.
I only have simple circuits on the outputs with a resistor + LED on each pin (see below).
Whenever i switch on a LED it works just fine, but sometimes when i shut off the pin, the LED is not totally turned of, but it's slightly glowing, so there might still be some small current flowing threw the LED, but i don't know why.
Here is my code (Arduino):
i have a problem with my new ESP8266 E12.
I only have simple circuits on the outputs with a resistor + LED on each pin (see below).
Whenever i switch on a LED it works just fine, but sometimes when i shut off the pin, the LED is not totally turned of, but it's slightly glowing, so there might still be some small current flowing threw the LED, but i don't know why.
Here is my code (Arduino):
Code: Select all
#define PIN 13
void setup()
{
pinMode(PIN, OUTPUT);
}
void loop()
{
// Turn on LED
analogWrite(PIN, 1023);
// Hold state for 10sec
delay(10*1000);
// Turn off LED
analogWrite(PIN, 0); // ! LED still glowing slightly
// Hold state for 10sec
delay(10*1000);
}