![background image](http://html.mh-extra.com/html/hyundai/gms800/gms800_instruction-manual_2196205049.webp)
Instruction Set
45
LSR
( Logical shift right )
Function
: 7
6
5
4
3
2
1
0
C
Description : Move the contents of the Accumulator or of the memory right by one bit position. "0" comes
in on the left(bit7). Bit0 into the carry flag.
Flag
:
Mnemonic
OP Code
Bytes
Cycles
LSR A
48
1
2
LSR dp
49
2
4
LSR dp + X
59
2
5
LSR !abs
58
3
5
Example
:
424 C183 C4FF
LDA
#0FFH
425 C185 E40808
LDM
TEMP,#8
426 C188 A908
LOOP3:
DEC
TEMP
427 C18A 48
LSR
A
428 C18B 70FB
BNE
LOOP3
MUL
( Multiply )
Function
: YA
Y
××××
A
Description : Multiply Y-register by accumulator. The result is left in the 16bit accumulator (YA).
Flag
:
Mnemonic
OP Code
Bytes
Cycles
MUL
5B
1
9
Example :
624 C2E6 C517
ADCHK:
LDA
ADCD0
625 C2E8 3E63
LDY
#99
;A/D input : 0 ~ 255 --> 0 ~ 99
626 C2EA 5B
MUL
627 C2EB C4FF
LDA
#0FFH
628 C2ED 9B
DIV
629 C2EE E502
STA
ADBUF
”
0
”