LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Phase Measurement

How does one display array data (Resulting Signal in your picture) on a XY Graph?
0 Kudos
Message 21 of 65
(1,710 Views)
It would be easier to display it on a waveform graph instead of an XY graph.  To display it on an XY graph you would have to generate the x values for each y value, unless the other array in each element of your array of clusters is the x values.
Randall Pursley
0 Kudos
Message 22 of 65
(1,705 Views)
Randall,
1. How does one change the X axis in a waveform/XY graph from Time to Frequency scale. Is there some F = 1/T property?
2. In you Phase vi, the output phase is a double. How can I get this to display on a waveform/XY graph? The waveform graph requires a 1-D array of double and the XY graph requires a cluster.
 
Thanks!
0 Kudos
Message 23 of 65
(1,692 Views)
Randall,
1. How does one change the X axis in a waveform/XY graph from Time to Frequency scale. Is there some F = 1/T property?
2. In you Phase vi, the output phase is a double. How can I get this to display on a waveform/XY graph? The waveform graph requires a 1-D array of double and the XY graph requires a cluster.


1.  The label is on X and Y axes are just labels and have no connection to the type of data you are displaying.  If you are displaying frequency data then go into the properties of the graph and change the label from Time to Frequency.

2.  You don't need to have your loop since the answer is just one value.
Randall Pursley
0 Kudos
Message 24 of 65
(1,689 Views)

Randall,
I am trying to save my Waveform Graph & Phase data to the same file (refer "Output Save.jpg"). The XY Graph contains both the channels A & B, but this doesn't take care of the DC Offset. I am running into this error (indicated in picture), and I am really not having any luck in debugging it so far. Also, tried using a cluster bundle (has pink output datatype) to write the Waveform Graph & Phase data to a file, but ran into the same error. I have attached the files for all the relevant VIs and will attach more VIs in the next email.

Also, how does one change I/P parameters on the fly when passing them as a string. Pls refer "Function Generator.jpg". Right now, user can set frequency/amplitude on the front panel and then run the program. I/P's are part of a string command to the Function Generator - "APPL:SIN FREQ, VOLT". Any change in I/P's while the program is running does not affect the program. User has to stop the program, change frequency/amplitude and then run the program again.

Will appreciate your feedback. Thanks!

Download All
0 Kudos
Message 25 of 65
(1,666 Views)

Randall,

Attached are some more VIs with reference to my last reply.

Download All
0 Kudos
Message 26 of 65
(1,666 Views)
A reference of the attached Waveform Graph control will work.  Replace your current graph with this one and then create a reference.

As for you other question, I have no idea how the hardware works that you are using, so I don't know why you can't change parameters on the fly.
Randall Pursley
0 Kudos
Message 27 of 65
(1,644 Views)
Here is a vi that should output the data correctly for your application

Message Edited by rpursley8 on 12-13-2005 10:14 AM

Randall Pursley
0 Kudos
Message 28 of 65
(1,641 Views)

Randall,

Thanks for your suggestions. Pls refer to the attached "Phase.jpg" file. The problem of DC Offset and writing I/P & O/P signal information to a file has been resolved. I am also writing phase information to the same file as well. I would like to have continuous phase data written to the file as against just throwing out a single value, which is the way it is set up right now. The number of phase values depends on the number of sample points set by the user (256, 512, 1024, 2048, 4096). Tried using a FOR loop enclosing the Phase VI and connecting the count terminal of the loop to the number of sample points. But this did not work. Is there a way to do this. Would appreciate your reply. Thanks.

0 Kudos
Message 29 of 65
(1,631 Views)
I guess you can

1. Get the size of one of you DBL arrays, that you are currently converting to the Dynamic Data Type and saving, using the Array Size function
2. Feed the single Phase value into an Initialize Array function using the Array Size output to set the dimension of the array.
3. Convert this new array into the Dynamic Data Type and merge it with the other two.

If you are using pure sine waves then there is not really any need to do all of this, but if you want to, this should do it.
Randall Pursley
0 Kudos
Message 30 of 65
(1,626 Views)