-->
Page 1 of 1

A strange problem-Blue led is on after reset

PostPosted: Sat Jan 02, 2016 10:47 am
by itay231
Ok, so i connected GPIO2 to the long wire of the LED and the short one to the ground - so far, normal.

and i'm switching the LED on and off with WiFi. but when i connect the RST wire to ground in order to reset, the blue light of the esp turns on constantly and the esp is not responding anymore.

if i reset with the LED not connected, it resets normally.

does anyone know what does it mean?

i thought the LED somehow lets the GPIO2 to touch the ground directly...

Re: A strange problem-Blue led is on after reset

PostPosted: Sat Jan 02, 2016 10:55 am
by martinayotte
If you attached the LED on GPIO2 in Source mode, it won't work, since it is acting like a pull-down which prevent booting in normal mode. You can still attached an LED on GPIO2, but it must be in Sink mode and, of course, the state of the output will be reversed, digitalWrite(LED, 0) will turn ON the LED while digitalWrite(LED, 1) will turn it OFF.

Image

Re: A strange problem-Blue led is on after reset

PostPosted: Sat Jan 02, 2016 11:35 am
by itay231
martinayotte wrote:If you attached the LED on GPIO2 in Source mode


sorry but i haven't heard about source\normal\sink mode..
are you talking about esp8266 or arduino?

Re: A strange problem-Blue led is on after reset

PostPosted: Sat Jan 02, 2016 1:04 pm
by martinayotte
Those Source/Sink modes can be apply to any digital circuits, therefore any CPU.
Since GPIO2/GPIO0/GPIO15 of ESP are special pins read to determine which boot mode should be executed at powerup or reset, you need to be careful at which state they are at that time.
Read this Wiki page : https://github.com/esp8266/esp8266-wiki ... ot-Process
This means Source mode can not be use on both GPIO2/GPIO0 while Sink mode can not be used on GPIO15 ...