LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to find average time taken by the data?

Hi prabesh,

 


@prabesh99 wrote:

Could you please help me to solve this problem?


Yes, I can help: implement my latest suggestion!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 31 of 42
(1,038 Views)

Dear Gerdw,

Thank you for your response.

yes, I did your latest suggestion but it did not work. 

0 Kudos
Message 32 of 42
(1,032 Views)

the latest version is found here, but not in your VI...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 33 of 42
(1,028 Views)

Dear GerdW,

Sorry to bother you again. I did what you told me to do, but it did not work again. I got the repetitive data and if I vary the sample length I got the same data. I have attached the Lv2017 as well as a pic.

thank you

Screenshot (58).png

0 Kudos
Message 34 of 42
(1,005 Views)

Dear Gerdw,

 

I found a snippet on the community, and it works well. However, Whenever I run for the second time this VI, I got previous as well as new data. How can I remove previous data?

I have attached the LV2017.

 

Thanks in advance

0 Kudos
Message 35 of 42
(998 Views)

Hi prabesh,

 


@prabesh99 wrote:

I did what you told me to do, but it did not work again.

I got the repetitive data and if I vary the sample length I got the same data.


Ofcourse you will get repetitive data: you wanted a new average value after each "sample length" samples! So when you set that to 100 then you get 100 times the same value, then a new value for the next 100 samples!

When I change the "sample length" to 10, then I get a new value each 10 iterations:

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 36 of 42
(991 Views)

Hi prabesh,

 


@prabesh99 wrote:

I found a snippet on the community, and it works well. However, Whenever I run for the second time this VI, I got previous as well as new data. How can I remove previous data?


Clear any shift registers.

Clear the chart history…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 37 of 42
(986 Views)

Hi Gerdw,

thank you for your message. I cleared the chart and shift register too but still, the previous data has been replaced yet by a new one.

Thank you

0 Kudos
Message 38 of 42
(982 Views)

Hi prabesh,

 


@prabesh99 wrote:

NOW: I cleared the chart and shift register too but still, the previous data has been replaced yet by a new one.

BEFORE: Whenever I run for the second time this VI, I got previous as well as new data. How can I remove previous data?


First you wanted to delete previous data on next run of the VI - now you wonder why previous data has been replaced "yet by new one"?

 

What exactly do you need?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 39 of 42
(978 Views)

Hi Gerdw,

Thank you for your prompt reply. For the second time running VI, I got both data previous data as well as new data. I want new data only. Whenever I run Vi for the third time or any time, I got the data from 1st running, 2nd running, and as many times as I run the VI. I want the data from the latest Vi that is run last time.

Thank you

0 Kudos
Message 40 of 42
(975 Views)