Setb/rstb, Applicable program areas operands, Flags function – Omron SYSMAC CP CP1E-N@@D@-@ User Manual
Page 69: 2 instructions, Operand specifications, Setb
2-33
2 Instructions
CP1E CPU Unit Instructions Reference Manual(W483)
Seq
uen
ce Ou
tp
ut I
n
stru
ctio
ns
2
SETB/RSTB
SETB/RSTB
Applicable Program Areas
Operands
Operand Specifications
Flags
Function
Instruction
Mnemonic
Variations
Function
code
Function
SINGLE BIT SET
SETB
@SETB, !SETB,
!@SETB
532
SETB(532) turns ON the specified bit.
SINGLE BIT RESET
RSTB
@RSTB, !RSTB,
!@RSTB
533
RSTB(533) turns OFF the specified bit.
Symbol
SETB
RSTB
Area
Step program areas
Subroutines
Interrupt tasks
Usage
OK
OK
OK
Operand
Description
Data type
Size
D
Word address
UINT
1
N
Bit number
UINT
1
Area
Word addresses
Indirect DM addresses
Constants
CF
Pulse bits
TR bits
CIO
WR
HR
AR
T
C
DM
@DM
*DM
D
OK
OK
OK
OK
OK
OK
OK
OK
OK
---
---
---
---
N
OK
Operand
Description
Data type
Error Flag
P_ER
• ON if N is not within the specified range of 0000 to 000F (&0 to &15).
• OFF in all other cases.
SETB
SETB(532) turns ON bit N of word D
when the execution condition is ON. The
status of the bit is not affected when the
execution condition is OFF.
D: Word address
SETB(532)
D
N
N: Bit number
D: Word address
RSTB(533)
D
N
N: Bit number
Execution condition
ON
OFF
Bit N of word D
ON
OFF
15
This bit is turned OFF.