Datasheet
1999-2012 Microchip Technology Inc. DS40192D-page 21
PIC16C505
FIGURE 5-2: SUCCESSIVE I/O OPERATION
PC PC + 1 PC + 2
PC + 3
Q1 Q2
Q3
Q4
Q1 Q2
Q3
Q4
Q1 Q2
Q3
Q4
Q1 Q2
Q3
Q4
Instruction
fetched
RB<5:0>
MOVWF PORTB NOP
Port pin
sampled here
NOPMOVF PORTB,W
Instruction
executed
MOVWF PORTB
(Write to PORTB)
NOPMOVF PORTB,W
This example shows a write to PORTB
followed by a read from PORTB.
Data setup time = (0.25 T
CY – TPD)
where: T
CY = instruction cycle.
T
PD = propagation delay
Therefore, at higher clock frequencies, a
write followed by a read may be problematic.
(Read PORTB)
Port pin
written here