03-10-2010 08:41 AM
03-10-2010 08:45 AM
Hi Jeff,
I am not exactly sure what you mean, but I think what you have are codes that are on the same thread as the delay and you want those codes to run while the delay is running?
If you want other code to run, while a delay subvi is being executed, that other code must be in parallel of the delay.
Yik
03-10-2010 09:26 AM
Yik is correct.
Your code needs to be architectured in such a way that the code with the delay runs in one thread, whereas the rest of the code is in one or more "other" threads. This is done quite simply in LabVIEW. Having two While Loops in parallel is an example. Having two threads within the same loop will cause both threads to experience the delay due to the dataflow nature of LabVIEW.
03-11-2010 01:37 AM
sry guys, may be i am new user of Labview so i really not understand about that. my system is like that. a have a fish feeder machine. when i set the position in the system. the feeder machine will launch, when the sensor detected the feeder machine, the feeder machine will stop and open the gate to feeding the fish. the gate will be close back in 5 second. then the machine continue to another position.now i face the problem in delay system. when the delay code put in the block diagram, whole block diagram will delay in process. do you have any idea to make the delay code stand alone in the block diagram? or do you anything similar ecample canshare with me?thank you Yik and Ray^^
03-11-2010 03:09 AM
Like this?
03-11-2010 05:18 AM
03-11-2010 09:39 AM
I still cannot i had draw a ecample in the picture, there have 2 different part , A and B and a delay Added in the Part A. then what should i do to make the part B is undisturb by part A. what code or function i should add? can teach me please^^
03-11-2010 08:58 PM
Hi Jeff,
Replace the box that you were for part a and b with while loops. Remember to put a time delay in the loops, so that the loops are not looping too quickly.
Yik
03-11-2010 11:09 PM
if i make a while loop in the part A but i another make a link from the switch in part B to connect the output RED in part A. issit the part B RED also will effected by the delay ? issit got method to solve it?
03-11-2010 11:15 PM
Post a VI so we can understand what you are describing .
Better yet, create the VI and try running it yourself and figure out how it is working. Turn on highlight execution to slow it down and watch it work.