-->
Page 1 of 1

[ESP-01] How to use both GPIO pins? (Pull up resistors)

PostPosted: Tue Nov 29, 2016 2:31 pm
by Cam Nealie
Hey everyone

Can someone point me in the right direction to learn about what circuit I need to make, to have GPIO0 high on startup, but then use it as an output pin?

I've attached two LEDs to each pin - but of course, when I start up, it's going to boot into flash mode! If I attach two resistors to the circuit, they'll go through the diodes before going through the pin...

As far as I can tell, I'm trying to place a pull-up resistor on an output pin. Right?

Re: [ESP-01] How to use both GPIO pins? (Pull up resistors)

PostPosted: Wed Nov 30, 2016 9:16 am
by martinayotte
Since GPIO0/GPIO2 need PullUps for boot mode, I can not connect LEDs in normal Source mode like other GPIOs, you need to connect them in Sink mode and still need PullUps in parallel with LEDs circuitry.
Of course, the LEDs will react with inverted logic state, meaning that a LOW on GPIO will make LED turned ON.

Image

Re: [ESP-01] How to use both GPIO pins? (Pull up resistors)

PostPosted: Wed Nov 30, 2016 12:42 pm
by rudy
The above LED resistor connections are illustrative. The +5 volts is if you were using a CPU that was powered by 5 volts. In the case of the ESP8266 the voltage that you use is the +3.3 volt supply voltage. Do not connect to 5 volts.

Re: [ESP-01] How to use both GPIO pins? (Pull up resistors)

PostPosted: Wed Nov 30, 2016 2:21 pm
by Cam Nealie
Ahhhhhh I didn't think of current going in as the switch.

Thanks guys, that is a big puzzle piece that fell into place there!