EasyManuals Logo
Home>Omron>Controller>CJ - INSTRUCTIONS

Omron CJ - INSTRUCTIONS User Manual

Omron CJ - INSTRUCTIONS
1308 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1104 background imageLoading...
Page #1104 background image
3. Instructions
1066
CS/CJ/NSJ Series Instructions Reference Manual (W474)
IF/IF NOT/ELSE/IEND
Applicable Program Areas
*1 IF(802), ELSE(803), and IEND(804) must be used in block programming regions even within subroutines and interrupt
tasks.
Operands
z Operand Specifications
*1 CJ2 CPU Units only.
Flags
Instruction Mnemonic Variations
Function
code
Function
Branching
IF --- 802
When the execution condition (when an operand is not
specified) or the specified bit (when an operand is specified)
is OFF, the next and following instructions are executed.
When ON, instructions up to ELSE are disregarded.
IF NOT --- 802
When the specified bit is ON, the next and following
instructions are executed. When OFF, instructions up to
ELSE are disregarded.
ELSE --- 803
Indicates the beginning of the block that is executed when IF
is false.
IEND --- 804 Indicates the end of the conditional branch block area.
Symbol
Operation without an IF instruction operand (operation by
execution condition)
Execution condition
Operation with an IF (IF NOT) instruction operand
Area
Function block
definitions
Block program areas Step program areas Subroutines Interrupt tasks
SFC action or transition
programs
Usage Not allowed OK OK
OK*
1
OK*
1
Not allowed
Operand Description Data type Size
B Bit operand BOOL 1
Area
Word addresses
Indirect DM/EM
addresses
Con-
stants
Registers Flags
Pulse
bits
TR
bits
CIO WR HR AR T C DM EM
@DM
@EM
*DM
*EM
DR IR
Indirect
using IR
TK CF
B OKOKOKOKOKOK
OK*
1
OK*
1
--- --- --- --- --- OK OK OK OK ---
Name Label
Operation
IF/IF NOT ELSE/IEND
Error Flag ER • ON if the branch instructions are not in a
block program.
• ON if more than 254 branches are
nested.
• OFF in all other cases.
• ON if the branch instructions are not in a
block program.
• OFF in all other cases.
IF(802)
ELSE(803)
IEND(804)
.. ..
IF NOT(802) B
IF(802) B
ELSE(803) B
IEND(804) B
.. ..
B: Bit operand
B: Bit operand
B: Bit operand
B: Bit operand

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron CJ - INSTRUCTIONS and is the answer not in the manual?

Omron CJ - INSTRUCTIONS Specifications

General IconGeneral
BrandOmron
ModelCJ - INSTRUCTIONS
CategoryController
LanguageEnglish

Related product manuals