LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Difference between 2 time in case structure

Hello Guys,

i want to know How long the LED ( pin 13 ) was on? in this format (Minute:Second). When i click on the button, start counting the times until when i click again. i need to calculate the 2 times between the True and False case structure. 

0 Kudos
Message 1 of 21
(1,910 Views)

cross-posting is ok, just mention it please

 

https://lavag.org/topic/22890-difference-between-2-time-in-case-structure/


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 2 of 21
(1,907 Views)

Hi amir,

 


@amirdifraxe1 wrote:

When i click on the button, start counting the times until when i click again. i need to calculate the 2 times between the True and False case structure. 


Use a shift register to hold a timestamp. Set the timestamp in one case and subtract in the other case…

 

Btw. we cannot edit/run/debug images with LabVIEW!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 21
(1,892 Views)

Thank you Dear, i will test it 

0 Kudos
Message 4 of 21
(1,876 Views)

thank you , i have attached my VI. if its possible for you can you do it like example for me ? because when i subtract it between two case error me. 

0 Kudos
Message 5 of 21
(1,872 Views)

Hi amir,

 

many of us aren't using the most recent LabVIEW version because of changes in the license scheme, so you better attach a downconverted version of your VI! (File->Save for previous)

 

Suggestion:

There might be simpler solutions… 😄

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 6 of 21
(1,816 Views)

oh sorry Dear, i forgot it. i have attached Version 2016. 

0 Kudos
Message 7 of 21
(1,800 Views)

Excuse me Dear, what is the name of these components? 

0 Kudos
Message 8 of 21
(1,704 Views)

First one is "feedback node", under Programming -> Structures

Second one is "Boolean crossing PtByPt.vi", under Signal processing -> Point by point -> Other functions

0 Kudos
Message 9 of 21
(1,700 Views)

Thank you Dear

could you please to explain these schemes? 

 

when i press the button(button=1), the input of crossing will be false-True then, on the selector, select True and start timing.  but on the 2 selector and feedbacks i don't understand whats happened.if i know the concepts of this method will be ok. 

0 Kudos
Message 10 of 21
(1,690 Views)