How to monitor an IO input continuously (for momentary switch probe ...

How to monitor an IO input continuously (for momentary switch probe ...