DEC (BINARY)

DEC, DECP, DDEC, DDECP (Binary)

 

DEC instruction decrements the value of Destination by one.

 

 

D

Destination

 

Instruction

Device address

No. of Steps

Flag

M

X

Y

K

L

F

T

C

S

Z

D

@D

Int.

 

Error

Zero

Carry

DEC(P)

DDEC(P)

D

o

-

o

o

o

-

o

o

-

o

o

o

-

2

o

-

-

 

When enabled, the DEC instruction Subtracts 1 from D and saves the result to D again.

 

Example)

If X02 is ON, the value of Y00(H0009) decrements by 1.