How can I internally pull-down GPIO3 on the ESP-01(ESP8266)? It seems to be pulled up by default
Exactly why do you need to pull it down?
There are internal pullup resistors that can be set (or unset).
What’s your application?
I’m trying to use a voltage comparator to turn the LED’s On/Off. So I’ve got the output of the comparator wired to GPIO3 of the ESP8266. On the WLED GUI I’ve set GPIO3 as a “switch” under the Macros settings. This way I can switch between On/Off based on the output of the voltage comparator
What would the input be?
The signal going to GPIO3 would be either HI or LO. depending on the state of the comparator inputs
But what is connected to it?
The input of the comparator is getting the output of a sensor that varies from 0 - 0.5VDC
If you’re just treating that input as if a pushbutton was connected, just configure it in WLED as a “Pushbutton”.
If the “sense” is backwards to what you intend (HI is LO), configure it as “Push inverted”.
If you want to treat it as a switch, configure it (whodathunk?) as “Switch”.
You don’t need to worry about whether it’s “normally” pulled up or down, that’s handled in your configuration of what you want to do when it’s HI or LO.
BTW, you probably want to put a res divider on the output of the LM358 so it doesn’t try and drive the ESP8266 past 3.3V. Things may end poorly otherwise.
Thanks for the reply. I think what ended up happening that confused me was I damaged the GPIO pin by driving it with >3.3V. I will try powering the LM358 with 3.3V instead, so the logic output cannot go above 3.3V
Yah very possibly an issue.
The pullup thing shouldn’t make any difference other than to force the '358 to drive an extra .33mA.