LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

default deadline for timed-loop

Solved!
Go to solution

When the deadline is not specified (i.e. set to -1), what is the default deadline that will set the Finished Late? [i-1] flag to true?

Fred
*Kudos are appreciated.*
0 Kudos
Message 1 of 9
(4,612 Views)

-1 means that there is no time-out.

It is similar to the time-out except it does not stop execution.

Cory K
0 Kudos
Message 2 of 9
(4,611 Views)

Here's what context help says :

 

timed loop.PNG

Cory K
Message 3 of 9
(4,604 Views)

I understand that, but the Finished Late [i-1] flag will still be set sometimes, even when no deadline is specified.

 

So, I would like to know: what is determining if the Finished Late [i-1] flag is set or not set when no deadline is specified?

Fred
*Kudos are appreciated.*
0 Kudos
Message 4 of 9
(4,602 Views)
The finished late flag will also be set if the time to execute the loop iteration is longer than the loop period.
Message 5 of 9
(4,589 Views)

Thanks. That is what I was guessing.

 

However, it seems strange b/c it appears that the period and deadline are almost the same for the case in which you do not have frames within the timed loop.  Is this correct?

 

The above would mean you only need to use the deadline if you have frames within a timed loop.

 

Let me know if this seems correct.

Fred
*Kudos are appreciated.*
0 Kudos
Message 6 of 9
(4,580 Views)

Yes. But I can also envision a case where let's say the period is 1000 milliseconds, but the deadline is 200 milliseconds.

 

So you want the loop to iterate every second, but you want the code inside to complete within 200 milliseconds, and if it doesn't, then signal it was late.

Message 7 of 9
(4,572 Views)

OK.  That's good to know. It changes my understanding.

 

The period is how long the loop will take to execute.

The deadline time compares against the time it takes to execute all the code inside the timed-loop.

 

period = time to execute code + empty fill time

 

Is this correct?

Fred
*Kudos are appreciated.*
0 Kudos
Message 8 of 9
(4,565 Views)
Solution
Accepted by topic author FLng
Correct.
0 Kudos
Message 9 of 9
(4,562 Views)