LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can we input and update numeric control in front panel when a fast while loop is running?

Solved!
Go to solution

Dear all,

 

In my code, I have a while loop doing fast grabbing (sampling)

how can I update other numeric controls in the front panel when the while loop is running?

 

right now, once I input a number into this numeric control, the computer seems to be no response at ell. it looks like computer is focusing on the while loop.

any ideas are appreciated.

thanks

 

jack 

Message Edited by igg_integrin on 02-26-2009 02:38 PM
Message Edited by igg_integrin on 02-26-2009 02:39 PM
0 Kudos
Message 1 of 15
(4,271 Views)

Are you sure the program is in the while loop?  The code below has a very fast while loop and the control updates fine.


I'm inclined to believe your program calls a program inside the while loop that is looping indefinitely, thus holding up the calling while loop. 

 

Please clarify/post the code in question.

 

 

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 2 of 15
(4,260 Views)

Posting your code would be very helpful - or at least a screen shot. Otherwise we are basically shooting in the dark.

 

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 3 of 15
(4,240 Views)
And are you sure the data is actually changing?
-Matt Bradley

************ kudos always appreciated, but only when deserved **************************




0 Kudos
Message 4 of 15
(4,225 Views)

thank you all for your reply

 

here is my code

one while loop is to processing the image grabbing..

the other one is to reponse the event to change the numeric control's value

 

every time when I input the numeric 1, the code seems stop..no response at all.

is it becuase the way I code two while loops in parallelll isn't correct?

thanks

 

Jack

 

 

Message Edited by igg_integrin on 02-26-2009 11:11 PM
0 Kudos
Message 5 of 15
(4,210 Views)
Try putting a 0ms wait timer in the top loop.  It may be running so fast that it never allows the other loop time to execute.  What does Windows Task Manager say your CPU usage is?
Message 6 of 15
(4,208 Views)

igg_integrin wrote:

 

every time when I input the numeric 1, the code seems stop..no response at all.

is it becuase the way I code two while loops in parallelll isn't correct?

thanks

 

Jack


Hi Jack,

 

Please see here.

 

Your parallel placing of while loops may not be a problem at all for LV, but only the non-availability of any small loop delay inside the top loop.

 

Also, please check your CPU usage, eventhough if it is a dual core PC, as Ravens Fan has suggested.

- Partha ( CLD until Oct 2024 🙂 )
0 Kudos
Message 7 of 15
(4,192 Views)

Hi Jack,

 

 

Try using Timed Loop ,where u can set the prority and which loop to run in which processor.

 

check out this link

 

https://www.ni.com/docs/en-US/bundle/labview-real-time-module/page/creating-deterministic-applicatio...

 

Rgds,

Venky

Message 8 of 15
(4,162 Views)
Why do you need this fast update rate. Your LCD computer screen has a update rate around 60Hz. Movies are usually filmed at a rate of 24 frames per second.  


Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
(Sorry no Labview "brag list" so far)
0 Kudos
Message 9 of 15
(4,128 Views)

thank you all, 

 

finally I found a way to solve it..

 

jack 

0 Kudos
Message 10 of 15
(4,103 Views)