N Bit Shift Left - Toshiba PROSEC T1-16S User Manual

Programmable controller basic hardware and function
Hide thumbs Also See for PROSEC T1-16S:
Table of Contents

Advertisement

FUN 071
SHL
Expression
Input
[ A SHL n
Function
When the input is ON, the data of register A is shifted n bits to the left (MSB direction) including the
carry flag (CF = S050), and stored in B. 0 is stored in lower n bits. After the operation, if the left
most bit (MSB) is ON, the output is turned ON.
Execution condition
Input
OFF
No execution
ON
Execution
When MSB = 1
When MSB = 0
Operand
Name
X
A Source
n Shift bits
B Destination
Example
When X008 is changed from OFF to ON, the data of RW18 is shifted 3 bits to the left and the
result is stored in RW20.
The figure below shows an operation example.
(MSB)
F
E
D
1 0 1 0 0 1 1 1 0 0 1 1 1 0 1 0
CF
1
0 0 1 1 1 0 0 1 1 1 0 1 0 0 0 0

n bit shift left

B ]
Output
Operation
Device
Y
R
S
T.
C. XW YW RW SW T
C
B
A
9
8
7
6
5
R002 is turned OFF
Output
OFF
ON
OFF
Register
C
(LSB)
4
3
2
1
0
RW18
RW20 (Result)
0
Basic Hardware and Function
7. Instructions
CF
Set or reset
Set or reset
Constant Index
D
I
J
K
1 - 16
6F3B0253
167

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents