User manual
Firmware Description
© 2006 Microchip Technology Inc. DS51609A-page 15
In disabled mode, ZERO
CAL
is not subtracted per Equation 3-1. When displaying the
direct ADC value (units = ADU), the output is simply the decimal representation of
ADC
VAL
. If zero calibrate is enabled, then ZERO
CAL
is subtracted before the value is
displayed.
Pressing the HOLD button freezes the LCD display to allow for viewing in fast sampling
modes (less averaging). Pressing the HOLD button again will resume normal
operation.
3.2.2.2 CHANNEL SELECT
In this menu, the user has control over which channel is being sampled. There are four
options. Pressing either F1 or F2 cycles through these options:
Channel 1 Normal
In this mode, the PIC16F877 samples the MCP3551 on channel 1. The LCD text above
F2 will display “1N”. In the normal mode, the analog switches on this channel are set
to the “positive” polarity. Refer to Chapter 2. “Hardware Description” for more
description on the analog switch sampling.
Channel 1 Inverted
In this mode, the analog switches set to reverse polarity, and the inverted ADC sample
is displayed on the LCD display. The LCD text above F2 will display “1I”. Refer to
Chapter 2. “Hardware Description” for more description on the analog switch
sampling.
Channel 1 Switched
In this mode, the PIC16F877 is switching back and forth between positive and reverse
polarity and the averaged value is displayed on the LCD display. The LCD text above
F2 will display “1S”. Refer to Chapter 2. “Hardware Description” for more description
on the analog switch sampling.
Channel 2
In this mode, the PIC16F877 is sampling channel 2. This channel is the high gain circuit
using amplifier CS3002. The resulting code is displayed on the LCD display.
3.2.2.3 UNITS
There are three units: A/D Units (ADU), grams (g), or kilograms (kg). When in this
menu, pressing either F1 or F2 will change the text to the right of the numerical output
to the proper unit and also display the appropriate representation of the A/D sample.
3.2.2.4 AVERAGING
In the averaging menu, the user can select how many samples are collected before the
value is applied to the LCD output. This averaging applies all sampling situations, i.e.
when calibrating zero, full scale, or displaying the output after calibration. The user can
select between 1 (no averaging), 2, 4, 8, or 16 averages. The output noise of the
system will be reduced by the square root of the number of averages per the equation
below.
EQUATION 3-2:
MCP3551 Output Noise
2.5 µV RMS
N
-----------------------------=
Where:
N = the number of conversions