04-24-2012 01:32 PM
I am trying to build a dynamic 3D graph system with information flowing in from a serial port. For example, to plot something like a live topographic map with live GPS coordinate and digital elevation. The longitude and the latitude are the XY of the graph and the elevation will be Z. Currently the parameters have been isolated into 3 distinct DBL values. They are then indexed into 3 different arrays and fed into a 3D plot VI. I have set the process so that a while loop is in encompassing the isolation processes and an auto-indexing tunnel at the exit of the while loop. The problem with this setup is that the indexed array is only send at the end of the while loop, thus end of the process, which prevent live plotting of the data. Is there anyway, I can get around that?
Thank you!
Solved! Go to Solution.
04-24-2012 02:51 PM
Use a Shift Register to store the data and update the data set (using build array) INSIDE the loop. (Note: Don't le tthe array grow without bounds since it will eventually kill performance).
I have done something very similar to show air speed vectors in 3-space.
Ben
04-24-2012 08:52 PM
Hi Ben,
Thank you very much for your help. Great! it's really similar to your air speed project.
However, I am fairly new to labview and still unfamiliar with shift register.
I have attached what I try to do so far, and I know it's flawed.
Would it be possible to give me an example of how to setup the process?
Much appreciated.
04-25-2012 07:31 AM
No example to offer but I may have a suggestion that can help.
If you click on the "light bulb" while the code is running you can see what data flows where and when.
If you watch your code, I think you will see that the 3D plot should be updated INSIDE the inner loop.
POst more images if you still have trouble. At first it may seem like a strange ritualistic dance trying to get the code wired up, but if you watch the message in the help window and get acquainted with the "Data Flow Paradigm" it will become easier.
Quick request:
When you get this working, I'd like to see the images. I like 3D plots.
Ben
04-25-2012 01:07 PM
Great that makes a whole lot more sense! I used a feedback node instead for esthetic purposes and it worked like a charm.
Unfortunately right now, I don't have the device yet. I am stuck with a small amout of sample data, thus you are going to see a relatively small graph.
But like you said, I can see it killing the performance as it gets bigger.
Thank you Ben!
02-01-2013 12:46 PM
So, I what would you do if you wanted to do this for large sets of data? I too am stuck with the shift register method but I really want to know how to do it right/better. Actually, I'm only w
02-01-2013 12:47 PM
I too would like to make a continuously updating graph, but I need to use fairly large sets of data. What is a better way to do this avoiding the shiftregister kill-performance?
Thanks,
Tal