Back to FBD referenceTypical FBD symbol for XOR
Basic logic
XOR
Exclusive OR
The XOR block compares two BOOL signals by difference. Q is TRUE only when one input is TRUE and the other is FALSE.
Typical FBD symbol
IN1
IN2
XOR
Q
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| IN1 | BOOL | Yes | The first compared signal. |
| IN2 | BOOL | Yes | The second compared signal. |
Outputs
| Name | Type | Required | Description |
|---|---|---|---|
| Q | BOOL | Yes | TRUE when inputs differ. |
Stateful
No, the block does not keep internal state.
Behavior rule
Q = TRUE when the inputs are different.
Truth table
| IN1 | IN2 | Q |
|---|---|---|
| FALSE | FALSE | FALSE |
| FALSE | TRUE | TRUE |
| TRUE | FALSE | TRUE |
| TRUE | TRUE | FALSE |
Practical use
- mismatch checking between two states;
- diagnosing contradictory signals.
What to watch
- Confusing XOR with OR. With two TRUE inputs, XOR emits FALSE.