03-30-2009 03:35 PM
What I want to do is this
When I push a button on the main VI, a SubVI (#1) must run and take data.
At the same time, a sequence, in which there are other subVIs must run.
My problem is that the subVI #1 does not run when I push the button. The sequence is running well. How can I run both the sequence and the subVI at the simultaneously?
Solved! Go to Solution.
03-30-2009 03:55 PM - edited 03-30-2009 03:59 PM
Hey Hugo,
Sounds like you'll just want to do some parallel loops. I'll attach a screenshot of a VI that has a sequence where the counter goes up to 3, then restarts, each time it reads the iteration count from the subVI above. (The subVI is just a while loop with the iteration count attached to the global)
Each iteration of the sequence shows an increased count from the subVI via a global variable.
Is this what you are looking for?
Keep in mind that I just threw this together to show functionality, its got a lot of rough edges to it.
03-30-2009 03:57 PM
03-31-2009 02:01 PM
03-31-2009 03:41 PM
05-05-2009 11:06 AM
Yes, please!
I run subvi from parallel loop as described above... But when subvi runs, main vi is NOT operational (can't press no buttons, or alter anything).
Is there a way to keep subvi running and also be able to keep using MAIN vi?
Thanks!
05-05-2009 11:41 AM - edited 05-05-2009 11:42 AM
If you really have parallel loops with no data dependency, then the main will run. You need to attach your code so someone can see what you've done wrong.
It's also a good idea to create a new question instead of posting to a 'Solved' thread.
05-05-2009 01:08 PM
My main vi is very large. No way I can paste it here 😞 But parallel loop is very small - just button calling subVi inside.
I can't think of any data dependency unless it is that button? ('rozplyw 2' is located on main vi's frontpanel. naah...
main vi freezes while subvi is showing. Just picture on subvi's front panel - nothing more.
PS: Sorry if I post at wrong place, but it seems natural to me to continue just the same thread, especially there was:
Anything else that may help others to solve such problems too?
05-05-2009 02:04 PM
05-05-2009 02:36 PM
I think I've just done so... But here's the link anyway: http://www.freeimagehosting.net/uploads/e921245685.jpg
Thanks!