English
Language : 

PIC18F-LF1XK50 Datasheet, PDF (245/420 Pages) Microchip Technology – 20-Pin USB Flash Microcontrollers
PIC18F/LF1XK50
21.0 VOLTAGE REFERENCES
There are two independent voltage references
available:
• Programmable Voltage Reference
• 1.024V Fixed Voltage Reference
21.1 Voltage Reference
The Voltage Reference module provides an internally
generated voltage reference for the comparators and
the DAC module. The following features are available:
• Independent from Comparator operation
• Single 32-level voltage ranges
• Output clamped to VSS
• Ratiometric with VDD
• 1.024V Fixed Reference Voltage (FVR)
The REFCON1 register (Register 21-2) controls the
Voltage Reference module shown in Figure 21-1.
21.1.1 INDEPENDENT OPERATION
The voltage reference is independent of the
comparator configuration. Setting the D1EN bit of the
REFCON1 register will enable the voltage reference by
allowing current to flow in the VREF voltage divider.
When the D1EN bit is cleared, current flow in the VREF
voltage divider is disabled minimizing the power drain
of the voltage reference peripheral.
21.1.2 OUTPUT VOLTAGE SELECTION
The VREF voltage reference has 32 voltage level
ranges. The 32 levels are set with the DAC1R<4:0>
bits of the REFCON2 register.
The VREF output voltage is determined by the following
equations:
EQUATION 21-1: VREF OUTPUT VOLTAGE
IF D1EN = 1
VOUT
=

VSOURCE+ –

VSOURCE- x
--D----A----C----21---R5----[--4---:--0---]-
+
V
SO
URC

E-

IF D1EN = 0 & D1LPS = 1 & DAC1R[4:0] = 11111:
VOUT = VSOURCE+
IF D1EN = 0 & D1LPS = 1 & DAC1R[4:0] = 00000:
VOUT = VSOURCE-
21.1.3 OUTPUT RATIOMETRIC TO VDD
The comparator voltage reference is VDD derived and
therefore, the VREF output changes with fluctuations in
VDD. The tested absolute accuracy of the Comparator
Voltage Reference can be found in Section 27.0
“Electrical Specifications”.
21.1.4 VOLTAGE REFERENCE OUTPUT
The VREF voltage reference can be output to the device
CVREF pin by setting the DAC1OE bit of the REFCON1
register to ‘1’. Selecting the reference voltage for out-
put on the VREF pin automatically overrides the digital
output buffer and digital input threshold detector func-
tions of that pin. Reading the CVREF pin when it has
been configured for reference voltage output will
always return a ‘0’.
Due to the limited current drive capability, a buffer must
be used on the voltage reference output for external
connections to CVREF. Figure 21-2 shows an example
buffering technique.
21.1.5 OPERATION DURING SLEEP
When the device wakes up from Sleep through an
interrupt or a Watchdog Timer time-out, the contents of
the RECON1 register are not affected. To minimize
current consumption in Sleep mode, the voltage
reference should be disabled.
21.1.6 EFFECTS OF A RESET
A device Reset affects the following:
• Voltage reference is disabled
• Fixed voltage reference is disabled
• VREF is removed from the CVREF pin
• The DAC1R<4:0> range select bits are cleared
 2010 Microchip Technology Inc.
Preliminary
DS41350E-page 245