I have ESP8266 NodeMCU V3 board, I defined GPIO2, GPIO14, GPIO12 as input and set to LOW in setup function, but when I read state of these GPIO they always give HIGH, I read that these are set to HIGH by board after bootup.
Please not I have used all other GPIO, and they are working, so only these two are available.
My question is what to do to use these GPIO as input?
When an ESP8266 pin is defined as INPUT, it is in floating mode, that is, it has no level defined.
Setting a pin that is in INPUT mode to LOW turns off the PULL_UP resistors, and this mode is the default for an INPUT pin.
If you set it to HIGH, then yes, you connect the PULL_UP resistors at the inputs, and then the pin has HIGH values.
But if you vary this input to LOW through some pulse or external circuit, it will go to LOW.
See this tutorial: Arduino INPUT_PULLUP Explained (pinMode) - The Robotics Back-End
In this case I am planning to switch to arduino than ESP8266.
I have two digital inputs to check, two analog sensors input, two relay to operate and connect Reyax RYL998 lora module to send data to gateway, is my choice of choosing Arduino solve all inputs?
I think so.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.