Scaling S7-300 Analog Inputs: FC105 FC106 STEP 7 Reference

David Krause19 min read
S7-300SiemensTechnical Reference
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Overview of Analog Signal Scaling on S7-300

Every S7-300 analog input delivered by a SIMATIC S7-300 SM 331 (or generated by an integrated AI on a CPU with onboard I/O) appears in the process image as a signed 16-bit integer, not as a real engineering value. The S7-300 has no concept of "volts" or "°C" on its own — it only stores a number that is proportional to the input signal. Converting that number into bar, °C, ppm, m/s, or kW is what the SIMATIC documentation calls scaling, and it is the most common source of start-up problems on S7-300 stations.

Two functions are shipped with STEP 7 Classic for exactly this job:

  • FC105 (SCALE) — converts a raw analog input value to a real engineering value.
  • FC106 (UNSCALE) — converts a real engineering value back into a raw value for an analog output module (SM 332 / SM 334).

Both blocks live in the STEP 7 Standard Library under Libraries → Standard Library → TI-S7 Converting Blocks. The library is included with every STEP 7 V5.x installation and is also distributed with the SIMATIC S7-300 documentation package. The official Siemens Knowledge Base article "How do you scale analog values in STEP 7 V5.x?" (entry ID 786890) is the canonical reference for the FC105/FC106 block behaviour.

Read this first. The S7-300 does not implement automatic engineering-unit conversion inside the analog input modules. Even though the SM 331 supports voltage, current, RTD and TC, the module only gives you back a number in the range 0..27648 (unipolar) or -27648..+27648 (bipolar). It is the user's FC105 (or hand-written code) that performs the linear transform into engineering units. Skipping FC105 is the most common reason a panel reads -32768 or 32767 at commissioning.

Raw Value Encoding and Numeric Ranges

SIMATIC S7-300 analog channels use a fixed 16-bit left-aligned representation in the process image. The relationship between the electrical signal at the terminal and the integer in the process image is defined in the SIMATIC S7-300 module data manual (SM 331 / SM 332 manual, entry ID 8859629):

Signal type Module measurement range Raw value range Overflow Underflow
Voltage ±10 V -10 V … +10 V -27648 … +27648 32767 -32768
Voltage 0…10 V 0 … 10 V 0 … 27648 32767 -1
Voltage 1…5 V (live zero) 1 … 5 V 0 … 27648 32767 -1
Current ±20 mA -20 … +20 mA -27648 … +27648 32767 -32768
Current 0/4…20 mA 0 … 20 mA or 4 … 20 mA 0 … 27648 32767 -1
Current 4…20 mA (live zero) 4 … 20 mA 0 … 27648 32767 -1 (wire break: -32768 on diagnostic modules)
RTD PT100 standard -200.0 … +850.0 °C -2000 … +8500 32767 -32768
RTD PT100 climatic -120.0 … +130.0 °C -1200 … +1300 32767 -32768
TC type K, internal comp. -270 … +1372 °C -2700 … +13720 32767 -32768

The overflow value 32767 and the underflow value -32768 are the same on every S7-300 AI module, regardless of resolution. A raw value of 32767 therefore does not mean "+327.67 V" — it means "the input signal is outside the configured range of this channel." Always mask these values in your scaling logic before passing the result to the HMI, otherwise a single broken wire can crash a recipe with a 3.3e5 ton/h reading.

The signed representation is also why STEP 7 keeps the bipolar raw range asymmetric: -27648 … +27648 (a span of 55296). The upper limit is 2^15 - 1 - 128 = 32670 for the linear part and the remaining codes 27649…32767 are reserved for diagnostic states. This is the same reason FC105 internally uses -27648 and +27648 as the bipolar endpoints and not ±32767.

S7-300 SM 331 Analog Input Module Catalog

Before picking a scaling formula, confirm which SM 331 is mounted in the rack. The raw value range is always 16-bit, but the effective resolution differs by module and that resolution decides whether a PT100 returns 0.1 °C steps or 0.01 °C steps.

Order number (MLFB) Channels / type Resolution Notes
6ES7331-1KF02-0AB0 8 AI voltage/current 12/13 bit Basic module, no diagnostics.
6ES7331-7HF01-0AB0 8 AI U/I/RTD/TC 14 bit Most common PT100 module, supports 2/3/4-wire RTD.
6ES7331-7NF00-0AB0 8 AI U/I/RTD/TC 16 bit High feature, used for accurate temperature.
6ES7331-7NF10-0AB0 8 AI U/I/RTD/TC 16 bit Replacement for -7NF00-0AB0.
6ES7331-7PF01-0AB0 8 AI TC / voltage 16 bit Thermocouple module with internal reference junction.
6ES7331-7KB02-0AB0 2 AI U/I/RTD 14 bit Low-cost 2-channel variant.
6ES7334-0CE01-0AA0 4 AI/2 AO combo 8 bit AI / 8 bit AO SM 334, very limited resolution.
6ES7335-7HG02-0AB0 4 AI/4 AO combo 14/12 bit SM 335 fast AI/AO.
RTD resolution: On a 6ES7331-7HF01 the PT100 climatic range (-120.0 … +130.0 °C) is encoded as -1200..+1300 (one digit = 0.1 °C), while the standard range (-200.0 … +850.0 °C) is encoded as -2000..+8500. Some older SM 331 modules return 15-bit unsigned values; STEP 7 still maps these into the same 0…27648 range after the channel driver normalises them. Always check the module's Properties → Inputs → Measuring tab in HW Config before wiring FC105.

FC105 SCALE - Parameter Reference and Behaviour

FC105 takes the raw integer from an analog input, the bipolar/unipolar flag, and a real low/high engineering limit, and produces a real engineering value on the OUT pin. The block signature is fixed and identical on every S7-300/S7-400 firmware.

Parameter Type Meaning Typical source / value
IN INT (input) Raw value from the AI channel (PIW …) PIW 304
HI_LIM REAL (input) Upper engineering limit corresponding to full-scale 100.0 for 0-100 bar, 850.0 for PT100 high
LO_LIM REAL (input) Lower engineering limit corresponding to zero scale 0.0 for 0-100 bar, -200.0 for PT100 low
BIPOLAR BOOL (input) 1 = bipolar (-27648..+27648); 0 = unipolar (0..27648) TRUE for ±10 V, FALSE for 4-20 mA
RET_VAL WORD (output) FC error code (see diagnostic table below) MW 50
OUT REAL (output) Scaled engineering value MD 60 (or DB10.DBD0)

The internal equation executed by FC105 is:

OUT = ( (IN - K1) / (K2 - K1) ) * (HI_LIM - LO_LIM) + LO_LIM

where K1 = 0 and K2 = +27648 for unipolar, or K1 = -27648 and K2 = +27648 for bipolar. This is documented in the STEP 7 online help for FC105 (F1 in LAD/FBD/ST editors) and reproduced in the Siemens Knowledge Base article entry ID 786890.

Worked example 1 — 4-20 mA pressure transmitter 0-10 bar:

  • Hardware: SM 331 (6ES7331-7HF01) channel 0 wired to 4-20 mA, configured as 4-wire current, 4-20 mA range, address PIW 304.
  • FC105: IN = PIW304, HI_LIM = 10.0, LO_LIM = 0.0, BIPOLAR = FALSE, OUT = MD60.
  • At 12 mA (50 % of span): raw = 13824, OUT = 5.0 bar.
  • At 3.6 mA (live-zero failure): raw = -32768, FC105 returns 0.0 and sets RET_VAL = 0; the overflow must be detected before calling FC105 by checking PIW 304 = 32767 or PIW 304 = -32768.

Worked example 2 — bipolar ±10 V position sensor -100 % … +100 %:

  • Hardware: SM 331 (6ES7331-1KF02) channel 1 configured ±10 V, address PIW 306.
  • FC105: IN = PIW306, HI_LIM = 100.0, LO_LIM = -100.0, BIPOLAR = TRUE, OUT = MD64.
  • At +5 V: raw = 13824, OUT = +50.0 %.
  • At 0 V: raw = 0, OUT = 0.0 %.

FC106 UNSCALE - Parameter Reference and Behaviour

FC106 performs the reverse: it converts a real engineering value (e.g. a setpoint) into the raw integer that the SM 332 analog output requires.

Parameter Type Meaning Typical source / value
IN REAL (input) Engineering value to be output MD 100 (setpoint from HMI)
HI_LIM REAL (input) Engineering value at full-scale 100.0
LO_LIM REAL (input) Engineering value at zero-scale 0.0
BIPOLAR BOOL (input) Bipolar / unipolar target FALSE for 4-20 mA output
RET_VAL WORD (output) FC error code MW 110
OUT INT (output) Raw value to write to PQW … PQW 320

FC106 uses the same linear mapping as FC105 and clips the result to the valid range:

OUT = ( (IN - LO_LIM) / (HI_LIM - LO_LIM) ) * (K2 - K1) + K1

If the engineering value lies outside [LO_LIM, HI_LIM] the output is clipped to the nearest valid raw code (0 or 27648 unipolar; -27648 or +27648 bipolar). RET_VAL is set to W#16#0000 — the clip does not raise an error, so a stuck HMI setpoint of 9999 bar will silently drive the valve to its hardware maximum rather than flagging a fault. Always clamp IN yourself before the call, and alarm on IN being out of range.

Linear Scaling Formula and Manual Implementation

On tight-cycle S7-300 systems FC105's call overhead (~600 µs on a CPU 315-2 DP) can be undesirable, or the user may want to scale more than four channels in a single FB. In these cases it is perfectly acceptable to inline the formula. The exact FC105 transform is:

// Unipolar:    raw in 0..27648
// Bipolar:     raw in -27648..+27648
// EU_HI / EU_LO: engineering full-scale and zero-scale

IF bipolar THEN
    normalized := INT_TO_REAL(raw) / 27648.0;       // -1.0..+1.0
    scaled     := normalized * (EU_HI - EU_LO)/2.0 + (EU_HI + EU_LO)/2.0;
ELSE
    normalized := INT_TO_REAL(raw) / 27648.0;       //  0.0..+1.0
    scaled     := normalized * (EU_HI - EU_LO) + EU_LO;
END_IF;

For ladder logic the same expression fits in four network segments using ITD (16→32 bit), DTR (32-bit int → REAL), /R, *R, +R. The Siemens application example "S7-SCL: Scale analog values without FC105" (entry ID 1094770) is the recommended template.

Watch the sign. The S7-300 raw value is an INT (signed 16-bit), not a WORD. If you read PIW304 into a MW and then L MW with an ITD, the sign is preserved. If you read it into a DBW that you cast as WORD first, the sign is lost and a value of 0x8000 becomes +32768 instead of -32768. This is the single most common bug when people "remove FC105 to save scan time."

FC105 and FC106 in Ladder / FBD / Structured Text

LAD (FC105):

  |  FC105                               |
  |  EN     IN           HI_LIM   LO_LIM  |
  |  |--+--|PIW 304|---- 100.0    0.0  --|BIPOLAR: FALSE
  |  |  |    |         |        |       |     |   RET_VAL    OUT
  |  |  |    |         |        |       |     +---| MW 50  |MD 60
  |  |  |    |         |        |       |         |       |

ST (FC105 inside a periodic OB1 segment):

// --- Scale 4-20 mA channel 0 to 0.0..10.0 bar ---
IF PIW304 = 16#7FFF OR PIW304 = 16#8000 THEN
    Pressure_Quality := 0;          // bad
    Pressure_EU      := 0.0;
ELSE
    Pressure_Quality := 1;          // good
    FC105(
        IN       := PIW304,
        HI_LIM   := 10.0,
        LO_LIM   := 0.0,
        BIPOLAR  := FALSE,
        RET_VAL  := FC105_RetVal,
        OUT      := Pressure_EU);
END_IF;

ST (FC106 for an SM 332 4-20 mA output):

// --- Drive valve to 0.0..100.0 %  ---
Setpoint_Clamped := LIMIT(0.0, Setpoint_HMI, 100.0);
FC106(
    IN       := Setpoint_Clamped,
    HI_LIM   := 100.0,
    LO_LIM   := 0.0,
    BIPOLAR  := FALSE,
    RET_VAL  := FC106_RetVal,
    OUT      := PQW320);

FBD block view (FC105 with explicit input terminals):

  • Top of the block: IN (INT), HI_LIM (REAL), LO_LIM (REAL), BIPOLAR (BOOL).
  • Bottom of the block: RET_VAL (WORD), OUT (REAL).
  • EN tied to TRUE; ENO is a pure OR of ENO = EN AND (RET_VAL = 0), so pass it on to the next block if you are chaining.

RTD and Thermocouple Scaling (PT100/PT1000/TC)

For resistance-temperature sensors and thermocouples, the SM 331 already linearises the signal and returns a 16-bit integer that is the temperature multiplied by 10 (PT100/PT1000 climatic) or 100 (TC type K, internal compensation). The S7-300 manual SM 331 manual, entry ID 8859629, section "Representation of measured values for resistance thermometers" lists every sensor type and the scaling factor.

Sensor Module raw range Engineering unit FC105 LO_LIM FC105 HI_LIM BIPOLAR
PT100 standard -2000 … +8500 °C × 0.1 -200.0 +850.0 TRUE
PT100 climatic -1200 … +1300 °C × 0.1 -120.0 +130.0 TRUE
PT1000 standard -2000 … +8500 °C × 0.1 -200.0 +850.0 TRUE
Ni100 standard -600 … +2500 °C × 0.1 -60.0 +250.0 TRUE
TC type K (int. comp.) -2700 … +13720 °C × 0.01 -270.0 +1372.0 TRUE
TC type S -500 … +17680 °C × 0.01 -50.0 +1768.0 TRUE

Notice the bipolar flag is always TRUE for RTD/TC channels even though the raw range is technically defined as the offset-by-10 representation of a value that can be negative. FC105 treats the symmetric -27648…+27648 range, but the actual limit codes for the sensor are smaller (e.g. -2000…+8500 for PT100 standard). The unused codes at the top of the range are simply unreachable: a process temperature of 999.0 °C will not produce raw=27648 on a PT100, because the sensor saturates at 850.0 °C and the module returns 32767 (overflow).

2-wire vs 4-wire PT100. The 6ES7331-7HF01 supports 2/3/4-wire RTD. With 2-wire mode, lead resistance is added to the measurement and a typical installation error of 0.3 Ω/lead produces ~0.8 °C of error. With 4-wire mode the lead resistance is cancelled in hardware. Whatever mode you choose, the scaling inside FC105 is identical — the difference is entirely in the analogue front end. See the SM 331 manual section "4-wire connection of resistance thermometers" for the wiring rules.

Overflow, Underflow, and Wire-Break Diagnostics

FC105 does not signal an overflow condition; it simply clips the input to the bipolar/unipolar limit and continues. The actual diagnostic information is held in the raw value itself:

Raw value (PIW) Meaning on SM 331 Recommended handling
+32767 (16#7FFF) Overflow — input above configured range (e.g. >20 mA on 4-20 mA channel) Set quality = bad, freeze last good value, raise HMI alarm "AI overflow ch x"
-32768 (16#8000) Underflow — input below configured range (e.g. <4 mA on 4-20 mA channel); also wire break on diagnostic-capable modules Same as overflow; on 4-20 mA treat as wire break
+32511 (16#7EFF) End of overrange (some modules only) Clamp to full-scale; flag warning only
-27649 … -32512 End of underrange (some modules only) Clamp to zero; flag warning only

For modules that support hardware diagnostics (6ES7331-7HF01 and newer), the wire-break and overrange events also set the corresponding bits in the channel diagnostics structure and trigger OB82 if it is loaded. Reading PEW 304 (peripheral error word) for the channel will give you a module-specific error code. Siemens Knowledge Base article "S7-300/400 Analog Modules - Diagnostics and Troubleshooting" (entry ID 19292950) lists the diagnostic byte layout.

Safe scaling wrapper (recommended pattern):

// Returns TRUE if the value is valid; OUT contains engineering value
FUNCTION_BLOCK FB_SafeScale
VAR_INPUT
    Raw       : INT;
    HiLim     : REAL;
    LoLim     : REAL;
    Bipolar   : BOOL;
END_VAR
VAR_OUTPUT
    EuValue   : REAL;
    Quality   : BOOL;     // 1 = good
END_VAR
BEGIN
    IF Raw = 16#7FFF OR Raw = 16#8000 THEN
        EuValue := 0.0;
        Quality := 0;
    ELSE
        FC105(
            IN       := Raw,
            HI_LIM   := HiLim,
            LO_LIM   := LoLim,
            BIPOLAR  := Bipolar,
            RET_VAL  := RetValLocal,
            OUT      := EuValue);
        Quality := 1;
    END_IF;
END_FUNCTION_BLOCK

Step-by-Step: Wiring FC105 in STEP 7 Classic

  1. Install the standard library. Open SIMATIC Manager → File → Open → Libraries and load Standard Library → TI-S7 Converting Blocks. You should see FC105 (SCALE) and FC106 (UNSCALE) in the right-hand pane.
  2. Copy FC105/FC106 into your S7 program. Drag both FBs from the library to the Blocks folder of your S7-300 station. They will be copied as FCs without an instance DB; the scaling limits are passed in at call time.
  3. Identify the AI address. Open HW Config, double-click the SM 331, switch to the Inputs tab, and read the start address of the channel (e.g. PIW 304). The address depends on slot position and module type — there is no default.
  4. Configure the channel measurement type. In HW Config → Inputs, set the channel to Voltage ±10 V, Current 4…20 mA, PT100 standard, etc. The choice directly drives the raw range that FC105 sees.
  5. Place a call in OB1 (or in a cyclic OB like OB35). In LAD/FBD/ST, drop an empty box, type FC105, and connect the inputs. A common mistake is to wire IN to a W data type; it must be IW (or PIW for direct peripheral access in OB82-driven OBs).
  6. Wire LO_LIM and HI_LIM with the engineering full-scale and zero-scale values. If the HMI shows the same bar reading on two channels, the limits are swapped — fix the parameter order, not the wiring.
  7. Set BIPOLAR to TRUE for ±10 V, ±5 V, ±20 mA, PT100, TC; FALSE for 0-10 V, 0-20 mA, 4-20 mA. A bipolar sensor wired to a unipolar FC105 call will show roughly half-scale at zero input.
  8. Connect RET_VAL to a status word you can monitor online (e.g. MW 200). RET_VAL should always be W#16#0000 for healthy operation.
  9. Connect OUT to the engineering variable, e.g. MD 300 or a symbolic tag "Pressure_bar". If you use a global symbol table, declare the variable as REAL, not DINT — STEP 7 will not warn about implicit truncation when the size matches.
  10. Compile, download, and go online. Open Monitor/Modify and force the PIW to a known value (e.g. 0 for a 4-20 mA channel with the transmitter disconnected). Verify the OUT reads the engineering value you expect (0.0 for 4 mA, 10.0 for 20 mA on a 0-10 bar input).

Verification, Commissioning, and Field Diagnostics

Before signing off the loop, run these checks in the order listed. Each one fails for a different root cause; resist the temptation to skip directly to "check the wiring."

  1. Raw value sanity — in Monitor/Modify, read the PIW directly. A constant value of 0 or 32767 is almost always a wiring problem. A constant value of 27648 ± a few LSBs on a 4-20 mA channel means the loop is in saturation — check the transmitter scaling, not FC105.
  2. Range check — apply 0 %, 25 %, 50 %, 75 %, 100 % of full-scale with a calibrator (Beamex MC6, WIKA CPC 8000, or any class-0.05 source) and verify the scaled value is within tolerance. For a 0-10 bar, 4-20 mA loop the expected values are 0.0 / 2.5 / 5.0 / 7.5 / 10.0 bar.
  3. Bipolarity check — on a ±10 V channel, apply 0 V and verify the output is exactly the midpoint of LO_LIM and HI_LIM. A small residual offset indicates BIPOLAR is set to FALSE.
  4. Wire-break response — disconnect one leg of the field wire. The raw value should jump to 32767 or -32768 within one scan. The wrapper FB should report bad quality on the HMI faceplate.
  5. RET_VAL polling — force a deliberate misconfiguration, e.g. set LO_LIM > HI_LIM. The RET_VAL should read W#16#0007. Reset to a valid configuration and confirm the error clears on the next scan.
  6. Scan-time impact — measure OB1 with and without the FC105 call. On a CPU 315-2 PN/DP each FC105 call is approximately 0.6 ms; on a CPU 319F-3 PN/DP it is approximately 0.05 ms. If 50+ channels are scaled in OB1, consider moving them to a slower OB (OB35 at 200 ms is typical for thermal loops).

Edge Cases, Alternatives, and Migration Notes

Negative raw values on unipolar modules. A 0-10 V channel cannot physically return a negative voltage, but it can return -1 (16#FFFF) as an underrange indicator. FC105 interprets -1 as -0.0000036 % of full-scale — essentially zero. To distinguish a real zero from an underrange, mask -1 before scaling.

Multiple ranges on one module. Channels 0-3 of a SM 331 6ES7331-7HF01 can be configured independently. If you mix a PT100 and a 4-20 mA on the same module, call FC105 with different HI_LIM/LO_LIM pairs and the same bipolar flag for the bipolar sensor. Forgetting the per-channel configuration is the standard cause of "the panel shows half of what it should."

FC105 vs NORM_X (S7-1500). On S7-1500 the successor block is NORM_X in the Basic Instructions → Converter group. The behaviour is identical but the I/O are explicit (MIN/MAX/VALUE instead of HI_LIM/LO_LIM/IN). When porting FC105 calls to a S7-1500 with TIA Portal, swap HI_LIM ↔ MAX, LO_LIM ↔ MIN, and pass the raw value as VALUE. The output is the same REAL. See the TIA Portal help entry "NORM_X: Normalize" and the migration guide "SIMATIC S7-1500 / ET 200 - Migration from S7-300/400" (entry ID 109478801).

SCALE library alternatives. The SIMATIC S7-300 documentation package also provides FB41 (CONT_C) and FB42 (CONT_S) for PID control, but these are controller blocks and not scaling blocks. For high-density systems (>8 channels) consider the function block SCALE_8 in the S7-SCL sample library, which scales up to eight channels per call and reduces the per-channel overhead to ~80 µs on a CPU 315.

Direct access in OB82. When a wire-break triggers OB82, the process image for the affected channel is not updated with the new value. Always read the channel via PID … (peripheral direct access) in OB82, not via PIW …, to see the current hardware state.

Multi-instance avoidance. FC105 and FC106 are pure functions — they have no instance DB. If your program has grown to the point where a single OB1 with hundreds of FC105 calls is hard to read, encapsulate the scaling inside an FB with the channel address and the engineering limits as VAR_INPUT, and call one instance per channel. The S7-300 supports 16 instances of the same FB per priority class without noticeable scan-time penalty on a CPU 31x-2 PN/DP or newer.

What is the difference between FC105 and FC106 on an S7-300?

FC105 (SCALE) converts a raw integer from an analog input (PIW) to a real engineering value using LO_LIM, HI_LIM, and the bipolar/unipolar flag. FC106 (UNSCALE) performs the reverse: it converts a real engineering value into the raw integer that an analog output (PQW) expects. Both are in the STEP 7 Standard Library under TI-S7 Converting Blocks.

Why does my scaled value read -32768 or +32767 on the HMI?

The raw value 32767 (overflow) or -32768 (underflow / wire break) means the input signal is outside the configured measurement range. FC105 clips the result to LO_LIM or HI_LIM, so the HMI shows a full-scale or zero-scale reading instead of a fault. Add a check IF PIW = 16#7FFF OR PIW = 16#8000 THEN quality := 0 before the FC105 call to detect the fault and alarm it.

How do I scale a PT100 input that returns values like 2350?

On a 6ES7331-7HF01 with PT100 standard range, the raw value is the temperature in tenths of a degree. Wire FC105 with IN = PIW, LO_LIM = -200.0, HI_LIM = 850.0, BIPOLAR = TRUE, OUT = MD. A raw value of 2350 then scales to 23.5 °C. Use LO_LIM = -120.0 and HI_LIM = 130.0 if the module is set to PT100 climatic range.

Do I need FC105 for a 4-20 mA channel on a CPU with onboard analog inputs?

Yes. The onboard analog inputs of CPUs 312C, 313C, 314C, and 315F-2 DP use the same 0-27648 raw range as the SM 331 modules, so a 4-20 mA input returns 0 at 4 mA and 27648 at 20 mA. FC105 with LO_LIM = 0.0, HI_LIM = 10.0, and BIPOLAR = FALSE converts this to 0.0-10.0 bar or any other engineering range you configure.

How do I replace FC105 with manual code on a slow S7-300 CPU?

Inline the linear formula OUT = ( (IN - K1) / (K2 - K1) ) * (HI_LIM - LO_LIM) + LO_LIM with K1 = 0 and K2 = 27648 (unipolar) or K1 = -27648 and K2 = +27648 (bipolar). Use ITD + DTR to convert the signed INT to REAL before dividing. Always read the PIW as INT, not WORD, or the sign is lost on negative raw values. The Siemens SCL example entry ID 1094770 provides tested code.

Can FC105 and FC106 be called from OB35 (cyclic interrupt) on S7-300?

Yes, and this is the recommended pattern for slow thermal loops. With OB35 at 500 ms the per-channel scan overhead is negligible and the HMI updates are smoother than with OB1-driven scaling. Make sure OB35 has a higher priority than any OB that writes to the same OUT variables, or use symbolic tags and the automatic cross-OB consistency check in STEP 7.

Back to blog