beautypg.com

Chapter 8 - thermocouple measurement, Low-level thermocouple data conversion functions, Thermocouple measurement – Measurement Computing TempBook rev.3.0 User Manual

Page 57

background image

Thermocouple Measurement

8

TempBook User’s Manual

Thermocouple Measurement 8-1

Note: The enhanced API commands do not work exactly like the standard API commands used in this chapter.

The TempBook software includes two groups of functions for obtaining thermocouple temperatures:

Low-level data conversion functions provide thermocouple linearization for previously acquired ADC
data. Functions include: tbkTCSetup, tbkTCConvert, tbkTCSetupConvert,
tbkTCAutoZero

.

High-level thermocouple measurement functions provide combined scan sequencer setup, triggering,
data collection, and linearization. Functions include: tbkRdTemp, tbkRdTempN,
tbkRdTempScan, tbkRdTempScanN

.

Both of theses function groups support types J, K, T, E, N28, N14, S, R and B thermocouples. The
TempBook accepts thermocouple attachment on differential input channels 0 through 7. In addition, the
TempBook provides a cold-junction compensation circuit on channel 16 and a permanently shorted input on
channel 18 for performing zero compensation.

Two software techniques can be used to increase the measurement accuracy: software calibration and zero
compensation. Software calibration uses gain and offset calibration constants, unique to each unit, to
compensate for inherent errors. Zero compensation is a method by which offset voltages in the input
amplifier stages can be removed at run-time. This is done by measuring a shorted channel at the same gain
as the signal measurement to find the offset, and subtracting this from the actual reading. Both of these
methods are described in the Zero Compensation and Calibration chapter.

The thermocouple linearization functions have a special auto-zero compensation feature that will perform
zero compensation on the raw thermocouple data before linearizing. This auto-zero feature is enabled by
default but can be disabled using the tbkTCAutoZero function.

Low-Level Thermocouple Data Conversion Functions

The low-level thermocouple linearization functions are designed to convert ADC data which was collected
in a specific scan sequence format.

When not using the auto-zero feature, the scan sequence should consist of a CJC reading followed by
thermocouple readings. If different thermocouple types are being read, the readings should be
grouped by type with a CJC reading preceding each group. The thermocouple linearization functions
must then be called once for each thermocouple type.

When using the auto-zero feature, the scan sequence should consist of 2 shorted channel reading
followed by the CJC and thermocouple readings. The first shorted channel reading should be taken at
the CJC gain and the second at the thermocouple gain. If different thermocouple types are being read,
the reading should be grouped by thermocouple type with two shorted channel and one CJC readings
preceding each group. The thermocouple linearization functions must then be called once for each
thermocouple type.

The scan is not restricted to thermocouple measurements. The scan may include other signals such as
voltage or digital input. The linearization functions will ignore this other data within the scan group.

The gain settings for the CJC and thermocouple types depend on the bipolar/unipolar setting of the
TempBook as specified in the table below. Note: Unipolar operations are not recommended for
thermocouple measurement unless the temperatures to be measured are guaranteed to be greater than the
TempBook temperature.

TempBook Gain Codes

Type

Unipolar Gain Code

Unipolar Gain

Bipolar Gain Code

Bipolar Gain

CJC

TbkUniCJC

50

TbkBiCJC

100

J

TbkUniTypeJ

100

TbkBiTypeJ

200

K

TbkUniTypeK

100

TbkBiTypeK

200

T

TbkUniTypeT

200

TbkBiTypeT

200

E

TbkUniTypeE

50

TbkBiTypeE

100

N28

TbkUniTypeN28

100

TbkBiTypeN28

200

N14

TbkUniTypeN14

100

TbkBiTypeN14

200

S

TbkUniTypeS

200

TbkBiTypeS

200

R

TbkUniTypeR

200

TbkBiTypeR

200

B

TbkUniTypeB

200

TbkBiTypeB

200