02-18-2009 07:24 AM
Hello,
I am new in Labview and I am studying how to measure the temperature from two Pt100 sensors using DAQ USB-6009. Does anybody could help me to configure the DAQ channel and with the VI?
02-18-2009 10:01 AM
Have you taken a look at the examples that ship with LabVIEW? There are tons of examples showing you how to do data acquisition. You probably should start off making sure you are acquiring measurements by using MAX (Measurement and Automation Explorer). With this you can access the USB-6009 and use the test panels to make sure the card is reading correctly. You can also create a task to read the two channels. This task can be used in LabVIEW directly. The MAX Help file contains the information on using the test panels and on creating tasks.
This is also a good place to get started: Getting Started with NI-DAQmx.
02-18-2009 11:35 AM
I think you also need some way to get a voltage from the sensor. Pt100 sensors are resistors whose value depends on temperature. At 0 Celsius the resistance is 100 ohms. And, the resistance is roughly proportional to the absolute temperature, or more precisely it follows a curve known as the Callendar - van Dusen curve (not sure I spelled that right).
I don't think the 6009 can read a resistance directly.
You could use a signal conditioning module that senses the resistance and outputs a voltage. This is a completely analog device; you would only need to scale the output once you have read its voltage in LV.
Or you could use a constant current power supply running at about 1 milliamp to send current through the sensor and measure the voltage across it.
You might also want to know that sensors like this are usually wired with 3 or even 4 leads, so that the resistance in the leads can be compensated for or ignored completely.
Finally, if you have a choice in what kind of sensor to read, and want to get a voltage out of the sensor directly without any additional circuitry, and if you can live with a temperature range below maybe 100 or 150 C, you could use a solid state sensor instead, like a TMP36 or an LM61.
02-18-2009 01:21 PM
Thank you for the answers.
I had already checked the acquired signal with MAX with possitive results. The two channels are readed properly from the card.
I have made a VI with the Getting started guide and I have been able to measure the voltage input from the device, but now I don´t know how to convert it into temperature. Do I have to use the van Dusen curve?
I also dont know how to plot the two channels in the same chart.
I add the VI I have created.
Thank you in advance for the help
02-18-2009 01:55 PM - edited 02-18-2009 01:55 PM
Your VI is currently setup to read only from one channel. If you want to read multiple channels then you have to
(a) Specify that you want to read 2 channels when creating the task. The Help File tells you how to specify the physical channels. For example, "Dev0/ai0:4" indicates to read channels 0 through 4.
(b) Change the DAQmx Read to read "Multiple Channels" instead of "Single Channel". This will give you an array of waveforms that you can wire directly to your graph. You will not be able to wire this directly to the thermometer indicator since that requires a scalar. You will need to index the array of waveforms from DAQmx Read to select the one you want to display on the thermometer indicator.
Note: Your VI has no loop. If you want to be running this more than one time you should have a loop so that you can run the VI continuously. Do not use the "Run Continuously" button on the toolbar.
02-18-2009 04:17 PM
I see in the Functions > Numeric > Scaling palette there is a Convert RTD vi, so maybe you should try that first to turn resistance into temperature.
Do you know how your sensor, which electrically is a resistor, is giving you a voltage? That is, can you tell how many ohms it is from the voltage signal you are getting? You must translate a resistance to a temperature.
02-19-2009 09:46 AM
Smercurio, thank you for the multiple channel help, now it works perfectly with the 2 sensor signal. I had tried it before but i forgot to change from multiple to single channel in the DAQmx Read. Now I have to convert the voltage signal from the sensors into temperatura.
Do you know how could I do it?
I have not seen the Converter RTD vi. I have tried the function but I didnt make it work in the circuit. I put it after the DAQmx Read but it didnt read any temperature in the termometer.
Help?
I add the VI. Thank you in advance
02-19-2009 09:52 AM
02-19-2009 10:32 AM
Sorry, this is the VI with the Convert RTD function
02-19-2009 11:02 AM