EasyManuals Logo

Omron CJ2 CPU UNIT SOFTWARE User Manual

Omron CJ2 CPU UNIT SOFTWARE
670 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 #197 background imageLoading...
Page #197 background image
5-105
5 Understanding Programming
CJ2 CPU Unit Software User’s Manual
5-10 Precautions
5
5-10-1 Condition Flags
5-10 Precautions
Conditions flags are shared by all instructions, and will change during a cycle depending on results of
executing individual instructions. Therefore, be sure to use Condition Flags on a branched output with
the same execution condition immediately after an instruction to reflect the results of instruction execu-
tion. Never connect a Condition Flag directly to the bus bar because this will cause it to reflect execution
results for other instructions.
Example: Using Instruction A Execution Results
Mnemonic
The same execution condition (a) is used for instructions A and B to execute instruction B based on the
execution results of instruction A. In this case, instruction B will be executed according to the Condition
Flag only if instruction A is executed.
If the Condition Flag is connected directly to the left bus bar, instruction B will be executed based on the
execution results of a previous rung if instruction A is not executed.
When interrupt tasks are being used, an interrupt task will operate when its start conditions are met,
even during execution of a cyclic task. In this case, the Condition Flags are returned to their original sta-
tus when processing switches back from the interrupt task to the cyclic task, even if those flags were
turned ON/OFF in the interrupt task.
5-10-1 Condition Flags
Using Condition Flags
Correct Use
Instruction A
Instruction B
Condition Flag
P_EQ (Equals Flag)
Reflects instruction A
execution results.
Instruction B
Instruction A
Incorrect Use
Preceding rung
Reflects the execution results of
the preceding rung if instruction
A is not executed.
Condition Flag
P_EQ (Equals Flag)

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron CJ2 CPU UNIT SOFTWARE and is the answer not in the manual?

Omron CJ2 CPU UNIT SOFTWARE Specifications

General IconGeneral
BrandOmron
ModelCJ2 CPU UNIT SOFTWARE
CategorySoftware
LanguageEnglish

Related product manuals