10-23-2019 08:45 AM - edited 10-23-2019 08:50 AM
hi ,
i would like to start two first processes with same start time, and rest 1a and 1b after 1 of my vi. (plz see jpg file and vi)
objective:
1 and 2 should start at the same time,
1a and 1b should start after 1 finishes his task
issue:
1 and 2 starts same time but i dont know is this exact by programming or not.
1a and 1b waits for 2 to finish his task.
regards
10-23-2019 10:59 AM
According to the picture you posted, the ordering will be 1, 2, 1a, 1b. 2 runs strictly after 1.
This is because one of the outputs of 1 (the error wire) is an input to 2 (via the edge of the For loop containing 2).
If you want 1+2, then 1a when 1 finishes, and 1b when 1a finishes, place only the 1{,a,b} sections in the sequence structure (or use error out -> error in to sequence them) and have 2 be separate.
Forcing them to run at exactly the same time is impossible with these nodes, but since they're simulated signals, probably within nearly 0 time is close enough. To do that, just don't have them depend on each other (no dataflow from one to the other).
10-23-2019 12:50 PM
yes so how about this one as error in is feed to both 1 and 2 ,
10-23-2019 01:14 PM
Use the Error Line (it is there for a very good reason). You don't seem to understand the Principle of Data Flow, a central Principle in LabVIEW. Here are ways to improve your program (mostly cosmetic, but emphasizing Data Flow:
Admire your work. The Error Line clearly shows Data Flow and emphasizes that 1 and 2 run together, then comes 3, then comes 4.
Bob Schor
10-23-2019 07:29 PM - edited 10-23-2019 07:31 PM
Hi DMic,
The image you most recently uploaded looks like it will do what I think you described, (1+2) at the same time, then 1a when 1 finishes, then 1b when 1a finishes.
If instead you wanted (1+2), then 1a, then 1b, (i.e. wait for 2 to finish before starting 1a) then you should make the change that Bob_Schor suggested:
@Bob_Schor wrote:
3. Bring Error Out from the For Loop (you'll need to change the Tunnel to a Non-Indexing Tunnel). Merge Errors with the Error Out from Sim Sig2.
4. Wire this (now merged) Error Line to Error In of Sim3. Wire Error Out of Sim3 to Error In of Sim4.
But otherwise, the ordering should be fine.
I will (of course) go on to suggest the tutorials at the top of the forum again 😉
They have some good information on a range of topics, here is a link to the one introducing the concept of dataflow.
There also seems to be some new "interactive" tutorial system, which I'm not familiar with (but this might be an appropriate link for dataflow), and the SSP required courses are probably the best (but require an SSP...)