Logical Blocks > Multiplexer function block

Multiplexer function block execution

The Multiplexer function block reads the values and statuses of as many as sixteen inputs and selects the input designated by the SELECTOR parameter. The number of inputs to the block is an extensible parameter. The block default is two inputs. You add inputs by right-clicking the function block diagram, clicking Extensible Parameters, and modifying the number of inputs. This creates additional input connectors for the block.

The transfer from one input to another can be smoothed by using the balance time parameter (BAL_TIME). The BAL_TIME parameter defines the amount of time for the previous input value to ramp to the newly selected input value. When BAL_TIME is set to zero, the transition between inputs is instantaneous.

You can choose to have the block automatically select the next input with Good status by configuring the SELECT_NEXT_GOOD parameter. Next, if the selected input has Bad status, the next Good input is selected, in ascending order and rotating from last to first. If all of the input statuses are Bad, the block places the selected input at the output and labels it with a Bad status. When this option is False, the block sets the output to the selected input regardless of status.

The following table gives an example of what the output value and status would be with three multiplexed inputs. The input value and status in the table are represented using a value[status] nomenclature. For example, 1[Good] is a value of 1 and a status of Good.

Table: Multiplexer function block response example

IN1 Value [Status]

IN2 Value [Status]

IN3 Value [Status]

SELECTOR

SELECT_ NEXT_ GOOD

OUT Status

OUT

10 [Good]

20 [Bad]

30 [Good]

1

False

Good

10

10 [Bad]

20 [Good]

30 [Good]

1

True

Good

20

10 [Good]

20 [Bad]

30 [Bad]

2

True

Good

10

10 [Good]

20 [Good]

30 [Good]

2

False

Good

20

10 [Bad]

20 [Bad]

30 [Bad]

3

True

Bad

30