Download Print this page

Omron SYSMAC CS1D-PD Series Operation Manual page 375

Duplex system

Advertisement

Condition Flags
!Caution Condition Flags can be tricky to use. They are manipulated by essentially all
Saving and Loading Condition Flag Status
instructions and if they are not used with the proper timing, the wrong status
may be read, leading to unexpected operation. Program Condition Flags with
caution.
The Condition Flags are cleared when the program switches tasks, so the sta-
tus of a Condition Flag cannot be passed to another task. For example the
status of a flag in task 1 cannot be read in task 2. (The flag's status must be
transferred to a bit.)
The CS1D CPU Units support instructions to save and load the Condition
Flag status (CCS(282) and CCL(283)). These can be used to access the sta-
tus of the Condition Flags at other locations in a task or in a different task.
The following example shows how the Equals Flag is used at a different loca-
tion in the same task.
Task
CMP
CCS
Instruction A
CCL
=
Instruction B
Section 8-20
Stores result of comparison in the Condition
Flags. This will enable loading the results to
use with Instruction B.
Saves status of Condition Flags.
Loads the statuses of the Conditions Flags
that were stored.
The result of the comparison instruction in the
Equals Flag can be used by Instruction B
without interference from Instruction A.
335

Advertisement

loading
Need help?

Need help?

Do you have a question about the SYSMAC CS1D-PD Series and is the answer not in the manual?

This manual is also suitable for:

Sysmac cs1d-cpu ha seriesSysmac cs1d-cpu h seriesSysmac cs1d-cpu sa seriesSysmac cs1d-cpu s seriesSysmac cs1d-pa seriesSysmac cs series ... Show all