Lecture 13 PicoBlaze I/O & Interrupt Interface Example of Assembly Language Routine ECE 448 – FPGA and ASIC Design with VHDL.

Slides:



Advertisements
Similar presentations
Lecture 16 PicoBlaze Instruction Set & Assembler Directives
Advertisements

1ASM Algorithmic State Machines (ASM) part 1. ASM2 Algorithmic State Machine (ASM) ‏ Our design methodologies do not scale well to real-world problems.
Multiplication Schemes Continued
PicoBlaze CPLD Microcontroller
ECE 448 – FPGA and ASIC Design with VHDL Lecture 13 PicoBlaze I/O & Interrupt Interface.
ECE 448 – FPGA and ASIC Design with VHDL Lecture 15 External SRAM.
Sequential Multipliers Lecture 9. Required Reading Chapter 9, Basic Multiplication Scheme Chapter 10, High-Radix Multipliers Chapter 12.3, Bit-Serial.
Digital Kommunikationselektronik TNE027 Lecture 2 1 FA x n –1 c n c n1- y n1– s n1– FA x 1 c 2 y 1 s 1 c 1 x 0 y 0 s 0 c 0 MSB positionLSB position Ripple-Carry.
1 KU College of Engineering Elec 204: Digital Systems Design Lecture 21 Multiplier Example Example: (101 x 011) Base 2 Note that the partial product summation.
July 2005Computer Architecture, The Arithmetic/Logic UnitSlide 1 Part III The Arithmetic/Logic Unit.
Chap 8. Sequencing and Control. 8.1 Introduction Binary information in a digital computer –data manipulated in a datapath with ALUs, registers, multiplexers,
CPU Internal memory I/O interface circuit System bus
ECE 448 – FPGA and ASIC Design with VHDL Lecture 12 PicoBlaze Overview.
ECE 448 – FPGA and ASIC Design with VHDL Lecture 12 PicoBlaze Overview.
1 Lecture #17 EGR 277 – Digital Logic Reading Assignment: Chapter 6 in Digital Design, 3 rd Edition by Mano Timing Sequences So far we have designed circuits.
Introduction to Experiment 7 Sorting Using PicoBlaze ECE 448 Spring 2010.
TK2633 : MICROPROCESSOR & INTERFACING Lecture 10: Fixed Point Arithmetic Lecturer: Ass. Prof. Dr. Masri Ayob.
Introduction to Experiment 6 Internal FPGA Memories, Pseudo Random Number Generator, Advanced Testbenches ECE 448 Spring 2009.
9/15/09 - L15 Decoders, Multiplexers Copyright Joanne DeGroat, ECE, OSU1 Decoders and Multiplexer Circuits.
ECE 448 – FPGA and ASIC Design with VHDL Lecture 19 PicoBlaze Interrupt Interface & Assembly Code Development.
Microprocessor Dr. Rabie A. Ramadan Al-Azhar University Lecture 8.
CDA 4253 FPGA System Design PicoBlaze Instruction Set Hao Zheng Comp Sci & Eng U of South Florida.
ECE 2110: Introduction to Digital Systems Number Systems.
Lecture 3 RTL Design Methodology Transition from Pseudocode & Interface to a Corresponding Block Diagram.
ECE 448: Lab 6 Using PicoBlaze Fast Sorting. Part 1: Introduction to Lab 6 Part 2: Instruction Set of PicoBlaze-6 Part 3: Hands-on Session: OpenPICIDE.
Picoblaze Overview EENG Introduction 8-bit microcontroller for Xilinx devices Soft Core – Soft Processor 5% of the resources of spartan 3 (3S200.
Introduction to Experiment 7 Replacing Hardwired Control Unit with the Picoblaze Microcontroller ECE 448 Spring 2009.
ECE 545—Digital System Design with VHDL Lecture 1
ECE 447: Lecture 11 Introduction to Programming in Assembly Language.
MICROPROCESSOR DETAILS 1 Updated April 2011 ©Paul R. Godin prgodin gmail.com.
George Mason University Class Exercise 1B. 2ECE 448 – FPGA and ASIC Design with VHDL Rules If you believe that you know a correct answer, please raise.
Microprocessor & Assembly Language
Logic Design (CE1111 ) Lecture 4 (Chapter 4) Combinational Logic Prepared by Dr. Lamiaa Elshenawy 1.
CDA 4253 FPGA System Design PicoBlaze Interface Hao Zheng Comp Sci & Eng U of South Florida.
CDA 4253 FPGA System Design PicoBlaze Interface Hao Zheng Comp Sci & Eng U of South Florida.
Implementing Combinational
Lecture 18 PicoBlaze Instruction Set & Assembler Directives
Temperature Measurement
RTL Design Methodology Transition from Pseudocode & Interface
Lecture 15 PicoBlaze Overview
ECE 3110: Introduction to Digital Systems
8086 Microprocessor.
Principles & Applications
RTL Design Methodology
Microcomputer & Interfacing Lecture 1
CS-401 Assembly Language Programming
KU College of Engineering Elec 204: Digital Systems Design
Lecture 14 PicoBlaze Overview
Lecture 16 PicoBlaze I/O & Interrupt Interface
ECE 434 Advanced Digital System L13
ECE 434 Advanced Digital System L12
Lecture 16 PicoBlaze Overview
Introduction to ModelSim Implementing Sequential
Lecture 18 PicoBlaze I/O Interface
8086 Ahad.
ECE 448: Lab 6 Using PicoBlaze Fast Sorting Class Exercise 2.
Review of Aldec Active HDL Implementing Combinational
Lecture 13 PicoBlaze I/O & Interrupt Interface
MBR MAR RWM Unit R (Read Control) W (write Control) MBR.
Data Flow Description of Combinational-Circuit Building Blocks
Lecture 15 PicoBlaze I/O & Interrupt Interface
ECE 434 Advanced Digital System L11
Lecture 13 PicoBlaze I/O & Interrupt Interface
Lecture 17 PicoBlaze I/O & Interrupt Interface
14 Digital Systems.
RTL Design Methodology Transition from Pseudocode & Interface
RTL Design Methodology Transition from Pseudocode & Interface
RTL Design Methodology Transition from Pseudocode & Interface
Chapter 6 Programming the basic computer
Lecture 14 PicoBlaze Instruction Set
Presentation transcript:

Lecture 13 PicoBlaze I/O & Interrupt Interface Example of Assembly Language Routine ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL Required reading P. Chu, FPGA Prototyping by VHDL Examples Chapter 16, PicoBlaze I/O Interface Chapter 17, PicoBlaze Interrupt Interface ECE 448 – FPGA and ASIC Design with VHDL

Output Decoding of Four Output Registers ECE 448 – FPGA and ASIC Design with VHDL

Timing Diagram of an Output Instruction ECE 448 – FPGA and ASIC Design with VHDL

Truth Table of a Decoding Circuit ECE 448 – FPGA and ASIC Design with VHDL

Block Diagram of Four Continuous-Access Ports ECE 448 – FPGA and ASIC Design with VHDL

Timing Diagram of an Input Instruction ECE 448 – FPGA and ASIC Design with VHDL

Block Diagram of Four Single-Access Ports ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL FIFO Interface clk rst clk rst FIFO din dout 8 8 full empty write read ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL Operation of FIFO ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL Interrupt Flow ECE 448 – FPGA and ASIC Design with VHDL

Timing Diagram of an Interrupt Event ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL

Interrupt Interface with a Single Event ECE 448 – FPGA and ASIC Design with VHDL

Interrupt Interface with Two Requests ECE 448 – FPGA and ASIC Design with VHDL

Time-Multiplexed Seven Segment Display ECE 448 – FPGA and ASIC Design with VHDL

Block Diagram of the Hexadecimal Time-Multiplexing Circuit ECE 448 – FPGA and ASIC Design with VHDL

ECE 448 – FPGA and ASIC Design with VHDL Hexadecimal Multiplexing Circuit Based on PicoBlaze and mod-500 Counter ECE 448 – FPGA and ASIC Design with VHDL

Example of a function in the PicoBlaze assembly language ECE 448 – FPGA and ASIC Design with VHDL

Notation a Multiplicand ak-1ak-2 . . . a1 a0 x Multiplier xk-1xk-2 . . . x1 x0 p Product (a  x) p2k-1p2k-2 . . . p2 p1 p0

Multiplication of two 4-bit unsigned binary numbers Partial Product 0 Partial Product 1 Partial Product 2 Partial Product 3

Unsigned Multiplication – Basic Equations k-1 x =  xi  2i p = a  x i=0 k-1 p = a  x =  a  xi  2i = = x0a20 + x1a21 + x2a22 + … + xk-1a2k-1 i=0

Iterative Algorithm for Unsigned Multiplication Shift/Add Algorithm p = a  x = x0a20 + x1a21 + x2a22 + … + xk-1a2k-1 = = (...((0 + x0a2k)/2 + x1a2k)/2 + ... + xk-1a2k)/2 = k times p(0) = 0 p(j+1) = (p(j) + xj a 2k) / 2 j=0..k-1 p = p(k)

Unsigned Multiplication Computations 8 bits 8 bits pH pL p p(j) xj a + xj a 28 + pH pL C 2 p(j+1) >> 1 p(j+1) pH pL C pH = s5 pL = s6 PicoBlaze Registers a = s3 x = s4

Unsigned Multiplication Subroutine (1) ;========================================================= ; routine: mult_soft ; function: 8-bit unsigned multiplier using ; shift-and-add algorithm ; input register: ; s3: multiplicand ; s4: multiplier ; output register: ; s5: upper byte of product ; s6: lower byte of product ; temporary register: ; s2: index j

Unsigned Multiplication Subroutine (2) mult_soft: load s5, 00 ;clear s5 load s2, 08 ;initialize loop index mult_loop: sr0 s4 ;shift lsb to carry jump nc, shift_prod ;lsb is 0 add s5, s3 ;lsb is 1 shift_prod: sra s5 ;shift upper byte right, ;carry to MSB, LSB to carry sra s6 ;shift lower byte right, ;lsb of s5 to MSB of s6 sub s2, 01 ;dec loop index jump nz, mult_loop ;repeat until i=0 return

Edit instructions - Shifts *All shift instructions affect Zero and Carry flags