1 (6)
12.13
Department of Information Technology
Faculty of Mathematics and Natural Sciences
University of Turku
Department of Microelectronics
School of Information Science and Technology
Fudan University
Exercise 7: Modelling an
embedded microcontroller
Introduction
The purpose of this exercise is to design, simulate a behavioural clone of the Ken Chapman's
popular PicoBlaze embedded microcontroller. The PicoBlaze™ microcontroller is a compact,
capable, and cost-effective fully embedded 8-bit RISC microcontroller core optimized for the
many FPGA families.
In this design, the focus is to bring the most significant advantages that a processor can offer to
a design environment at minimum cost. For this reason, these small processors have been
considered to be "Programmable State Machines" and are referred to as "PSM". A PSM, like
any other processor, will execute a program. A program is formed by a set of instructions that
are defined by the user and held in a memory. Each instruction is encoded into a machine
code.
The block of the microcontroller is shown below:
Block Diagram
As shown in the block diagram, the microcontroller supports the following features:
16 8-bit-wide general-purpose data registers: The microcontroller includes 16 byte-wide
general-purpose registers, designated as registers R0 through RF.
256-Instruction Program Store: The microcontroller executes up to 256 instructions from
memory. Each instruction is 17 bits wide.
Arithmetic-Logic Unit (ALU): The byte-wide Arithmetic Logic Unit (ALU) performs all
microcontroller calculations, including:
Basic arithmetic operations such as addition and subtraction
o bitwise logic operations such as AND, OR, and XOR
o zero and carry flags calculations
o shift and rotate operations
All operations are performed using an operand provided by any specified register (Rx). The
result is returned to the same specified register(Rx). If an instruction requires a second
operand, then the second operand is either a second register (Ry) or an 8-bit immediate
constant (kk).