Panasonic FP Series Programming Manual page 584

Hide thumbs Also See for FP Series:
Table of Contents

Advertisement

Left shift operation
d1_Start
Bit position
Data
Shifted-out bit is transferred to
R9009 (carry flag)
Bit position
Data
d1_End
Right shift operation
d1_Start
Bit position
Data
d1_End
Bit position
Data
Availability of F119_LRSR (see page 1320)
PLC types
 The variables 'd1 and d2' have to be of the same data type.
 This function does not require a variable at the output "Carry".
Data types
Variable
LeftDirection
DataInput
ShiftTrigger
Reset
Carry
d1
d2
15 . . 12 11 . . 8 7 . . 4 3 . . 0
0 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1
15 . . 1211 . . 8 7 . . 4 3 . . 0
0 0 1 0 0 0 1 0 0 0 1 0 0 0 1 0
When DataInput turns on, "1" is shifted into bit position 0.
When DataInput turns off, "0" is shifted into bit position 0.
15 . . 12 11 . . 8 7 . . 4 3 . . 0
0 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1
15 . . 12 11 . . 8 7 . . 4 3 . . 0
1 0 0 0 1 0 0 0 1 0 0 0 1 0 0 0
When DataInput turns on, "1" is shifted into
bit position 15.
When DataInput turns off, "0" is shifted into bit
position 15.
Data type
Function
BOOL
specifies direction of shift, TRUE = left, FALSE = right
BOOL
shift-in data, TRUE = 1, FALSE = 0
BOOL
activates shift
BOOL
resets data in area specified by d1 and d2 to 0
BOOL
bit shifted out
starting 16-bit area
ANY16
ending 16-bit area
15 . . 12 11 . . 8 7 . . 4 3 . . 0
1 0 0 0 1 0 0 0 1 0 0 0 1 1 0 0
LeftDirection: ON
ShiftTrigger: OFF, ON
15 . . 12 11 . . 8 7 . . 4 3 . . 0
0 0 0 1 0 0 0 1 0 0 0 1 1 0 0 0
15 . . 12 11 . . 8 7 . . 4 3 . . 0
1 0 0 0 1 0 0 0 1 0 0 0 1 1 0 0
LeftDirection: OFF
ShiftTrigger: OFF, ON
15 . . 12 11 . . 8 7 . . 4 3 . . 0
0 1 0 0 0 1 0 0 0 1 0 0 0 1 1 0
Shifted-out bit is
transferred to
R9009 (carry flag).
Bit-shift instructions
583

Advertisement

Table of Contents
loading

Table of Contents