PIC16F690DM-PCTLHS Microchip Technology, PIC16F690DM-PCTLHS Datasheet - Page 6

BOARD DEMO PICTAIL HUMIDITY SNSR

PIC16F690DM-PCTLHS

Manufacturer Part Number
PIC16F690DM-PCTLHS
Description
BOARD DEMO PICTAIL HUMIDITY SNSR
Manufacturer
Microchip Technology
Series
PICtail™r

Specifications of PIC16F690DM-PCTLHS

Sensor Type
Humidity
Sensing Range
1 ~ 99% RH
Interface
Analog
Voltage - Supply
5V
Embedded
Yes, MCU, 8-Bit
Utilized Ic / Part
MCP6291, PIC16F690
Processor To Be Evaluated
MCP6291 and PIC16F690
Interface Type
ICSP
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With
AC162061 - HEADER INTRFC MPLAB ICD2 20PIN
Sensitivity
-
Lead Free Status / RoHS Status
Lead free / RoHS Compliant, Lead free / RoHS Compliant
AN1016
DESIGN MODIFICATIONS AND
ALTERNATIVES
Possible Modifications
SIMPLE MODIFICATIONS
To produce different resolutions (pF / count), change
the R
resolution is a simple multiple of 1 pF. One possible set
of values is:
• R
• R
• R
More than one resolution in the same circuit can be
obtained by switching between several R
on the Printed Circuit Board (PCB). It is also possible
to use multiple microcontroller pins, one for each R
on the PCB. The R
have their pins set to hi-Z.
The parasitic capacitance (C
is caused by board and op amp package stray
capacitances. It is typically about 0.5 pF; the calculated
C
this amount. C
C
Many of the errors over relative humidity, supply
voltage and temperature will be consistent over time.
This makes it possble to calibrate out these errors; see
“Error Analysis”.
OP AMP INTEGRATOR WITH REDUCED
CURRENT
The circuit in Figure 6 achieves greater resolution by
attenuating the square wave (V
R
point at V
rent magnitudes I
smaller than those produced by the circuit in Figure 3.
This, in turn, produces longer integration times.
This circuit has the following key performance
numbers:
• C
• Resolution
The attenuator increases the equivalent error at V
This can be handled by using resistors with tighter
tolerances for R
resistors for low cost.
DS01016A-page 6
SEN
SEN
A1
accuracy and for stability
INT
INT
INT
, R
SEN
INT
open (0 pF).
should be corrected (have C
A2
= 6.65 M for 0.1 pF / count
= 665 k
= 66.5 k for 10 pF / count
needs to be larger than 0.6 pF for a 0.5%
DD
value. It makes the code simpler when the
and R
/2 and a gain of 0.0100 V/V. Thus, the cur-
PAR
0.001 pF / count
A3
A1
for 1 pF / count
can be measured by leaving having
INTP
, R
form an attenuator with a DC bias
INT
A2
and I
values not being used would
and R
PAR
INTM
A3
) in parallel with C
A
; Figure 6 uses 1%
). The components
PAR
will be 100 times
subtracted) by
INT
resistors
SEN
CM
INT
.
FIGURE 6:
with Reduced Current.
Other Ciruits
A quick overview of different methods to measure
capacitance is found in AN990, “Analog Sensor Condi-
tioning Circuits - An Overview” (AN990) [5]. Those
designs include an R-C decay and an oscillator.
The R-C decay method [6, 8] is very low cost and easy
to implement. It is difficult to use this method for small
capacitive sensors because of the microcontroller’s
parasitic pin capacitance and leakage currents.
It is quite popular to use a 555 timer and the capacitive
sensor to form an oscillator circuit, which works well for
larger capacitors. Smaller capacitors see greater
inaccuracies due to the 555 timer’s parasitic pin
capacitance and leakage currents. Also, 555 timers
from different vendors behave quite differently.
It is also possible to create other oscillator circuits [7].
They can be quite accurate with proper calibration, and
they can be either simple or complicated.
Note 1: C
P4
P3
100 nF
PIC16F690
C
Timer1
Comparator
2: R
Latch
1
SR
U
V
sitic capacitance. C
at the op amp’s inverting input pin to
improve the op amp’s stability and elimi-
nate any dynamic current through C
calculate C
1
REF
V
CG
INT
DD_DIG
is the sensor’s case-to-ground para-
is chosen to minimize the effort to
P1
P2
Op Amp Integrator Circuit
V
V
SEN
© 2005 Microchip Technology Inc.
MCP6291
A
SEN
1M
R
.
100 nF
A1
C
C
C
100 nF
SEN
2
CG
CG
U2
C
R
20 k
R
20 k
CM
should be placed
A2
A3
I
INT
V
V
INT
CM
R
6.65 M
R
R
V
20 k
20 k
INT
CM1
CM2
DD
CG
.

Related parts for PIC16F690DM-PCTLHS