02-09-2007 12:59 PM
I have a real time controller is running at 4kHz, which means that every 250uSec (1/4kHz) the real time controller will be storing a data point from position (and force, output, etc.). The block size that is defined is 512, which means I will be reading 512 data points every 128mSec (250uSec * 512 = 128mSec). I want to display this data on the graph; however, I do not need to do this in real time. I can buffer this data and update the graph every 1 second if I need to. The only thing that is important is that the data waveform display correctly with a time stamp, which I can easily calculate. What type of chart should I use (i.e. ChartY, ChartXY, ChartXvsY, or something else)?
Thanks in advance the help!!
02-12-2007 12:54 PM
If you can generate the time stamp then it really depends on which function you think would do what you want the best. It's really a matter of what your goal is. You can read about each of the different methods in the documentation.
Copy and paste this link (ms-help://MS.VSCC.2003/NI.MeasurementStudio/NIVCUI/Objects/CNiGraph/Main.htm) into your browser and you'll be able to search the CNiGraph class for all the Charting functions.
You will probably need one that takes in a vector as opposed to a single point. Since you are reading 512 points off the buffer. You are on the right track with the charting though. Plotting will override your data.
Regards,