Nevermind. My code was correct: PORTF = B11111110; set A0 Low; A1-A7 High PORTK = B11111110; set A8 Low; A9-A15 High