3 . Instruction Set

API

37

 

Mnemonic

 

Operands

Function

 

 

 

 

 

 

 

WSFL

 

P

 

Word Shift Left

 

 

 

 

 

 

Controllers

ES2/EX2

SS2

SA2

SX2

SE

 

Type

 

Bit Devices

 

 

 

 

Word devices

 

 

 

 

 

 

Program Steps

 

OP

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

X

Y

M

S

 

K

H

KnX

KnY

KnM

KnS

T

C

D

E

F

WSFL, WSFLP: 9 steps

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

S

 

 

 

 

 

 

 

 

*

*

*

*

*

*

*

 

 

 

 

 

 

 

 

 

D

 

 

 

 

 

 

 

 

 

*

*

*

*

*

*

 

 

 

 

 

 

 

 

 

n1

 

 

 

 

 

 

*

*

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

n2

 

 

 

 

 

 

*

*

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

PULSE

 

 

 

16-bit

 

 

 

 

32-bit

 

 

 

 

 

 

 

 

ES2/EX2

SS2

SA2

SX2

ES2/EX2

SS2

 

SA2

SX2

ES2/EX2

SS2

 

SA2

SX2

 

 

 

 

 

 

SE

 

SE

 

SE

Operands:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

S: Start No. of source device D: Start No. of destination device

n1: Length of data to be

 

shifted n2: Number of devices to be shifted as a group

 

 

 

 

 

 

 

 

 

 

 

Explanations:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1.This instruction performs a left shift from source device of n2 registers starting from S to destination device of n1 registers starting from D.

2.This instruction is generally used in pulse execution mode (WSFLP).

3.The type of devices designated by S and D has to be the same, e.g. KnX, KnY, KnM, and KnS as a category and T, C, and D as another category

4.Provided the devices designated by S and D belong to Kn type, the number of digits of Kn in S and D has to be the same.

5.Valid range of operand n1, n2 : 1≤ n2 n1 ≤512

Program Example:

1.When X0 is triggered, WSFLP instruction shifts D10~D13 into data stack D20~D35 and D20~D35 also shift to the left with a group of 4 registers.

2.The figure below illustrates the left shift of the words in one scan

 

n D35~D32

 

Carry

 

 

 

 

 

 

 

 

 

 

 

 

o D31~D28

 

D35~D32

 

 

 

 

 

 

 

 

 

 

 

p D27~D24

 

D31~D28

 

 

 

 

 

 

 

 

 

 

 

q D23~D20

 

D27~D24

 

 

 

 

 

 

 

 

 

 

 

r D13~D10

 

D23~D20

completed

 

 

 

 

 

 

 

 

 

X0

WSFLP

D10

D20

K16

 

K4

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

4 registers in one group shift to the left

 

 

 

D13

D12

D11

D10

Carry

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5

D35

D34

D33

D32

D31

D30

D29

D28

D27

D26

D25

D24

D23

D22

D21

D20

 

1

 

 

 

2

 

 

 

3

 

 

 

4

 

 

 

3 - 99

Page 215
Image 215
Delta DVP-ES2/EX2/SS2/SA2/SX2/SE manual Wsfl, Word Shift Left