This sample project is based on the Simple State Machine and Queued Message Handler templates. Refer to the Simple State Machine and Queued Message Handler templates and their documentation, available from the Create Project dialog box, for information about how these templates work.
This sample project consists of eight parallel loops on two execution targets. The following loops run in parallel on the desktop computer:
The following loops run in parallel on the real-time controller:
Locate the Control (PID) subdiagram of the Case structure in RT Loop - DAQ Control.vi and modify this subdiagram to apply a control algorithm. For example, you can use the PID VI that is included with the NI LabVIEW PID & Fuzzy Logic Toolkit. By default, this algorithm returns a constant value of 0 on all output channels. You can perform a different algorithm on each individual channel.
Although this sample project is designed to implement a PID algorithm, you can modify the sample project to use any algorithm.
The Safe Output Value in Global - Configuration Options.vi defines the value that is considered safe for the hardware connected to the output channels of the DAQ device. The Safe State, Default subdiagram of the Case structure in RT Loop - DAQ Control.vi writes this value to all DAQ output channels. By default, this safe state is a value of 0.
In the Project Explorer window, open My Computer»Globals»Global - Configuration Options.vi and configure the sample project settings.