Datasheet

2011 Microchip Technology Inc. DS41391D-page 123
PIC16(L)F1826/27
REGISTER 12-6: WPUA: WEAK PULL-UP PORTA REGISTER
U-0 U-0 R/W-1/1 U-0 U-0 U-0 U-0 U-0
WPUA5
bit 7 bit 0
Legend:
R = Readable bit W = Writable bit U = Unimplemented bit, read as ‘0
u = Bit is unchanged x = Bit is unknown -n/n = Value at POR and BOR/Value at all other Resets
‘1’ = Bit is set ‘0’ = Bit is cleared
bit 7-6 Unimplemented: Read as ‘0
bit 5 WPUA5: Weak Pull-up RA5 Control bit
If
MCLRE in Configuration Word 1 = 0, MCLR is disabled):
1 = Weak Pull-up enabled
(1)
0 = Weak Pull-up disabled
If
MCLRE in Configuration Word 1 = 1, MCLR is enabled):
Weak Pull-up is always enabled.
bit 4-0 Unimplemented: Read as ‘0
Note 1: Global WPUEN
bit of the OPTION register must be cleared for individual pull-ups to be enabled.
2: The weak pull-up device is automatically disabled if the pin is in configured as an output.
REGISTER 12-7: ANSELA: PORTA ANALOG SELECT REGISTER
U-0 U-0 U-0 R/W-1/1 R/W-1/1 R/W-1/1 R/W-1/1 R/W-1/1
ANSA4 ANSA3 ANSA2 ANSA1 ANSA0
bit 7 bit 0
Legend:
R = Readable bit W = Writable bit U = Unimplemented bit, read as ‘0’
u = Bit is unchanged x = Bit is unknown -n/n = Value at POR and BOR/Value at all other Resets
‘1’ = Bit is set ‘0’ = Bit is cleared
bit 7-5 Unimplemented: Read as0
bit 4-0 ANSA<4:0>: Analog Select between Analog or Digital Function on pins RA<4:0>, respectively
0 = Digital I/O. Pin is assigned to port or digital special function.
1 = Analog input. Pin is assigned as analog input
(1)
. Digital input buffer disabled.
Note 1: When setting a pin to an analog input, the corresponding TRIS bit must be set to Input mode in order to
allow external control of the voltage on the pin.