If you replace the numeric values, you get the following transfer function: For the sake of simplicity consider a basic transfer function for a DC motor where effects such as friction and disturbances are being considered:ī is the Friction Torque Constant (1.8E-6 N-m-s) In this tutorial, we will design the velocity controller for a DC motor. Your goal is to implement a PID algorithm that is going to run on a Real-Time controller with a loop rate of 1000 Hz (0.001 second period).
Start by opening the LabVIEW Development Environment and navigating to the Block Diagram. On the Functions Palette, select Control Design & Simulation->Simulation->Control & Simulation Loop then click and drag to size and create a Control & Simulation Loop.įigure 1. Create a Control & Simulation Loop.Īgain on the Simulation subpalette, select Continuous Linear Systems and click once on Transfer Function and once inside the Control & Simulation Loop you created previously. This places a Transfer Function block inside the Control & Simulation Loop.
Now double-click on the Transfer Function block to input the transfer function parameters.įigure 3. On the function palette, select the Control Design & Simulation->PID subpalette and drag and drop the PID.vi into the Control & Simulation Loop.