LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

multiple time-synched graphs

I want to create three graphs, stacked vertically, to display up to 9
channels of a/d data. The problem I've always had in trying something like
this is keeping all three graphs absolutely time synched (to within one
sample).

I'm about to attempt to actually simulate these three graphs by placing them
all on one giant graph, adding offsets to my signals for vertical
separation, and creating 3 false axes. This should eventually work, but it
seems like a real patchwork solution.

So, is there any way to try to lock the x-axes on three graphs such that
they are all the same?

Thanks,
Scott
0 Kudos
Message 1 of 4
(3,055 Views)
Scott Seidman (ScottSeidman@mindspring.com) wrote:
$ I want to create three graphs, stacked vertically, to display up to 9
$ channels of a/d data. The problem I've always had in trying something like
$ this is keeping all three graphs absolutely time synched (to within one
$ sample).

Doesn't that essentially mean you have to redraw the graphs at the same
time? I can see this being done by replotting after each datapoint is
acquired OR by putting them into a sequence box. In either case however
the time spent drawing the plots would be prohibitive!

$ I'm about to attempt to actually simulate these three graphs by placing them
$ all on one giant graph, adding offsets to my signals for vertical
$ separation, and creating 3 false axes. This should eventually wo
rk, but it
$ seems like a real patchwork solution.

$ So, is there any way to try to lock the x-axes on three graphs such that
$ they are all the same?

So is autoscaling the problem? You can actually create property nodes
for the graphs and manually (via the VI) set the X scale ... and set it the
same for all graphs.

Rudolf
0 Kudos
Message 2 of 4
(3,055 Views)
Thanks for your input.

Perhaps I can explain things another way. I have three graphs. Lets say I
want my X axes locked to display 20 sec of smoothly-scrolling streaming
data. Eventually, the x-axes on the graphs will start to differ. Though all
are displaying 20s cf data, they are not displaying the same 20s.

I indent to put 3 traces on each graph, just to be able to interpret data in
near real time. If I put all nine traces on one plot, there wouldn't be a
problem--there would only be one x-axis. However, it would be confusing to
look at. Of course, I can simulate three graphs by adding appropriate
y-offsets, but that's a tedious solution, and I would have to create some
sort of "psuedo-scale" so I would be able to interpret a screen like that.
Autoscaling doesn't enter into it.

"Rudolf Potucek" wrote in message
news:90ljrs$1i4m$2@nserve1.acs.ucalgary.ca...
> Scott Seidman (ScottSeidman@mindspring.com) wrote:
> $ I want to create three graphs, stacked vertically, to display up to 9
> $ channels of a/d data. The problem I've always had in trying something
like
> $ this is keeping all three graphs absolutely time synched (to within one
> $ sample).
>
> Doesn't that essentially mean you have to redraw the graphs at the same
> time? I can see this being done by replotting after each datapoint is
> acquired OR by putting them into a sequence box. In either case however
> the time spent drawing the plots would be prohibitive!
>
> $ I'm about to attempt to actually simulate these three graphs by placing
them
> $ all on one giant graph, adding offsets to my signals for vertical
> $ separation, and creating 3 false axes. This should eventually work, but
it
> $ seems like a real patchwork solution.
>
> $ So, is there any way to try to lock the x-axes on three graphs such that
> $ they are all the same?
>
> So is autoscaling the problem? You can actually create property nodes
> for the graphs and manually (via the VI) set the X scale ... and set it
the
> same for all graphs.
>
> Rudolf
>
>
0 Kudos
Message 3 of 4
(3,055 Views)
> Perhaps I can explain things another way. I have three graphs. Lets say I
> want my X axes locked to display 20 sec of smoothly-scrolling streaming
> data. Eventually, the x-axes on the graphs will start to differ. Though all
> are displaying 20s cf data, they are not displaying the same 20s.
>
> I indent to put 3 traces on each graph, just to be able to interpret data in
> near real time. If I put all nine traces on one plot, there wouldn't be a
> problem--there would only be one x-axis. However, it would be confusing to
> look at. Of course, I can simulate three graphs by adding appropriate
> y-offsets, but that's a tedious solution, and I would have to create some
> sort of "psuedo-scale" so I would be able to interpret a screen like that.

> Autoscaling doesn't enter into it.
>

Assuming that you really want a chart with nine traces and
three Y scales each with three plots, then do the following.
Drop one chart, not a graph. Popup and make it stacked
rather than overlayed. Make your data into a 2D array using
a build array node. Wire the 2D array to the chart. Grow
the legend of the chart to show three plots. This will
also grow the chart to have three scales and three plot areas.

You can now hide the legend if you like and set the different
plots to the correct plotting area using attributes per plot.

In otherwords, the best way to have the charts update as one
is to make them one. You could also leave them as separate
charts and have them update in the same loop so that they will
always have the same number of points, or in some other way
synchronize the loops they are in using the semaphore VIs.

Greg McKaskle
0 Kudos
Message 4 of 4
(3,055 Views)