11-28-2018 09:05 AM
Hello,
I'm trying to make a function which takes an initialized array of some size, and within a while loop, creates an array such that
array[i] = total time elapsed,
where i is the current loop iteration. According to numeric indicators, the behaviour of elapsed time and iterations is correct, but nothing is ever inserted into the array. All elements are still 0. What might be wrong? I've attached my code below.
Solved! Go to Solution.
11-28-2018 09:10 AM
It's getting inserted into the array. The problem is that on the next iteration of the loop, you act on the original initialized array and the actions from your previous loop iteration were discarded. Only the last iteration of the while loop outputs the last value you inserted.
You need shift registers on those array tunnels so the results of the first loop iteration are "shifted" to the beginning of the loop and available for the next loop iteration.
I would recommend looking at the online LabVIEW tutorials
LabVIEW Introduction Course - Three Hours
LabVIEW Introduction Course - Six Hours
11-28-2018 09:13 AM
Wow, that was incredibly quick. It works as expected now, thank you! I'll take a look at those links as well.