3. Instruction Set

Program example 1:

1.When M1168 = OFF (in BCD mode) and X0 = ON, the 4th (thousand) and 3rd (hundred) digit of the decimal value in D10 start to move to the 3rd (hundred) and 2nd (ten) digit of the decimal value in D20. 103 and 100 of D20 remain unchanged after this instruction is executed.

2.When the BCD value exceeds the range of 0 ~ 9,999, PLC detects an operation error and will not execute the instruction. M1067, M1068 = ON and D1067 stores the error code OE18 (hex).

 

 

M1001

M1168

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

X0

 

 

 

 

 

 

 

 

 

 

 

 

 

SMOV

D10

K4

K2

D20

K3

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

D10(BIN 16bit)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Auto conversion

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

103

 

102

101

100

 

D10(BCD 4 digits)

 

No variation

 

 

No variation

 

Shift move

 

 

 

D20(BCD 4 digits)

 

103

 

102

101

100

 

 

Auto conversion

D20(BIN 16bit)

If D10 = K1234, D20 = K5678 before execution, D10 remains unchanged and D20 = K5128 after execution.

Program example 2:

When M1168 = ON (in BIN mode) and SMOV instruction is in use, D10 and D20 will not be converted in BCD format but be moved in BIN format (4 digits as a unit).

 

 

M1000

M1168

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

X0

 

 

 

 

 

 

 

 

 

 

 

 

 

SMOV

 

D10

K4

K2

D20

K3

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Digit 4

Digit 3

 

Digit 2

Digit 1

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

D10(BIN 16bit)

 

 

 

 

 

 

 

 

 

 

 

 

Shift move

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

D20(BIN 16bit)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Digit 4

Digit 3

 

Digit 2

Digit 1

 

 

 

 

 

No variation

 

 

 

No variation

 

 

 

If D10 = H1234, D20 = H5678 before execution, D10 remains unchanged and D20 = H5128 after execution.

3 - 6 5

Page 181
Image 181
Delta DVP-ES2/EX2/SS2/SA2/SX2/SE manual Smov