12-12-2016 04:30 AM
Hello Everyone,
I am trying to index multiple rows and columns into 2d array
My program consists of real-time data streaming through the com ports (VISA), running in a continuous while loop. I was hoping someone could help me with the following:
1) How do I initialize a 2D array of 16 rows and 16 columns
2) How to I index this array and represents the rows and columns
3) How do i present my data over an intensity graph within specific dimensions (please check the difference between graph 1 and 2).
Most examples I find to create rows and columns of arrays use random number vi embedded INSIDE a for loop, then auto-indexing it. However how do I index my data through rows and columns. I tried to index and i know that my VI is Spaghetti, but i indexed only one row, cause when i tried to index a column the VI breaks.
I'm reading my data from Arduino UNO with 9600 baud rate.
It would be great if someone could help me out because I have tried countless ways to create my array
Thank you!
12-12-2016 04:38 AM - edited 12-12-2016 04:39 AM
Hi N.,
unfortunately I cannot open your VI because of its LabVIEW version, but the answers to your 3 questions are quite simple:
Question 1 and 2 are asking for very basic LabVIEW stuff: did you take the free online resources to learn LabVIEW?
12-12-2016 04:46 AM
GredW,
the answer for your question, i'm learning from youtube and i'm trying. but when it's coming to real time i'm having those problems.
please check the VI .
the pic represents first two questions
12-12-2016 04:49 AM - edited 12-12-2016 04:52 AM
Hi N.,
I'm limited to LV2014 (as indicated in my signature).
And before posting images of a block diagram you should use the AutoCleanup tool to unbend all those wires…
Why do you need to initialize those arrays in each loop iteration again?
i'm learning from youtube
This is bad behaviour (IMHO) - why don't you use those free lessons offered by NI?
12-12-2016 04:52 AM
thanks for your advices GredW
12-12-2016 05:03 AM
Mr. GredW,
thanks for the learning link, haven't knew about it before. i'm already in.
regarding the VI, what i'm trying is, represent each column and row in the intensity graph and that's will help me to detect the resolution.
but when i tried to do columns and rows in the indexing array, my VI start to break.
Regards,
12-12-2016 05:36 AM - edited 12-12-2016 05:39 AM
12-12-2016 06:00 AM - edited 12-12-2016 06:08 AM
GerdW
thanks for your reply, but still not working
check the attached pic please
12-12-2016 06:12 AM - edited 12-12-2016 06:13 AM
Hi N.,
LabVIEW will tell you why the run arrow is broken!
If you would use AutoCleanup more often I would be sure to spot the problem - so I can only guess.
But I'm sure LabVIEW will tell you the exact problem… 😄
12-13-2016 04:06 AM
Hello GerdW,
first of all thanks for your advices till now.
I have couple of question if you don't mind.
1- i used index array function to specify my data, but why my columns are disabled and i can't send the data to them ?
2- i build a 3rd intensity graph, through the process , this graph display the results only once, how can i make it read the data all the time similar to the 1st and 2nd graphs. ?
please check the attachment.
PS: thanks for the link regarding the labview training.
many thanks.