LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can the two tasks run in parallel?

Solved!
Go to solution

As is shown in the picture, my question is that two tasks in my scene have to run in parallel and both of them are expected to restart when a certain error comes up.
Could my structure run correctly?

Is there any potential problem here AND better methods for my model?

 

Download All
0 Kudos
Message 1 of 6
(3,130 Views)
Solution
Accepted by topic author Heartnode

Your structure is wrong.

First finished inner loop will wait for second one.

Use state machine/

1st state = initialization

2nd = work. And if error 2->1

 

0 Kudos
Message 2 of 6
(3,123 Views)

Understand! Thanks! I learn much from your answer. In my another scene, I want some parallel tasks can stop and restart togheter(the first finished task is expected to  wait for the last task), I think your advice and such a structure will be useful. Thx again!

0 Kudos
Message 3 of 6
(3,089 Views)

In fact, in my program, when a certain inner loop is finishing, other inner loop is indicated to be finished and so that the program will end soon  if without the outer loop. The main point I want to know clearly is that when the two tasks are both running , are they in parallel if the outer loop exists?thx!

0 Kudos
Message 4 of 6
(3,075 Views)

As long as there is no data dependency between the loops they will run in parallel. In fact, any node in LabVIEW will run in parallel provided there are no data dependencies between the nodes. A node is ready to execute when all of its inputs are available. This is the core premise of data flowing programming.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 5 of 6
(3,068 Views)

Well I also thought so until I faced this problem I have right now with mine. If you could check it out that would be great 🙂

https://forums.ni.com/t5/LabVIEW/Running-two-Python-Coded-simultaneously/m-p/3937866

 



0 Kudos
Message 6 of 6
(2,839 Views)