JohnQPublic Posted August 4, 2017 Share Posted August 4, 2017 I have a small C program where a GPIO pin on Orange Pi is polled using digitalRead. It works fine and detects HIGH and LOW as expected. When I put a dupont wire with nothing connected at the other end (ie. just extend the GPIO pin) digitalRead starts registering intermittent HIGHs and LOWs wildly. What the heck am I seeing? I have a Raspberry 3 nearby and it does not show this phenomenom. Using digitalWrite on the pin works as expected. Link to comment Share on other sites More sharing options...
martinayotte Posted August 4, 2017 Share Posted August 4, 2017 Did you use either internal PullUp or external PullUp to 3.3V ? If not, the wire is acting as an antenna with random states. 1 Link to comment Share on other sites More sharing options...
Recommended Posts