Overview: 3-Wire Transmitter Compatibility with the S7-1214C Onboard AI
The SIMATIC S7-1200 CPU 1214C integrates two onboard analog input channels (AI0 and AI1) directly on the bottom terminal strip of the module. These channels are factory-configured as single-ended voltage inputs with a nominal range of 0..10 V and 10-bit resolution. Because the onboard AI is hard-wired to a voltage input stage, there is no factory support for current-mode (4..20 mA) or RTD measurements on AI0/AI1 — those require an SM 1231 signal module or an external precision shunt.
Three-wire transmitters are an extremely common sensor class in discrete and process applications (inductive proximity, photoelectric, ultrasonic distance, pressure transducers, level switches). They use a shared 0 V conductor between the power supply return and the signal return, which means the sensor only needs three conductors instead of the four required by a fully isolated loop. The S7-1214C onboard AI accepts this wiring topology without modification, provided the sensor signal output is a true voltage (not a current sink) within the 0..10 V input window.
This article documents the field-proven terminal mapping, the 2M reference requirement, the TIA Portal configuration for the onboard AI, and a verification procedure for commissioning. References are drawn from the SIMATIC S7-1200 Programmable Controller System Manual and the SM 1231 wiring diagrams published in the TIA Portal documentation.
Prerequisites and Hardware Identification
Before terminating any conductor, confirm the exact CPU variant, the analog input topology, and the sensor manufacturer specifications.
-
Identify the CPU order number. The relevant variants of the S7-1214C with onboard 0..10 V AI are the DC/DC/DC, DC/DC/Relay, and AC/DC/Relay. Examples of common MLFBs include
6ES7214-1AG40-0XB0(DC/DC/DC),6ES7214-1BG40-0XB0(AC/DC/Relay), and6ES7214-1HG40-0XB0(DC/DC/Relay). All three carry the same two-channel onboard AI topology; only the digital output stage differs. -
Confirm firmware. The onboard AI configuration blocks (e.g.
AI0_CFG,AI1_CFG) and theIWinput word addressing exist from firmware V1.0 onwards, but the descriptive help, scaling blocks, and theSCALE_X/NORM_Xinstructions are stable from V4.0 onwards. Verify your firmware in Online & Diagnostics → CPU Information in TIA Portal V13+ or the matching Step 7 Basic variant. -
Confirm sensor specification. Open the sensor datasheet and locate: supply voltage range (typically 18..30 V DC for 24 V-class sensors), output type (voltage
0..10 Vor current4..20 mA), output load, and connector pinout. A 3-wire sensor typically identifies terminals as1 = U_b+,3 = 0 V / U_b-, and4 = S+(signal out) following the IEC 60947-5-2 convention. -
Confirm the analog reference plane. On the S7-1214C, the analog reference terminal is
2M.2Mis internally bonded to the digitalMterminal inside the CPU, but field wiring practice should still land the sensor 0 V on2Mand not onMto keep return currents segregated from digital switching noise.
4..20 mA, the onboard AI cannot read it directly. Either select a voltage-output sensor or wire a 500 Ω, 0.1% precision resistor across the AI terminals to convert 4..20 mA into 2..10 V, and accept the resulting input range reduction.S7-1214C Onboard Analog Input Topology
The onboard AI is implemented as a single-ended, unipolar voltage ADC with the following datasheet parameters. Refer to the SM 1231 wiring diagrams page in the TIA Portal documentation for the canonical reference wiring. The onboard AI on the CPU follows the same electrical principles as the SM 1231 AI 4×13 bit modules (e.g. 6ES7231-4HD32-0XB0) but with two channels instead of four.
| Parameter | Value |
|---|---|
| Number of channels | 2 (AI0, AI1) |
| Input type | Voltage, single-ended |
| Nominal range | 0..10 V (unipolar) |
| Resolution | 10 bits |
| Quantization step | ~9.77 mV (10 V / 1024) |
| Input impedance | ≥ 100 kΩ |
| Overvoltage protection | ±35 V continuous (refer to datasheet for current CPU revision) |
| Update rate | Depends on integration time setting (typically 1.25 ms / 2.5 ms / 16.67 ms / 20 ms) |
| Galvanic isolation | None between AI0 and AI1; backplane bus isolation only |
| Recommended cable | Shielded twisted pair, shield grounded at PLC end only, max 100 m |
The internal reference ground for the ADC is bonded to 2M. A signal connected to AI0 with its return landed on 2M is read as the differential voltage between those two terminals. A floating sensor (signal return not bonded to 2M) will produce unstable, drifting, or pegged readings because the ADC cannot establish a stable common-mode reference.
2-Wire, 3-Wire, and 4-Wire Sensor Architecture
Selecting the correct wiring scheme depends on the sensor output stage, the supply class, and the application environment. The S7-1214C onboard AI is compatible with all three sensor classes for voltage-output devices.
| Class | Conductors | Power path | Signal path | Compatibility with onboard AI |
|---|---|---|---|---|
| 2-wire (loop-powered) | 2 | Signal carries loop current (e.g. 4..20 mA) | Same pair as power | Requires 4..20 mA input — NOT supported on onboard AI without external shunt |
| 3-wire (shared ground) | 3 | Separate U_b+ and 0 V/U_b- conductors | Independent S+ conductor referenced to common 0 V | Supported for 0..10 V output sensors |
| 4-wire (fully isolated) | 4 | Separate U_b+ and 0 V/U_b- conductors | Isolated S+ and S- pair, no shared reference | Supported; land S- on 2M, S+ on AI.x |
A 3-wire sensor internally connects the sensor electronics 0 V rail to the signal return. Externally, only three terminals are presented: U_b+ (24 V supply positive), 0 V / U_b- (shared supply/signal return), and S+ (signal output, typically 0..10 V). When the PLC provides U_b+ from the same 24 V source that feeds the sensor's 0 V, both 0 V points are at the same potential and the signal is read against that potential at 2M.
Terminal Mapping: Connecting a 3-Wire Sensor
The terminal map below applies to a CPU 1214C DC/DC/DC variant with the typical Siemens 35 mm terminal block layout. The analog section is at the bottom-right of the removable terminal strip.
| Sensor terminal | Sensor function | Wire color (typical) | Lands on PLC terminal |
|---|---|---|---|
| 1 | U_b+ (24 V supply) | Brown | External 24 V source positive (e.g. PLC power module L+ or a dedicated analog 24 V rail) |
| 3 | 0 V / U_b- (common return) | Blue | 2M on the CPU terminal strip |
| 4 | S+ (analog signal out) | Black | AI0 (or AI1) on the CPU terminal strip |
2M terminal is reserved for the supply/signal common return only. A short between AI0 and 2M forces the ADC to read 0 V continuously regardless of sensor output.For dual-channel applications, repeat the mapping for the second sensor and land its 0 V on the same 2M terminal block. The 2M terminal accepts the parallel landings of both sensor returns because both sensors share the same 24 V source return. If the second sensor is fed from a different power supply, ensure both supplies share a common ground at 2M to prevent ground-loop drift.
Step-by-Step Wiring Procedure
- De-energize the cabinet. Open the main disconnect and verify absence of voltage on the PLC power supply terminals with a CAT III multimeter.
- Pull the removable terminal strip. Depress the small lever on the front of the terminal strip and slide it outward. This isolates the wiring work from the CPU.
-
Land the sensor 0 V on 2M. Strip 10 mm of insulation from the sensor blue conductor, crimp a ferrule (e.g. Weidmüller
90192000000.75 mm²), insert into the2Mposition, and torque to 0.6 Nm. -
Land the sensor signal on AI0. Crimp the black signal conductor and insert into the
AI0terminal. Torque to 0.6 Nm. -
Land U_b+ on the 24 V source. Do not power the sensor from the CPU's
L+if the sensor draws more than 100 mA continuous or shares a noisy digital 24 V bus. Use the analog 24 V output on the PM 1207 or a dedicated regulated 24 V supply. - Bond the shield at one end only. Strip the shield at the PLC end, terminate into a grounding bar or shield clamp within 50 mm of the terminal strip, and leave the sensor-end shield floating or terminate through a 0.01 µF capacitor to suppress high-frequency noise while breaking the DC ground loop.
- Reinsert the terminal strip. Slide it firmly into the CPU until the lever clicks. Re-apply cabinet power.
TIA Portal Hardware Configuration
The onboard AI does not appear as a separate device in the device configuration because it is part of the CPU itself. Configuration is performed in the CPU properties.
- In the project tree, right-click the CPU 1214C and select Properties.
- Navigate to Analog inputs in the left pane.
- For channel 0 (and channel 1 if used), set the following parameters:
Parameter Setting Measurement type Voltage Voltage range 0..10 V Integration time 20.0 ms (50 Hz rejection) or 16.67 ms (60 Hz rejection) Smoothing None, Weak, Medium, or Strong (per application noise) Diagnostics Wire break — disable (0..10 V does not support reliable wire break detection) - Click Compile and download the hardware configuration to the CPU.
The 10-bit unipolar conversion yields a raw input word from 0 (at 0 V) to 27648 (at 10 V) following the Siemens SIMATIC analog value representation. Note that the onboard 10-bit converter is normalized to the same 0..27648 scale as the 13-bit SM modules for software compatibility — the lower 3 bits simply remain at zero.
TIA Portal Program Block: Scaling the Reading
The raw value in %IW64 (AI0) or %IW66 (AI1) must be scaled to engineering units. Use the standard NORM_X and SCALE_X instructions, or a manual scaling calculation.
Manual scaling formula:
Engineering_value = ((Raw - 0) / (27648 - 0)) * (Eng_max - Eng_min) + Eng_min
Structured Text (SCL) implementation in OB1:
// AI0 raw value from %IW64
"DB_AI".RawInput := %IW64;
"DB_AI".NormResult := NORM_X(MIN := 0, // raw low
VALUE := %IW64,
MAX := 27648); // raw high
"DB_AI".EngValue := SCALE_X(MIN := 0.0, // engineering low, e.g. 0.0 bar
VALUE := "DB_AI".NormResult,
MAX := 100.0); // engineering high, e.g. 100.0 bar
Ladder logic alternative using CALCULATE:
CALCULATE(EN := TRUE,
IN1 := %IW64,
IN2 := 100.0,
IN3 := 0.0,
OUT := "DB_AI".EngValue,
// (IN1 / 27648.0) * (IN2 - IN3) + IN3
);
For sensors with non-zero output at zero measurement (e.g. 1..5 V transmitters, which require a 4..20 mA-to-voltage conversion or a different output class), adjust MIN and MAX of NORM_X to 5529 and 27648 respectively (corresponding to 2..10 V after a 500 Ω shunt).
Verification Procedure
-
Online watch table. Open a watch table, drag
%IW64into the column, and go online. With the sensor disconnected, the raw value should be0(within ±2 counts of noise). -
Apply a known reference. Connect a precision 24 V supply directly to AI0 through a calibrated 0..10 V source (e.g. a precision decade box or a calibrated process calibrator). Verify
%IW64reads within ±0.5% of full scale. -
Power the sensor and observe. Apply 24 V to the sensor U_b+. With no process stimulus, the raw value should match the datasheet zero-output (e.g.
0for a 0..10 V output, or the live-zero value for 1..5 V class). -
Apply full-scale stimulus. Drive the sensor to its rated maximum. The raw value should reach the expected full-scale count (e.g.
27648for a 0..10 V sensor at maximum). - Verify linearity. Step through 0%, 25%, 50%, 75%, and 100% of full scale and confirm the scaled engineering value matches each step within the datasheet accuracy specification.
- Check shield effectiveness. Power-cycle any large VFDs or contactors in the cabinet while monitoring the raw value. Drift greater than ±10 counts indicates inadequate shielding or shared 0 V with a noisy digital return.
Troubleshooting Matrix
| Symptom | Likely root cause | Corrective action |
|---|---|---|
Raw value reads 32767 (overflow) |
Sensor output exceeds 10 V, or signal landed on wrong terminal, or polarity reversed | Verify signal is within 0..10 V with a multimeter at the PLC terminals. Reverse S+ and 2M if miswired. |
Raw value reads 0 regardless of stimulus |
Sensor unpowered, 0 V not landed on 2M, or signal shorted to 2M | Confirm 24 V at sensor U_b+ and U_b-. Confirm continuity between sensor 0 V and PLC 2M. Inspect for insulation displacement shorts. |
| Raw value drifts or jumps | Floating reference, ground loop, shared 24 V with digital noise, or inadequate shield termination | Land sensor 0 V directly on 2M. Power the sensor from a clean analog 24 V source. Re-terminate the shield at the PLC end. |
| Reading is offset by a constant value | Sensor has a non-zero zero output (e.g. 1..5 V device misconfigured as 0..10 V), or sensor calibration drift | Recalibrate sensor zero per datasheet, or correct the NORM_X MIN parameter to match the actual zero-output raw count. |
| Reading is inverted or full-scale at zero stimulus | Signal polarity reversed at the terminal | Swap the S+ and 2M connections if the sensor is single-ended and true polarity reversed. |
| One channel reads correctly, the other reads noise | Unshielded cable on the noisy channel, or sensor powered from a different supply without a shared ground | Use shielded twisted pair. Bond both supplies' 0 V at the PLC 2M terminal. |
Expanding Beyond Two Channels (When to Use SM 1231)
The two onboard channels are sufficient for simple two-loop control applications. When the system requires more channels, isolated inputs, current (4..20 mA) loops, RTD, or thermocouple measurements, expand with an SM 1231 signal module. Common expansion modules include:
-
6ES7231-4HD32-0XB0— SM 1231 AI 4×13 bit, voltage and current configurable per channel -
6ES7231-5ND32-0XB0— SM 1231 AI 4×16 bit, higher resolution -
6ES7231-5PD32-0XB0— SM 1231 AI 8×16 bit, high-density channel count
The SM 1231 wiring diagram set is published in the TIA Portal documentation under SM 1231 wiring diagrams. The 4..20 mA current wiring on the SM uses the same terminal strip pattern but adds a shunt resistor selection in the device configuration. For 3-wire voltage sensors, the wiring remains identical to the onboard AI: land sensor 0 V on M (or M ana on newer modules) and S+ on the AI terminal.
Can I connect a 3-wire 4..20 mA sensor to the S7-1214C onboard AI?
No — the onboard AI is a 0..10 V voltage input only. To read 4..20 mA on AI0/AI1 you must convert the current to voltage with a precision 500 Ω shunt resistor (0.1% tolerance, 50 ppm/°C or better) wired across AI0 and 2M, which produces a 2..10 V signal. For a clean current input with galvanic isolation and wire-break diagnostics, use an SM 1231 module such as the 6ES7231-4HD32-0XB0.
Does the sensor's 0 V have to land on the CPU's 2M terminal?
Yes. The S7-1214C onboard ADC references its input against 2M. If the sensor 0 V is left floating or bonded to a different ground, the ADC cannot establish a stable common-mode reference and the reading will drift, read zero, or peg at overflow. Land the sensor 0 V (terminal 3 on a typical IEC 60947-5-2 3-wire device) on 2M at the PLC end.
What is the raw count for 0 V and 10 V on the onboard AI?
The onboard AI is normalized to the SIMATIC analog value range: 0 V reads 0 and 10 V reads 27648. The raw value appears in %IW64 for AI0 and %IW66 for AI1. Use NORM_X and SCALE_X to convert the raw count to engineering units.
How long can the analog cable be between the sensor and the S7-1214C?
Siemens specifies up to 100 m for shielded twisted-pair analog cable on the SM 1231 family; the onboard AI follows the same recommendation because it shares the same ADC topology. Keep the cable physically separated from VFD power cables and AC contactor wiring, and terminate the shield at the PLC end only.
Can I power the 3-wire sensor from the PLC's L+ terminal?
Yes, provided the sensor current draw is below the L+ terminal rating (typically 300 mA continuous for the CPU L+ terminal, shared with all digital outputs and any devices powered from the same rail). For noise-sensitive analog sensors, powering from a dedicated analog 24 V supply or from the PM 1207's analog output reduces conducted digital noise coupling into the AI.