LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why is timing different when subvi is called vs. stepped into?

I have a subvi that is called from within a larger vi. This subvi uses a sequence of wait(ms) vis and custom white-noise generator vis to create a sequence of sounds outputted to headphones. The timing of the sequence is very reliable when the subvi is either run directly or if I step-into it from the calling vi. However, when labview calls the subvi as part of the larger routine, the sequence is off.

 

It's confusing because I'd expect the same behavior regardless of step-into or running it from the calling vi. Any help will be much apprecitated.

 

 

0 Kudos
Message 1 of 3
(2,586 Views)
What do you mean by step into? Is that during the debug phase?
Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 2 of 3
(2,564 Views)

I solved this. The problem was my design of the parent vi was such that there were concurrent while loops running that were throwing off the timing of the sub vi. I put everything into an event handler with one loop and that fixed it.

 

thanks!

0 Kudos
Message 3 of 3
(2,561 Views)