# Overview of Open Thermocouple Detection

## Visão geral

This article intends to explain the benefits and consequences of Open Thermocouple Detection (OTD) circuitry that is often deployed with thermocouple measurement systems. It includes descriptions of how these circuits function as well as the offset errors they create and discussion (by example) on analyzing whether these errors are significant or trivial in particular applications. It also seeks to provide effective methods for avoiding or eliminating offset errors when necessary.

## A Brief Overview of Thermocouples

Thermocouples are temperature sensors made of two dissimilar metals attached as a wire. There are 8 types designated by the National Institute of Standards and Technology (NIST) with letters (J,K,E,N,B,R,S,T). These sensors work on physical properties of various metals that cause voltage on a metal to change corresponding to changes in temperature. Different metals have different temperature voltage relationships. In a measurement application, two dissimilar metals are shorted together at the sensing end of the wire. On the other end of the wires a volt meter measures the voltage created by the dissimilar metals (see figure 1). Given knowledge of the temperature at which the dissimilar metals meet the measuring instrument connectors, the voltage created by the dissimilar metals, and voltage to temperature curves for the particular thermocouple, one can solve for the temperature of the measuring junction. For more details on the physics and technique of thermocouple measurements see the application note entitled Thermocouple Measurements.

Figure 1: Example of a TC measurement

## How an OTD Circuit Functions

Thermocouples are used in many applications because they are relatively cheap, rugged, and can take accurate measurements over a wide range.  Despite these advantages, on occasion thermocouples can break. When they do break, it is possible, the thermocouples still give reasonable (but faulty) voltages at their outputs. When looking at live information or even in a data log, it can be very difficult to tell that a thermocouple was damaged or to know when the damage occurred. For this reason National Instruments employs Open Thermocouple Detection circuitry on many thermocouple devices.

In figure 2 we have an example of a broken thermocouple. This thermocouple has broken at the measurement junction. The biasing circuitry on the measuring instrument slightly pulls the positive element of the thermocouple down to the internal ground of the instrument. The biasing circuitry also pulls on the negative element. This biasing circuitry will tend to reduce the voltage of the thermocouple to approximately zero.

Figure 2: A Broken (open) Thermocouple

In some applications, zero volts is a sensible reading for the thermocouple to produce. In these applications, without physically examining the thermocouple, it would be impossible to know if a given thermocouple is still correctly connected. In some cases an open thermocouple could also result in a non-zero voltage. For example, if the thermocouple is electrically in contact with a surface that is electrically related to (not isolated from) the volt meter ground, then if the thermocouple breaks and opens up, one end of the thermocouple will be floating (and weakly tied to volt meter ground) while the other end will be tied to the voltage of the surface that the thermocouple is touching. This means that instead of measuring the thermocouple we are now measuring the common mode voltage difference between the surface the TC was measuring and the ground of the volt meter.

In order to detect open thermocouples, many of National Instruments’ thermocouple measurement instruments employ an OTD circuit to detect open-circuit faults. These circuits commonly consist of a small differential current source with a magnitude somewhere between 10nA-1000nA. This current continually flows through the thermocouple wire. If a thermocouple breaks open, the current suddenly has no place to flow and produces a large voltage in response. In the example shown in figure 3, the OTD current (IOTD) flows out of the positive terminal and into the negative terminal. If the thermocouple opens, this current source will push charge into the positive input forcing its voltage high and pull charge out of the negative input forcing its voltage low.

Figure 3: Example of an OTD Circuit

In devices that support OTD, the open condition is evidenced in the full scale data returned by the device. Some devices additionally support reading the OTD state through a method or property node. This makes it easy to quickly note when a thermocouple breaks and to pinpoint the instant of a breakage in a data log.

## OTD Induced Offset Errors

When introducing a current source such as IOTD in figure 4, there are some errors that can creep up due to parasitic properties of the thermocouple wires themselves. Since the thermocouple wires consist of two dissimilar metals (with unique resistivities), each leg of the thermocouple has a unique resistance associated with it. These resistances increase with longer or narrower gauge thermocouple wire.  Increased resistance can contribute to offsets in acquired data. The effect of the offset voltage may be negligible or critical depending on the particular measurement system.

Figure 4: Offset voltage caused from OTD current

The total offset voltage created by the detection current can be calculated from Ohms law V=I*R, as,

where RP and RN are the resistances of the positive and negative legs of the thermocouple. Whether the offset produced causes significant error depends on the accuracy requirements of the application as well as the sensitivity of the deployed thermocouple type in the range of operation.

Products with OTD functionality from National Instruments generally specify OTD current so that users can determine the impact of this circuitry on their particular system. To facilitate comprehension of the topics discussed above we will work through a couple of examples.

### Example 1 PXIe-4353 deployed with 15ft, 24AWG K-type Thermocouples, at 500-800°C

First let’s calculate the resistance of the thermocouple.  To be complete, one could refer to reference tables of resistivity by each element of the thermocouple. However, many vendors provide reference tables sorted by thermocouple type that give resistance as a function of length and gauge. Omega provides a table [1] in their catalog as well as online that shows K-type resistance per double foot (double foot means that it includes both the positive and the negative elements) as 1.490Ω at 24AWG. Fifteen feet of this wire would therefore only be 22.35Ω.

Second we need the specification of the OTD current for the PXIe-4353. OTD current is specified as 17nA when enabled.

Third, we calculate the voltage error.

Fourth, we convert this voltage error to a temperature error at the measurement temperature of interest.  According to NIST Monograph-175 [2], the sensitivity of K-type at 500°C is 42.628µV/°C. And the sensitivity at 800°C is 41.000µV/°C. It is slightly less sensitive at 800°C, so a small offset voltage creates a slightly larger temperature error at 800°C. We will use this less sensitive point to calculate the worst case temperature error given our OTD induced offset voltage.

In this case, the OTD current produces less than 1/100th of a degree Celsius of error. This is probably negligible in any thermocouple application.

### Example 2 NI-9211 deployed with 1500ft, 30AWG E-type Thermocouples, at 0-900°C

First let’s calculate the resistance of the thermocouple.  The table from the vendor specifies E-type resistance per double foot as 7.169Ω at 30AWG. Fifteen hundred feet of this wire would therefore be 10.75kΩ.

Second we need the specification of the OTD current for the NI-9211. OTD current is specified as 50nA.

Third, we calculate the voltage error.

Fourth, we convert this voltage error to a temperature error at the measurement temperature of interest.  According to NIST Monograph-175 [2], the sensitivity of E-type at 0°C is 58.666µV/°C. And the sensitivity at 900°C is 76.835µV/°C. It is less sensitive at 0°C, so an offset voltage creates a larger temperature error at 0°C. We will use this less sensitive point to calculate the worst case temperature error given our OTD induced offset voltage.

In this case, the OTD current produces more than 9°C of error even at a measurement temperature of 0°C. This magnitude of error is much more likely to cause trouble than the 1/100th of a degree of error from the first example. If an application with 1500ft of 30AWG required better than 9°C of accuracy, then some form of compensation should be used in order to reduce the effect of the offset voltage.

## Compensating for OTD Offset Errors

In most cases, the effect of OTD current is negligible. The currents necessary to provide fault detection are, after all, quite small. However in some cases, if the wires are narrow enough and long enough, and if the accuracy requirements of the measurement are strict enough, then it may be necessary to reduce the current of the OTD circuitry or the effect of the current through other means. We will discuss several ways to compensate for these errors below.

### Disable OTD

Some thermocouple measurement instruments support disabling the OTD circuit. When using devices such as the PXIe-4353 or NI 9214 the configuration step is programmatic and reduces the differential input current to less than a nanoamp. If an application does not benefit from detection of open/broken thermocouples then disabling the OTD current is the easiest way to avoid additional errors created from high resistance thermocouple wires.

### Calculate and Compensate

The effect of the detection current is to create an offset voltage when pushing against the resistance of the thermocouple wire. However, since vendors generally provide details about resistivity of their sensors, and since National Instruments generally provides specifications for OTD current, it is possible to calculate the offset voltage (as in Examples 1 and 2 from the section OTD Induced Offset Errors). This voltage error will remain constant as long as the resistance of the wire and the current from the OTD circuit remain constant.

In the processing step of converting from voltage to temperature, one can then subtract the calculated offset voltage from all measurements before converting the voltage to temperature. This method provides functional compensation along the entire range of the thermocouple sensor.

It would be incorrect to calculate the offset temperature and then subtract the offset temperature from all readings. This method would work well if the sensitivity of a given thermocouple were constant. However, sensitivity curves for thermocouples are not constant. They are not even linear. Therefore, calculating an offset temperature would only work well for a small range around the point where the calculations were made.

### Measure and Compensate

Devices that can programmatically disable/enable OTD, such as the PXIe-4353 and the NI 9214, can automatically measure the voltage offset created by OTD current pushing against the thermocouple wire resistance and subtract the readings from subsequent measurements. This removes the potentially cumbersome task of looking up various physical material properties and making calculations by hand.

First, ensure the measurement system is stable enough that measurement temperatures will not drift appreciably. Second, take a voltage measurement with OTD disabled. Third, take a voltage measurement with OTD enabled. Fourth, take the difference between the second reading and the first reading and record it as a constant. Subtract the constant from all subsequent readings before converting the thermocouple voltage readings and associated CJC readings to a temperature measurement. The method described above will work across any hardware platform and on any device that supports the ability to programmatically enable and disable the OTD circuitry.

#### NI-DAQmx Automated Compensation

NI-DAQmx 9.2 and later supports the AI.Thrmcpl.LeadOffsetVoltage property for all thermocouple measurements. This allows a user to input their own calculated or previously measured voltage offset.

And for NI-DAQmx users of the NI 9214, when using the DAQ Assistant to create thermocouple channels, the entire process of performing the compensation measurements, saving constants, and implementing the voltage subtractions for all subsequent measurements can be carried out automatically on the Device tab using the Null Lead Offset button.

#### Example Code

For examples performing these operations in NI-DAQmx, LabVIEW FPGA, or with the RIO Scan Interface see the examples below:

 NI-DAQmx \examples\examples\DAQmx\Analog Input\Thermocouple (with OTCD) - Continuous Input.vi LabVIEW FPGA \examples\CompactRIO\Module Specific\NI 9214\NI 9214 Open TC Detection Offset Compensation\NI 9214 Open TC Detection Offset Compensation.lvproj RIO Scan Interface \examples\CompactRIO\NI Scan Engine\Module Specific\Analog Input\NI 9214 - Compensation - Scan Mode\NI 9214 OTD Compensation - Scan Mode.lvproj

## Caveats

### Resistance varies with temperature

Different metals have different temperature coefficients of resistivity (TCR). Omega publishes tables [3] with these factors at various temperatures. Some thermocouples have dramatic increases in resistance when they get very hot. If only a very small section of a thermocouple becomes hot, then the TCR probably won’t matter. Just be careful to consider the fluctuations in environment that could change the resistance of your thermocouple wire if you are using high enough resistance wires to care.

### Unstable environments

Performing compensation by measuring requires that the sensors be stable. Otherwise the compensation measurement includes not only voltage offset from OTD current, but also whatever voltage change the sensor produces from measuring a different temperature in the OTD-disabled-measurement than in the OTD-enabled-measurement. Therefore the entire system should be stable when performing compensation measurements. If the deployed environment has too much variation in temperature to do these compensation measurements, try isolating the measurement junctions in an oil bath, a book, a box, or anything else that can keep the measuring junction stable during compensation.

If the deployed system cannot remain stable for a compensation measurement and it’s not practical to isolate the measuring junctions for compensation measurements, the next best option is to perform many compensation measurements and then average the results together which should reduce the effect of system noise on the calculation of compensation constants.

### OTD enable/ disable settling time

Some devices specify a waiting time required after disabling or enabling the OTD circuit and prior to taking valid measurements. Make sure to observe any required settling times for the particular instruments in use.

## References

[1] Resistivity of Thermocouple Types
http://www.omega.com/temperature/z/pdf/z049-050.pdf  (Also available in the 2010 Omega Catalog on page H-8)

[2] NIST Monograph 175 Temperature-Electromotive Force Reference Functions and Tables for Letter-Designated Thermocouple Types Based on the ITS-90, Burns, Scroger, Strouse, U.S. Government Printing Office, Washington, 1993

[3] Temperature Coefficients of Resistance of Thermocouple Types
http://www.omega.com/temperature/z/pdf/z049-050.pdf