Perhaps this is noted somewhere, but I found out the slow way that on a Teensy 3.1 ...
the delay() is needed else the digitalRead() gets a 0 instead of a 1. I have a jumper block on that pin which if not in place (grounded pin, the problem arises).
Perhaps the delay is needed due to the R/C time constant for the high value pullup.
or read the pin later in the code.
Code:
pinMode(pin, INPUT_PULLUP);
delay(microseconds or 1 mSec);
x = digitalRead(pin);
Perhaps the delay is needed due to the R/C time constant for the high value pullup.
or read the pin later in the code.
Last edited: