PIN16 Still Reading High When Normally Closed Switch is Open

I have a normally closed contact switch between PIN16 and PIN17 (PIN17 is 3.3V, and PIN16 is set as input). When the switch is open, PIN16 still reads high instead of low.

What could be causing this? Is it related to pull-up/down resistors or GPIO configuration?

Thanks!

Please try a pull-up resistor not a power supply directly.

Hello,should I connect an external pull-up resistor to PIN16?Thanks

Yes, a pull-up on PIN16 is recommended.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.