05-02-2012 09:29 AM
Hi guys,
I need some help with waveform chart in labview. In my code, I use a waveform chart which displays time on x-axis and motor current on y-axis. The number of samples is 100 and the sample rate is 1000. I have set the display format (x-axis) in the chart to display absolute time. However, the X axis scale does not display the actual current time. What I would like to see on the x axis is that, say I start the code execution at 10:00 am, then the x axis scale starting point should be 10:00 am and the last point on the scale should keep updating and display the current time until I stop the code execution.
Another thing I would like to see is data on the chart for a 6 hour window. Is there a way to control this by changing the chart history lenght? The default is 1024. How do I make the chart display 6 hours of data? Also I am planningto run the code for 30 days. So I need to make sure I do not run out of memory (My PC has 4GB ram). Please give me suggestions in this regard. Any help is greatly appreciated.
Thanks,
Raj
05-02-2012 10:06 AM
I assume you are going to sample .1 sec at 1000/sec rate. How many times are you going to do it during your 6 day period? Do you wan to keep all the data? How large is the chart going to be? Are you going to filter any of the data? Are you going to sample the data for display on the chart?
This will detrmine the following:
1. The size of the chart
2. The number of points on the chart
3. The size of the buffer
Everything you said is feasible under chart, but your specification is not well expressed.
05-02-2012 10:21 AM
Hi Joseph,
Apologies for the lack of details of my reqirements. Here is what I need:
1. How many times are you going to do it during your 6 day period?
I am going run the code for 30 days without pausing/stopping. I need to see data displayed in a batch of six hours for 30 days.
2. Do you wan to keep all the data?
No. I dont want to keep all the data collected in the chart buffer as I am saving the data anyways. I need to see the data for an interval of 6 hours and after the every hours, the data stored in the buffer can be cleared.
3. Are you going to filter any of the data?
No.
4. Are you going to sample the data for display on the chart?
Not sure what you mean by this. Sorry!
I hope I answered most of your questions. Can you please suggest how I can do this? Any help is greatly appreciated.
Thanks,
Raj
05-02-2012 10:31 AM
Have you looked at the chart examples? You set the chart's multiplier property to show the actual time just like the Real Time Chart example shows.
To show a 6 hour window, you need to set the min/max property or click on the max of the chart itself.
To set the history, do the math - 1000 samples/sec x 60 sec/min x 60 min/hr x 6 hr.
05-02-2012 10:42 AM
You said that you were going to do 100 samples at a rate of 1000. It seems to me that you are truncating the number of samples.
You don't specify the actual sample rate. I have been bitten by loose specifications. Is it 1000 samples / sec hour days? Are you taking a total of 100 points? If not how many times are you going to do it over a 6 hour period?
Since you specified you are using only 100 per sample time period, you are going to filter the data. Is it 1 every 10, first 100 items, average 10 samples in each block?
When you display the data, are you going to display each point of your "sample"? Do you want to average it?
Like Dennis is saying, the chart will do some kind of filtering on the data from a visual standpoint. If you use his equation, that represents 2.16e6 points. I do not there is any monitor that will display a chart linearly for that kind of rate. Using your modification is it 2.16e5 points?