1928
29 BOOLEAN FUNCTIONS
29.1 AND Operation, OR Operation, and XOR Operation
Processing details
■
Operation processing
1.
AND(_E)
• These functions perform an AND operation (bit-by-bit) on the BOOL, WORD, or DWORD data type values input to (s1) to
(s28), and output the operation result, in the same data type as (s), from (d).
Ex.
Data type: WORD
2.
OR(_E)
• These functions perform an OR operation (bit-by-bit) on the BOOL, WORD, or DWORD data type values input to (s1) to
(s28), and output the operation result, in the same data type as (s), from (d).
Ex.
Data type: WORD
3.
XOR(_E)
• These functions perform an XOR operation (bit-by-bit) on the BOOL, WORD, or DWORD data type values input to (s1) to
(s28), and output the operation result, in the same data type as (s), from (d).
Ex.
Data type: WORD
• If three or more (s) settings exist, (s3) will be XORed with the result of XOR between (s1) and (s2). In addition, if (s4) exists,
(s4) will be XORed with the result of subjecting (s) to XOR. After this, XOR will repeat for the number of (s) settings.
Ex.
Data type: BOOL
(1) Number of s's: 3
(2) Number of s's: 4
(3) Number of s's: 5
The XOR operation is repeated by the number of s's.
(s1)
(s2)
(d)
AND
1
1
1
1
0
0
0
1
1
1
1
1
1
1
1
0
0
0
1
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
1
0
1
1
0
0
0
0
1
0
0
1
0
0
(s1)
(s2)
(d)
OR
1
1
1
1
0
0
0
1
1
0
0
1
1
1
1
0
1
1
1
1
1
1
0
1
1
0
0
1
1
1
1
0
0
0
1
0
1
1
0
0
0
0
0
0
0
1
0
0
(s1)
(s2)
(d)
XOR
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
1
0
1
1
0
1
1
0
0
0
1
0
0
0
0
0
1
1
1
0
0
0
1
1
0
1
1
1
(s1)
(s2)
(s3)
(s4)
(s5)
TRUE
FALSE
TRUE
XOR
FALSE
TRUE
TRUE
XOR
TRUE
FALSE
TRUE
XOR
FALSE
TRUE
TRUE
XOR
(1)
(2)
(3)
(4)
Summary of Contents for MELSEC iQ-R Series
Page 1: ...MELSEC iQ R Programming Manual Instructions Standard Functions Function Blocks ...
Page 2: ......
Page 24: ...22 INDEX 2092 INSTRUCTION INDEX 2093 REVISIONS 2104 WARRANTY 2105 TRADEMARKS 2106 ...
Page 34: ...32 MEMO ...
Page 35: ...33 PART 1 PART 1 OVERVIEW This part consists of the following chapter 1 OVERVIEW ...
Page 68: ...66 1 OVERVIEW 1 5 Precautions on Programming MEMO ...
Page 1448: ...1446 14 REDUNDANT SYSTEM INSTRUCTIONS 14 2 Disabling Enabling System Switching MEMO ...
Page 1972: ...1970 33 TIME DATA TYPE FUNCTIONS 33 4 Division MEMO ...
Page 2067: ...APPX Appendix 5 PID Control Program Examples 2065 A 252 Set PID control data for loop 2 ...
Page 2109: ......