Math.Scale

Scales the value of the input item using a pre-offset, a factor, and a post-offset and writes the result to the output item.

Description

This logic is used to linearly transform the value of an item according to the following formula: result = (<input value> + <pre-offset>) * <factor> + <post-offset>

The output item's data type must be suitable to the size of the result.

Inputs

Name

Type

Mandatory/Optional

Description

InputItemIDMThe source item that shall be scaled.

Outputs

Name

Type

Mandatory/Optional

Description

OutputItemIDMThe output item where the scaled value is stored.

Parameters

Name

Type

Mandatory/Optional

Description

PreOffsetnumberOThe value added as pre-offset to the input.
FactornumberOThe value used as multiplication factor.
PostOffsetnumberOThe value added to the multiplication result.

Possible trigger types

  • All

Applies to

  • NETx BMS Platform, XLogic Library 1.0.11+
  • NETx Multi Protocol Server, XLogic Library 1.0.11+