Overview
These examples illustrate how to synchronize measurements between NI-SCOPE oscilloscopes/digitizers and DAQmx based devices.
Both examples use signal-based synchronization, sharing a common reference clock signal (The PXI 10MHz clock) and triggers. (see Forms of Device Synchronization for NI-SCOPE)
Description
Here is a brief description of each example:
niScope EX Continuous DAQmx Synchronization.vi
Configures the NI-SCOPE device for continuous acquisition, synchronizing reference clocks and the start trigger.
niScope EX multi-record DAQmx Synchronization.vi
Configures the NI-SCOPE device for a multi-record acquisition, and the DAQmx device for a re-triggerable AI acquisition. The devices share a common reference clock, and NI-SCOPE reference triggers are used to synchronize the DAQmx acquistion.
Synchronization Limitation
The timestamp in the waveform acquired is based on the system clock; however, it is a software time value because it is based on when the operating system retrieves the data values from the buffer of the DAQ card (Tos_retrieval) after the DAQmx Read VI is called and the samples are available."
(see DAQmx Timestamp Accuracy)
For the best accuracy the DAQmx Read VI needs to be called while the DAQ card is still acquiring the first set of samples. If there is a delay and the Read VI is called after the DAQ card has completed the acquisition the timestamp will not be accurate at all. To ensure that the Read VI is called before the first set of samples, the DAQ card is configured as the slave device when syncronized with a NI-SCOPE digitizer card.
NI-SCOPE digitizer's timestamps are hardware based, and therefore more accurate. (see NI-SCOPE Time Stamping) Due to this difference, the sycronization capability between NI-SCOPE and DAQmx cards, is limited to the accuracy of the DAQmx timestamps provided by the operating system.
Steps to Implement or Execute Code
1. Setup a PXI based system using a NI-SCOPE device and a DAQmx based device.
2. Open the example VI(s).
3. Follow the instructions on the front panel.
4. Run the VI.
Requirements
Software
LabVIEW 2011 or later
NI-SCOPE
NI-DAQmx
Hardware
NI-SCOPE device
NI-DAQmx device (x-series for re-triggerable features used in multi-record example)
Additional Images or Video
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
Hello, I am new learner of LabView. I do need to trigger a NI SCOPE acquisition placed in a consumer/producer architecture to measure a high speed signal from my channel 1 in my NI PXI 5124 using a digital triggers from a NI PXIE 6341 using a DAQmx. I want to save data only when the digital trigger is on/true.
Could you please show me how to modified your code to archive this goal?