11-17-2015 03:36 PM
I am trying to plot the x and y location of these circles that i have obtained from the IMAQ find circles module.How is it possible to extract the data from the module and plot them? can anybody give me a suggestion?I have attched the print screen and block diagram together.
11-18-2015 04:40 PM
Hi sidh023_mun,
You can extract X and Y position for each circle from the "Circles Data" output of IMAQ find circles. Circles Data is an array of clusters, with each individual cluster corresponding to a different detected. You can use the Index Array function to pull an individual cluster out of the arry. To pull the individual elements out of a cluster, you can use the "Unbundle By Name" function. You could then plot the xy coordinates of the circles on an XY graph. I've linked a couple of LabVIEW help pages below for the funcitons I mentioned.
IMAQ Find Circles VI
http://zone.ni.com/reference/en-XX/help/370281P-01/imaqvision/imaq_find_circles/
Index Array Function
http://zone.ni.com/reference/en-XX/help/371361M-01/glang/index_array/
Unbundle By Name Function
http://zone.ni.com/reference/en-XX/help/371361M-01/glang/unbundle_by_name/
XY Graphs
http://zone.ni.com/reference/en-XX/help/371361M-01/lvconcepts/types_of_graphs_and_charts/#XY_Graphs
Regards,
11-20-2015 09:00 AM
Hi Ryan,
What connector of IMAQ find circles would link to the Index Array Function and pull an individual cluster out of it ?I was guessing the procedure has to be of such kind cause it makes sense.Then again i am very new to LabVIEW.Thanks again for the previous reply.If you can direct me to an example that might help further.
Regards,
Sidh023_mun.
11-20-2015 12:42 PM
Hi Ryan,
Another question.i kind of figured out what you said.So now i can see a very fast moving point on the xy plot but i need to see a pathline of the moving point.Is it possible?I have attched the front panel and the block diagram here.,
Thanks
sidh023_mun
11-23-2015 03:02 PM
You can try something like this if you want to add a new point to the graph each iteration:
XY Graphs are mean to plot an entire data set at once, so if you want to configure them to update with a new point every iteration, you have to build an array that gets updated with your new data point each iteration and then write that updated array to your graph. In this case, the inputs going in to the X and Y inputs of the bundle by name function would be the X coordinate and Y coordinates comming out of the unbundle by name you're using on the circle data.
Regards,