Great, now the hardware is sorted.
On this chip there are analog functions (the ADC and comparators) on PortB, these are turned on by default.
When reading a pin that is configured as analog it will be read as low resulating in the same behaviour as before. To enable the digital functionality on all the pins add the following at the beginning of your program:
/Henrik.Code:ANSEL = 0 ANSELH = 0
Bookmarks