Omron C20K Video Game Controller User Manual


 
59
Find the instruction
that requires deletion.
Confirm that this is the
instruction to be deleted.
Program After Deletion
Deleting an Instruction
0000
0000
OUT 0000
0000
OUT 0201
0208SRCH
OUT 0201
0207READ
AND NOT 0104
0207 DELETE?
AND NOT 0104
0207DELETE END
OUT 0201
0206READ
AND 0105
Address Instruction Operands
0000 LD 0100
0001 AND NOT 0101
0002 LD 0201
0003 AND NOT 0102
0004 OR LD ---
0005 AND 0103
0006 AND 0105
0007 AND NOT 0104
0008 OUT 0201
4-7 Controlling Bit Status
There are five instructions that can be used generally to control individual bit
status. These are the OUTPUT or OUT, OUTPUT NOT or OUT NOT, DIF-
FERENTIATE UP, DIFFERENTIATE DOWN, and KEEP instructions. All of
these instruction appear as the last instruction in an instruction line and take
a bit address for an operand. Although details are provided in
5-6 Bit Control
Instructions
, these instructions are described here because of their impor-
tance 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
devices), 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 (DIFU(13)) and DIFFERENTIATE DOWN (DIFD(14))
instructions are used to turn the operand bit ON for one cycle at a time. The
DIFFERENTIATE UP turns ON the operand bit for one cycle after the execu-
tion condition when it goes from OFF to ON; the DIFFERENTIATE DOWN
instruction turns ON the operand bit for one cycle after the execution condi-
tion when it goes from ON to OFF.
0000
0001
DIFU(13) 0500
DIFD(14) 0501
Address Instruction Operands
0000 LD 0000
0001 DIFU(13) 0500
Address Instruction Operands
0000 LD 0001
0001 DIFD(14) 0501
Controlling Bit Status Section 4-7