t1_verilog (1)

20
EE344 – DIGITAL SYSTEMS DESIGN

Upload: 0307ali

Post on 20-Jul-2016

217 views

Category:

Documents


0 download

DESCRIPTION

This is a presentation on verilog.

TRANSCRIPT

Page 1: T1_Verilog (1)

EE344 – DIGITAL SYSTEMS DESIGN

Page 2: T1_Verilog (1)

REFERENCE:

Hardware Descriptive Language (HDL)

EE344 – DIGITAL SYSTEMS DESIGN

September 2010

Abdullah MansoorDept of Electrical Engineering

NUST School of Electrical Engineering and Computer Sciences (SEECS)

Page 3: T1_Verilog (1)

Outline Why HDL? Evolution of CAD and HDL Abstraction and Level of Abstraction in HDL Verilog Design Flow Verilog Programming components

Page 4: T1_Verilog (1)

WHY HDL??

Page 5: T1_Verilog (1)

Hardware Descriptive Language (HDL) Why not C, C++, Java, Fortran or other

Higher level language?? Need true Hardware representation!

Concurrency

Page 6: T1_Verilog (1)

Evolution of Computer-Aided Digital Design (CAD)

Very Large Scale Integration (VLSI)

More then 100,000 transistors Automated Design

Large Scale IntegrationThousands of Transistors Manual design

Medium Scale IntegrationFew Hundreds of Transistors Manual design

Small Scale Integration (SSI)Hundred Transistors Manual Design

Electronic Design Automation (EDA)

Page 7: T1_Verilog (1)

Verilog HDL

Developed at Automated Integrated Design Systems in 1985 which is acquired by Cadence in 1989.

The US Department of Defense developed VHDL (VHSIC HDL) as open source

Cadence opened Verilog to the public in 1990 afraid of losing market share.

IEEE defined standard for Verilog (IEEE 1364-2001)

Page 8: T1_Verilog (1)

Abstraction

Mean identifying aspects that are important to a task at hand, and hiding details of other aspects

Example Logic Levels: 0 or 1

Page 9: T1_Verilog (1)

Real Word Circuits

Page 10: T1_Verilog (1)

Representation of Real World Circuits

Logic Levels Capacitive Load and Propagation Delay Power

Ref: Ch1 Ashenden Book

Page 11: T1_Verilog (1)

Verilog Levels of Abstraction

Behavioral/Algorithmic Level Describes a system by sequential algorithms.

Register Transfer Level (RTL) Here we specify the characteristics of circuits by

operations and the transfer of data between the registers

Structural/Gate Level Here you define the circuit in terms of its connection

of building block e.g defining NAND gate in terms of AND and NOT

Page 12: T1_Verilog (1)

Behavioral level of Abstraction

Example Representation of MUX using If-else statements

If (S==0) thenY = I0

else Y =I1

end

Maximum level of AbstractionProgramming at this level is similar to programming in C. Implementation of algorithms using if-else and similar constructs

Page 13: T1_Verilog (1)

Structural level of AbstractionMinimum level of Abstraction

Page 14: T1_Verilog (1)

Register Transfer Level (RTL) of Abstraction Implementation of shifters using Flip Flop

circuits instead of using operators

Medium level of Abstraction

Page 15: T1_Verilog (1)

Verilog Design Flow

Design Entry Functional Verification Synthesis Pos-Synthesis Verification Physical Implementation Physical Verification

Page 16: T1_Verilog (1)

Module in Verilog A module defines the input and output of a block and its operation

either in terms of behavioral style or structural style Its like function definition in C but there is no return call unlike C General Module style:module <NAME> (<LIST OF PORTS>);<declaration & implementation>endmodule Examplemodule and (a, b, out);input a, b;output out;out=a&b;endmodule

Page 17: T1_Verilog (1)

Instantiation of Modules

Instantiation Instantiation helps re-using pre-defined modules Instantiation defines hierarchy of the design Example of a system with multiple MUX

Syntax for Instantiation:<Buit-in gates or predefined Modules> <instance_name>(interconnections;output is first then inputs);

Example:and A1 (Y, A, B);

Page 18: T1_Verilog (1)

Port Mapping in Instantiation

It is the association of ports between instantiated module and the predefined module.

There are two types

Page 19: T1_Verilog (1)

In the next lecture you will learn… More detail about code synthesis Test Bench: to test your circuit Data types and variables

Reading Assignment: Chapter 1& 2 PALNITKAR BOOK

Page 20: T1_Verilog (1)

Thank you!