Just use the ADC to measure the voltage on the pin and decide in software what is a high and what is a low.