![background image](http://html1.mh-extra.com/html/omron/sysmac-c200h/sysmac-c200h_operation-manual_742423102.webp)
89
4-7
Controlling Bit Status
There are five instructions that can be used generally to control individual bit
status. These are the OUTPUT, OUTPUT NOT, DIFFERENTIATE UP,
DIFFERENTIATE DOWN, and KEEP instructions. All of these instructions
appear as the last instruction in an instruction line and take a bit address for
an operand. Although details are provided in 5-7 Bit Control Instructions,
these instructions (except for OUTPUT and OUTPUT NOT, which have al-
ready been introduced) are described here because of their importance in
most programs. Although these instructions are used to turn ON and OFF
output bits in the IR area (i.e., to send or stop output signals to external de-
vices), they are also used to control the status of other bits in the IR area or
in other data areas.
4-7-1
DIFFERENTIATE UP and DIFFERENTIATE DOWN
DIFFERENTIATE UP and DIFFERENTIATE DOWN instructions are used to
turn the operand bit ON for one cycle at a time. The DIFFERENTIATE UP
instruction turns ON the operand bit for one cycle after the execution condi-
tion for it goes from OFF to ON; the DIFFERENTIATE DOWN instruction
turns ON the operand bit for one cycle after the execution condition for it
goes from ON to OFF. Both of these instructions require only one line of
mnemonic code.
00000
00001
DIFU(13) 00200
DIFD(14) 00201
Address
Instruction
Operands
00000
LD
00000
00001
DIFU(13)
00200
Address
Instruction
Operands
00000
LD
00001
00001
DIFD(14)
00201
Here, IR 00200 will be turned ON for one cycle after IR 00000 goes ON. The
next time DIFU(13) 00200 is executed, IR 00200 will be turned OFF, regard-
less of the status of IR 00000. With the DIFFERENTIATE DOWN instruction,
IR 00201 will be turned ON for one cycle after IR 00001 goes OFF (IR 00201
will be kept OFF until then), and will be turned OFF the next time DIFD(14)
00201 is executed.
4-7-2 KEEP
The KEEP instruction is used to maintain the status of the operand bit based
on two execution conditions. To do this, the KEEP instruction is connected to
two instruction lines. When the execution condition at the end of the first in-
struction line is ON, the operand bit of the KEEP instruction is turned ON.
When the execution condition at the end of the second instruction line is ON,
the operand bit of the KEEP instruction is turned OFF. The operand bit for the
KEEP instruction will maintain its ON or OFF status even if it is located in an
interlocked section of the diagram.
In the following example, HR 0000 will be turned ON when IR 00002 is ON
and IR 00003 is OFF. HR 0000 will then remain ON until either IR 00004 or
IR 00005 turns ON. With KEEP, as with all instructions requiring more than
Controlling Bit Status
Section 4-7
Содержание SYSMAC C200H
Страница 1: ...OPERATION MANUAL C200H CPU01 E 03 E 11 E SYSMAC Programmable Controllers Cat No W130 E1 05 ...
Страница 2: ...C200H Programmable Controllers CPU01 E 03 E 11 E Operation Manual Revised June 2003 ...
Страница 3: ...iv ...
Страница 5: ...vi ...
Страница 8: ...TABLE OF CONTENTS ix Glossary 345 Index 363 Revision History 369 ...
Страница 342: ...336 Programmer Program Date Page Word Contents Notes Word Contents Notes Data Storage ...
Страница 374: ...Cat No W130 E1 05 C200H Programmable Controllers CPU01 E 03 E 11 E OPERATION MANUAL ...