Use the Asynchronous Message Communication (AMC) Reference Library to communicate between processes in a robotics application when you do not need to guarantee the transfer of every data point. AMC consists of a set of VIs that you download from the National Instruments Web site at ni.com. You can deploy processes that communicate using AMC to a single target or multiple targets depending on your resources and application needs. For example, assume that you use AMC to communicate between GPS, path planning, and steering processes in a robotics application. You could deploy all of those processes to an RT target or divide the processes between a host computer and an RT target without modifying code in either situation. If the processes reside on the same target, AMC transfers data using message queues. If the processes reside on different targets, AMC transfers data to those targets over the network using UDP. Those targets listen for the data with processes called AMC dispatchers, which transfer the data to other processes on the target using message queues.
The following figure shows an example of a robotics application that uses AMC to transfer data over a network.
|Note Refer to the National Instruments Web site at ni.com to download source code for this example.|
The following events occur in the previous figure.
|The GPS acquisition process on the RT target unicasts GPS data to a desktop computer.
|The AMC dispatcher on the desktop computer receives the GPS data and transfers it through a message queue to the path planning process.|
|The path planning process generates waypoints and unicasts them back to the RT target.|
|The AMC dispatcher on the RT target receives the waypoints and transfers them through a message queue to the steering process.|