Or you could have the hardware invert the pin by writing a 1 into the PIN instead of the PORT register.