Blog

Comparing Ethernet and USB cDAQs for Control Applications

Comparing Ethernet and USB cDAQs for Control Applications

DMC recently completed a project that involved controlling an applied load using a hydraulic cylinder. Ramping the load at a controlled rate required a fast control loop with analog feedback from a load cell. The speed of the hydraulic cylinder was determined by a proportional valve controlled by an analog output from DMC’s control system.

Based on other requirements of the software, DMC chose a PC-based control system using National Instruments hardware. The customer wanted the control computer to be located far away from the electrical panel that contained the data acquisition and control hardware. Given the desired distance between the PC and control panel, the customer requested an Ethernet CompactDAQ (cDAQ) system. However, concerned about the latency of the Ethernet connection, DMC decided to compare the functionality of the following data acquisition hardware:

National Instruments published an article on How to Choose the Right Bus for Your Measurement System. In this article, they compare various buses in five different categories. The comparison for USB to Ethernet is copied below:

 

USB

Ethernet

Waveform Streaming

60 MB/s

125 MB/s

Single Point I/O

Better

Good

Multi-device

Good

Good

Portability

Best

Best

Distributed Measurements

Better

Best

The Waveform Streaming category makes the Ethernet cDAQ appear “faster”. Waveform Streaming defines how quickly a large block of buffered data can be transferred to the PC. In order for our control loop to function properly, it needs to read an input, then calculate and set an output as quickly as possible. For this control application, Single Point I/O is the most critical category since we have a small amount of data (i.e. a “single point”) that we need to quickly update with minimal latency.

To test this, DMC implemented a program with a control algorithm which used a 10ms loop rate. This program was then run on a USB cDAQ and an Ethernet cDAQ. The result of the test was clear: a USB cDAQ is significantly better for high-speed control applications. The Ethernet cDAQ was approximately 5 times slower – the control loop still ran at 10ms, but the output to the hydraulic cylinder was delayed by 40-50ms, which completely threw off the control algorithm.

The graphs below clearly illustrate the effect of the Ethernet’s latency. The exact same control algorithm and loop rate was used to generate these graphs, the only difference was the hardware.

Ethernet:
Ethernet cDAQ Graph

USB:
USB cDAQ Graph

In the end, DMC chose to use the USB cDAQ based on its vastly superior performance in this particular application.

Learn more about DMC's Test and Measurement Automation services.

Comments

There are currently no comments, be the first to post one.

Post a comment

Name (required)

Email (required)

CAPTCHA image
Enter the code shown above:

Related Blog Posts