LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

tick count

how to make a "tickcount" count seconds without using a while loop?

0 Kudos
Message 1 of 11
(3,170 Views)

Well, when you want to read the current time regularly (to calc the time interval) you need a loop structure anyway...

Best regards,
GerdW


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

I'd like a led indicator to turn on after 15 seconds AFTER i press an "OK" button. Is it possible to do ALL this inside ONE while loop? Are case structures required?

 

Thank you.

0 Kudos
Message 3 of 11
(3,152 Views)

Hi Majd,

 

yes, you can do this in just one loop.

And yes, you need a case structure (or a Select node) to analyze the button press signal... (pseudocode IF ... THEN ... ELSE ...)

Best regards,
GerdW


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

can you please send me a VI containing what you explained?

0 Kudos
Message 5 of 11
(3,147 Views)

Hi Majd,

 

this is a very basic task you have to perform. It's suited perfectly to learn to use LabVIEW!

 

Write some pseudocode to have an abstract of the programming task, then try to create it using LabVIEW structures/functions. When you have problems then, you can ask here while attaching your VI...

Best regards,
GerdW


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

can you please try to replace teh while loop with someting esle?

0 Kudos
Message 7 of 11
(3,136 Views)

Hi Majd,

 

why should I? Your VI has to run for atleast 15s, so it needs a loop...

Best regards,
GerdW


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

@Majd.n96 wrote:

can you please try to replace teh while loop with someting esle?


We could replace the loop with your instructor, but he/she probably wouldn't be too happy about that...

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 9 of 11
(3,103 Views)

Isn't this the same question as your other thread? http://forums.ni.com/t5/LabVIEW/Tick-count/td-p/2604645

0 Kudos
Message 10 of 11
(3,074 Views)