Demystify PID Controller Design

The PID controller design process, once a considered a complex task, can be implemented simply and directly from a PID block diagram to a working circuit with an FPAA (field programmable analog array) device and software tools—using the device itself to model physical processes. The silicon of the FPAA device is easily programmed with the use of CAD software tools and CAMs (configurable a...


The PID controller design process, once a considered a complex task, can be implemented simply and directly from a PID block diagram to a working circuit with an FPAA (field programmable analog array) device and software tools—using the device itself to model physical processes.

The silicon of the FPAA device is easily programmed with the use of CAD software tools and CAMs (configurable analog modules). CAMs, which are modular FPAA engineering building blocks (such as filters, gain stages, rectifiers, and comparators), abstract the circuit design and let the design engineer concentrate on developing system controls without concern for the details of the underlying circuitry. Circuits designed using this new methodology can be changed and downloaded in a matter of seconds, facilitating rapid implementation and testing. Furthermore, dynamic control 'C' code can be generated automatically, allowing configuration and modification of the FPAA device via a microprocessor.

Creating a PID controller with CAMs is straightforward because the engineer designs at a system level, not a circuit level. Starting from the left in the 'PID controller' graphic, both the SP (set point) and PV (process variable) are fed through analog anti-alias filters into an offset-compensated sum-difference stage. This stage creates the error signal, e(s). Note that because SP is being fed through a 4:1 multiplexed input, the circuit can be programmed to switch between four pre-configured set points. The error signal is then fed through a differentiator, an integrator, and individually to a sum-difference amplifier that creates the P+I+D controloutput, u(s). Finally, the signal is fed into a two-pole, low-pass filter, which removes noise and spurious signals while damping the control action to avoid an abrupt u(s) move that can damage some physical systems. This circuit has, in fact, implemented a PID controller with a second-order filter where Kp is proportional gain, Td is derivative gain, 1/Ti is integrator gain, andë is the response-speed parameter (filter time constant):

PID controller tuning

To design a controller, the P, D, and I gain constants are set appropriately to achieve a desired response curve for the plant. The engineer might tune based on damping coefficient, decay ratio, settle time, frequency response, or other criteria that meet a project's control requirement. Practical design and tuning techniques used in industrial process control include IMC, Cohen Coon, Ziegler-Nichols, and Ultimate gain. The PID controller must be tuned based on the mathematical characteristics of the process or plant being controlled.

As well as building the controller, FPAAs can be used to create a linear approximation of a process model, thereby saving the time needed to debug and tune a PID controller. Consequently, the engineer can tune the controller in simulation or simply download the plant and controller onto two separate FPAA chips. Having developed the PID control in this way using the FPAA plant model, it can be fine-tuned on the real plant.

PID controller implemented in an FPAA chip.

Various combinations of CAMs can create a wide variety of plant models. An integrator CAM, for example, can represent a pure capacity system. A negative voltage could represent an output flow from a tank, or a 'disturbance.' The 'FPAA model' graphic shows a simulated FPAA model of a tank filled by a control value with a sinusoidal varying outflow. The sinusoidal varying outflow could be changed to an on/off outflow by maximizing the gain in the rectifier and causing the sine wave to 'rail.' Using a periodic waveform generator to represent any arbitrary out- or inflow desired could vary the outflow further. These models can be run in simulation and then downloaded to the actual FPAA devices.

Filter Requirements

Filtering is an inevitable part of any control system, either for frequency band limiting or phase compensation.

The FPAA described here can be programmed with CAMs that will implement single-pole high-pass, low-pass, and all-pass filters and two-pole -high, -low, band-pass and band-stop filters. If more complex filters are required, the filter synthesis tool can both design and synthesize monolithic multi-pole filters of arbitrary complexity. An eight-pole filter can be created in a single FPAA device, and any number of these devices can be connected together.

Experiments have shown that these tool-generated filters are highly accurate and temperature-insensitive. These filters are directly synthesized from drag-and-place Bode plots or direct parameter entry with no need for the engineer to understand or work with components or filter mathematics.

Microprocessor control

An FPAA model of a tank with fill-valve and a periodic outflow.

An engineer can automatically generate 'C' code that will configure and control these FPAA devices. This 'C' code, which the engineer loads into a system as a library of custom-built 'C' subroutines, generates data segments to reconfigure and control an FPAA device. These data segments are uploaded into FPAA—a process which, depending on the size of the data segment and system clock frequency, can take just 10 microseconds or so per segment. They are then simultaneously applied at a system-designated instant without interrupting the operation of the device.

Any circuit configuration or parameter setting that the CAD tool can realize can be realized also from this embedded 'C' code. The FPAA can provide adaptive control, multiplex between several inputs and outputs, and perform multiple roles, saving engineering time and money.

Author Information

Chris Schene, Victor de la Torre and Mike Waters are software engineers with Anadigm.

No comments
The Engineers' Choice Awards highlight some of the best new control, instrumentation and automation products as chosen by...
The System Integrator Giants program lists the top 100 system integrators among companies listed in CFE Media's Global System Integrator Database.
Each year, a panel of Control Engineering and Plant Engineering editors and industry expert judges select the System Integrator of the Year Award winners in three categories.
This eGuide illustrates solutions, applications and benefits of machine vision systems.
Learn how to increase device reliability in harsh environments and decrease unplanned system downtime.
This eGuide contains a series of articles and videos that considers theoretical and practical; immediate needs and a look into the future.
Additive manufacturing benefits; HMI and sensor tips; System integrator advice; Innovations from the industry
Robotic safety, collaboration, standards; DCS migration tips; IT/OT convergence; 2017 Control Engineering Salary and Career Survey
Integrated mobility; Artificial intelligence; Predictive motion control; Sensors and control system inputs; Asset Management; Cybersecurity
Featured articles highlight technologies that enable the Industrial Internet of Things, IIoT-related products and strategies to get data more easily to the user.
This article collection contains several articles on how automation and controls are helping human-machine interface (HMI) hardware and software advance.
This digital report will explore several aspects of how IIoT will transform manufacturing in the coming years.

Find and connect with the most suitable service provider for your unique application. Start searching the Global System Integrator Database Now!

Infrastructure for natural gas expansion; Artificial lift methods; Disruptive technology and fugitive gas emissions
Mobility as the means to offshore innovation; Preventing another Deepwater Horizon; ROVs as subsea robots; SCADA and the radio spectrum
Future of oil and gas projects; Reservoir models; The importance of SCADA to oil and gas
Automation Engineer; Wood Group
System Integrator; Cross Integrated Systems Group
Jose S. Vasquez, Jr.
Fire & Life Safety Engineer; Technip USA Inc.
This course focuses on climate analysis, appropriateness of cooling system selection, and combining cooling systems.
This course will help identify and reveal electrical hazards and identify the solutions to implementing and maintaining a safe work environment.
This course explains how maintaining power and communication systems through emergency power-generation systems is critical.
click me