02-15-2024 07:53 AM
Hello everyone,
I am wondering if there is a way to measure the elapsed time since a specific boolean button was pressed (i.e., turned to 1) and then use this elapsed time as a condition for executing a particular part of the code.
Specifically, I need to send a frame to a certain device, but I want to do this after a designated amount of time has passed since the button was pressed. Both the time interval to "wait" and the boolean variable indicating the button press are located on the front panel.
Thank you for your help.
02-15-2024 08:13 AM
Hi Holly,
@MinHolly wrote:
I am wondering if there is a way to measure the elapsed time since a specific boolean button was pressed
Wow, LabVIEW comes with a function called ElapsedTime, that will do what you are asking for!
(Even though it's an ExpressVI it is a quite useful one...)
02-15-2024 08:16 AM
Actually, I've seen that this function starts counting at a set "start time" input and does not take a boolean as a starting condition. am I wrong ?
02-15-2024 09:10 AM
Hi Holly,
@MinHolly wrote:
Actually, I've seen that this function starts counting at a set "start time" input and does not take a boolean as a starting condition. am I wrong ?
Yes, this function also has boolean inputs available…
02-15-2024 09:14 AM
@MinHolly wrote:
Actually, I've seen that this function starts counting at a set "start time" input and does not take a boolean as a starting condition. am I wrong ?
Read the Help for Elapsed Time