LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Synchronize acquisition between 2 different modules

Hi all,

I am using following 2 modules in PXI chasis

1) PXIe 4480 : Hydrophone is connected -- acquiring 262144 Samples/sec

2) PXI 6238 -- pressure sensor is connected -- acquiring 16 Samples/sec 

 

I want to synchronize t0 of both data blocks (pressure 16 point wvf and hydrophone 262144 points wvf).

 

Please give me some hint or point me to some document. Thanks.

0 Kudos
Message 1 of 7
(3,375 Views)

Here's a hint -- the best way for us to help you with your code is for you to post your code, attaching the VIs (not pictures of the VIs, but the actual .vi file(s)) so that we can see what you are attempting.  We'll also know what version of LabVIEW you are using, and can get some idea of your level of LabVIEW experience.  In particular, if you are trying to do this using the Dreaded DAQ Assistant, we can suggest how to migrate to basic DAQmx.

 

What else is in that PXI chassis?  What is generating the Timer signals?

 

Bob Schor

0 Kudos
Message 2 of 7
(3,352 Views)

The two devices have different kinds of A/D converters, making sync less trivial.  I'm away from my LV machine and can't post a snippet of what I'll describe, but can probably come back to do it later.

 

You would likely end up exporting the 262.144 kHz sample clock from the 4480 to one of the PXI trigger lines.  Then you would use that signal on the designated PXI trigger line as the 6238's sample clock *timebase*.  You would further define the desired actual sample rate for the 6238 and DAQmx will figure out how to divide down the timebase signal to produce it.  It will be able to do so since 262.144 kHz is an integer multiple of 16 Hz.  (Note: if the 4480 can't *exactly* produce 262.144 kHz, you'll get a similar % error in the desired 16 Hz rate on the 6238.  They'll still be synced to one another though.)

   After all that, there's still the issue of filter delay and samples to discard.  More info can be found at the following links:

 

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P9uTSAS&l=en-US

 

https://forums.ni.com/t5/LabVIEW/Sample-Delta-Sigma-Module-and-Scanned-Module-Synchronous/td-p/32860...

 

https://forums.ni.com/t5/Multifunction-DAQ/Synchronizing-different-DAQ-cards/td-p/3568813

 

 

-Kevin P

 

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
Message 3 of 7
(3,347 Views)

Thanks @Bob_Schor and @Kevin_Price for quick reply and providing links to study possible options.

 

I had simplified my question. But my actual requirement is,

1) PXIe 4480 : Hydrophone is connected -- 16384 samples * 16 blocks = acquiring 262144 Samples/sec

2) PXI 6238 -- pressure sensor is connected -- 1 sample * 16 blocks = acquiring 16 Samples/sec 

Vi snippet as well as VI is attached, programmed for above requirement.timeSync3.png

 timeSync3-FP.png

 

 

 

As you may observe in FP, there's difference of 2 to 3 mSec between T1 and T2 timestamps. And I am trying get it synchronized.

 

In the mean time, I am trying to understand documents referred by Kevin_Price.

0 Kudos
Message 4 of 7
(3,328 Views)

Look in the example finder for synchronization, there are a lot of good examples there.

 

You also need to look at the manuals for your cards to see what kind of synchronization they support. Some modules allow you to export the sample clock, others do not. Depending on what you modules support will determine your synchronization scheme. Also, your Delta-Sigma digitizer may support the DAQmx property of removing the filter delay.

 

mcduff

0 Kudos
Message 5 of 7
(3,312 Views)

Here's an incomplete snippet to illustrate how to establish hardware-level sync based on using the 4480 board as the timing master.  Heed mcduff's advice about checking into filter delay removal.  I'm afraid I don't know exactly where to point you for those DAQmx properties though.

 

 

-Kevin P

 

sync Delta-Sigma with SAR.png

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
Message 6 of 7
(3,307 Views)

Here is the property that removes the delay that I alluded to earlier, note not all boards support this property.

snip.png

 

 

mcduff

0 Kudos
Message 7 of 7
(3,305 Views)