12-06-2007 08:50 AM
Hello,
I would like to develop a VI that performs two parallel tasks (that is easy). However, I need that when task1 finishes it would send values to her friend task and start all over again - with no dependence on the performing of task 2 (that is difficult to me). I will explain in detail:
My VI has two main tasks. Execution of both tasks should be parallel:
1. Task 1: N samples and N channels DAQ. After all of the data was sampled I need to transfer the sampled data to task 2 and start sampling all over again at the same time task 2 execute and without saving in memory the previous sampled data
2. Task 2:
a. Doing some calculations with the sampled data
b. Write the results to a file
c. Deleted all the data that was not saved
d. Accepting new samples
e. Repeat a-e
Transferring the sampled data from task 1 to task 2 there is the only connection between the tasks.
I would appreciate any help in planning the suitable structure of the VI to the above description,
Regards,
Eran
12-06-2007 09:46 AM
12-07-2007 11:59 AM
Hi Eran,
Yes, the best solution for you is the producer/consumer design pattern (data) multiple loop architecture. You can find it in the templates from the Getting Started Window. You can acquire your data in the producer loop and analyze it in your consumer. Everything is done in parallel. The consumer loop executes as soon as a new element shows up in the Queue.
What version of LabVIEW do you have?
12-09-2007 01:37 AM
Hi Kalin T,
Thank you for your reply. I have labview version 8.2.
I will try what you reccommend ,
Regards,
Eran