1. Distributed Applications Requiring Deterministic CommunicationThe tremendous growth in the number of computing devices as well as physical buses and networks connecting such devices has made distributed systems a logical solution for many applications in design, control, and test. While virtually all distributed systems require communication between the elements of the system, a subset of these systems require the communication to be deterministic. These distributed applications may include:
- Distributed motion control
- Industrial control and monitoring
- Hardware-in-the-loop simulation
- Software-in-the-loop simulation
- Synchronized data acquisition
For example, a fly-by-wire aircraft simulation may require a flight control simulator to communicate a new angle parameter to the rudder control simulator. The rudder must receive the latest angle parameter within a fixed amount of time; otherwise the response of the rudder will be late and the flight control system will fail. Buffering of data on the network does not alleviate the issue, because buffered data is useless in a dynamic system such as an aircraft. A fly-by-wire simulation is an example that falls on the extreme side of the network response spectrum, shown in Figure 1. Industrial control systems have similar requirements when I/O and processing is distributed among nodes. To meet the requirements of these applications, the network itself must have a real-time (deterministic) response.
Figure 1: Network response requirements by application
2. Deterministic Ethernet with the LabVIEW Real-Time Module
With the time-triggered network, two or more LabVIEW Real-Time PXI or PC targets can transfer data deterministically over a private Ethernet network using off-shelf-network interfaces. With this technology, network loops can be closed at network rates approaching 5 kHz. Each PC is also connected to a public network for normal network traffic and communication with additional network nodes.
Figure 2: Time-triggered networks use a dedicated private network to transfer data
3. Transferring Data with Shared Memory Blocks
Figure 3: Shared variables can be configured to be part of a time-triggered network
To configure the network, one node is designated as the master node while all other nodes are slaves. The period of each network cycle is also configured to be between
100 µs and 100 ms. In the example shown in Figure 4, the network cycle has been configured to be 500 µs. At the start of each cycle, the master node sends a cycle start packet to the slave nodes. Once the start cycle packet has ended, other network transfers can be scheduled.
Using one packet to transfer multiple shared variables reduces the overhead per transfer. The packets from each node are scheduled successively so they do not collide. For example, in Figure 4, the node named “RT I/O System” is scheduled to transfer all of its data 100 µs following the start of the network cycle. The length of the transmission will depend on the size of the data.
Figure 4: Shared memory blocks "reflect" data to other nodes
A software application executing on a real-time node can be programmed to receive an interrupt when a particular shared memory block has been updated. Figure 5 shows how the timing source can be used in conjunction with timed loops to process data as soon as it has been reflected to the network.
Figure 5: Use timing sources to trigger events on other network nodes
4. Transferring Data with Dedicated Slot Variables
Figure 6: Dedicated slot variables are scheduled to be sent at specific times during a network cycle
With dedicated slot variables, a loop can be closed in one network cycle. In Figure 6, all nodes will have received the Radar Simulator shared memory block and the RT I/O System shared memory block 130 µs into the network cycle. The master node has 45 µs between receiving the shared memory blocks (t=130) and the scheduled transmission of the Throttle shared variable (t=175) to process the data and produce a value for Throttle. Using dedicated slot variables, users can solve advanced applications that require a loop to be closed using a network.
5. Conclusion: Time-Triggered Networks Meet Advanced Application Requirements
With the time-triggered features of the LabVIEW Real-Time Module, users can develop advanced applications requiring deterministic transfer of data across an Ethernet network. This technology extends the reach of applications that can be handled with virtual instrumentation.
For a demonstration of LabVIEW Real-Time, to request a visit from your local field engineer, or to attend a FREE LabVIEW Real-Time Hands-On seminar, contact National Instruments at (800) 433-3488 or visit ni.com/realtime.
National Instruments Real-Time Software and Hardware