2-19
2 Instruction Descriptions
NJ-series Instructions Reference Manual (W502)
Ladder Diagram Instructions
2
OR and ORN
The operation is as shown below if you do not specify upward or downward differentiation.
If you specify upward or downward differentiation, the operation depends on the following: the value of
the variable the last time the instruction was executed, the current value of the variable, and the execu-
tion condition. This is shown below.
• An error occurs in the following case and the output value from the last execution is retained.
• You specify an array element for the variable value and the element does not exist.
Example: A BOOL array a[0..5] is defined, but the instruction is executed using a[10] as the vari-
able.
• Do not use these instructions as the rightmost instruction on a rung. If you do, an error occurs on the
Sysmac Studio and you cannot transfer the user program to the Controller.
Instruction
Combination of variable value and execution
condition
Output
value
OR
Variable value: FALSE
Execution condition: FALSE
FALSE
Other than the above. TRUE
ORN
Variable value: TRUE
Execution condition: FALSE
FALSE
Other than the above. TRUE
Instruction
Differentiation specifi-
cation
Combination of value of variable at last execution,
current value of variable, and execution condition
Output value
OR
Upward differentiation
Variable value: FALSE at the last execution →
Currently TRUE
Execution condition: Ignored.
TRUE
Variable value: Ignored
Execution condition: TRUE
Other than the above. FALSE
Downward differentia-
tion
Variable value: TRUE at the last execution →
Currently FALSE
Execution condition: Ignored.
TRUE
Variable value: Ignored
Execution condition: TRUE
Other than the above. FALSE
ORN
Upward differentiation
Variable value: FALSE at the last execution →
Currently TRUE
Execution condition: FALSE
FALSE
Other than the above. TRUE
Downward differentia-
tion
Variable value: TRUE at the last execution →
Currently FALSE
Execution condition: FALSE
FALSE
Other than the above. TRUE
Precautions for Correct Use