Mitsubishi Electric MELSEC iQ-R Series Programming Manual page 538

Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

Processing details
■DROL(P)
• These instructions rotate the 32-bit binary data in the device specified by (d) to the left by (n) bit(s), excluding the carry flag
(SM700). The carry flag (SM700) is on or off depending on the status prior to the execution of the DROL(P) instruction.
(SM700)
b31
b30 b29 b28 b27
• When (d) is a bit device, bits are rotated to the left within the device range specified by digit specification. The number of
bits actually to be rotated is the remainder of (n)(specified number of bits). For example, when (n) is 31 and the specified
number of bits is 24, 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7.
• Specify any value between 0 and 31 for (n). If a value 32 or bigger is specified, bits are rotated by the remainder value of
n32. For example, when (n) is 34, 2 bits are rotated to the left because 34 divided by 32 equals 1 with a remainder of 2.
■DRCL(P)
• These instructions rotate the 32-bit binary data in the device specified by (d) to the left by (n) bit(s), including the carry flag
(SM700). The carry flag (SM700) is on or off depending on the status prior to the execution of the DRCL(P) instruction.
(SM700)
b31
b30 b29 b28 b27
• When (d) is a bit device, bits are rotated to the left within the device range specified by digit specification. The number of
bits actually to be rotated is the remainder of (n)(specified number of bits). For example, when (n) is 31 and the specified
number of bits is 24, 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7.
• Specify any value between 0 and 31 for (n). If a value 32 or bigger is specified, bits are rotated by the remainder value of
n32. For example, when (n) is 34, 2 bits are rotated to the left because 34 divided by 32 equals 1 with a remainder of 2.
Operation error
There is no operation error.
7 APPLICATION INSTRUCTIONS
536
7.1 Rotation Instructions
(d)+1
b18 b17
b16
b14
b15
Left rotation by (n) bits
(d)+1
b18 b17
b16
b15
b14
Left rotation by (n) bits
(d)
b5 b4 b3 b2 b1
b0
(d)
b5 b4 b3 b2 b1
b0

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents