344
SFTBR, SFTBRP, SFTBL, SFTBLP
(2) n1 and n2 are specified under the condition that n1 is larger than n2. If the value of n2 is equal to or larger than the value
of n1, the remainder of n2 / n1 (n2 devided by n1) is used for a shift.
However, if the remainder of n2 / n1 is 0, the instruction will be not processed.
(3) This instruction specifies n1 ranged from 1 to 64.
(4) Bits starting from the lowest bit to n2th bit are filled with 0s. If the value of n2 is larger than the value of n1, the remainder
of n2 / n1 will be 0.
(5) If the value specified by n1 or n2 is 0, the instruction will be not processed.
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns on, and an error code is stored into
SD0.
Program Example
(1) The following program shifts the data of Y10 to Y17 (8 bits) specified by to the right by 2 bits (n2), when M0 is turned
on.
[Ladder Mode]
[List Mode]
[Operation]
(2) The following program shifts the data of Y21 to Y2C (12 bits) specified by to the left by 5 bits (n2), when M0 is turned
on.
[Ladder Mode]
[List Mode]
[Operation]
Error
code
Error details
Q00J/
Q00/
Q01
QnH
QnPH QnPRH
QnU
LCPU
4100
The value specified in n1 is other than 0 to 64.
The value in n2 is negative.
4101
The points specified in n1 exceed those of the device specified in .
D
D
Step
Instruction
Device
1
0
1
1
1
0
0
1
Y10
Y11
Y12
Y13
Y14
Y15
Y16
Y17
Y10
Y11
Y12
Y13
Y14
Y15
Y16
Y17
0
0
1
0
1
1
1
0
0
Carr
y
flag
(
SM700
)
D
Step
Instruction
Device
0
1
0
1
1
1
0
1
1
0
0
1
Y21
Y22
Y23
Y24
Y25
Y26
Y27
Y28
Y29
Y2A
Y2B
Y2C
0
0
1
0
0
1
0
1
1
0
0
0
Y21
Y22
Y23
Y24
Y25
Y26
Y27
Y28
Y29
Y2A
Y2B
Y2C
0
Carr
y
flag
(
SM700
)