Fb 179 "F_Sca_I": Scaling Values Of Data Type Int - Siemens SIMATIC S7 Configuration And Programming Manual

Hide thumbs Also See for SIMATIC S7:
Table of Contents

Advertisement

1.2.11

FB 179 "F_SCA_I": Scaling Values of Data Type INT

Connectors
Parameter Data
Inputs
IN
HI_LIM
LO_LIM
Outputs
OUT
OUT_HI
OUT_LO
Mode of Operation
This F-application block scales the value at input IN in physical units between the
lower limit value at input LO_LIM and the upper limit value at input HI_LIM. It is
assumed that the value at input IN is between 0 and 27,648. The scaling result is
provided at output OUT.
The F-application block operates according to the following equation:
OUT = [ IN * (HI_LIM–LO_LIM)] / 27648 + LO_LIM
So long as the value at input IN is greater than 27,648, the output OUT is linked to
HI_LIM, and OUT_HI is set to 1.
So long as the value at input IN is less than 0, the output OUT is linked to LO_LIM,
and OUT_LO is set to 1.
For reverse scaling, you must assign LO_LIM > HI_LIM. With reverse scaling, the
output value at output OUT decreases while the input value at input IN increases.
Performance in the Event of Overflow or Underflow of Analog Values and Fail-
Safe Value Output
Note
If inputs from the PII of an SM 336; AI 6 x 13 bit are used as input values, you
must bear in mind that the F-system detects an overflow or underflow of a
channel of this F-SM as an F-I/O fault or channel fault. The fail-safe value 0 is
provided in place of 7FFF
safety program.
If other fail-safe values are to be output in this case, you must evaluate the QBAD
tag in the F-I/O DB (branch to output of an individual fail-safe value).
If the value in the PII of the F-SM is within the overrange or underrange, but is
greater than 27648 or less than 0, you can likewise branch to the output of an
individual fail-safe value by evaluating the outputs OUT_HI or OUT_LO.
Product Information for the S7 Distributed Safety, Configuring and Programming Manual
A5E00169432-02
Description
Type
INT
Input value to be scaled in physical units
INT
Upper limit value in physical units
INT
Lower limit value in physical units
INT
Result of scaling
BOOL
1 = input value > 27,648: OUT = HI_LIM
BOOL
1 = input value < 0: OUT = LO_LIM
(for overflow) or 8000
H
Default
0
0
0
0
0
0
(for underflow) in the PII for the
H
45

Advertisement

Table of Contents
loading

Table of Contents