Establish what the channel returns
Confirm the input mode, data format, nominal endpoints, sign and diagnostic codes. Check the wiring, configuration, address and read type in sequence. Use the values the PLC actually receives after those transformations.
The SIMATIC S7-1200 G2 system manual shows an example with a 0 to 27,648 nominal count range. On a teaching scale from 50 to 100 °C, the arithmetic midpoint of 13,824 yields 75 °C. These are example endpoints for the documented case. OWEN MV210-101 can supply already scaled values or percentages. Applying a second scaling operation to an engineering-unit register distorts the reading.
Use floating-point arithmetic
For a raw count x, calculate f = (x − x₀)/(x₁ − x₀), then y = y₀ + f(y₁ − y₀). The signal endpoints must differ. Convert operands before division to avoid integer truncation. Selecting y₁ below y₀ reverses the scale. For inverse conversion swap the scales and apply the program’s rounding rules afterward.
Check four states
Verify both endpoints, the midpoint and one out-of-range count. Check module fault codes before scaling, then decide whether to flag or extrapolate a range excursion. Preserve bad-quality information if zero is a valid process value.
PLC analog input calculator · 0–10 V calculator · Siemens S7-1200 G2 system manual · OWEN MV210 manual