Building an NI Motion Control System


National Instruments offers motion control solutions for a variety of applications, ranging from simple single-axis control to distributed synchronized multi-axis control. This document provides a guide to NI’s Motion Control platform and offers some suggestions on selecting the right hardware setup for your application.



This document compares different implementations of a fully featured motion control system and assumes prior knowledge of a motion control system architecture and the various components that make it up, such as a real-time operating system and an FPGA.

For an introduction to motion system components and control concepts discussed below, see What is Motion Control? and the NI Motion Control Technical Library.

Motion System Components

A motion system is comprised of multiple components that interact to implement the various tasks necessary to perform motion control.  


Figure 1.  Motion Control System Architecture

Traditional motion control applications bundle many of these tasks together in proprietary software to abstract them from users. NI SoftMotion modularizes these tasks so they can be implemented on different components of the system depending on the application requirements and system hardware.

Figure 2. NI SoftMotion Architecture

The result is a flexible motion control system that abstracts much of the above architecture, yet lets you dive in to customize various pieces as needed while still interacting with the others high level components. See [NI SoftMotion] for further benefits of this implementation.

The flexibility of NI SoftMotion, combined with the NI Reconfigurable I/O (RIO) architecture, allows for many different system configurations. This document summarizes the different ways you can build an NI Motion Control System, and how each system implements the motion control architecture shown above.  

Distributed Motion control using EtherCAT communication

Figure 3. EtherCAT Drive based Motion Control System

An NI Real-Time controller combined with an AKD EtherCAT drive is simple to integrate, providing high performance servomotor control that is natively integrated with NI SoftMotion.

The real-time controller can be any NI Real-Time controller capable of acting as an EtherCAT Master (NI CompactRIO, PXI RT, NI Industrial Controller, or Compact Vision System) and runs the user’s code and the NI SoftMotion Engine. The controller is connected over the EtherCAT bus (uses standard CAT 5 cable just like an Ethernet network) to the AKD drive, which handles the interpolation of command signals, control loops, motion I/O such as limit, home, and emergency stop switches, and motor control signal generation.

Some of the advantages of this system setup include easy expansion and implicit synchronization. To add additional axis to the system, drives are daisy-chained as shown in the above figure. And because the system uses an EtherCAT bus, each additional drive added is automatically synchronized to the other components in the system.   

LabVIEW and the NI SoftMotion Module seamlessly support the NI AKD EtherCAT drives by offering complete project configuration. This allows customers to set up, configure, and validate a complete motion system from the LabVIEW project and develop their custom motion application using the NI SoftMotion API.

Figure 4. Motion Project Configuration and NI Softmotion API.

Controlling Third-Party EtherCAT Drives with NI SoftMotion

Figure 5.  Using an SDI Plug-in to control a third-party EtherCAT drive with NI SoftMotion.

National Instruments also offers support for third-party EtherCAT drives through the SoftMotion Drive Interface (SDI).  Download existing SDI plug-ins from the LabVIEW Tools Network or create your own using the LabVIEW project template provided by NI SoftMotion. With the SDI, you have a standardized method for integrating any EtherCAT drive into your application.  Learn more about the SoftMotion Drive Interface and current SDI Partners [here].

NI Ethernet Expansion Chassis and C Series Drive Interface

Figure 6. NI Ethernet Expansion Chassis based system

For simple automated motion tasks you can execute a NI SoftMotion based application with a Windows based host PC connected to the new NI 9149 Ethernet RIO Expansion Chassis and a C Series drive interface module. Using this approach, the NI SoftMotion engine is deployed on the NI 9149 to assure reliable execution of the motion control application, and so that users don’t have to realize a real-time application. The user application will be executed on the Windows based host PC, sending the position commands directly to the C Series drive interface modules using the RIO Scan Engine. This implementation offers the ease-of-use of programming a Windows based application and provides reliable motion control for closing the position control loops on dedicated hardware inside the C Series Module.

A drive interface module can connect to any compatible 3rd party drive, and the 9149 can implement up to 8 axis of motion (1 axis per drive interface module). The major advantages of this hardware configuration are the ability to program a Windows-based application while retaining reliable deterministic execution of your motion control application, as well as the ability to add any of over 100 NI and 3rd party C Series Modules to easily integrate other types of I/O into a motion application.

CompactRIO Based Systems

For applications that require tighter determinism or which operate autonomously, users can switch to a CompactRIO Real-Time system by simply deploying their application to a Real-Time controller instead of a NI 9149 RIO Expansion Chassis.  The user code requires no modification between targets.

Depending on the power requirements of the motors and the level of control loop access the application requires, customers can choose between C Series drive interface modules, which connect the NI CompactRIO system with an external drive, or C Series Drives which include power electronics to directly connect to lower power stepper or servo motors. There is also a 3rd option that enables customization of the FPGA control implementation and use of standard NI I/O modules through User-Defined Variables.

1.      C Series Drive Interface Modules

Figure 7. cRIO and C Series Drive Interface System

NI 951x C Series drive interface modules for NI CompactRIO offer direct connectivity to hundreds of stepper and servo drives. These motion modules provide servo or stepper drive interface signals for a single axis to connect the CompactRIO system to an external drive. In addition, they offer a full set of motion I/O including inputs for a home switch and limit switches, incremental encoder inputs for position feedback, and digital input and digital output lines. The NI 951x drive interfaces include a processor to run the spline interpolation engine and the patented NI step generation algorithm, allowing them to be used in LabVIEW Real-Time or customized using LabVIEW FPGA.

This system setup is best for interfacing to existing 3rd party drive and motor hardware in a system, and offers the same C Series expansion options with other types of I/O as mentioned above.

National Instruments offers direct connectivity cables from the C Series drive interface modules to servo drives (AKD) also available from National Instruments. For connectivity to third party drives different cable and connector block bundles are available. Visit [link] for more information about the C Series drive interface modules, and which one would best suit your application.

2.      C Series Drives

Figure 8. cRIO and C Series Drive based System

For motors up to the power of around 100W National Instruments offers C Series drive modules which can directly provide the required current to the motor coils. In this case no external drive is required and all of the control algorithms are implemented within the FPGA.  NI offers C Series drive modules that can connect and control Brushed DC, Brushless Servo, and Stepper motors.

This system offers the advantage of integrating the drive directly into the cRIO chassis, eliminating another piece of hardware and lots of additional cabling.  It is an ideal option for space-conscious applications.

3.      Standard C Series I/O Modules and User-Defined Variables

Figure 9. A system utilizing User-Defined Variables to create a custom control loop using standard NI C Series Modules

Besides the autonomous execution of your control application, the deployment to a real-time CompactRIO system offers additional customization. If your application requires specialty feedback or advanced control algorithms for the position control loop you can move this part of the algorithm in the FPGA off the CompactRIO backplane and use LabVIEW FPGA programming to customize or replace the algorithms with your own implementation. This also allows you to use Standard I/O modules from NI or 3rd party vendors instead of the C Series motion modules to connect to specialty encoders like EnDAT encoders or resolvers, or to implement applications with more than 8 axis using high-channel count input and output modules. This implementation requires additional LabVIEW Modules like LabVIEW Real-Time and LabVIEW FPGA.

NI SingleBoard RIO

Figure 10. NI Singleboard RIO based system

If you are looking for a small footprint and plan to deploy your control system in larger quantities you can implement the same motion control system on the NI SingleBoard RIO, an unpackaged version of the NI CompactRIO system. This platform requires custom packaging and will leave certification and the implementation of safety features up to the customer, but provides a more cost-effective solution for larger deployment quantities. Most of the NI C Series modules, including the motion drive and drive interface modules, are also available as board-only versions.

Ethernet-Capable Stepper Drives and Motors

Figure 11. NI offers a variety of Ethernet-capable Stepper Drives and Integrated Stepper Motors that can be controlled from a PC or Real-Time Target like CompactRIO.

National Instruments offers a stepper motion portfolio with easy-to-configure, Ethernet-connectible Integrated Stepper Motors and Stepper Motor Drives.  Integrated Stepper Motor (ISM) technology allows drive and motor to be combined into a single device, eliminating wiring complexity, cost, and system footprint.  Stepper Motor Drive (SMD) technology provides an easy-to-configure, easy-to-connect interface for NI and third-party stepper motors.  For simple applications, an Ethernet-connected drive eliminates the need for a drive interface module, reducing system cost and wiring complexity.  Any PC or platform with NI SoftMotion installed and an Ethernet adapter can interact with these ISMs or SMD drives.  Learn more about ISMs [here] and learn more about SMD drives [here].


National Instruments offers motion control solutions for a variety of applications, ranging from simple single-axis control to distributed synchronized multi-axis control.

Figure 12. NI Motion System Options: Each system contains multiple components, but is titled by its defining feature.

NI SoftMotion, combined with the NI Reconfigurable I/O (RIO) architecture, is the foundation upon which these system permutations are built, and allows for seamless integration of other I/O types with motion control. Continue to explore the above systems and more at [].