Professional Documents
Culture Documents
PORT B:
PORTB is an 8-bit wide, bi-directional port. The corresponding Data Direction register is
TRISB.
AllPORTB pins have a weak internal pull-up. A single control bit (clearing bit RBPU)
can turn on all the pull-ups. For port pin as output, this weak pull-up is automatically
turned off. The pull-ups are disabled on a Power-on Reset.
Four of the PORTB pins, RB7:RB4, have an interrupton-change feature. The pins
which are configured as inputs can only cause this interrupt to occur. This interrupt
can wake the device from SLEEP.
RB0, RB1 and RB2 can be used as external interrupt inputs.
RB3 can be used as the alternate peripheral pin for the CCP2 module.
Bit0 RB0 I/O TTL/ST INT0
ICSP enable
Bit5 RB5 I/O TTL/ST Interrupt on change
pin
Serial prog.
Bit6 RB6 I/O TTL/ST Interrupt on change
clock
Serial prog.
Bit7 RB7 I/O TTL/ST Interrupt on change
data
PORT C:
PORTC is an 8-bit wide, bi-directional port. The corresponding Data Direction register is
TRISC. PORTC is multiplexed with several peripheral functions:
PORTC all pins have Schmitt Trigger input buffers.
RC1 is configured as the default peripheral pin of the CCP2 module and RC2 for
CCP1.
RC4 can also be the SPI Data In (SPI mode) or Data I/O (I2C mode).
RC5 used for Synchronous Serial Port data output SDO
RC6 is used as Addressable USART Asynchronous Transmit, or Addressable USART
Synchronous Clock.
RC7 is used as Addressable USART Asynchronous Receive, or Addressable USART
Synchronous Data.
Bit0 RC0 I/O ST TMR1 oscillator output