NumericSwitch Function Block

The Numeric Switch function block selects one of the eight boolean outputs that is set to "true". If the numeric input uses a wrong value, all boolean outputs are "false". The function can be extended to more inputs via an offset if the eight outputs are not sufficient.

Figure 1: NumericSwitch Function Block

Figure 2: Numeric Switch property sheet

The valid range of the input minus the offset is 1 through 8. The output X (1 through 8) is true, if Switch - Offset = X, else, it is false.

Figure 3: NumericSwitch Logic Diagram

Input

Input Name

Description

Switch

This is 32-bit floating point input slot. From (1 - 8). More than 8 will be invalid value and None of the out will be set as true.

Table 1: Input of NumericSwitch Function

Outputs

Output Name

Description

Out1 - Out8

The output 1 through 8 is true if (input -offset) = X, otherwise it is false If an output is negated, then it is also negated from the value determined by the function block logic.

Table 2: Outputs of NumericSwitch Function

Parameter

Parameter Name

Description

Offset

Used to determine which output is set to true based on the expression.

(Switch - Offset) = Output

Out Save

Master Sync Enabled : If you set it to "true" the last output will be set as output for one cycle after the controller restarts. The application can use it to return to the same state before the controller restart.

Out1: To enable or disable the Out1 feature.

Out2: To enable or disable the Out2 feature.

Out3: To enable or disable the Out3 feature.

Out4: To enable or disable the Out4 feature.

Out5: To enable or disable the Out5 feature.

Out6: To enable or disable the Out6 feature.

Out7: To enable or disable the Out7 feature.

Out8: To enable or disable the Out8 feature.

Table 3: Parameter of NumericSwitch Function

Examples

Example for numeric switch selector.

Figure 4: Numeric Switch Selector

Example for numeric switch selector along with offset.

Figure 5: Numeric Switch Selector with Offset

Refer to General for general information about IRMN4 Function Blocks.