From Saturday, Nov 23rd 7:00 PM CST - Sunday, Nov 24th 7:45 AM CST, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Choosing a CompactDAQ Synchronization Technology

Overview

Choosing synchronization technologies depends on distance between nodes, synchronization accuracy requirements, platform support, technology availability, and more. This article describes synchronization recommendations and the breadth of options on the CompactDAQ platform.

Contents

Signal-Based Versus Time-Based Synchronization


There are two types of synchronization:

  • Signal-based—Clocks and triggers are physically connected between systems using wires or cables. This method is the most precise for components that are close to each other.
  • Time-based—All system components have a common reference to time. Events, triggers, and clocks can be generated based on this time. For example, consider a CompactDAQ system that has its time set to 5:05 p.m. Using time-based synchronization, another CompactDAQ system 100 meters away also has its time set to 5:05 p.m. Data points that are acquired on both CompactDAQ systems can be timestamped and correlated together.

 

General Guidelines


The following table compares the synchronization technologies on CompactDAQ, listing the maximum distance allowed between nodes, typical synchronization accuracy, time server requirements, cabling requirements, timestamp support, recommended hardware, and the subsystem that they will synchronize. This table is intended only as a general guideline, and all technologies are explained in more detail below.

 

TechnologyPhysical Distance Between NodesAccuracy1Need Time Server?2CablingTimestamp?Recommended Hardware
Signal-Based<100 mVaries (Refer to the Manual)NoCAT 5ENoNI-9469
IEEE 1588 software-based timestamping (default 1588 profile)3Within Subnet1 msNoLANYescDAQ-9132/9133/9134/9135/9136/9137 running NI Linux Real-Time
IEEE 1588 with hardware assisted timestamping (IEEE 802.1AS or default profile)6Within Subnet<1 µsNoLANYescDAQ-9185/9189
SNTP4Global (access to NTP server)10s msYes5LANYescDAQ-9132/9133/9134/9135/9136/9137 running WES7


1This is an accuracy estimate for a typical system. Accuracy varies depending on the system.
2A time server requirement indicates that you need a time server to synchronize to a global notion of time.
3
SW IEEE 1588v2 is supported on only CompactDAQ controllers running NI Linux Real-Time
4
(S)NTP is supported on only CompactDAQ controllers. Refer to the Time-Based Synchronization Methods section for more information.
5There are a variety of NTP time servers publicly available on the web. A time server is required for (S)NTP synchronization.
69185/9189 firmware 18.1 or later is required to enable support for IEEE 1588 with hardware assisted timestamping (default profile)

 

Signal-Based Synchronization Methods


In signal-based synchronization, devices are wired directly together and a master device exports timing signals to slave devices. In this paradigm, all systems acquire together, but one does not necessarily know the data point’s time. Typically, either trigger signals or sample clocks are shared. The following is a list of signal-based synchronization options for CompactDAQ.

NI-9469 Synchronization Module


The NI-9469 is a C Series module specifically designed for sharing clocks and triggers between chassis. It has a software-configurable, multiport interface that enables distribution of triggers and clocks from a host chassis, and it has an onboard DDS and PLL for clock generation and synchronization capabilities.

For sharing the triggers and clocks, the NI-9469 has three RJ45 connectors on the front panel, which use standard CAT 5E cabling to pass DIO signals to other NI-9469 modules. Although this is standard Ethernet cabling, these modules only pass timing signals and cannot provide general communication. Each port is software-configurable and can drive or receive four differential signals through the cable.

The NI-9469 was also designed to synchronize modules with simultaneous delta-sigma analog-to-digital converters (ADCs) for high-channel-count systems that require more than one chassis. Delta-sigma modules require a separate oversample clock to operate. Delta-sigma modules are also referred to as DSA devices and include accelerometer and microphone data. Each delta-sigma module has an onboard clock for normal operation that is physically routed through the CompactDAQ chassis to synchronize all delta-sigma modules within a single chassis. For multichassis systems, the NI-9469 generates the required oversample clock for delta-sigma modules and routes it to both the local CompactDAQ chassis and any other CompactDAQ chassis connected by an NI-9469.

The NI-9469 module allows for a flexible network topology. Refer to the NI-9469 Getting Started Guide for more information on the possible network topologies.

The NI-9469 is supported on both CompactRIO and CompactDAQ platforms. However, it is not possible to interface the NI-9469 with the PXI platform. For example, the Ethernet port on the PXI-6683H timing module does not interface with the NI-9469.

Custom Programming With Digital I/O and PFI Lines


It is also possible to manually import and export timing signals through digital I/O C Series modules or the integrated BNC/SMB PFI lines included on some CompactDAQ chassis/controllers using the NI-DAQmx driver to route the signals. With this method, the DIO/PFI lines can be connected to route triggers and timing signals. Using NI-DAQmx, these signals can be exported from a master task by using the NI-DAQmx Export Signals Property Node. The other tasks in the nonmaster chassis then need to be configured to have the sample clock and start trigger inputs use the DIO/PFI terminals as the input to accept the signal.

Below is a simple example where sample clock and start trigger are being routed to the BNC ports on the CompactDAQ chassis, which has the master task. The example also shows the slave task using the BNC ports from the slave CompactDAQ chassis as the input terminals for the sample clock and start trigger, which receive the signals from the master task.
 

Figure 1: Example of a sample clock and start trigger being routed to the BNC ports.

 

Time-Based Synchronization Methods


In time-based synchronization, all system components have a common reference to time. It is more scalable than signal-based synchronization as more devices are added to the system. The data from the new device can be correlated with other devices on the system once the system is synchronized to a time source.

There are two central software APIs for time-based synchronization on CompactDAQ:

  • NI-DAQmx is the driver software you use to communicate with and control your NI DAQ devices. The driver includes an extensive library of functions and VIs you can call from your application software, such as LabVIEW or LabWindows™/CVI, to program your devices. Starting in NI-DAQmx 17.1, network-synchronized devices can also take advantage of time-based synchronization features. Certain triggers and timestamps can be specified in terms of time of day.
  • NI-TimeSync provides the ability to synchronize the CompactDAQ controller’s system clock to a specified time reference. The only officially supported time reference plug-in is software IEEE 1588; however, there are commonly used community versions of other time reference plug-ins, such as the custom time reference (often used in conjunction with GPS), the SNTP time reference, and the NI-Sync hardware time reference. All community time references are on the Sync Labs NI Community Page. To use one of the time reference plug-ins, install it to the target. Some minor modifications to the configuration files may be required, which are described in the sections below.

    The following is a list of time synchronization options for CompactDAQ, many of which use the above software methods.



IEEE 1588


IEEE 1588, also known as the Precision Time Protocol (PTP), is an Ethernet-based synchronization method designed for cabled, local networks. The benefit of IEEE 1588 is that it allows you to synchronize your targets over a standard network. It works by determining a master clock automatically from the network and having all other clocks slave to this master clock. IEEE 1588 is also a relatively fault-tolerant synchronization option. If the master clock is disconnected from the network, a new master is dynamically determined. For a detailed description of the protocol, refer to the white paper, Introduction to Distributed Clock Synchronization and the IEEE 1588 Precision Time Protocol.

IEEE 1588 has many different profiles, each of which use different features. Because the profiles are not interoperable with each other, make sure you are aware of which profiles your device supports

Software-Based IEEE 1588v2

All CompactDAQ controllers based on NI Linux Real-Time support a software implementation of IEEE 1588v2 through the NI-TimeSync driver. After the driver is installed, you can connect multiple CompactDAQ controllers over any standard Ethernet network, and they automatically synchronize their system clocks. TSN-enabled Ethernet CompactDAQ chassis with firmware 18.1 or later installed also support IEEE 1588v2. The typical accuracy of this type of synchronization between controllers is about 1 ms. Although there is no specific network hardware (Ethernet switches) required to support IEEE 1588v2, an IEEE 1588v2-enabled switch is recommended to obtain the best synchronization performance. These switches mitigate the impact of network loading that can adversely affect synchronization on standard switches.

To enable software-based IEEE 1588v2 synchronization on your CompactDAQ controllers running NI Linux Real-Time, you need to install NI-TimeSync on each controller. This can be done through the software installation process in Measurement & Automation Explorer (MAX). IEEE 1588v2 settings for NI Linux Real-Time targets need to be configured through file modifications. For details on configuring and monitoring the IEEE 1588v2 synchronization status on NI Linux Real-Time, refer to Using NI-TimeSync to Configure IEEE 1588 and 802.1AS Time References.

Hardware-Based IEEE 1588v2 (default profile)

TSN-enabled CompactDAQ chassis with firmware 18.1 and later support HW IEEE 1588v2 (default profile). HW IEEE 1588v2 (default profile) is compatible with SW IEEE 1588v2, but is not compatible with the 802.1AS profile. HW IEEE 1588v2 (default profile) features greater accuracy due to hardware timestamping, but is otherwise the same protocol as SW IEEE 1588v2.

Hardware-Based IEEE 1588v2 (802.1AS profile)


A newer PTP profile within IEEE 1588 is IEEE 802.1AS, which was selected for time synchronization within Time Sensitive Networking (TSN). TSN is a series of additions and updates to the IEEE 802.1 standard, which is a local area networking standard for bridges. One of the aspects of TSN is defining a global sense of time between network components within the TSN subnet. Both the 4-slot cDAQ-9185 Ethernet chassis and the 8-slot cDAQ-9189 Ethernet chassis use this PTP profile to provide time-based synchronization across the network. The typical accuracy of this type of synchronization between chassis is less than 1 μs, but this can be greatly reduced to the 100s of nanosecond range, depending on the configuration of the system. To synchronize these chassis, you can daisy chain them together, creating a line topology, with just Ethernet cables. For other topologies where they are not daisy chained and you want to have all the chassis synchronized, you must use an IEEE 802.1AS-compliant switch between the devices.

These chassis leverage the addition of the time-based synchronization features in NI-DAQmx to be able to now configure certain triggers and timestamps to be specified in terms of time of day. The IEEE 802.1AS-2011 profile is already enabled on these CompactDAQ Ethernet chassis, so to use this feature, all you need to do is install your application software and the NI-DAQmx driver.

Default IEEE 1588v2 profiles are not compatible with the 802.1AS profile.

(S)NTP


SNTP is a time synchronization method for clocks located on the Internet. The current time is obtained from public NTP servers. It uses a distributed network of NTP servers and synchronizes clocks within the network to national time standards over Ethernet. NTP and SNTP are indistinguishable from each other on the network level. SNTP has a smaller footprint in terms of memory and CPU usage while still being good enough to achieve system clock synchronization for typical desktop usage. Many industries, such as government and oil, prefer (S)NTP because it is a mature and well-tested standard that requires only a network connection. The major trade-off with (S)NTP is that it is less accurate than the other time-based technologies described in this article. It has typical accuracy on the order of tens of milliseconds. (S)NTP is not officially supported on LabVIEW Real-Time targets, but there are methods to enable it, as described below.

On CompactDAQ controllers based on NI Linux Real-Time, NTP can be enabled using an open-source Linux NTP daemon. Documentation on the NI Developer Community  details how to install this daemon to an NI Linux Real-Time target. Note that you should not install NI-TimeSync to your target if you choose to use this daemon. Both NI-TimeSync and this daemon adjust system time, and your systems may not synchronize properly if both NI-TimeSync and the NTP daemon are attempting to modify time on the target

For TSN-enabled Ethernet CompactDAQ chassis using NI-DAQmx 18.1 or later, there must be at least one IEEE 1588 or IEEE 802.1AS time reference running for NI-DAQmx tasks to start. Because running (S)NTP and NI-Timesync cannot run at the same time, (S)NTP time references cannot be used on TSN-enabled Ethernet CompactDAQ chassis using NI-DAQmx 18.1 or later.

Summary of Support for CompactDAQ Synchronization Methods

 

Synchronization Type Technology Multislot USB CompactDAQ Chassis Multislot ENET CompactDAQ Chassis CompactDAQ Controllers Running WES7 CompactDAQ Controllers Running NI Linux Real-Time
Signal-BasedNI-9469
Manual Routing With Digital I/O or PFI Lines
Time-BasedHW IEEE 1588v2 (default or 802.1AS)1
SW IEEE 1588v22
SNTP3

 

1IEEE 802.1AS-2011 synchronization is supported on the following Ethernet CompactDAQ chassis: cDAQ-9185 and cDAQ-9189. IEEE 802.1AS-2011 synchronization is also supported on CompactRIO with NI-DAQmx controllers allowing you to create distributed synchronized systems with a mix of devices.
2
SW IEEE 1588v2 synchronization is supported on only the following CompactDAQ controllers based on NI Linux Real-Time: cDAQ-9132/9133/9134/9135/9136/9137
3There is currently not an NI-supported method for enabling (S)NTP on CompactDAQ controllers running NI Linux Real-Time, but there are open-source options available. See the (S)NTP section above for more details.

The mark LabWindows is used under a license from Microsoft Corporation. Windows is a registered trademark of Microsoft Corporation in the United States and other countries. The registered trademark Linux® is used pursuant to a sublicense from LMI, the exclusive licensee of Linus Torvalds, owner of the mark on a worldwide basis.