LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to adjust the scale of a waveform chart

I'm new using labview, and I try to understand several post about this topic but I'm don't understand it so well. I have this three graphs that I receive from a sensor:

 

 

capture 16.png

I would like that every graph has zero in the middle and that the new values taken by the sensor appear in the middle of the graph, since these appear generally in the end and are more difficult and late to observe. This data are dynamic, so I don't know how I can set up this parameters. 

 

And the other hand the graph Y are in reverse order!! , how I can fixed that? 

 

Let me know if I'm not clear. 

0 Kudos
Message 1 of 7
(7,432 Views)

You can set the range with property nodes. If you set the ymin to -Max(abs(Y)) and the ymax to +Max(abs(Y)), the zero will be in the center. It is sufficient to set the property only when Y(max) changes. Also make sure to disable Y auto-scaling, of course.

 

You can use the "ptbypt min&max" matched to the chart history length. No need to constantly get the history data.

 

(The axis will flip depending on what edge value you enter manually, but if you set them as described, the problem will not occur.).

(If you would attach your code, we could show you in more detail)

0 Kudos
Message 2 of 7
(7,390 Views)

@altenbach  

You can set the range with property nodes. If you set the ymin to -Max(abs(Y)) and the ymax to +Max(abs(Y)), the zero will be in the center. It is sufficient to set the property only when Y(max) changes. Also make sure to disable Y auto-scaling, of course.


I'm sorry but I'm new using Labview, and I don't understand you so well, when you say Max(abs(y)) is you way to say me that I must set up in the  property node the max value that I will measure in the Y axis?, if that so, that's a problem becouse I don't really know what it is that value :s . Or Max(abs(y)) is some type of function?? Can you tell me where is it? or how I can make the code that you try to explain me? 

 

This is my code capture 19.pngIn the other hand, I try to integrate the value of the gaphs, I do it with the accelaration of X that I have and give this result: 

capture 20.png

 

Seems well, except that  when I stop the program apeear some stranger horizontal line in the middle, when I do this graphs I stop the program two times and for that I have 2 horizontal lines that are saying above, you can see it better here: 

capture 21.pngcapture 22.png

 

Well I think that this graph can work if I don't stop the program. But what I really want is to scale the velocity in its real units that I want that ware mm/s, not in that units that have, How I can do that conversion?, I will like do it that with the acceleration too maybe in mm/s^2  

0 Kudos
Message 3 of 7
(7,368 Views)

Attach your vi.

0 Kudos
Message 4 of 7
(7,365 Views)

I would appreciate if you can adjust and change the units of the graphs... 

0 Kudos
Message 5 of 7
(7,354 Views)

Maybe this simple draft can give you some ideas.

 

 

0 Kudos
Message 6 of 7
(7,347 Views)

I already explained how to scale your data in this thread. But I was wrong about the bitness, this module does indeed put out 16bit data as evidences by the magnitude of the raw data (>1024) and the datasheet of the device. The calculation is left as an exercise for the reader.

0 Kudos
Message 7 of 7
(7,342 Views)