From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
09-23-2011 01:22 PM
Hi,
I am using the PXIe 1062Q chassis with two modules
- NI PXI 4461 in slot 2
- NI PXIe 6251 in slot 5
with PXIe 8105 controller. I would like to synchronize AI channels of these two modules. I am using NIDAQmx driver. After reading through the documentation, it seems that I can route the reference clock for each of these modules to use the PXI_Clk10 on the PXIe chassis and then share the start trigger.
However, after sharing the reference clock, using function DAQmxSetRefClkSrc and exporting the start trigger for 4461 to a PXI_Trig0 line and configuring the start trigger for 6251 from PXI_Trig0, my test inputs are still not completly synchronized. They seem to be off by 2ms.
Are there any special consideration that I need to keep in mind when synchronizing PXI and PXIe modules. Are there any DAQmx C examples that would be useful for PXI synchronization.
Thanks,
Regards,
Manisha
The MathWorks
Solved! Go to Solution.
09-26-2011 10:13 AM
Did you take into account the ADC filter delay? Due to the filtering performed by the 4461, there will be a delay based on the sampling frequency:
So let's assume that based on the above table, you have a 63 sample delay. This means that the first 63 samples you acquire from the 4461 will be pre-trigger samples, or junk data. You will need decimate these samples. An easy way to do this is:
This way, you are reading the first 63 samples, and then discarding them, and then reading the remaining samples simultaneously with the 6251. There are other ways to accomplish this, but this is one simple way. Let me know if this helps.
Thanks,
Sean N.
09-28-2011 12:57 PM
Hi Sean,
Thanks for your reply. Even after taking into accoount the filter delay, I still do not see them synchronized.
Here are two ways that I have tried
1. Master-Slave Sample Clock Synchronization with Sharing Start Trigger
Master Device - PXI 4461 ( PXI1Slot2)
Slave Device - PXIe 6251c ( PXI1Slot5)
For sample Clock Synchronization
PXI 4461 master uses 'OnboardClock' as it clock in the function DAQmxCfgSampClkTiming
PXI 4461 exports it clock on PXI1Slot2\PXI_Trig0 line using DAQmxExportSignal
PXIe 6251 uses the PXI1Slot5\PXI_Trig0 line as its clock in function DAQmxCfgSampClkTiming
For Sharing Start Trigger
PXI 4461 exports it start trigger on PXI1Slot2\PXI_Trig1 line using DAQmxExportSignal
PXIe 6251 is configured to use PXI1Slot5\PXI_Trig1 as its digital start trigger using the command DAQmxCfgDigEdgeStartTrig
It looks like the start trigger is getting ahred as they start together, but not the clock ( as the inputs drift slowly)
2. Reference Clock Synchronization with Sharing Start Trigger
Both PXI 4461 uses OnboardClock (in DAQmxCfgSampClkTiming ) but set /PXI1Slot2/PXI_CLK10 as the refernce clock using DAQmxSetRefClkSrc.
PXIe 6251 uses OnboardClock (in DAQmxCfgSampClkTiming ) but set /PXI1Slot5/PXI_CLK10 as the refernce clock using DAQmxSetRefClkSrc
I do the same setup for start triggers as above.
In this scenario also, I see the same behavior.
Are there any other easier ways to synchronize all modules on my PXI chassis?
Thank for all the help,
Regards,
Manisha
09-28-2011 02:43 PM
What is the sampling rate that you are using? On the 4461, are you AC coupled or DC coupled? If you are AC coupled, there is a settling time associated with it that could cause a delay.
Thanks,
Sean
09-29-2011 08:54 AM
Thanks Sean for the quick reply.
I was able to get them synchronized. The M-series was changing the rate to something that was acceptable by it, so both the modules were running at slightly different rates. Making the rates exactly the same, solved the issue.
Thanks again,
Manisha
09-29-2011 09:30 AM
Manisha-
Good to hear! I like to use the property node to read the actual sample clock rate because of coercion (as you were seeing).
Thanks,
Sean