LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

change wavechart default variable (e.g. frequency) to the real measured data

Dear all,

 

can i please consult a question that in an VI program, if I would like to change the variables (eg from the 'default' frequency VS data point number) in the wavechart, to the real pressure/volume reading from the instrument VS elapse time

 

any advice how to do it please ?

 

 

many thanks !

 

0 Kudos
Message 1 of 9
(2,646 Views)

The "E" in the name "LabVIEW" stands for "Engineering".  In many instances, engineers record (analog) data by sampling, taking measurements at equally spaced intervals of time to approximate recording a "continuous Waveform".  Since this form of "acquired data" is so prevalent, the inventors of LabVIEW came up with a structure to represent such sampled data and called it a "Waveform".

 

Waveform charts are explcitly made for Waveforms, where the data being plotted all have the exact same "X" spacing (expressed by the parameter "dt" in the Waveform Cluster).  Examples of data in "Chart" format are oscilloscopes (the beam moves left-to-right at a fixed rate, and you see the data move the beam up and down) and a strip-chart recorder (the paper moves at a fixed rate underneath the pen being driven by the data).

 

But what if you have "real pressure/volume reading from an instrument vs. elapsed time", i.e. have both X and Y varying (with X, perhaps, always increasing, but not at a fixed "dt")?  Simple, you use a Waveform Graph, where you give the X and Y values explicitly.  Drop down a LabVIEW Waveform Graph, right-click it, and read its Help (or look up Waveform Graphs) to learn how to do this.

 

Bob Schor

0 Kudos
Message 2 of 9
(2,637 Views)

@ChrisNo17 wrote:

can i please consult a question that in an VI program, if I would like to change the variables (eg from the 'default' frequency VS data point number) in the wavechart, to the real pressure/volume reading from the instrument VS elapse time


  • You are talking about "properties" of the chart, not "variables".
  • You can label the axes anything you want.
  • Assuming that the time points are equally spaced, all you need is set the multiplier of the time axis according to the real timing.
  • If the time points are not equally spaced, use an xy graph and some code instead.
0 Kudos
Message 3 of 9
(2,626 Views)

many thanks, both !

 

so to make my question clear, I attached the snapshot (one for X- acquisition time, one for Y- pressure/volume) - the version from supplier, the properties on the wavechart are:

"

  Y: "amplitude" for both Pressure/Volume, which have no specification, 

  X: On the time axis, the results are shown depending on the sample time and the values are in sample numbers instead of absolute time

"

So my aim is to change these to the real data of pressure/volume VS time.

Please advise where the changes should be made ?

 

(Sorry I am a beginner if the question sounds basic 🙂

 

many thanks again !

Download All
0 Kudos
Message 4 of 9
(2,622 Views)

Your images are completely useless (and why are you covering most of them with right-click menus???). Please attach your VI instead. What's the loop rate (which determines dx of the chart).

0 Kudos
Message 5 of 9
(2,595 Views)

Please find the VI. file attached.

 

Many thanks,

Chris

0 Kudos
Message 6 of 9
(2,587 Views)

There is no easy way for me to find the update rate of the chart. (So many states, so many loops inside loops inside loops. I see a 5 second wait in the outer loop and e.g. a 500ms wait deeply buried in a stacked sequence inside one of the numeric states. From the outermost structure, this looks like a subVI but there are no connectors defined. Very strange....

0 Kudos
Message 7 of 9
(2,580 Views)

Many thanks though.

 

actually we only need to modify the properties that to be shown on the wavechart, I suppose somewhere around the middle wavechart, but not sure how to do it (as the image attached) ?

 

 

0 Kudos
Message 8 of 9
(2,563 Views)

The chart assumes a regular update rate (constant dt between points), but for me it is impossible to determine what that actually is by looking at your code and since some of the timing is via a control, it might not even be regular. One option would be to actually measure each update time and use an xy graph and some suitable history code.

0 Kudos
Message 9 of 9
(2,548 Views)