Removing extra pin reads

Removed a few near-sequential pin reads to reduce the chances of missing a state change due to one value being read for the compare, then a different one being stored.