CPU 1512SP vs S7-1200 1214C: Sizing 25 PID Temperature Loops
Selecting a SIMATIC controller for a multi-zone thermal process (heat-treat furnace, plastic-extrusion die, hot-plate battery, environmental chamber) usually starts with one question: can the CPU sustain 25 PID loops at the scan time the process demands? This reference sizes the two controllers most often proposed for this workload - the S7-1200 CPU 1214C DC/DC/DC (6ES7214-1AG40-0XB0) and the ET 200SP CPU 1512SP-1 PN (6ES7512-1DK02-0AB0, 200 KB program / 1 MB data) - and walks through the cyclic-interrupt, phase-shift, and memory-budget decisions needed to land on a defensible choice.
1. Problem Statement & Control Architecture
The target application is 25 independent heat-only temperature zones. Each zone contains:
- One PT100 (RTD, 2- or 4-wire) measuring the workpiece or platen temperature.
- One control element (analog 0-10 V or 4-20 mA to a thyristor power controller driving a resistive heater).
- One PID loop with a target scan time of 300 ms (matches the dominant time constant of typical heated masses: thermal τ in tens of seconds, disturbance spectrum well below 1 Hz).
There is no cascade and no master/slave relationship. The user program is supervisory only: it writes setpoints, monitors alarms, and handles mode changes. The 25 PIDs are the dominant CPU load.
The two candidate controllers differ significantly in:
- Work memory for code and instance data.
- Bit-instruction throughput - relevant because each PID block runs sequentially inside its cyclic-interrupt OB.
- Number of cyclic-interrupt OBs available for distributing PID execution.
Each candidate is evaluated against (a) fitting 25 PID instances into work memory, (b) sustaining a 300 ms effective PID sample time under all 25 loops, and (c) leaving CPU headroom for the supervisory program and PROFINET diagnostics.
2. CPU Candidates: Specifications & Catalog Numbers
| Specification | S7-1200 CPU 1214C DC/DC/DC | ET 200SP CPU 1512SP-1 PN |
|---|---|---|
| Order number (MLFB) | 6ES7214-1AG40-0XB0 | 6ES7512-1DK02-0AB0 |
| Firmware at writing | V4.4 / V4.5 | V2.9 (DK02 hardware) |
| Work memory (program) | 100 KB | 200 KB |
| Work memory (data) | 4 MB load | 1 MB data |
| Bit operation (typical) | 0.08 μs | 0.048 μs |
| Onboard I/O | 14 DI / 10 DO / 2 AI | none (head module) |
| PROFINET interfaces | 1 | 3 (X1, X2, X3 with switch) |
| PROFINET IO controller | Yes | Yes |
| Cyclic-interrupt OBs | OB30–OB38 (9) | OB30–OB38 (9) |
| OB1 minimum cycle | 1 ms | 1 ms |
| Phase offset (cyclic OBs) | 0–30 000 ms | 0–30 000 ms |
| PID_Compact support | Yes (FW 4.0+) | Yes |
| PID_Temp support | Yes (FW 4.4+) | Yes (FW 2.0+) |
| 25 PID_Temp headroom | Marginal / none | Comfortable |
Specifications are taken from the S7-1200 System Manual (109754400) and the ET 200SP System Manual (58649293). Confirm the firmware release against the Siemens Industry Online Support entry for your specific MLFB before ordering.
3. PID Block Selection: PID_Compact vs PID_Temp
TIA Portal ships three PID libraries; the right one for 25 heat-only zones is the trade-off between footprint, autotune capability, and pre-conditioning for thermal processes.
| Block | FB number | Best use | Approx. instance DB | Available on 1214C | Available on 1512SP |
|---|---|---|---|---|---|
| PID_Compact | FB 1130 | Universal continuous PID | 0.7–1.5 KB | Yes | Yes |
| PID_3Step | FB 1131 | Motorised / solenoid valve | 1.0–2.0 KB | Yes | Yes |
| PID_Temp | FB 1132 | Temperature-specific (auto-tune, multi-zone) | 2.0–3.5 KB | Yes (FW 4.4+) | Yes |
PID_Temp is the technical first choice for heat-only processes because it includes:
- Anti-windup, derivative filter, and setpoint ramp shaping sized for thermal time constants.
- Pretuning and tune in running wizards that converge from a cold-start in a few cycles.
- Two auxiliary outputs (OutputHeat, OutputCool) that can be wired to the same analog output if cooling is not used.
See the PID_Temp block description (108591596) for parameter details. If footprint is the binding constraint, fall back to PID_Compact; the user is giving up the temperature-specific tuning heuristics, not basic loop closure.
4. Memory Budget for 25 PID Instances
A back-of-envelope memory budget decides the choice before cycle-time is even considered.
Memory budget (PID_Temp):
25 instances x 2.5 KB (avg instance DB) = 62.5 KB
+ 1x PID_Temp FB code (shared) approx. 50 KB
+ 1x PID_Compact FB (auxiliary) approx. 8 KB
+ supervisory logic, alarms, I/Os approx. 25 KB
--------------------------------------------
Total program memory approx. 145 KB
The 1214C's 100 KB work memory cannot host 25 PID_Temp instances plus a normal supervisory program. Even compressing to PID_Compact:
Memory budget (PID_Compact):
25 instances x 1.0 KB = 25 KB
+ 1x PID_Compact FB code (shared) approx. 8 KB
+ I/O mapping, alarms, OB1 logic approx. 15 KB
--------------------------------------------
Total approx. 48 KB
Compiles into the 1214C, but only if the user is disciplined about no extra blocks. The 1512SP's 200 KB program memory accepts PID_Temp with comfortable headroom for future expansion. If the work envelope is fixed at 100 KB, you must use PID_Compact - and accept that autotune will be the generic PID_Compact variant rather than the temperature-tuned PID_Temp.
5. Cyclic-Interrupt Architecture (OB30–OB38)
Cyclic-interrupt OBs are the right execution container for PID blocks. They run at a fixed, hardware-time-stamped interval independent of OB1's scan - critical when the PID sample time must remain constant regardless of how busy the main scan is.
Both CPUs support nine cyclic-interrupt OBs: OB30 through OB38. Each OB has a configurable cycle time (1 ms to 60 000 ms) and a phase offset (0 to 30 000 ms). The phase offset staggers multiple cyclic OBs so that they do not all fire at the same instant.
| OB | Purpose in this design | Cycle time | Phase offset | Priority |
|---|---|---|---|---|
| OB1 | Supervisory: HMI, alarms, setpoint download, mode handling | Free (cyclic) | 0 | 1 |
| OB30 | Heat zones 1–5 (PID 1–5) | 100 ms | 0 ms | 16 |
| OB31 | Heat zones 6–10 (PID 6–10) | 100 ms | 20 ms | 16 |
| OB32 | Heat zones 11–15 (PID 11–15) | 100 ms | 40 ms | 16 |
| OB33 | Heat zones 16–20 (PID 16–20) | 100 ms | 60 ms | 16 |
| OB34 | Heat zones 21–25 (PID 21–25) | 100 ms | 80 ms | 16 |
Each cyclic OB runs five PID instances. With five OBs staggered at 20 ms intervals, the CPU sees one OB every 20 ms - never a spike of 25 PIDs at once. Each individual PID block is called every 100 ms; the PID block's internal CycleTime parameter is then set to 0.3 s (3 × OB cycle) so the output updates only every third call, which is the desired 300 ms effective sample time.
6. Phase-Shift Load Distribution
Phase shifting is the single biggest performance lever for multi-PID CPUs. Without it, OB30 fires every 100 ms and processes 5 PIDs in a 5–10 ms burst; OB31 fires immediately after, creating a CPU-load envelope of 5 PIDs every 100 ms, no smoothing. With 20 ms phase offsets, the load envelope becomes 1 OB every 20 ms, with each OB doing 1/5 of the total work. Worst-case cycle-time jitter is reduced by 5× and the OB1 main program is never starved.
Fig. 1 - Five cyclic-interrupt OBs staggered at 20 ms intervals, distributing 25 PID evaluations evenly across the 100 ms fundamental period.
Implementation: in TIA Portal, create five cyclic OBs (Add new block > Organizational block > Cyclic interrupt). Open the OB's properties and set:
OB30: Cycle time = 100 ms, Phase offset = 0 ms
OB31: Cycle time = 100 ms, Phase offset = 20 ms
OB32: Cycle time = 100 ms, Phase offset = 40 ms
OB33: Cycle time = 100 ms, Phase offset = 60 ms
OB34: Cycle time = 100 ms, Phase offset = 80 ms
7. PT100 Signal Conditioning & RTD Module Selection
PT100 inputs in TIA Portal are wired through dedicated RTD modules - never through standard analog inputs. Use the SIMATIC module selection that matches the line length and the required accuracy.
| Series | Module | Order number | Channels | Resolution | Typical accuracy |
|---|---|---|---|---|---|
| S7-1200 | SM 1231 RTD | 6ES7231-5PD32-0XB0 | 4 | 15 bit + sign | ±0.1 °C |
| ET 200SP | AI 4×RTD/TC 2-/3-/4-wire | 6ES7134-6JD00-0CA1 | 4 | 16 bit | ±0.05 °C |
Twenty-five PT100 channels need 7 modules in either series (4 ch × 7 = 28 channels, 3 spare for redundancy). Wire the RTD in 4-wire configuration to eliminate lead-resistance error:
Fig. 2 - 4-wire RTD wiring eliminates lead-resistance error; I+/I- carry the excitation, I0a+/I0a- sense the voltage drop directly at the PT100 element.
In TIA Portal, configure the RTD module's channel with the following parameters to match the application:
Measurement type : RTD thermal resistance
RTD type : Pt 100 (standard climatic range)
Temperature unit : °C
Temperature range : -200 ... +850 °C
Smoothing : 4 (or higher if the PT100 lead is electrically noisy)
Noise rejection : 50 Hz (mains frequency match)
Wire break detection: enabled
8. Analog Output & Heater Actuator Wiring
The user specified analog output to the heater driver, which is the most flexible approach (continuous phase-angle or burst-firing SCR power controllers). Output range is 0–10 V or 4–20 mA; the SCR unit determines which one.
| Series | Module | Order number | Channels | Resolution |
|---|---|---|---|---|
| S7-1200 | SM 1232 AQ | 6ES7232-4HD32-0XB0 | 4 (voltage or current) | 14 bit |
| ET 200SP | AQ 4×U/I | 6ES7135-6HD00-0CA1 | 4 (voltage or current) | 16 bit |
For 25 zones, use seven 4-channel AQ modules. Configure each channel for 0–10 V (unipolar) unless the SCR unit requires 4–20 mA for long cable runs. Map the PID's OutputHeat to the raw analog word and set the output scaling in the channel configuration (default 0–27648 corresponds to 0–10 V).
Fig. 3 - Heat-zone signal flow: CPU PID_Compact → analog output → SCR power controller → resistive heater. PT100 closes the loop on the temperature feedback path.
9. TIA Portal Configuration Procedure
- Hardware configuration. Add the CPU and the I/O modules to the device view. For ET 200SP: slot the CPU 1512SP first, then add BaseUnits (BU15-P16+A0+2D, 6ES7193-6BP00-0DA0) for each I/O module. Configure PROFINET network parameters (IP, subnet mask, gateway, device name).
- Insert cyclic OBs. Project tree → PLC → Program blocks → Add new block → Organizational block → Cyclic interrupt. Repeat five times for OB30 through OB34.
- Configure cyclic OB properties. For each OB, open Properties → Cycle / Phase offset. Set Cycle time = 100 ms, Phase offset = 0, 20, 40, 60, 80 ms respectively. Keep priority at the default 16.
- Add PID blocks. Project tree → Technology → PID Control → PID_Compact (or PID_Temp) → Add new instance. Repeat 25 times, one per zone. In the configuration dialog, assign each PID to one of the five OBs (five PIDs per OB).
- Set PID sample time. For each instance, open Configuration → Output / Limits → Cycle time. Set CycleTime = 0.3 s. The block will be called every 100 ms (its OB cycle) and update the output every third call.
- Wire I/O. In each PID's configuration, set Input to the PT100 scaled value (e.g. "DB_Zone1".ProcessValue), Input_PER to the raw RTD word (e.g. %IW0), and OutputHeat to the scaled AO word (e.g. "DB_Zone1".Output).
- Compile and download. Compile the project (Hardware and Software), then download to the CPU. Use "Download to target device" with PG/PC interface = PROFINET.
- Perform CPU online diagnostics. Right-click the CPU → Online & diagnostics → Cycle time. Confirm OB1, OB30, OB31, OB32, OB33, OB34 cycle times are within tolerance.
10. Cycle-Time Budget & Watchdog Analysis
Compute the worst-case execution time of each cyclic OB to confirm the watchdog is not violated.
OB30 worst-case (5 x PID_Temp, 1512SP DK02):
1x PID_Temp execution time, typ. 1.2 ms
5x = 6.0 ms
+ 7x RTD input scan (overlapped) 0.4 ms
+ 7x AO write (overlapped) 0.2 ms
+ alarm generation + HMI update 0.4 ms
-----------------------------------------
Total OB30 execution 7.0 ms
Cycle time 100 ms
Headroom 93 ms (approx. 15x)
For the 1214C, the same loop computes to:
OB30 worst-case (5 x PID_Compact, 1214C):
1x PID_Compact execution time 2.0 ms
5x = 10.0 ms
+ I/O scan (local modules) 3.0 ms
+ supervisory calls 2.0 ms
-----------------------------------------
Total OB30 execution 15.0 ms
Cycle time 100 ms
Headroom 85 ms (approx. 6.7x)
Both controllers clear the watchdog. The 1214C is operating with only 6.7× margin; if the user adds a second HMI poll, a GRAPH sequence, or a safety program, the margin tightens below 5× and the PID sample time becomes fragile. Field experience on earlier 1512SP hardware (FW 2.0, 16 PID_Compact loops + 100 ms safety program + 2–3 GRAPH blocks) was that the 100 ms cycle time had to be relaxed to 200 ms. On the DK02 hardware, the 25 PIDs at 300 ms cycle is comfortable.
11. Online Diagnostics & Acceptance Test
A repeatable acceptance test confirms the design before hand-over:
- Cycle-time trace. Open the Online & diagnostics view → Cycle time. Record OB1, OB30, OB31, OB32, OB33, OB34 minimum, average, and maximum cycle times over 5 minutes. The maximum should be below 50% of the cycle time on both CPUs.
- Memory utilisation. Online & diagnostics → Memory. Confirm used work memory is below 70% of the available 200 KB (1512SP) or 70% of 100 KB (1214C, with PID_Compact).
- Step-response test. On one zone, set a +20 °C setpoint step from ambient. Record the process value, the controller output, and the manipulated variable in the trace. The controlled temperature should reach the new setpoint without overshoot larger than 2 °C and without sustained oscillation. Use this zone to tune Gain, Ti, Td manually if autotune is unsatisfactory.
- Disturbance-rejection test. Open a door / disturb the airflow for 10 s on the same zone. The PID should re-converge to setpoint within 2 minutes with no oscillation. Document the IAE (Integral of Absolute Error).
- Wire-break test. Disconnect one PT100 lead. The PID should drop its output to a configurable safe value (default 0%) within 1 cycle and raise a wire-break alarm. Reconnect the lead and confirm automatic recovery.
- Watchdog test. Briefly insert a delay loop (e.g. 50 ms busy-wait) in OB30 and download. The OB should time-out, the CPU should enter STOP, and the diagnostic buffer should record "OB30 time-out". Remove the test loop and restart.
If any step fails (cycle time > 50%, memory > 70%, step response overshoots > 5 °C), revisit the cyclic OB count or move from PID_Compact on a 1214C to PID_Temp on a 1512SP. Do not raise the cycle time above 300 ms without re-checking the process dynamics: thermal mass time constants are usually long, but the disturbance spectrum from a multi-zone system can be much faster than the τ of a single zone.
Decision Summary
| Criterion | 1214C + PID_Compact | 1512SP + PID_Temp |
|---|---|---|
| 25 loops fit in work memory | Yes (tight) | Yes (comfortable) |
| 300 ms cycle time achievable | Yes (~6.7× headroom) | Yes (~15× headroom) |
| Future expansion headroom | Limited | Generous |
| Temperature-tuned autotune | No | Yes (pretuning, tune in running) |
| Watchdog margin under load | Marginal | Safe |
| Recommended use | Compact, fixed scope, cost-sensitive | Production system, growth path, mixed program |
12. Frequently Asked Questions
Can the S7-1200 CPU 1214C DC/DC/DC run 25 PID loops?
Yes - but only with PID_Compact, not PID_Temp. The 1214C has 100 KB of work memory; 25 PID_Compact instances (approx. 25 KB) plus the FB code (approx. 8 KB) plus a lean supervisory program fit. The 300 ms cycle is achievable on the OB30–OB34 phase-shifted architecture, but the cycle-time headroom is roughly 6.7× rather than 15× on the 1512SP. Adding a safety program, GRAPH blocks, or a second HMI poll is enough to push the 1214C out of margin.
What is the benefit of phase-shifting the cyclic-interrupt OBs?
Without a phase offset, all cyclic OBs fire at the same instant of their period, causing a CPU load spike. With 20 ms phase offsets, OB30 fires at t=0, OB31 at t=20, OB32 at t=40, OB33 at t=60, OB34 at t=80. The CPU load becomes a uniform 1 OB every 20 ms (each containing 5 PIDs), eliminating the load spike, reducing OB1 scan-time jitter, and protecting the cyclic OB watchdog.
How much work memory does each PID_Temp instance consume?
A PID_Temp instance DB occupies 2.0 to 3.5 KB depending on which options are enabled (multi-zone coupling, derivative action, setpoint ramp, limit monitoring). For 25 zones at 2.5 KB average, plan 62.5 KB of program memory for the instances alone, plus ~50 KB for the shared FB code. A 1512SP with 200 KB is the right size; a 1214C with 100 KB is not.
Which PID block is best for temperature control, PID_Compact or PID_Temp?
PID_Temp (FB 1132) is purpose-built for temperature. It includes temperature-tuned autotune (pretuning, tune in running), multi-zone coupling (heat-cool asymmetry), setpoint ramp generation, and anti-windup sized for thermal processes. PID_Compact (FB 1130) is a generic universal PID that does all the basic functions but lacks the temperature-specific heuristics. Use PID_Temp when the project has thermal time constants; use PID_Compact only when memory is binding.
How is the cyclic-interrupt phase offset configured in TIA Portal?
In the project tree, open the cyclic OB (e.g. OB30), select Properties, then in the "Cycle / Phase offset" section set the Cycle time in milliseconds and the Phase offset in milliseconds. The phase offset must be smaller than the cycle time. The phase offset is the time between the OB's scheduled start and the actual time it begins execution; it staggers multiple cyclic OBs so they do not fire at the same instant.