Special offers from our partners!
Find Replacement BBQ Parts for 20,308 Models. Repair your BBQ today.
7-45
DROL(P),DRCL(P)
1
2
3
4
6
6
7
8
7.2 Rotation instruction
7.2.4 Left rotation of 32-bit data (DROL(P),DRCL(P))
(2) When a bit device is designated for , a rotation is performed within the device range
specified by digit specification. The number of bits by which a rotation is executed is the
remainder of n /(specified number of bits).
For example, when n 31 and (specified number of bits) 24 bits, the remainder of 31/24
1 is "7", and the data is rotated 7 bits.
(3) Specify any of 0 to 31 as n. If the value specified as n is 32 or greater, the remainder of n/32
is used for rotation. For example, when n 34, the data is rotated 2 bits to the left since the
remainder of 34/32 1 is "2".
Operation Error
(1) There are no operation errors associated with the DROL(P) or DRCL(P) instructions.
Program Example
(1) The following program rotates the contents of D0 and D1, not including the carry flag, 4 bits
to the left when XC is ON.
[Ladder Mode] [List Mode]
[Operation]
(2) The following program rotates the contents of D0 and D1, including the carry flag, 4 bits to
the left when XC is ON.
[Ladder Mode] [List Mode]
[Operation]
D
Step Instruction Device
1D0, D1111
000
0
111
1
000
0
111
1
000
0
111
1
0000
0
D0, D1
00
0
111
1
000
0
111
1
000
0
111
1
000
0
1111
b31 b16 b0b15b28b27 b24b23 b20 b19 b12 b11 b8 b7 b4 b3
Contents of b31 to b28
before execution
Contents of b27 to b0
before execution
0
1
Carry flag
(SM700)
Carry flag
(SM700)
Content of b28
before execution
b31 b16 b0b15b28b27 b24b23 b20 b19 b12 b11 b8
b7
b4 b3
Step Instruction Device
1
D0, D1
111
000
0
111
1
000
0
111
1
000
0
111
1
0000
0
D0, D1
0
*
*
*
0
0
111
1
000
0
111
1
000
0
111
1
000
0
111
b31 b16 b0b15b28b27 b2 4b23 b20 b19 b12 b11 b8 b7 b4 b3
Contents of b31 to b29
before execution
Contents of b27 to b0
before execution
1
Carry flag
(SM700)
Carry flag
(SM700)
Content of b28
before execution
Content of carry flag
SM700 before execution
b31 b16 b0b15b28b27 b2 4b23 b20 b19 b12 b11 b8
b7
b4 b3
: ON/OFF status of the carry flag depends on its status before the execution of DRCL.