Re: A83: Assembly commands


[Prev][Next][Index][Thread]

Re: A83: Assembly commands




HOPE THIS HELPS:

-Phelan 'Amen' Wolf

ldir,djnz,sbc,rra,drl, and rr I have no idea.

and (binary):

01000101 and
10011101

OUTPUT: 00100111
EXPLANATION:  If bit = bit output 1, if bit (not)= bit output 0

xor (binary):

01000101 xor
10011101

OUTPUT: 11011000
EXPLANATION If bit or bit on, but not both on output 1, else 0

or (binary):

01000101 or
10011101

OUTPUT: 11011101
EXPLANATION: If bit or bit on or both on, output 1, else 0

push:

SYNTAX:
push 16bitregister

OUTPUT: none
EXPLANATION:  Puts a 16bit register on the stack.
NOTE:  You may only use 16bit registers, nothing else.

pop:

SYNTAX:
pop 16bitregister

OUTPUT: 16bitregister set at XX
EXPLANATION:  Takes the last number off the stack and stores it into a
16bit register.

ei:

SYNTAX:
EI

OUTPUT: interupts enabled
EXPLANATION:  [re]Enables interupts.


jp:

SYNTAX:
jp label
jp z,label
jp nz,label
jp c,label
jp nc,label
jp o,label
jp no,label

OUTPUT:
    jp label:
    jumps to specified label

    jp z,label:
    jumps to specified label if zero flag set

    jp nz,label:
    jumps to specified label if zero flag isn't set

    jp c,label:
    jumps to specified label if the carry flag is set

    jp nc,label:
    jumps to specified label if the carry flag isn't set

    jp o,label:
    jumps to specified label if the overflow flag is set

    jp no,label:
    jumps to specified label if the overflow flag in't set

OUTPUT:  jumps to label or goes to next command
EXPLANATION:  All but jp label are jumps if the previous command set a
certain flag, if the previous command subtracts 5 from 5, then the zero
flag will be set, if an 8bit + 8bit > 8bit then the carry flag is set.  If
the previous operation results in a number too large then the overflow flag
is set.

jr:

SYNTAX:
jr label

OUTPUT: jumps to a close label, actual range I do not know.
EXPLANATION:  Jumps to a close label.


References: