Getting Started
19
3.2.3 A/D Converter Inputs
The following sample programs are found in the SAMPLES\RCM3700\ADC folder.
AD_CALDIFF_CH.C
—Demonstrates how to recalibrate one differential analog input
channel using two known voltages to generate the calibration constants for that channel.
Constants will be rewritten into user block data area.
AD_CALMA_CH.C
—Demonstrates how to recalibrate an A/D input channel being used to
convert analog current measurements to generate the calibration constants for that channel.
Before running this program, make sure that pins 3–5 are connected on headers JP5,
JP6, and JP7. Connect pins 1–2, 3–4, 5–6, 7–8 on header JP8.
AD_CALSE_ALL.C
—Demonstrates how to recalibrate all single-ended analog input
channels for one gain, using two known voltages to generate the calibration constants
for each channel. Constants will be rewritten into the user block data area.
AD_CALSE_CHAN.C
—Demonstrates how to recalibrate one single-ended analog input
channel with one gain using two known voltages to generate the calibration constants
for that channel. Constants will be rewritten into user block data area.
NOTE: The above sample programs will overwrite any existing calibration constants.
AD_RDDIFF_CH.C
—Demonstrates how to read an A/D input channel being used for a
differential input using previously defined calibration constants.
AD_RDMA_CH.C
—Demonstrates how to read an A/D input channel being used to con-
vert analog current measurements using previously defined calibration constants for
that channel.
Before running this program, make sure that pins 3–5 are connected on headers JP5,
JP6, and JP7. Connect pins 1–2, 3–4, 5–6, 7–8 on header JP8.
AD_RDSE_ALL.C
—Demonstrates how to read all single-ended A/D input channels
using previously defined calibration constants.
AD_SAMPLE.C
—Demonstrates how to use a low-level driver on single-ended inputs.
The program will continuously display the voltage (average of 10 samples) that is
present on the A/D channels.
ANAINCONFIG.C
—Demonstrates how to use the Register Mode method to read single-
ended analog input values for display as voltages. The sample program uses the func-
tion call anaInConfig() and the ADS7870 CONVERT line to accomplish this task.
THERMISTOR.C
—Demonstrates how to use analog input THERM_IN7 to calculate
temperature for display to the STDIO window. This sample program assumes that the
thermistor is the one included in the Development Kit whose values for beta, series
resistance, and resistance at standard temperature are given in the part specification.
DNLOADCALIB.C
—Demonstrates how to retrieve analog calibration data to rewrite it
back to simulated EEPROM in flash with using a serial utility such as Tera Term.