Table Of Contents

Signal-Based Synchronization in NI-Sync

    Last Modified: September 15, 2017

    Signal-based synchronization is characterized by physically sharing a combination of clocks and triggers to synchronize data acquisition and instrument control. Using a signal-based synchronization method, you can route clock and trigger signals throughout the system with Connect Clock Terminals and Connect Trigger Terminals. Once you connect clock and trigger terminals, the signals are used to synchronize devices and modules using the terminal routes you established.

    Using the signal-based synchronization method, you can perform the following actions:

    • Generate a clock that runs at a user-defined frequency.
    • Use triggers to synchronize data acquisition.
    • Divide a clock to create new frequencies that are still synchronized with the main clock.
    • Route clock and trigger terminals between devices using Connect Clock Terminals and Connect Trigger Terminals.
    • Lock the backplane clock to an external device's clock using the PLL circuit.
    • Discipline the backplane clock to a module's oscillator.
    • Measure the frequency on a specific terminal using Measure Frequency.

    The clock signal(s) used to synchronize devices in the signal-based synchronization method can originate from an external clock connected to ClkIn, a DDS signal created with a signal-based timing and synchronization module, the backplane clock of a PXI or PXIe chassis, or the oscillator of an NI-Sync device.

    Signal-Based Synchronization Phases

    The signal-based synchronization method can be broken down into the following phases:

    • Initialize: Create an NI-Sync session to establish communication with an NI signal-based timing and synchronization device. Initialize creates a unique session handle that identifies the device to subsequent NI-Sync nodes. You can also use Initialize to reset the device to a known state and verify that the NI-Sync instrument driver is valid for the device.
    • Configure Hardware: Set up your device for synchronization, typically using niSync Properties. You can choose the type of signal to generate or synchronize with, the frequency of the signal (if you are using DDS), and the synchronization clock the front and rear zones of your chassis should use.
    • Connect Terminals: Connect clock and trigger terminals between modules and chassis. Use this step to route triggers to different parts of the chassis and synchronize modules to the same clock signal. During the Connect Terminals phase, you can connect source and destination terminals, set a synchronization clock for triggers, and discipline the backplane clock to a clock signal. You can use Connect Clock Terminals, Connect Trigger Terminals, and Connect Software Trigger in the Connect Terminals phase.
    • Configure and Perform Measurement: Begin data acquisition using the parameters you set in the Configure Hardware phase and the terminal routes you created in the Connect Terminals phases. Taking a measurement is an application-specific operation that usually involves the use of a separate API, such as NI-DAQmx. You can also return synchronization information using niSync Properties or send a software trigger using Send Software Trigger in this phase.
    • Disconnect Terminals: Disconnect the terminal routes you set up in the Connect Terminals phase. Once you disconnect terminals, they are free for use in other applications. You can use Disconnect Clock Terminals, Disconnect Trigger Terminals, and Disconnect Software Trigger in this phase.
    • Close: Close the NI-Sync session and end communication between the driver and the device using Close. This phase is necessary for deallocating memory and freeing other operating system resources. You must close every NI-Sync session you initialize, even if an error occurs when you execute the program.

    Signal-Based Advanced and Utility Functions

    Functions that do not fall into the above signal-based synchronization phases are considered Advanced or Utility functions.

    Recently Viewed Topics