BMUL (BCD)

BMUL, BMULP, DBMUL, DBMULP (BCD)

 

BMUL instruction multiplies S1 with S2 and save the result in Destination (assigned device address).

 

 

S1, S2

Source (BCD value)

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

BMUL(P)

DBMUL(P)

S1

o

o

o

o

o

o

o

o

-

o

o

o

o

4

o

-

-

S2

o

o

o

o

o

o

o

o

-

o

o

o

o

D

o

-

o

o

o

-

o

o

-

o

o

o

-

 

Function

  • Multiply S1 with S2 and save the result as double word type to D (Low byte) and D+1 (High byte).

 

Example)

If X20 is ON, multiply 7777(D1) with 8888(D2) and save 1976 to M40 and 6912 to M50.