ECE Department: University of Massachusetts, Amherst Using Altera CAD tools for NIOS Development.

Slides:



Advertisements
Similar presentations
Electrical and Computer Engineering MIDI Note Number Display UGA Presentation and Demo ECE 353 Lab B.
Advertisements

Avalon Switch Fabric. 2 Proprietary interconnect specification used with Nios II Principal design goals – Low resource utilization for bus logic – Simplicity.
My First Nios II for Altera DE2-115 Board 數位電路實驗 TA: 吳柏辰 Author: Trumen.
ECE 272 Xilinx Tutorial. Workshop Goals Learn how to use Xilinx to: Draw a schematic Create a symbol Generate a testbench Simulate your circuit.
Electrical and Computer Engineering How to Program with JTAG ECE 353 – Computer Systems lab I Mike O’Malley Tom Stack September 20 th 2005.
Configurable System-on-Chip: Xilinx EDK
The Xilinx EDK Toolset: Xilinx Platform Studio (XPS) Building a base system platform.
DE1 FPGA board and Quartus
Altera’s Quartus II Installation, usage and tutorials Gopi Tummala Lab/Office Hours : Friday 2:00 PM to.
Technion – Israel Institute of Technology Department of Electrical Engineering High Speed Digital Systems Lab Project performed by: Naor Huri Idan Shmuel.
Downloading to Altera Nios Development Kit CSCE 488 Witawas Srisa-an.
LAUNCHXL2-RM57L – Project 0
Using PDG with e2studio: Example
ECE Department: University of Massachusetts, Amherst Lab 1: Introduction to NIOS II Hardware Development.
CSCE 430/830 A Tutorial of Project Tools By Dongyuan Zhan Feb. 4, 2010.
Installing geant4 v9.5 using Windows Daniel Brandt, 06 April 2012 Installing Geant4 v9.5 for Windows A step-by-step guide for Windows XP/Vista/7 using.
Figure 1.1 The Altera UP 3 FPGA Development board
Introduction Purpose Objectives Content Learning Time
Introduction to FPGA Design Illustrating the FPGA design process using Quartus II design software and the Cyclone II FPGA Starter Board. Physics 536 –
Part 1 Using the ARM board And start working with C Tutorial 5 and 6
By: Nadav Haklai & Noam Rabinovici Supervisors: Mike Sumszyk & Roni Lavi Semester:Spring 2010.
CSE430/830 Course Project Tutorial Instructor: Dr. Hong Jiang TA: Dongyuan Zhan Project Duration: 01/26/11 – 04/29/11.
Cumulative Design Review: Interactive Teaching Device April 8 th, 2005 Lance Haney Micah Nance Nathan Young.
Renesas Technology America Inc. 1 M16C/Tiny SKP Tutorial 2 Creating A New Project Using HEW4.
Advanced Digital Circuits ECET 146 Week 3 Professor Iskandar Hack ET 221B,
Lab 2: Capturing and Displaying Digital Image
Technion – Israel Institute of Technology Department of Electrical Engineering High Speed Digital Systems Lab Spring 2009.
NetBurner MOD 5282 Network Development Kit MCF 5282 Integrated ColdFire 32 bit Microcontoller 2 DB-9 connectors for serial I/O supports: RS-232, RS-485,
COMPUTER SYSTEM LABORATORY Lab10 - Sensor II. Lab 10 Experimental Goal Learn how to write programs on the PTK development board (STM32F207). 2013/11/19/
OS Implementation On SOPC Midterm Presentation Performed by: Ariel Morali Nadav Malki Supervised by: Ina Rivkin.
Lecture #3 Page 1 ECE 4110– Sequential Logic Design Lecture #3 Agenda 1.FPGA's 2.Lab Setup Announcements 1.No Class Monday, Labor Day Holiday 2.HW#2 assigned.
1 3-General Purpose Processors: Altera Nios II 2 Altera Nios II processor A 32-bit soft core processor from Altera Comes in three cores: Fast, Standard,
Simulink ® Interface Course 13 Active-HDL Interfaces.
Lab 1 Department of Computer Science and Information Engineering National Taiwan University Lab1 - Sensor 2014/9/23/ 13 1.
Spring Introduction  Today’s tutorial focuses on introducing you to Xilinx ISE and Modelsim.  These tools are used for Verilog Coding Simulation.
1 Introduction to Xilinx ISL8.1i Schematic Capture and VHDL 1.
© 2005 Altera Corporation SOPC Builder: a Design Tool for Rapid System Prototyping on FPGAs Kerry Veenstra Workshop on Architecture Research using FPGA.
Active-HDL Interfaces Building VHPI Applications C Compilation Course 9.
NIOS II Ethernet Communication Final Presentation
Synopsys Custom Designer Tutorial for a chip integration using the University of Utah Standard Cell Libraries In ON Semiconductor 0.5u C5 CMOS Version.
1 EDK 7.1 Tutorial -- SystemACE and EthernetMAC on Avnet Virtex II pro Development Boards Chia-Tien Dan Lo Department of Computer Science University of.
Lecture #3 Page 1 ECE 4110–5110 Digital System Design Lecture #3 Agenda 1.FPGA's 2.Lab Setup Announcements 1.HW#2 assigned Due.
Lecture #2 Page 1 ECE 4110– Sequential Logic Design Lecture #2 Agenda 1.Logic Design Tools Announcements 1.n/a.
Programmable Logic Training Course HDL Editor
Altera’s Excalibur Development System Tyson Hall School of Electrical and Computer Engineering Georgia Institute of Technology.
Lab 2 Parallel processing using NIOS II processors
Renesas Technology America Inc. 1 M16C Seminars Lab 3 Creating Projects Using HEW4 14 March 2005 M16C Seminars Lab 3 Creating Projects Using HEW4 Last.
A Skeleton NIOS II Project for the DE1 board :
Part A Final Dor Obstbaum Kami Elbaz Advisor: Moshe Porian August 2012 FPGA S ETTING U SING F LASH.
Renesas Technology America Inc. 1 SKP8CMINI Tutorial 2 Creating A New Project Using HEW.
 Seattle Pacific University EE Logic System DesignAlteraBoard-2 Altera Cyclone II (484 Pin BGA) 22 Pins.
Proposal for an Open Source Flash Failure Analysis Platform (FLAP) By Michael Tomer, Cory Shirts, SzeHsiang Harper, Jake Johns
11 EENG 1920 Introduction to VHDL. 22 Hardware Description Language A computer language used to design circuits with text-based descriptions of the circuits.
Teaching Digital Logic courses with Altera Technology
Embedded Systems Design with Qsys and Altera Monitor Program
Active-HDL Server Farm Course 11. All materials updated on: September 30, 2004 Outline 1.Introduction 2.Advantages 3.Requirements 4.Installation 5.Architecture.
Copyright © 2007 by Pearson Education 1 UNIT 6A COMBINATIONAL CIRCUIT DESIGN WITH VHDL by Gregory L. Moss Click hyperlink below to select: Tutorial for.
Maj Jeffrey Falkinburg Room 2E46E
Workshop Setup The software/hardware used in this workshop are:
Introduction to Vivado
Lab 0: Familiarization with Equipment and Software
Lab 1: Using NIOS II processor for code execution on FPGA
The first change to your project files that is needed is to change the device to the correct FPGA. This is done by going to the Assignments tab on the.
Computer System Laboratory
ECE 4110–5110 Digital System Design
Avalon Switch Fabric.
Getting Started with Vivado
Figure 17.2 It is important that the Advanced Import Options be set as shown here.
Founded in Silicon Valley in 1984
ECE 3567 Microcontrollers Lab
Presentation transcript:

ECE Department: University of Massachusetts, Amherst Using Altera CAD tools for NIOS Development

2 ECE 354 – Spring 2008 Tools  Altera Quartus Complete FPGA chip development tool. Design a hardware, simulate, synthesis and burn a chip.  Altera SOPC Builder Included in Quartus tool Build a hardware part of target SoC (System on Chip) Project. Based on a Processor-core (named NIOS II processor), you can add other peripherals (e.g. Parallel IO, Ethernet Controller, Serial Ports and ETC.)  Altera NIOS IDE Build a software part of target SoC Project

3 ECE 354 – Spring 2008 Goal for this Lab  To be familiar with Altera tools  Part I : Step-by-Step process Print a “Hello, world” message that generated by your embedded system to the debug console  Part 2 : is a small modification from Part1.

4 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Open Quartus II, and select file - > New Project Wizard…  Specify a working directory for your project, and give your project a name. We haven’t defined a top-level design entity yet, so leave that field the same as the project name.  NOTE: Be sure your working directory contains no white- space. This will cause problems later when trying to compile your project from the SOPC Builder.  Click “next”

5 ECE 354 – Spring 2008  We are now asked for a target device.  Select Cyclone II in the drop- down box labeled “family”. We will be using device EP2C35F672C6.  At this point, click finish. All necessary project parameters have been configured. Tutorial: Using the SOPC Builder

6 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Now that a Quartus project has been setup, select File -> New…  We will be using the SOPC Builder System, so select this option and click OK.  You are prompted for an SOPC system name. SOPC generates VHDL or Verilog to describe the system. Select the language you are more comfortable programming in.

7 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder

8 ECE 354 – Spring 2008  The menu on the left side of the Builder shows a a variety of modules that can be included in the system. We will start by adding a module central to all NIOS based SOPC systems: The NIOS II Processor.  Double-clicking on the device will open a dialogue box containing a number of different options for configuring your NIOS II Processor. Tutorial: Using the SOPC Builder

9 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder

10 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  As you can see, there are 3 different varieties of the NIOS II, which provide a trade-off between FPGA resource usage and performance.  The Cyclone II is MUCH larger than the PLDs you are accustomed to working with. Our design will be very small, so we are not too concerned with resource usage.  Select the 2 nd option (NIOS II/s). Don’t worry about the other settings. These allow you to change options such as instruction cache size and Debug support. Do not disable debug support, as it will be impossible to program the Nios!

11 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Next, we will be adding a JTAG UART module, found under Serial. This provides us a way to communicate with the NIOS processor from the host computer.

12 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Next, we will be adding an interval timer to the system. This provides a system “heart-beat” which will handle many operations that happen outside of normal program-flow (interrupts, bus-arbitration, etc.)

13 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Looking at the right-most column (labeled IRQ) of the modules you have instantiated, you will notice that the JTAG debug module has a lower IRQ than the interval-timer.  Lower IRQ means higher priority. We want the interval timer to have a higher priority than the JTAG UART.  Swap the two IRQ assignments to give the interval timer a higher priority.

14 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Your system should now look something like this:

15 ECE 354 – Spring 2008  One more module is necessary to specify a bare- bones system to run a program on the NIOS processor: a program memory.  The simplest solution is to provide an on-chip memory.  On-chip memories can be found under “Memory”. Leave all options at their default values, but do change the memory size to 20kB. Tutorial: Using the SOPC Builder

16 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder

17 ECE 354 – Spring 2008 Tutorial: Using the SOPC Builder  Change the momory offset if it is needed.  Double click cpu instance (cpu_0) and provide Reset Vector and Exception Vector  Your system should now be ready to go! Click generate.

18 ECE 354 – Spring 2008 Tutorial: Programming the FPGA  Back to Quartus Now select Processing -> start -> Start Analysis & Synthesis. A number of warnings will appear during the check. This is normal.

19 ECE 354 – Spring 2008 Tutorial: Programming the FPGA

20 ECE 354 – Spring 2008 Tutorial: Programming the FPGA  The DE2 comes with a.csv (comma separated value) file that can be used to automatically provide more intuitive names to the generic names pins have by default.  The.csv file can be found on the DE2 CD in the DE2_tutorials/design_files directory select Assignments -> Import Assignments… -> Browse the.csv file.  We will change two assignments from default : reset and the 50 MHz clock. Now select Assignments -> Pins.

21 ECE 354 – Spring 2008 Tutorial: Programming the FPGA You should see assignments similar to the screenshot found below:

22 ECE 354 – Spring 2008 Tutorial: Programming the FPGA  Clicking the leftmost column (To), will allow the entries to be alphabetized.  Find the entry “CLOCK_50”, and replace it with our unassigned pin “clk_0”. Doing so will connect the clock found in our design to the 50 MHz oscillator on the DE2 board.  Now assign the reset_n input signal to any of the SW[x] pins. This will connect the reset signal to one of the switches found on the DE2 board.  Now select Processing -> Start Compilation. If compilation is successful, a programming file to be written to the FPGA will be generated.

23 ECE 354 – Spring 2008 Tutorial: Programming the FPGA  Select Tools -> Programmer. The generated programming file should automatically be selected. Be sure the DE2 is connected to the computer via the provided USB cable. Check the Program/Configure box to configure the Cyclone II FPGA as the NIOS system defined in the SOPC Builder.  A dialogue box will open, mentioning we are using a time-limited version of the NIOS processor. Leave this box open. The FPGA has now been successfully configured!

24 ECE 354 – Spring 2008 Tutorial: Programming the FPGA

25 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE  Now that you have successfully developed an SOPC system, we will write a very simple program to run on our new processor.  Open the NIOS IDE.  create a new workspace.

26 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE  Select File -> New -> Project. A new dialogue box should open.  Select C/C++ Application. Click next.  A variety of project templates are provided as a starting point. We will be using the “Hello World” template.  In order to develop a NIOS project, the IDE needs a.ptf (plain text file) file that indicates various peripherals unique to our design.

27 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE

28 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE  If we had developed a multi-processor design, we have the option of selecting a CPU, but as our design only contains one, we may only select cpu_0.  Now click finish. The compiler will generate various libraries necessary to interact with the hardware. These libraries are dependant upon the type of system we have defined in SOPC.

29 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE  You should now be looking at a window like this:

30 ECE 354 – Spring 2008  Before we compile this project a couple of optimizations are necessary.  Using the default libraries to compile our project will result in a memory footprint larger than the 20kB provided by our on-chip memory.  Under the “C/C++ Projects” tab, right-click hello_world_0. Select System Library Properties.  Uncheck “clean exit” and check “small C library”.  Click OK to update the library settings. Tutorial: Using the NIOS II IDE

31 ECE 354 – Spring 2008 tutorial: Using the NIOS II IDE

32 ECE 354 – Spring 2008 Tutorial: Using the NIOS II IDE  Under the “C/C++ Projects” tab, right-click hello_world_0. This time select Run As -> NIOS II Hardware.  This option will compile and write the program to the on-chip memory we specified in SOPC.

33 ECE 354 – Spring 2008 HELLO WORLD!  If compilation was successful, and the hardware is properly connected, you should see a greetings message printed to the console from the DE2 board.

34 ECE 354 – Spring 2008 Hello World!

35 ECE 354 – Spring 2008 What you have learned:  How to develop a simple NIOS system in the Quartus II SOPC Builder  Use the NIOS II IDE to run a very simple C program on the system defined in SOPC.  Gain confidence necessary to build more complex systems ;-).

36 ECE 354 – Spring 2008 Part II  You will use external memory  You will use other devices (LED, seven segment and ETC.)  Please read lab instruction on class website