02-01-2012 08:45 AM - edited 02-01-2012 08:49 AM
Hello everyone,
I am trying to trying to make an intensity graph that shows the voltage on each electrode in a 64-electrode array (giving an 8x8 grid) and I am running into some problems (probably because I am pretty much a labview newbie).
To make this graph, I will have a 1D array with 64 elements, that I need to put in the correct place on the graph, so that the graph reflect the actual layout of the array.
So, I am trying to write each of the elements of the 1D array to a specific location in a 2D array. I am using the replace array subset function and a shift register for that, in a loop that needs an iteration for each element/electrode. However, for some reason, the loop only executes once.
I am using a much smaller dummy array (9 elements 1D to a 3x3 array) to get this thing working in the attached vi, but I guess the principle should be the same.
I am sure I am missing something rather stupid, but I can't figure out what
Susan
ETA: with the way I define x- and y-axes now, I guess a simple reshape array could work. But, sadly, the real input data are too messy for that.
Solved! Go to Solution.
02-01-2012 09:02 AM - edited 02-01-2012 09:02 AM
You have an 8 element 1-D array. Then you build that into a 2-D array which has 8 columns 1 row. Then you autoindex that at the For Loop which autoindexes by rows. Since you only have 1 row, it will only iterate 1 time.
Your Index Array inside with the i wired up to the index is the equivalent of autoindexing. Eliminate those Index Arrays, eliminate the Build array going from 1-D to 2-D. Let the loop autoindex on the 1-D array.
02-01-2012 09:29 AM
Thanks so much! It actually makes sense now
For future things I will refrain from such indexing overkill.
03-03-2012 07:39 AM
Hi!
Small question ... how to save in the array with shift registers summation of different values ...
Thanks!