A PID controller continuously compares a measured process variable (PV) with a setpoint (SP) and adjusts its output to remove the difference, using proportional, integral and derivative action. It is the default algorithm of industrial control: an ABB process-solutions paper states that over 90% of process control systems are based on PID type controllers. Knowing what each term does, and how to tune a loop methodically, is a core skill for any automation engineer.
What do the P, I and D terms do?
Proportional reacts to the present error, integral to the accumulated past error, and derivative to how fast the error is changing. The error is e = SP - PV.
In plain text, the ideal (standard) form is:
Output = Kp x [ e + (1 / Ti) x (integral of e over time) + Td x (rate of change of e) ]
where Kp is the proportional gain, Ti the integral time and Td the derivative time.
| Term | Responds to | Effect | Side effect |
|---|---|---|---|
| Proportional (P) | Current error | Larger error, larger correction; sets how aggressively the loop reacts | Alone, it leaves a steady-state offset |
| Integral (I) | Accumulated error over time | Removes the offset by continuing to correct until error is zero | Too much causes overshoot, oscillation and windup |
| Derivative (D) | Rate of change of error | Anticipates, damping the approach to setpoint | Amplifies measurement noise |
Vendors write the equation differently (gain versus proportional band, integral time versus repeats per minute, parallel versus standard form), so check your platform's definition before reusing numbers from another system (Wikipedia, PID controller).
What does a control loop look like in practice?
A loop is a measurement, a controller and a final control element in a ring. The diagram below shows a flow loop: a flow transmitter (FTX 001) sends the process value to the flow indicating controller (FIC 001), which compares it with the setpoint and sends a valve-position signal to the flow control valve (FCV 001). The controller can be a stand-alone device or a function block inside a DCS, SCADA or PLC system. Our sensors guide and actuators guide cover the two ends of that loop.

How do you tune a PID loop?
Put the loop in manual, bring the process to a steady state, then tune P first, then I, then D only if needed. Two widely taught methods are manual tuning and Ziegler-Nichols.
Manual tuning. Wikipedia's procedure: set integral and derivative to zero, increase Kp until the output oscillates, then reduce Kp to about half that value, add integral action to remove the offset, and add derivative action only if the response needs it. Make each change one at a time with a setpoint step and watch the response.
Ziegler-Nichols (closed-loop). John Ziegler and Nathaniel Nichols introduced this heuristic in the 1940s. Raise Kp, with I and D off, until the loop oscillates steadily; that gain is the ultimate gain Ku, and the oscillation period is Pu. The classic PID settings in Wikipedia's table are Kp = 0.6 x Ku, Ti = 0.5 x Pu and Td = 0.125 x Pu. For a PI controller, Kp = 0.45 x Ku and Ti is about 0.83 x Pu.
Worked example: suppose a temperature loop sustains oscillation at Ku = 4 with a period Pu = 60 seconds. Classic PID gives Kp = 0.6 x 4 = 2.4, Ti = 0.5 x 60 = 30 seconds and Td = 0.125 x 60 = 7.5 seconds. Treat these as starting values: they give a fairly aggressive response, so most process engineers detune them (lower Kp, longer Ti) to avoid overshoot. The test also drives the loop to sustained oscillation, which is unacceptable on many live processes, so agree it with operations first or use an open-loop step test instead.
This video introduces PID control and the intuition behind each term.
What are integral windup and derivative noise?
They are the two classic ways a textbook PID misbehaves in a real plant. Integral windup happens when the output saturates (a valve fully open, say) while error persists: the integral term keeps accumulating, then takes a long time to unwind after the process recovers. Wikipedia lists the usual remedies: pause integration while the output is saturated, or cap the integral term. This is called anti-windup, and the MATLAB video below covers it.
Derivative action amplifies higher-frequency measurement noise, because a noisy signal has a large rate of change. Low-pass filtering helps but limits how much derivative is worth having, which is why derivative is often small or omitted on noisy flow loops. Wikipedia reports an estimate that derivative action is used in only about 25% of deployed controllers.
Also look for bumpless transfer when switching between manual and automatic, so the output does not jump at the changeover.
How do you read the response and decide what to change?
Judge a setpoint step by its overshoot, how quickly it settles and whether it oscillates, then adjust one parameter at a time. These are typical symptoms and the usual corrective direction:
| What you see | Likely cause | Usual action |
|---|---|---|
| Sustained, regular oscillation | Gain too high, or integral too fast | Reduce Kp; lengthen Ti |
| Slow creep back to setpoint after a disturbance | Integral too weak | Shorten Ti (more integral action) |
| Large overshoot after a setpoint step | Aggressive tuning, or windup | Reduce Kp; check anti-windup; consider setpoint ramping |
| Jittery output on a steady process | Derivative amplifying noise | Reduce Td or filter the measurement |
| Output pinned at 0% or 100% | Wrong action direction, or undersized final element | Check direct or reverse acting, and the valve or drive sizing |
Always confirm the action direction first. A heating loop is reverse acting (more output raises the PV), a cooling loop is direct acting, and getting this wrong makes the loop run away to a limit.
Beyond a single loop, Wikipedia describes two common upgrades: cascade control, where an outer loop (for example temperature) sets the setpoint of a faster inner loop (for example steam flow), and feed-forward, which adds a correction based on a measured disturbance before it shows up in the error. Both reduce the burden on the PID itself.
Which loops are typically PI and which need D?
As a rule of thumb, fast and noisy loops use PI and slow loops with long lags may use PID. These are typical starting points, not rules:
| Loop | Typical behaviour | Common starting point |
|---|---|---|
| Flow | Fast, noisy | PI, modest gain, no derivative |
| Pressure (gas) | Fast | PI |
| Level | Integrating process | P or PI, depending on how tight the level must be |
| Temperature | Slow, with lag and dead time | PI or PID |
| Motor speed | Fast, often handled inside the drive | PI inside the drive |
How is PID implemented in Siemens TIA Portal?
TIA Portal provides the PID_Compact technology object for S7-1200 and S7-1500 CPUs. According to Siemens' documentation, PID_Compact calculates the proportional, integral and derivative parameters during pretuning, fine tuning can refine them further, and both manual and automatic modes are available. A sensible workflow is:
- Scale the process value to engineering units, and confirm the sensor reads correctly.
- Set realistic output limits for the final control element.
- Start from a stable operating point and run pretuning, then fine tuning if the response needs improving.
- Test setpoint steps and disturbances; check the behaviour when changing between manual and automatic.
- Record the final parameters and the operating conditions they were tuned for.
Auto-tuning is a starting point, not a substitute for judgement: always review the response and the limits against the process requirements.
How EDWartens can help
The Professional Module is a five-day live online Siemens TIA Portal class covering S7 PLC programming, HMI and WinCC SCADA, with self-paced Basic Engineering that includes control systems and automation. PID tuning is not a day-by-day topic of the live class, and the course is online and Siemens-focused, so there is no physical process rig. To practise loops, use the free process control simulator and the free PID control course. See the Professional Module or sign up.





