Mitsubishi Electronics FXCPU Welding System User Manual


 
5.5 Standard Bitwise Boolean Functions
158
FXCPU Structured Programming Manual
(Application Functions)
5.5.3 XOR_E
Outline
This function obtains the exclusive logical sum of two or more bits, and outputs it.
1. Format
*1. Output variable
2. .Set data
In explanation of functions, I/O variables inside ( ) are described.
Explanation of function and operation
1) This function obtains the exclusive logical sum using each bit of bit/word [unsigned]/bit string [16-bit]/
double word [unsigned]/bit string [32-bit] data stored in devices specified in and , and outputs
the operation result to a device specified in using the data type of data stored in devices specified in
and .
Example: When the data type is word [unsigned]/bit string [16-bit]
2) The number of pins in can be changed.
FX3U(C) FX3G FX2N(C) FX1N(C) FX1S
FX
U
/FX
2C
FX0N FX0(S)
Function name
Expression in each language
Structured ladder ST
XOR_E
XOR_E(EN,_IN,_IN,Output
label);
Example:
XOR_E(X000,M0,M10,M20);
Variable Description Data type
Input
variable
EN Execution condition Bit
_IN ( )
Device used to obtain the exclusive logical sum ANY_BIT
Output
variable
ENO Execution status Bit
*1 ( )
Device which will store the operation result ANY_BIT
XOR_E
EN ENO
*1
M20
X000
M0
_IN
_IN
M10
s1
d
s1
s2
d
s1
s2
0001101111110000
1010101010101010
1011000101011010
Exclusive logical sum
s1
s2
d
s