LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I chose the length of the x-axis of a waveform chart?

Hi,
 
I would like to know if it is possible to chose the length of the x-axis of a waveform chart. I want to be able to chose de "start time" and "end time" of a waveform chart. As for an example, "start time" is current time and "end time" is chosen by the user.
 
Thank you
0 Kudos
Message 1 of 7
(3,761 Views)
You can use the waveform chart's X Scale property nodes (right click the chart and Create Property Node) to configure the axis (either the full cluster as in X.ScaleRange.All or the individual properties such as Minimum).

LV7 Example attached.


2006 Ultimate LabVIEW G-eek.

0 Kudos
Message 2 of 7
(3,746 Views)
I believe the following from the included examples files will do what you want. 
 
Eric
Eric P. Nichols
P.O. Box 56235
North Pole, AK 99705
0 Kudos
Message 3 of 7
(3,745 Views)
It's also important to note that the chart will only plot as many points as the history contains on the indicator at once.  You should account for that fact when the user selects the end point, as they may miss some data if the history length is not altered, should their selection be larger than your default.

Message Edited by Novatron on 07-18-2006 01:21 PM

0 Kudos
Message 4 of 7
(3,736 Views)
Also important is that once the chart has reached the history buffer length, it will start to scroll the data. So, for example, if the chart max is set for 1024 samples, at sample 1025 the beginning of the chart will display 1 and the last value in the chart will display 1026. Whether you choose to display time on the x-axis doesn't matter. It will still scroll. Now, if you want to stop acquisition after a certain amount of time, or if you want to display a window of data after acquisition is complete, then that can be done too but you'll have to explain more on exactly what you want to do.
0 Kudos
Message 5 of 7
(3,725 Views)

Thank you all for your help.

I still cannot do what I want to do! I want the time scale (x-axis) to start a the current time the data acquisition starts and end at the value the user entered. I tried using the property nodes, but I am not able to input time, it can only use numbers. I hope you will continue to help me!

0 Kudos
Message 6 of 7
(3,714 Views)
You can use a numeric control set to display relative time. The x-axis of a chart is numbers so either use a numeric control or convert a time string into a number. If for example, you want to display 1 hour's worth of data and you take a sample every second, setting xscale.max to 3600 will initially set the max to show 01:00:00. Also, be sure to set the xscale.imultiplier to match your actually sample rate. Look at the shipping example called Rea-Time Chart. It has a constant wired to the xscale.amximum but go ahead and replace it with a numeric control
0 Kudos
Message 7 of 7
(3,703 Views)