PIC18F-LF1XK50 MICROCHIP [Microchip Technology], PIC18F-LF1XK50 Datasheet - Page 241

no-image

PIC18F-LF1XK50

Manufacturer Part Number
PIC18F-LF1XK50
Description
20-Pin USB Flash Microcontrollers
Manufacturer
MICROCHIP [Microchip Technology]
Datasheet
20.0
The module consists of a single SR Latch with multiple
Set and Reset inputs as well as selectable latch output.
The SR Latch module includes the following features:
• Programmable input selection
• SR Latch output is available internally/externally
• Selectable Q and Q output
• Firmware Set and Reset
20.1
The latch is a Set-Reset latch that does not depend on a
clock source. Each of the Set and Reset inputs are
active-high. The latch can be Set or Reset by CxOUT,
INT1 pin, or variable clock. Additionally the SRPS and
the SRPR bits of the SRCON0 register may be used to
Set or Reset the SR Latch, respectively. The latch is
reset-dominant, therefore, if both Set and Reset inputs
are high the latch will go to the Reset state. Both the
SRPS and SRPR bits are self resetting which means
that a single write to either of the bits is all that is
necessary to complete a latch Set or Reset operation.
FIGURE 20-1:
 2010 Microchip Technology Inc.
Note 1:
SR LATCH
Latch Operation
INT1
INT1
SYNCC2OUT
SYNCC1OUT
SYNCC2OUT
SYNCC1OUT
2:
3:
4:
SRPS
SRPR
SRRCKE
SRSCKE
If R = 1 and S = 1 simultaneously, Q = 0, Q = 1
Pulse generator causes a 2 Q-state pulse width.
Output shown for reference only. See I/O port pin block diagram for more detail.
Name denotes the source of connection at the comparator output.
SRRC1E
SRSC1E
SRRC2E
SRSC2E
SRRPE
SRSPE
SRCLK
SRCLK
SR LATCH SIMPLIFIED BLOCK DIAGRAM
(4)
(4)
(4)
(4)
Gen
Gen
Pulse
Pulse
(2)
(2)
Preliminary
SR
Latch
S
R
20.2
The SRQEN and SRNQEN bits of the SRCON0 register
control the latch output selection. Only one of the SR
latch’s outputs may be directly output to an I/O pin at a
time. Priority is determined by the state of bits SRQEN
and SRNQEN in registers SRCON0.
TABLE 20-1:
The applicable TRIS bit of the corresponding port must
be cleared to enable the port pin output driver.
20.3
Upon any device Reset, the SR latch is not initialized.
The user’s firmware is responsible to initialize the latch
output before enabling it to the output pins.
SRLEN
Q
Q
(1)
0
1
1
1
1
Latch Output
Effects of a Reset
PIC18F/LF1XK50
SRQEN
X
0
0
1
1
SR LATCH OUTPUT
CONTROL
SRNQEN
X
0
1
0
1
SRLEN
SRNQEN
SRNQEN
SRQEN
SRQ pin
SR Latch Output
DS41350E-page 241
to Port I/O
(3)
SRLEN
I/O
I/O
Q
Q
Q

Related parts for PIC18F-LF1XK50