mux
The mux function is for the ST Language only.
Inputs
Input |
Data Type |
Range |
Unit |
Default |
Description |
---|---|---|---|---|---|
K |
DINT |
0 to 7 |
N/A |
No default |
Selection command. |
IN0 |
ANY |
Depends on the Data Type. |
N/A |
No default |
First input. |
IN1 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Second input. |
IN2 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Third input. |
IN3 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Fourth input. |
IN4 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Fifth input. |
IN5 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Sixth input. |
IN6 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Seventh input. |
IN7 |
ANY |
Depends on the Data Type. |
N/A |
No default |
Last input. |
Outputs
Output |
Data Type |
Range |
Unit |
Description |
---|---|---|---|---|
Q |
ANY |
No range |
N/A |
IN0 or IN1 ... or IN7 depending on K. See the Truth Table. |
Remarks
None
Truth Table
K |
Q |
---|---|
0 |
IN0 |
1 |
IN1 |
2 |
IN2 |
3 |
IN3 |
4 |
IN4 |
5 |
IN5 |
6 |
IN6 |
7 |
IN7 |
Other |
0 |
FBD Language Example
Not available.
FFLD Language Example
Not available.
IL Language Example
Not available.
ST Language Example
Q := MUX (K, IN0, IN1, IN2, IN3, IN4, IN5, IN6, IN7);
See Also