EasyManua.ls Logo

Toshiba PROSEC T1-16S - Page 168

Toshiba PROSEC T1-16S
301 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
6F3B0253
166 T1-16S User’s Manual
7. Instructions
FUN 070 SHR n bit shift right
Expression
Input [ A SHR n B ] Output
Function
When the input is ON, the data of register A is shifted n bits to the right (LSB direction) including
the carry flag (CF = S050), and stored in B. 0 is stored in upper n bits. After the operation, if the
right most bit (LSB) is ON, the output is turned ON.
Execution condition
Input Operation Output CF
OFF No execution OFF
ON Execution When LSB = 1 ON Set or reset
When LSB = 0 OFF Set or reset
Operand
Name Device Register Constant Index
X Y R S T. C. XWYWRWSW T C D I J K
A Source
√√√√√√√√√√
n Shift bits 1 - 16
B Destination
√√√√√√√√√
Example
When X007 is changed from OFF to ON, the data of RW18 is shifted 5 bits to the right and the
result is stored in RW20.
The figure below shows an operation example.
(MSB) (LSB)
FEDCBA9876543210
RW18 0100001010011010
CF
RW20 0000001000010100 1
(Result)
0 R001 is turned OFF

Table of Contents

Related product manuals