beautypg.com

Echelon Neuron User Manual

Page 208

background image

Mnemonic

Operand

Operation

Description

BRZ

label

IF [TOS]=0
IP = IP+SD
TOS = [DSP--]
IP = IP+2

Drop TOS, branch if TOS was

zero.
The IP-relative displacement

SD ranges from -128 to 127.

CALL

label

[RSP--] = LSB (IP+1)
[RSP--] = MSB (IP+1)
IP = absolute address

Call function.
Absolute address is 13 bits.

CALLF

word-label

[RSP--] = LSB (IP+2)
[RSP--] = MSB (IP+2)
IP = absolute address

Call far function using a 16-bit

address.

CALLR

label

[RSP--] = LSB (IP+1)
[RSP--]= MSB (IP+1)
IP = IP+SD
IP = IP+2

Call a function using relative

addressing.
The IP-relative displacement

SD ranges from -128 to 127.

DBRNZ

label

IF [--[RSP+1]] <> 0
IP = IP +SD
ELSE
RSP++
IP = IP+2

Decrement the top of the

return stack and branch if it is

not zero, else drop [RSP].
The IP-relative displacement

SD ranges from -128 to 127.

DEALLOC

#literal

DSP = DSP - literal
IPH = [++RSP]
IPL = [++RSP]
IP = IP+1

Move DSP by literal and

return.
Literal range is 1 to 8.

DEC

TOS = TOS - 1
IF result < 0
C = 1
ELSE
C = 0
IP = IP+1

Decrement TOS.

198

Neuron Assembly Instructions Listed by Mnemonic