02-02-2023 07:51 PM - edited 02-02-2023 07:52 PM
Hi, I need help with the Q4 (Hardware) section of
CLAD_Exam_Preparation_Guide_using_LabVIEW_2017.pdf
This is a forum post
https://forums.ni.com/t5/Certification/CLAD-labview/td-p/4228928
that is somewhat similar, but I still don't know why there is an extra iteration due to "Elapsed Time = 0" in the first iteration.
The right answer for Q4 is (B) 2 Rows and 5 columns.
I have attached a VI that reproduces the question, which also in addition outputs the iteration and my own way to track elapsed time. 2 iterations mean 10 seconds have elapsed, not 4 seconds as the code intends, which I am confused that there is an extra iteration.
Solved! Go to Solution.
02-02-2023 08:25 PM
Wire the Elapsed Time outputs to autoindexing tunnels and look at the resulting arrays. You will see that the Elasped Time after the first iteration is 0. 0 is less than 4, so another iteration is performed. This time it will be 5, which is more than 4, so the loop is stopped.
There are two things happening here to cause this:
1. The Elapsed Time express VI resets on the first call.
2. The Elapsed Time is in parallel with the DAQmx Read; it will run pretty much as soon as the loop is started.