LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Acquiring two analog channels consecutively. While one is being acquired the second is being processed.

Hi,

I need to acquire two different channels consecutively, while using processing time as efficiently as possible.  I want acquisition from channel one to start on a trigger and finish after N samples have been acquired.  On the next trigger acquisition should start from channel two and simultaneously process the already stored channel 1 data.  It should continue acquiring one channel while processing the other.  I've been able to realize consecutive acquisition using a flat sequence and two DAQmx tasks, but that does not seem to be processor efficient.  Execution speed is important here, so I'll need to analyze the acquired data from one channel while the second channel is being acquired, is there a way that I could set this up in Labview?

Regards,
Aleksandr
0 Kudos
Message 1 of 4
(2,627 Views)
Hi Aleksandr
 
A common design technique for acquiring and anaylsising data is to use the master/slave design. Where all the functions that acquire data are in one loop, and functions that require the data are in the other. ( I apologies if you already know this). This is an efficient block diagram because the processor does not waste cycles polling for an event. So this would allow you to efficiently analyze the data from one task as its being acquired.
 
So theres no reason why you can't have two of these running consecutively. Espically if your no worried about synchronization between the two tasks.
 
Is there any reason why you want 'While one is being acquired the second is being processed'?
 
Other things to be processor efficient, remember all loops should contain a small time delay to allow the processor sleep time to complete other tasks, such as windows tasks etc. And a note about sequence structure is there obviously prevent parallelism in labview.
 
thanks
Kind Regards
James Hillman
Applications Engineer 2008 to 2009 National Instruments UK & Ireland
Loughborough University UK - 2006 to 2011
Remember Kudos those who help! 😉
Message 2 of 4
(2,612 Views)
Hi Hillman,

Thank you for the help, I've set it up as you describe and it works well, I was overcomplicating it without a reason.

Aleksandr
0 Kudos
Message 3 of 4
(2,593 Views)
Hi Aleksandr,
 
Im glad that worked - its my pleasure to help.
 
Thanks for the rating and have a nice day.


Message Edited by Hillman on 08-07-2008 09:32 AM
Kind Regards
James Hillman
Applications Engineer 2008 to 2009 National Instruments UK & Ireland
Loughborough University UK - 2006 to 2011
Remember Kudos those who help! 😉
0 Kudos
Message 4 of 4
(2,577 Views)