PIC16F870-I/SP Microchip Technology Inc., PIC16F870-I/SP Datasheet - Page 39

no-image

PIC16F870-I/SP

Manufacturer Part Number
PIC16F870-I/SP
Description
28 PIN, 7 KB FLASH, 128 RAM, 22 I/O
Manufacturer
Microchip Technology Inc.
Datasheet

Specifications of PIC16F870-I/SP

A/d Inputs
5-Channel, 10-Bit
Cpu Speed
5 MIPS
Eeprom Memory
64 Bytes
Input Output
22
Interface
USART
Memory Type
Flash
Number Of Bits
8
Package Type
28-pin SPDIP
Programmable Memory
3.5K Bytes
Ram Size
128 Bytes
Speed
20 MHz
Timers
2-8-bit, 1-16-bit
Voltage, Range
2-5.5 V
Lead Free Status / Rohs Status
RoHS Compliant part Electrostatic Device

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC16F870-I/SP
Manufacturer:
MICROCHIP
Quantity:
5 600
Part Number:
PIC16F870-I/SP
Quantity:
2 871
4.3
PORTC is an 8-bit wide, bi-directional port. The corre-
sponding data direction register is TRISC. Setting a
TRISC bit (= 1) will make the corresponding PORTC
pin an input (i.e., put the corresponding output driver in
a Hi-Impedance mode). Clearing a TRISC bit (= 0) will
make the corresponding PORTC pin an output (i.e., put
the contents of the output latch on the selected pin).
PORTC is multiplexed with several peripheral functions
(Table 4-5). PORTC pins have Schmitt Trigger input
buffers.
When enabling peripheral functions, care should be
taken in defining TRIS bits for each PORTC pin. Some
peripherals override the TRIS bit to make a pin an out-
put, while other peripherals override the TRIS bit to
make a pin an input. Since the TRIS bit override is in
effect while the peripheral is enabled, read-modify-
write instructions (BSF, BCF, XORWF) with TRISC as
the destination should be avoided. The user should
refer to the corresponding peripheral section for the
correct TRIS bit settings.
TABLE 4-5:
TABLE 4-6:
 2003 Microchip Technology Inc.
07h
87h
Legend:
RC0/T1OSO/T1CKI
RC1/T1OSI
RC2/CCP1
RC3
RC4
RC5
RC6/TX/CK
RC7/RX/DT
Legend:
Address
Name
PORTC and the TRISC Register
PORTC
TRISC
x = unknown, u = unchanged
ST = Schmitt Trigger input
Name
PORTC FUNCTIONS
SUMMARY OF REGISTERS ASSOCIATED WITH PORTC
PORTC Data Direction Register
Bit 7
RC7
Bit#
bit0
bit1
bit2
bit3
bit4
bit5
bit6
bit7
Bit 6
RC6
Buffer Type
ST
ST
ST
ST
ST
ST
ST
ST
Bit 5
RC5
Input/output port pin or Timer1 oscillator output/Timer1 clock input.
Input/output port pin or Timer1 oscillator input.
Input/output port pin or Capture1 input/Compare1 output/
PWM1 output.
Input/output port pin.
Input/output port pin.
Input/output port pin.
Input/output port pin or USART Asynchronous Transmit or
Synchronous Clock.
Input/output port pin or USART Asynchronous Receive or
Synchronous Data.
Bit 4
RC4
Bit 3
RC3
FIGURE 4-5:
Peripheral Data Out
Data Bus
Note 1: I/O pins have diode protection to V
Port/Peripheral Select
Peripheral Input
Peripheral
OE
Bit 2
RC2
WR
TRIS
WR
PORT
(3)
2: Port/Peripheral Select signal selects between
3: Peripheral OE (Output Enable) is only activated
port data and peripheral output.
if Peripheral Select is active.
RD
PORT
Bit 1
RC1
Data Latch
TRIS Latch
Function
D
D
RD TRIS
CK
CK
PIC16F870/871
(2)
Q
Q
Q
Q
Bit 0
RC0
PORTC BLOCK DIAGRAM
(PERIPHERAL OUTPUT
OVERRIDE)
0
1
POR, BOR
xxxx xxxx
1111 1111
Value on:
Q
EN
D
DS30569B-page 37
Schmitt
Trigger
uuuu uuuu
1111 1111
DD
Value on
RESETS
all other
Vss
V
N
P
and V
DD
I/O
pin
SS
(1)
.

Related parts for PIC16F870-I/SP