LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Graph plot with time stamp

Hello All,

 

In my attached VI I am facing some issues.

 

My loop rate is 100ms and in chart plot data is not appering as per the x-scale(Time stamp). Values are just plotting in the chart without time. I am trying to implement a graph program that should show values according to time loop rate can be different. 

 

In attached VI I have chart and XY graph both. Please have a look and suggest me the valuable modifications.

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 1 of 15
(3,094 Views)

To plot the data with time stamp, refer here

 

 

Beat Regards,

Gogineni

CLAD

______________________________________________
Kudos are welcome
0 Kudos
Message 2 of 15
(3,076 Views)

Hello Gogineni,

 

Thanks for your response.

In my code if you can find that i have y as a single element not in array. To plot with array is quite simple, but here the problem is different.

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 3 of 15
(3,065 Views)

You can insert a Build array function for that element and check!!

 

 

Best Regards

Gogineni

CLAD

______________________________________________
Kudos are welcome
0 Kudos
Message 4 of 15
(3,055 Views)

Hello Gogineni,

 

Can you plese check my attached vi for your better understanding...........Smiley Very HappySmiley Wink

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 5 of 15
(3,045 Views)

Hi Himanshu,

 

Please check the attached modified VI in which the x-axis displays the current system time and see whether it meets your requirements.

 

 

______________________________________________
Kudos are welcome
0 Kudos
Message 6 of 15
(3,030 Views)

Hi Gogineni,

 

Please study the problem and check output before post any solution. Same as before check your modification output in XY Graph.

 

No change.

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 7 of 15
(3,027 Views)

Provided your timestamps are very increasing you can do that using a chart configured to use a Waveform Data type.

 

A Waveform Chart that hs the property "Ignore attributes" NOT set will plot data based on the timing info found in the waveform data.

 

If you only present a sinlge value in the "Y" array the single point will be plotted on teh graph at the time specified by the "t0" of the Waveform data.

 

By carefully controlling the "t0" values, you can control the exact time the value is plotted. It wokrs great for those widgets that do not spilt out a new value on a peridic basis. It will allow for different plots to be updated at different times if you wire it right.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 8 of 15
(3,012 Views)

In your first post you mentioned that Values are just plotting in the chart without time.

So modified only the Chart.

______________________________________________
Kudos are welcome
0 Kudos
Message 9 of 15
(3,010 Views)

Hello Ben,

 

Thanks for your valuable inputs.

I don't have waveform data from the field, its only RS232 communication and each and every 100 ms interval I am getting only one value from the device. Now in current program I am using the chart function. But the value(Y-Axis) and the time(X-Axis) sync in not proper. To avoid this i am planning to implement this using XY Graph so I develop this sample VI. Here if you browse and observer in the code I have both chart and XY graph, in chart you can see my current implementation. If you run this code for few seconds you will get some difference in Y-Axis and X-Axis values plot time difference.

 

Now If I am talking about XY graph on X axis I can send my system time with the field value to avoid this chart issue. (I am trying to implement same in XY Graph)

Today I achieve the target by done offset and some chart property settings. Now I am looking for same in XY Graph.

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 10 of 15
(2,998 Views)