LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to set x-axis on chart to be Real Time

my question is how to set the x-axis on the waveform chart to match the real time.  I'm not sure to how make the question more understandable, so i'm including an attachment with screen-shot and explanation. Any suggestions?
 
thanks
0 Kudos
Message 1 of 10
(3,859 Views)
Since you already have the X axis set to time, you can simply set the start time and end time as well as increment (be sure autoscale is off):
0 Kudos
Message 2 of 10
(3,852 Views)
Hello everybody I want to know how should i set the time axis to be showing relative time i.e each time i start the program i should have 0 as my starting point Thanks in advance for your reply
0 Kudos
Message 3 of 10
(3,841 Views)
smercurio, what happen in your implementation when time is 30, 40,... minutes after the starting time.  And what type of data you use for the time/date infront of the To-Double-Conversion?
0 Kudos
Message 4 of 10
(3,835 Views)
Right click on the x axis and select formatting. Make sure absolute time is selected.
0 Kudos
Message 5 of 10
(3,830 Views)
vaib, to answer your question. Simply go to chart/graph properties>>Format and Precision: select Relative time>>Scales: set the appropriate settings.
0 Kudos
Message 6 of 10
(3,829 Views)

@locman wrote:
smercurio, what happen in your implementation when time is 30, 40,... minutes after the starting time. 

The scale will adjust based on what you set the maximum to. Are you trying to do something else?


@locman wrote:
And what type of data you use for the time/date infront of the To-Double-Conversion?

That is just a timestamp constant (under Programming -> Timing).
0 Kudos
Message 7 of 10
(3,822 Views)

smercurio i'd like to send to you a sample of how i want my time axis to be.

 run TestDeptSoftware.vi>>collect data>>Ok>>ok

pay attention to the Chart.  Notice that the Minimum displays time the VI starts and Maximum displays 25 minutes in advance.  The chart continues plotting the data until it reaches maximum then the next frame. 

it would be really great if you can provide some hints from this.



Message Edited by locman on 06-13-2008 04:20 PM
0 Kudos
Message 8 of 10
(3,816 Views)
Sorry. I thought you were talking about a graph. Missed the bit about the chart. I would suggest looking at the example called "Real Time Chart" that ships with LabVIEW. Open the Example Finder and search for "real". It displays a chart with a moving 10 second window. I'm sure you can adapt it to use minutes.

A side comment regarding your code: It could really use a spring cleaning:
  • Your excessive use of local variables is bound to lead to problems.
  • Your "FieldPoint Module Set-Up" VI is screaming to have a cluster output, or better yet an array of clusters, with each element being a station.
  • Learn about the Cluster to Array function:



  • What is the purpose of this loop:



  • A number of your sequence frames are completely unnecessary - the wires will automatically create data dependency, and therefore execution dependency. The sequence frames just hide code.

altenbach, this is your cue to chime in...


Message Edited by smercurio_fc on 06-13-2008 05:27 PM
Download All
0 Kudos
Message 9 of 10
(3,803 Views)
okay, i got it.
i need to set up the chart parameters outside of the while loop so that it does not update the time regularly.
 
thank you so much.
0 Kudos
Message 10 of 10
(3,788 Views)