Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
LabVIEW-Measurements.pdf
Скачиваний:
61
Добавлен:
29.05.2015
Размер:
3.37 Mб
Скачать

Chapter 9 SCXI—Signal Conditioning

vi.lib\daq\zdaqutil.llb, to measure the amplifier offset. This VI acquires 100 measurements from the amplifier offset, designated in the offset channel input by calgnd, and then averages the measurements.

When you determine the amplifier offset, you must always use the same input limits and clock rates that you will be using in the acquisition. The Acquire and Average VI can measure the amplifier offset of many modules at once, but in Figure 9-6, it measures only one module.

Figure 9-6. Measuring a Single Module with the Acquire and Average VI

After measuring the amplifier offset, measure the temperature sensor for CJC. Both the amplifier offset and cold-junction measurements should be taken before any thermocouple measurements are taken. Use the Acquire and Average VI to measure temperature sensors, as shown in Figure 9-7. The main differences between the amplifier offset measurement and temperature sensor measurement are the channel string and the input limits. If you set the temperature sensor in mtemp mode (the most common mode), you access the temperature by using mtemp. If you set the temperature sensor in dtemp mode, you read the corresponding DAQ device onboard channel. Make sure you use the temperature sensor input limits, which are different from your acquisition input limits. To read from a temperature sensor based on an IC sensor or a thermistor, set the input limit range from +2 to –2 V.

© National Instruments Corporation

9-21

LabVIEW Measurements Manual

Chapter 9 SCXI—Signal Conditioning

Figure 9-7. Measuring Temperature Sensors Using the Acquire and Average VI

After determining the average amplifier offset and cold-junction compensation, you can acquire data using the Intermediate VIs as shown in Figure 9-8. This example continually acquires data until an error occurs or the user stops the execution of the VI. For continuous, hardware-timed acquisition, you need to set up a buffer. In this case, the buffer is 10 times the number of points acquired for each channel. Before you initiate the acquisition with the AI Start VI, you need to set up the binary-to-voltage scaling constants by using the Scaling Constant Tuner VI. This VI, available on the Functions»Data Acquisition»Signal Conditioning palette, passes the amplifier offset to the DAQ driver so that LabVIEW accounts for the amplifier offset as the AI Read VI retrieves the data. After the compensated voltage data from the AI Read VI is averaged, the voltage values are converted to temperature and linearized by using the Convert Thermocouple Reading VI, available on the Functions»Data Acquisition»Signal Conditioning palette. After completing the acquisition, remember to always clear the acquisition by using the

AI Clear VI.

LabVIEW Measurements Manual

9-22

www.ni.com

Chapter 9 SCXI—Signal Conditioning

Figure 9-8. Continuously Acquiring Data Using Intermediate VIs

Refer to the SCXI Temperature Monitor VI in the examples\daq\ scxi\scxi1100.llb for another temperature acquisition example using the SCXI-1100 module. This VI continually acquires thermocouple readings and sets an alarm if the temperature readings go above a user-defined limit.

You can use the SCXI-1100 examples with the SCXI-1122 module. Both modules have the capability to programmatically measure the

amplifier offsets, and both modules need the CJC to linearize thermocouple measurements. The main differences between the two modules include the type of temperature sensors available on their terminal blocks and the way module channels are multiplexed.

The SCXI-1100 uses a CMOS multiplexer, which is capable of fast-channel multiplexing, whereas the SCXI-1122 uses an electromechanical relay to switch one of its 16 channels. Because the SCXI-1122 uses a relay, this module imposes a minimum interchannel delay of 10 ms, which affects the maximum possible scan rate. Scanning multiple SCXI-1122 channels many times can quickly wear out the relay. To avoid this, acquire data from the SCXI-1122 module one channel at a time. Refer to the SCXI-1122 User Manual or the SCXI-1122 Voltage VI in the examples\daq\scxi\scxi1122.llb for more information about reading SCXI-1122 channels.

© National Instruments Corporation

9-23

LabVIEW Measurements Manual

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]