Weak Pull-Up's are only avaialble on PortA on this PIC with the exception of RA3 which does not have one.
There are TWO STEPS to enabling the Weak Pull-Up's on this PIC...
Step 1. You must first enable the Weak Pull-Ups by CLEARING the RAPU bit in the OPTION Register (see Datasheet section 2.2)... ie...
OPTION_REG.7=0
Step 2. Then you have to INDIVIDUALLY SET the bits for each pin you require them on in the WPUA Register (Datasheet 3.3). For example if you wish weak pull ups on RA0, RA1 and RA4, then you would set...
WPUA=%00010011
Bookmarks