12-24-2008 03:12 AM
Hi All,
I have developed one USB DAQ application with 3 while loops in main vi and 1 subvi with an activex container for video display.
This video displayer subvi has no function and it has that Activex container to display the video.
The purpose is to playback acquired signal with the recorded video.
So I keep both VIs frontpanel opened at all time.
The speed of the loops in main vi are as follows,
Loop1: Contains event structure with 250ms timeout terminal.
Loop2: Contains an while to play the recorded data with the recorded time duration between successive data points.
may be min of 70 ms delay for each iteration.
Loop3: Contains another while which run min of 15 ms delay for each iteration.
The speed problem is as follows,
When i click on the subvi which contains an activex container, the while loop in Loop2 does not run properly and each iterations delay in millisecond is increasing constantly in terms of 250 milliseconds atleast.
After releasing mouse button from subvi, the loop agains starts running normally.
it would be great help for me if somebody can provide a solution for this problem.
Thanks in advance.
Thanks,
Sathish
12-24-2008 03:27 AM
I think I know why this happens, I am not sure how te get a workaround.
The ActiveX interface runs in the UI thread just like the event structure.
The event structure forces the whole VI into the UI thread and is only triggered every 250 ms when the ActiveX is claiming all the UI power.
I think moving the 70 ms. loop into a seperate VI should do.
(I might be wrong about the above theory)
Ton