Performing a 16-bit test
TEST(P)
RnPCPU
RnCPU RnENCPU
(Process)
These instructions extract the 'n'th bit in the specified word device.
Ladder
(s1)
FBD/LD
EN
ENO
s1
d
s2
■Execution condition
Instruction
TEST
TESTP
Setting data
■Description, range, data type
Operand
Description
(s1)
Device where the extract target bit data is stored
(s2)
Extract target bit position
(d)
Device for storing the extracted bit data
EN
Execution condition
ENO
Execution result
■Applicable devices
Operand
Bit
X, Y, M, L,
SM, F, B, SB,
FX, FY
(s1)
(s2)
(d)
6 BASIC INSTRUCTIONS
344
6.4 Bit Processing Instructions
RnPCPU
RnSFCPU RnSFCPU
(Redundant)
(Standard)
(Safety)
(s2)
(d)
Execution condition
Word
J\
T, ST, C, D, W,
SD, SW, FD, R,
ZR, RD
ST
ENO:=TEST(EN,s1,s2,d);
ENO:=TESTP(EN,s1,s2,d);
Range
0 to 15
Double word Indirect
U\G, J\,
Z
LT, LST,
U3E\(H)G
LC
Data type
Data type (label)
16-bit signed binary
ANY16
16-bit unsigned binary
ANY16
Bit
ANY_BOOL
Bit
BOOL
Bit
BOOL
Constant
specification
LZ
K, H E
Others
$