Docsity

Altera Quartus II FPGA Design Tutorial: Building Adders and Multiplexers, Study notes of Computer Science

Partial preview of the text

Download Altera Quartus II FPGA Design Tutorial: Building Adders and Multiplexers and more Study notes Computer Science in PDF only on Docsity!

Altera Quartus II Tutorial

CSE140L – WI

TA: Jianhua Liu

CSE Dept. UCSD

Altera Quartus II

z

The Quartus II development softwareprovides a

complete design environment

for FPGA designs.

z

Design entry using schematics, blockdiagrams, VHDL, and Verilog HDL.

z

Design analysis and synthesis, fitting,assembling, timing analysis, simulation.

Tutorial Outline

z

Open Quartus II and pick a device.

z

Build a full adder.

(Block/Schematic)

z

Add components

z

Add ports

z

Add connections

(single wire connection)

z

Build a 4-bit adder.

z

Create a block for full adder

z

Use conduit and port mapping

Tutorial Outline

z

Compile the 4-bit adder.

z

Open compiler tool

z

Read compilation report

z

Open timing closure floorplan

z

Simulate the 4-bit adder.

z

Open simulator tool

z

Edit simulation waveform

z

Observe simulation results

z

Schematic for 16-bit Multiplexer

z

Use connections by name

Create a new project

z

Menu

Æ

File

Æ

New Project Wizard

Build a full adder

z

Menu

Æ

File

Æ

New

z

Create a Block Diagram/Schematic File

z

Menu

Æ

File

Æ

Save As: fadder.bdf

LibraryNew BlockSingle WireBusConduit

Build a full adder

z

Place two

xor

, two

and

and one

or

.

Build a full adder

z

Find

input

and

output

under

primitives

Æ

pin

,

and place three

input

and two

output

z

Double click on each pin, to change pin name.

Questions

Build a 4-bit adder

z

Menu

Æ

File

Æ

New

z

Create a Block Diagram/Schematic File

z

Menu

Æ

File

Æ

Save As: adder4.bdf

z

Click on new block

, and draw a block.

z

Double click on the block name, change it to

fadder

Build a 4-bit adder

z

Click on

OK

to dismiss the

properties window.

z

Right click on the block, andselect

AutoFit

in the pop-up

menu.

z

Select the block, make fourcopies by copy/paste.

z

Add 3 inputs and 2 outputs.

Build a 4-bit adder

z

Use conduit tool to connect each

fadder

to inputs and

outputs. Conduit can stop at any point on a blockborder.

Build a 4-bit adder

z

For A[3..0], B[3..0] and S[3..0], port mapping should bemanually defined. Edit the

signals

property for A[3..0]

like this:

Build a 4-bit adder

z

After port mapping for A[3..0], B[3..0] and S[3..0], youwill see this: