Lab Zero: LabVIEW Exercise with For Loop and Analog Out
A. Create a LabVIEW virtual instrument (VI) that adds up the numbers 0.1 to 1.6 (in steps of 0.3) with an initial condition on the sum of 0.15; each time another number is added to the sum, the VI will pause for 2 seconds. Show the current sum as a numeric indicator on the Front Panel of your VI: it will change once every 2 seconds while the VI is running.
B. Arrange that the current sum is used to generate an Analog Out signal on channel zero, and that your DMM (Agilent digital multimeter) shows the DC voltage from the output pin vs ground. The voltage will appear on pin 22 of your green connector board. (Where is ground for your measurement? try pin 55 or 56...) Thus every 2 seconds another voltage reading will stabilize on the DMM.
C. If you arrange that after the start of your VI with "the white arrow" the first reading on the DMM is 0 volts for at least one second, then no FTQ.
How accurate is the DMM at displaying the LabVIEW output as
How are your numbers like the Fibonacci sequence?
Each student should do Lab Zero alone. After you demonstrate Lab Zero we will ask you a "fault tolerance question", and once you answer it correctly we'll sign your scorecard. At that point, please use the text tool to enter your name and the year on the front page of your VI. Name your VI with your initials and save in the My Documents EN123_IP_201X folder...
Now you can proceed to Lab Point 5.
You will want to read about LabVIEW FOR loops, and their shift registers for iterating outputs back to be inputs on the next cycle of the loop. See pp. 69-78 of Mihura textbook, or the LabVIEW tutorial that accompanies the software installation, or the LabVIEW Users Manual on the www.ni.com website, chapter 8.
To generate an analog output go to the Data Acquisition menu on the block diagram Functions palette, then to Analog Output, and AO Update Single Channel.vi. Move that icon to your diagram. The channel identifier is a "string" variable (pink icon in String menu of the Functions palette).
The Time & Dialog menu of the Functions palette should have a delay function
you can use.
Although a printout of it should be in the lab near each computer, you can look up the pinout of the green connector card by searching for 6024E (DAQ card) on the www.ni.com website. Try the Dec. 2000 version of documentation. Or just look here!
You can test that the Analog Out channels are working properly (independent of LabVIEW) by using MAX Measurement and Automation Explorer (blue and yellow icon near LV icon on desktop).