R

Chapter 3: PicoBlaze Instruction Set

Table 3-1:PicoBlaze Instruction Set (alphabetical listing)

Instruction

Description

Function

ZERO

CARRY

 

 

 

 

 

ENABLE INTERRUPT

Enable interrupt input

INTERRUPT_ENABLE Å 1

-

-

(EINT)

 

 

 

 

 

 

 

 

 

Interrupt Event

Asynchronous interrupt input. Preserve

Preserved ZERO Å ZERO

-

-

 

flags and PC. Clear

Preserved CARRY Å CARRY

 

 

 

INTERRUPT_ENABLE flag. Jump to

 

 

 

INTERRUPT_ENABLE Å 0

 

 

 

interrupt vector at address 3FF.

 

 

 

TOS Å PC

 

 

 

 

 

 

 

 

PC Å 3FF

 

 

 

 

 

 

 

FETCH sX, (sY)

Read scratchpad RAM location pointed to

sX Å RAM[(sY)]

-

-

(FETCH sX, sY)

by register sY into register sX

 

 

 

 

 

 

 

 

FETCH sX, ss

Read scratchpad RAM location ss into

sX Å RAM[ss]

-

-

 

register sX

 

 

 

 

 

 

 

 

INPUT sX, (sY)

Read value on input port location pointed

PORT_ID Å sY

-

-

(IN sX, sY)

to by register sY into register sX

sX Å IN_PORT

 

 

 

 

 

 

 

 

 

 

 

INPUT sX, pp

Read value on input port location pp into

PORT_ID Å pp

-

-

(IN)

register sX

sX Å IN_PORT

 

 

 

 

 

 

 

 

 

 

JUMP aaa

Unconditionally jump to aaa

PC Å aaa

-

-

 

 

 

 

 

JUMP C, aaa

If CARRY flag set, jump to aaa

If CARRY=1, PC Å aaa

-

-

 

 

 

 

 

JUMP NC, aaa

If CARRY flag not set, jump to aaa

If CARRY=0, PC Å aaa

-

-

 

 

 

 

 

JUMP NZ, aaa

If ZERO flag not set, jump to aaa

If ZERO=0, PC Å aaa

-

-

 

 

 

 

 

JUMP Z, aaa

If ZERO flag set, jump to aaa

If ZERO=1, PC Å aaa

-

-

 

 

 

 

 

LOAD sX, kk

Load register sX with literal kk

sX Å kk

-

-

 

 

 

 

 

LOAD sX, sY

Load register sX with register sY

sX Å sY

-

-

 

 

 

 

 

OR sX, kk

Bitwise OR register sX with literal kk

sX Å sX OR kk

?

0

 

 

 

 

 

OR sX, sY

Bitwise OR register sX with register sY

sX Å sX OR sY

?

0

 

 

 

 

 

OUTPUT sX, (sY)

Write register sX to output port location

PORT_ID Å sY

-

-

(OUT sX, sY)

pointed to by register sY

OUT_PORT Å sX

 

 

 

 

 

 

 

 

 

 

 

OUTPUT sX, pp

Write register sX to output port location

PORT_ID Å pp

-

-

(OUT sX, pp)

pp

OUT_PORT Å sX

 

 

 

 

 

 

 

 

 

 

 

RETURN

Unconditionally return from subroutine

PC Å TOS+1

-

-

(RET)

 

 

 

 

 

 

 

 

 

RETURN C

If CARRY flag set, return from subroutine

If CARRY=1, PC Å TOS+1

-

-

(RET C)

 

 

 

 

 

 

 

 

 

RETURN NC

If CARRY flag not set, return from

If CARRY=0, PC Å TOS+1

-

-

(RET NC)

subroutine

 

 

 

 

 

 

 

 

RETURN NZ

If ZERO flag not set, return from

If ZERO=0, PC Å TOS+1

-

-

(RET NZ)

subroutine

 

 

 

 

 

 

 

 

RETURN Z

If ZERO flag set, return from subroutine

If ZERO=1, PC Å TOS+1

-

-

(RET Z)

 

 

 

 

 

 

 

 

 

20

www.xilinx.com

PicoBlaze 8-bit Embedded Microcontroller

 

 

UG129 (v1.1.2) June 24, 2008

Page 20
Image 20
Xilinx UG129 manual Enable Interrupt