SlideShare a Scribd company logo
1 of 78
Download to read offline
Ibrahim Mezzah
Introduction
Design abstraction levels timeline
1987 - VHDL
IEEE standard
Introduction
What is VHDL?
V: VHSIC or Very High-Speed Integrated Circuit.
HDL: Hardware Description Language.
 VHDL is a true computer language with the
accompanying set of syntax and usage rules.
 As opposed to higher-level computer languages,
VHDL is primarily used to describe hardware.
Hardware description languages Higher-level computer languages
Introduction
Pay attention!!
 The common mistake made by someone is to attempt to
program in VHDL as they would program a higher-level
computer language. Higher-level computer languages are
sequential in nature; VHDL is not.
 VHDL is a concurrent language: VHDL instructions are all
executed at the same time (concurrently).
 Higher-level computer languages are used to describe
algorithms (sequential execution) and VHDL is used to describe
hardware (parallel execution).
Introduction
Golden Rules of VHDL
 VHDL is a hardware-design language
When you are working with VHDL, you are not programming, you are
"designing hardware". Your VHDL code should reflect this fact. If your
VHDL code appears too similar to code of a higher-level computer
language, it is probably bad VHDL code.
 Have a general concept of what your hardware should look like
Although VHDL is vastly powerful, if you do not understand basic
digital constructs, you will probably be unable to generate efficient
digital circuits. If you are not able to roughly envision the digital
circuit you are trying to model in terms of basic digital circuits, you
will probably misuse VHDL.
VHDL Invariants
Case Sensitivity
White Space
VHDL is not sensitive to white space (spaces and tabs).
Comments
Comments in VHDL begin with the symbol "--" (two consecutive dashes).
VHDL is not case sensitive.
VHDL Invariants
Parentheses
VHDL Statements
Similar to other algorithmic computer languages, every VHDL statement
is terminated with a semicolon ";".
VHDL is relatively lax on its requirement for using parentheses.
VHDL Invariants
Identifiers
An identifier refers to the name given to various items in VHDL (variable names,
signal names and port names …etc).
 Identifiers can be as long as you want (contain many characters).
 Identifiers can only contain a combination of letters (A-Z and a-z), digits
(0-9) and the underscore character ("_").
 Identifiers must start with an alphabetic character.
VHDL Invariants
Reserved Words
There is a list of words that have been assigned special meaning by the VHDL
language. These special words, usually referred to as reserved words, cannot be
used as identifiers when writing VHDL code.
VHDL Design Units
VHDL description organisation
VHDL Design Units
VHDL Standard Libraries
VHDL Design Units
Entity declaration
The VHDL entity provides a simple wrapper for the
lower-level circuitry. This wrapper effectively describes
how the black box interfaces with the outside world.
 Each port name is unique and has an associated mode and data type.
 The VHDL compiler allows several port names to be included on a
single line. Port names are separated by commas.
 These input and output signals are associated with the keywords in,
out, inout or buffer.
Black-box
VHDL Design Units
Entity declaration
 As specified in the
package, the
implementation of the
type (and the
type) includes 9 different values:
0,1,U,X,Z,W,L,H,-.
The signals in the bus can be listed in one of two orders which are
specified by the to and downto keywords.
MSB LSB MSB LSB
VHDL Design Units
Entity declaration – Exercise 1
Write VHDL entity declarations that describe the following
black-box diagrams:
VHDL Design Units
Entity declaration – Exercise 2
Provide black-box diagrams that are defined by the following
VHDL entity declarations:
Are there any errors!?
VHDL Design Units
Architecture
The architecture describes what the circuit actually does. In other words,
the VHDL architecture describes the internal implementation of the
associated entity.
Several possible implementations (models) of the same behavior are
possible in VHDL:
 The data-flow model,
 The behavioral model,
 The structural model,
 Any combination of these three, generally called the hybrid models.
Data-flow model
VHDL Design Units
Signal and Variable Assignments
In VHDL there are several object types:
 The signal object type: is the representation of a wire.
 The variable object type: used to store local information.
 The constant object type: used to store constant values.
To assign a new value to a signal you use the operator "<=".
To assign a new value to a variable you use the operator ":=".
VHDL Assignment
Concurrent Statements
The main design consideration in VHDL modeling supports the fact that
digital circuits operate in parallel.
Each concurrent statement is
interpreted as acting in parallel
(concurrently) to other
concurrent statements.
VHDL Assignment
Assignment types in VHDL
The major signal assignment types in VHDL are:
 Concurrent signal assignment
 Conditional signal assignment
 Selected signal assignment
 Process statements
VHDL Assignment
Concurrent signal assignment
 The target is a signal that receives the values of the expression.
VHDL Assignment
Conditional signal assignment
 The term conditional signal assignment is used to describe
statements that have only one target but can have more than one
associated expression assigned to the target.
VHDL Assignment
Conditional signal assignment - Example
VHDL Assignment
Selected signal assignment
 Selected signal assignment statements differ from conditional
assignment statements in that assignments are based upon the
evaluation of one expression.
VHDL Assignment
Selected signal assignment – Example 1
VHDL Assignment
Selected signal assignment – Example 2
VHDL Assignment
Selected signal assignment – Example 3
VHDL Assignment
Process statements
 The process statement itself is a concurrent statement identified by its label,
its sensitivity list, a declaration area and a begin-end area containing
instructions executed sequentially.
 The execution of the sequential statements is initiated when a change in the
signal contained in the process sensitivity list occurs.
VHDL Assignment
Process statements
VHDL Assignment
Process statements – Example
Sequential Statements
There are 3 types of sequential statements:
 Signal assignment statement
 statement
 statement
Sequential Statements
 Signal assignment statement
 The target is a signal that receives the values of the expression.
Sequential Statements
 statement
 The statement is used to create a branch in the execution flow of the
sequential statements.
 Each -type statement contains an associated keyword. The final
clause does not have the keyword associated with it.
Sequential Statements
 statement – Example 1
Sequential Statements
 statement – Example 2
Sequential Statements
 statement – Example 3
Sequential Statements
 statement – Example 4
Using statement for Sequential Circuits (D flip-flop)
Sequential Statements
 statement – Example 5
Using statement for Sequential Circuits (D flip-flop)
Sequential Statements
 statement – Exercise 1
Design a 4-bit parallel-in register.
Sequential Statements
 statement – Exercise 2
Design a Serial-in shift register.
Sequential Statements
 statement
 The statement is somewhat similar to the statement in that a
sequence of statements is executed an associated expression is true.
 The statement differs from the statement in that the resulting
choice is made depending upon the value of the single control expression.
Sequential Statements
 statement – Example 1 F_OUT = A · B · C + B · C
 statement – Example 2
Sequential Statements
VHDL Operators
VHDL operators
 Operators in VHDL are grouped into seven different types:
logical, relational, shift, addition, unary, multiplying and others.
VHDL Operators
VHDL shift operators
Shift Operator
VHDL Operators
 The concatenation operator is often a useful operator when
dealing with digital circuits.
 There are many times when you will find a need to tack
together two separate values.
Concatenation operator
Data Objects
Types of Data Objects
 There are four types of data objects in VHDL:
signals, variables, constants and files.
 File data objects, exclusively used in simulations.
Data Objects
Types of Data Objects
 Each of the data objects can optionally be assigned initial values.
 Signal declarations do not usually include initial values as opposed to
constants which generally do.
 Initial values for signals are in fact not implementable on silicon by
the synthesizing tools but are taken into consideration by VHDL
simulation tools.
Data Objects
Signals vs. Variables
 The use of signals and variables can be somewhat confusing because
of their similarities.
 A signal can be thought of as representing a wire or some type of
physical connection in a design.
 Assignments made to signals inside a process are actually only
scheduled when the same process is completed. The actual
assignment is not made until after the process terminates.
 Variable assignment within processes is different. When a variable is
assigned a value inside of a process, the assignment is immediate and
the newly assigned value can be used immediately inside of the
process.
 Variables should only be used as iteration counters in loops or as
temporary values when executing an algorithm that performs some
type of calculation. It is possible to use variables outside of these
areas, but it should be avoided.
Data Objects
Signals vs. Variables (example)
Data Objects
Standard Data Types
List of some VHDL data types:
Data Objects
User-Defined Types
 VHDL allows you to dene your own data type. A typical
example of custom integer type is:
 Obviously it is possible to dene more complex data structures.
Data Objects
Commonly Used Types
Data Objects
Type
 The type is defined in the VHDL package
and provides a common
standard that can be used in VHDL.
Finite State Machine (FSM) Design Using VHDL
 Finite state machines (FSMs) are mathematical abstractions
that are used to solve a large variety of problems, among
which are electronic design automation, communication
protocol design, parsing and other engineering applications.
Block diagram for a Moore-type FSM
Finite State Machine (FSM) Design Using VHDL
FSM Example
Finite State Machine (FSM) Design Using VHDL
FSM Example
FSM Design Using VHDL
FSM Example
FSM Design Using VHDL
FSM Example
FSM Design Using VHDL
FSM Example
FSM Design Using VHDL
FSM Example
FSM Design Using VHDL
Exercise - traffic light FSM
Black box view of the
finite state machine
Campus map
Design this traffic light FSM
FSM Design Using VHDL
Exercise - traffic light FSM
Structural Modeling In VHDL
 Structural modeling in VHDL
supports hierarchical design
concepts. The ability to abstract
digital circuits to higher levels is
the key to understanding and
designing complex digital
circuits.
 The VHDL structural model
supports the reuse of design
units. This includes units you
have previously designed as well
as the ability to use predefined
module libraries.
Hierarchy design flow example
of an MCU
MCIP
MCU
Basic
components
Configurable
components
Peripherals
Interrupt
Controller
Address
Decoder
CPU
PLL
Reset
Module
Program
Counter
Operation
Unit
Data Address
Provider
Instruction
Decoder
Table Read
and Write
Watchdog
Ports
Timers
MSSPs
ALU
Multiplier
Decoder
Instruction
Manager
Program
Memory
Data
Memory
Memory
Controllers
Structural Modeling In VHDL
VHDL Modularity with Components
The approach to use a component in VHDL is:
1) Name the module you plan to describe (the entity) and describe
what the module will do (the architecture),
2) Let the design tool know the module exists and can be used
(component declaration),
3) Declare required internal signals used to connect the design units.
Structural Modeling In VHDL
VHDL Modularity with Components
4) Use the module in your code (component instantiation, or mapping).
Structural Modeling In VHDL
VHDL Modularity with Components
AND
Can be replaced with:
Structural Modeling In VHDL
Construction of parametrised components (Generics)
 Generics allow the component to be customised.
 The values assigned to generics in the component instantiation will override any initial
values assigned to the generic in the entity statement or component declaration.
 Generics can be of any type.
Structural Modeling In VHDL
Generic Map
Structural Modeling In VHDL
Generate Statement
 The generate statement simplifies description of regular design structures.
 Usually it is used to specify a group of identical components using just one
component specification and repeating it using the generate mechanism.
 A generate statement consists of three main parts:
• generation scheme (either for scheme or if scheme);
• declarative part (local declarations of subprograms, types, signals,
constants, components, attributes, configurations, files and groups);
• concurrent statements.
Structural Modeling In VHDL
Generate Statement - Example
Structural Modeling In VHDL
Generate Statement – Exercise (generic adder)
Looping Constructs
 There are two types of loops in VHDL: loops and loops.
 Since these two types of loops are both sequential statements, they
can only appear inside processes.
 If you know the number of iterations the loop requires, you should use
a loop.
 The loop should be used when you do not know the number of
iterations the loop needs to perform.
Looping Constructs
Bibliography
Bryan Mealy, Fabrizio Tappero,
“Free Range VHDL” 2013.
http://freerangefactory.org/pdf/free_range_vhdl.pdf

More Related Content

What's hot

Verilog operators.pptx
Verilog  operators.pptxVerilog  operators.pptx
Verilog operators.pptxVandanaPagar1
 
Verilog Test Bench
Verilog Test BenchVerilog Test Bench
Verilog Test BenchDr.YNM
 
Verilog presentation final
Verilog presentation finalVerilog presentation final
Verilog presentation finalAnkur Gupta
 
System Verilog (Tutorial -- 4X1 Multiplexer)
System Verilog (Tutorial -- 4X1 Multiplexer)System Verilog (Tutorial -- 4X1 Multiplexer)
System Verilog (Tutorial -- 4X1 Multiplexer)Denise Wilson
 
OPERATING OVERLOADING IN VHDL
OPERATING OVERLOADING IN VHDLOPERATING OVERLOADING IN VHDL
OPERATING OVERLOADING IN VHDLBLESSYDAISE PAUL
 
Verilog HDL Training Course
Verilog HDL Training CourseVerilog HDL Training Course
Verilog HDL Training CoursePaul Laskowski
 
Concepts of Behavioral modelling in Verilog HDL
Concepts of Behavioral modelling in Verilog HDLConcepts of Behavioral modelling in Verilog HDL
Concepts of Behavioral modelling in Verilog HDLanand hd
 
VHDL-PRESENTATION.ppt
VHDL-PRESENTATION.pptVHDL-PRESENTATION.ppt
VHDL-PRESENTATION.pptDr.YNM
 
encoder and decoder in digital electronics
encoder and decoder in digital electronicsencoder and decoder in digital electronics
encoder and decoder in digital electronicsvikram rajpurohit
 
VERILOG HDL :: Blocking & NON- Blocking assignments
VERILOG HDL :: Blocking & NON- Blocking assignments VERILOG HDL :: Blocking & NON- Blocking assignments
VERILOG HDL :: Blocking & NON- Blocking assignments Dr.YNM
 
Complex Programmable Logic Device (CPLD) Architecture and Its Applications
Complex Programmable Logic Device (CPLD) Architecture and Its ApplicationsComplex Programmable Logic Device (CPLD) Architecture and Its Applications
Complex Programmable Logic Device (CPLD) Architecture and Its Applicationselprocus
 

What's hot (20)

Fpga
FpgaFpga
Fpga
 
VHDL Part 4
VHDL Part 4VHDL Part 4
VHDL Part 4
 
Verilog
VerilogVerilog
Verilog
 
Verilog operators.pptx
Verilog  operators.pptxVerilog  operators.pptx
Verilog operators.pptx
 
Verilog Test Bench
Verilog Test BenchVerilog Test Bench
Verilog Test Bench
 
Data Flow Modeling
Data Flow ModelingData Flow Modeling
Data Flow Modeling
 
Verilog presentation final
Verilog presentation finalVerilog presentation final
Verilog presentation final
 
Vhdl
VhdlVhdl
Vhdl
 
Verilog hdl
Verilog hdlVerilog hdl
Verilog hdl
 
System Verilog (Tutorial -- 4X1 Multiplexer)
System Verilog (Tutorial -- 4X1 Multiplexer)System Verilog (Tutorial -- 4X1 Multiplexer)
System Verilog (Tutorial -- 4X1 Multiplexer)
 
OPERATING OVERLOADING IN VHDL
OPERATING OVERLOADING IN VHDLOPERATING OVERLOADING IN VHDL
OPERATING OVERLOADING IN VHDL
 
Introduction to FPGAs
Introduction to FPGAsIntroduction to FPGAs
Introduction to FPGAs
 
Verilog HDL Training Course
Verilog HDL Training CourseVerilog HDL Training Course
Verilog HDL Training Course
 
Vhdl programming
Vhdl programmingVhdl programming
Vhdl programming
 
Concepts of Behavioral modelling in Verilog HDL
Concepts of Behavioral modelling in Verilog HDLConcepts of Behavioral modelling in Verilog HDL
Concepts of Behavioral modelling in Verilog HDL
 
VHDL-PRESENTATION.ppt
VHDL-PRESENTATION.pptVHDL-PRESENTATION.ppt
VHDL-PRESENTATION.ppt
 
Behavioral modelling in VHDL
Behavioral modelling in VHDLBehavioral modelling in VHDL
Behavioral modelling in VHDL
 
encoder and decoder in digital electronics
encoder and decoder in digital electronicsencoder and decoder in digital electronics
encoder and decoder in digital electronics
 
VERILOG HDL :: Blocking & NON- Blocking assignments
VERILOG HDL :: Blocking & NON- Blocking assignments VERILOG HDL :: Blocking & NON- Blocking assignments
VERILOG HDL :: Blocking & NON- Blocking assignments
 
Complex Programmable Logic Device (CPLD) Architecture and Its Applications
Complex Programmable Logic Device (CPLD) Architecture and Its ApplicationsComplex Programmable Logic Device (CPLD) Architecture and Its Applications
Complex Programmable Logic Device (CPLD) Architecture and Its Applications
 

Similar to VHDL course

the-vhsic-.pptx
the-vhsic-.pptxthe-vhsic-.pptx
the-vhsic-.pptxjpradha86
 
Prilimanary Concepts of VHDL by Dr.R.Prakash Rao
Prilimanary Concepts of VHDL by    Dr.R.Prakash RaoPrilimanary Concepts of VHDL by    Dr.R.Prakash Rao
Prilimanary Concepts of VHDL by Dr.R.Prakash Raorachurivlsi
 
UNIT-I.pptx of subject in engineering bla bla bla
UNIT-I.pptx of subject in engineering bla bla blaUNIT-I.pptx of subject in engineering bla bla bla
UNIT-I.pptx of subject in engineering bla bla blaSEN150VAIBHAVWAKHARE
 
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs)
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs) OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs)
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs) Dr.YNM
 
VHDL_Lecture_new1 [Autosaved].ppt
VHDL_Lecture_new1 [Autosaved].pptVHDL_Lecture_new1 [Autosaved].ppt
VHDL_Lecture_new1 [Autosaved].pptNAVEENM849290
 
Design And Simulation of Electronic Circuits Lec_02
Design And Simulation of Electronic Circuits Lec_02Design And Simulation of Electronic Circuits Lec_02
Design And Simulation of Electronic Circuits Lec_02Mohamed Atef
 
vlsi introduction to hdl and its typesunit-1.pptx
vlsi introduction to hdl and its typesunit-1.pptxvlsi introduction to hdl and its typesunit-1.pptx
vlsi introduction to hdl and its typesunit-1.pptxiconicyt2
 
Lecture2 vhdl refresher
Lecture2 vhdl refresherLecture2 vhdl refresher
Lecture2 vhdl refresherNima Shafiee
 
session two hardware description language
session  two hardware description languagesession  two hardware description language
session two hardware description languagedhananjeyanrece
 
Ece iv-fundamentals of hdl [10 ec45]-notes
Ece iv-fundamentals of hdl [10 ec45]-notesEce iv-fundamentals of hdl [10 ec45]-notes
Ece iv-fundamentals of hdl [10 ec45]-notessiddu kadiwal
 

Similar to VHDL course (20)

the-vhsic-.pptx
the-vhsic-.pptxthe-vhsic-.pptx
the-vhsic-.pptx
 
Dica ii chapter slides
Dica ii chapter slidesDica ii chapter slides
Dica ii chapter slides
 
Vhdl
VhdlVhdl
Vhdl
 
Prilimanary Concepts of VHDL by Dr.R.Prakash Rao
Prilimanary Concepts of VHDL by    Dr.R.Prakash RaoPrilimanary Concepts of VHDL by    Dr.R.Prakash Rao
Prilimanary Concepts of VHDL by Dr.R.Prakash Rao
 
Vhdl 1 ppg
Vhdl 1 ppgVhdl 1 ppg
Vhdl 1 ppg
 
UNIT-I.pptx of subject in engineering bla bla bla
UNIT-I.pptx of subject in engineering bla bla blaUNIT-I.pptx of subject in engineering bla bla bla
UNIT-I.pptx of subject in engineering bla bla bla
 
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs)
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs) OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs)
OVERVIEW OF HARDWARE DESCRIPTION LANGUAGES (HDLs)
 
DLD5.pdf
DLD5.pdfDLD5.pdf
DLD5.pdf
 
VHDL_Lecture_new1 [Autosaved].ppt
VHDL_Lecture_new1 [Autosaved].pptVHDL_Lecture_new1 [Autosaved].ppt
VHDL_Lecture_new1 [Autosaved].ppt
 
VHDL lecture 1.ppt
VHDL lecture 1.pptVHDL lecture 1.ppt
VHDL lecture 1.ppt
 
vhdl
vhdlvhdl
vhdl
 
Vlsi(2)
Vlsi(2)Vlsi(2)
Vlsi(2)
 
VHDL_VIKAS.pptx
VHDL_VIKAS.pptxVHDL_VIKAS.pptx
VHDL_VIKAS.pptx
 
Vhdl introduction
Vhdl introductionVhdl introduction
Vhdl introduction
 
Design And Simulation of Electronic Circuits Lec_02
Design And Simulation of Electronic Circuits Lec_02Design And Simulation of Electronic Circuits Lec_02
Design And Simulation of Electronic Circuits Lec_02
 
vlsi introduction to hdl and its typesunit-1.pptx
vlsi introduction to hdl and its typesunit-1.pptxvlsi introduction to hdl and its typesunit-1.pptx
vlsi introduction to hdl and its typesunit-1.pptx
 
Lecture2 vhdl refresher
Lecture2 vhdl refresherLecture2 vhdl refresher
Lecture2 vhdl refresher
 
session two hardware description language
session  two hardware description languagesession  two hardware description language
session two hardware description language
 
Wi Fi documantation
Wi Fi documantationWi Fi documantation
Wi Fi documantation
 
Ece iv-fundamentals of hdl [10 ec45]-notes
Ece iv-fundamentals of hdl [10 ec45]-notesEce iv-fundamentals of hdl [10 ec45]-notes
Ece iv-fundamentals of hdl [10 ec45]-notes
 

Recently uploaded

Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxupamatechverse
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Serviceranjana rawat
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learningmisbanausheenparvam
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingrakeshbaidya232001
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...srsj9000
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxpurnimasatapathy1234
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile servicerehmti665
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝soniya singh
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSRajkumarAkumalla
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVRajaP95
 

Recently uploaded (20)

Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptx
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learning
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptx
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile service
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCRCall Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
 

VHDL course

  • 2. Introduction Design abstraction levels timeline 1987 - VHDL IEEE standard
  • 3. Introduction What is VHDL? V: VHSIC or Very High-Speed Integrated Circuit. HDL: Hardware Description Language.  VHDL is a true computer language with the accompanying set of syntax and usage rules.  As opposed to higher-level computer languages, VHDL is primarily used to describe hardware. Hardware description languages Higher-level computer languages
  • 4. Introduction Pay attention!!  The common mistake made by someone is to attempt to program in VHDL as they would program a higher-level computer language. Higher-level computer languages are sequential in nature; VHDL is not.  VHDL is a concurrent language: VHDL instructions are all executed at the same time (concurrently).  Higher-level computer languages are used to describe algorithms (sequential execution) and VHDL is used to describe hardware (parallel execution).
  • 5. Introduction Golden Rules of VHDL  VHDL is a hardware-design language When you are working with VHDL, you are not programming, you are "designing hardware". Your VHDL code should reflect this fact. If your VHDL code appears too similar to code of a higher-level computer language, it is probably bad VHDL code.  Have a general concept of what your hardware should look like Although VHDL is vastly powerful, if you do not understand basic digital constructs, you will probably be unable to generate efficient digital circuits. If you are not able to roughly envision the digital circuit you are trying to model in terms of basic digital circuits, you will probably misuse VHDL.
  • 6. VHDL Invariants Case Sensitivity White Space VHDL is not sensitive to white space (spaces and tabs). Comments Comments in VHDL begin with the symbol "--" (two consecutive dashes). VHDL is not case sensitive.
  • 7. VHDL Invariants Parentheses VHDL Statements Similar to other algorithmic computer languages, every VHDL statement is terminated with a semicolon ";". VHDL is relatively lax on its requirement for using parentheses.
  • 8. VHDL Invariants Identifiers An identifier refers to the name given to various items in VHDL (variable names, signal names and port names …etc).  Identifiers can be as long as you want (contain many characters).  Identifiers can only contain a combination of letters (A-Z and a-z), digits (0-9) and the underscore character ("_").  Identifiers must start with an alphabetic character.
  • 9. VHDL Invariants Reserved Words There is a list of words that have been assigned special meaning by the VHDL language. These special words, usually referred to as reserved words, cannot be used as identifiers when writing VHDL code.
  • 10. VHDL Design Units VHDL description organisation
  • 11. VHDL Design Units VHDL Standard Libraries
  • 12. VHDL Design Units Entity declaration The VHDL entity provides a simple wrapper for the lower-level circuitry. This wrapper effectively describes how the black box interfaces with the outside world.  Each port name is unique and has an associated mode and data type.  The VHDL compiler allows several port names to be included on a single line. Port names are separated by commas.  These input and output signals are associated with the keywords in, out, inout or buffer. Black-box
  • 13. VHDL Design Units Entity declaration  As specified in the package, the implementation of the type (and the type) includes 9 different values: 0,1,U,X,Z,W,L,H,-. The signals in the bus can be listed in one of two orders which are specified by the to and downto keywords. MSB LSB MSB LSB
  • 14. VHDL Design Units Entity declaration – Exercise 1 Write VHDL entity declarations that describe the following black-box diagrams:
  • 15. VHDL Design Units Entity declaration – Exercise 2 Provide black-box diagrams that are defined by the following VHDL entity declarations: Are there any errors!?
  • 16. VHDL Design Units Architecture The architecture describes what the circuit actually does. In other words, the VHDL architecture describes the internal implementation of the associated entity. Several possible implementations (models) of the same behavior are possible in VHDL:  The data-flow model,  The behavioral model,  The structural model,  Any combination of these three, generally called the hybrid models. Data-flow model
  • 17. VHDL Design Units Signal and Variable Assignments In VHDL there are several object types:  The signal object type: is the representation of a wire.  The variable object type: used to store local information.  The constant object type: used to store constant values. To assign a new value to a signal you use the operator "<=". To assign a new value to a variable you use the operator ":=".
  • 18. VHDL Assignment Concurrent Statements The main design consideration in VHDL modeling supports the fact that digital circuits operate in parallel. Each concurrent statement is interpreted as acting in parallel (concurrently) to other concurrent statements.
  • 19. VHDL Assignment Assignment types in VHDL The major signal assignment types in VHDL are:  Concurrent signal assignment  Conditional signal assignment  Selected signal assignment  Process statements
  • 20. VHDL Assignment Concurrent signal assignment  The target is a signal that receives the values of the expression.
  • 21. VHDL Assignment Conditional signal assignment  The term conditional signal assignment is used to describe statements that have only one target but can have more than one associated expression assigned to the target.
  • 22. VHDL Assignment Conditional signal assignment - Example
  • 23. VHDL Assignment Selected signal assignment  Selected signal assignment statements differ from conditional assignment statements in that assignments are based upon the evaluation of one expression.
  • 24. VHDL Assignment Selected signal assignment – Example 1
  • 25. VHDL Assignment Selected signal assignment – Example 2
  • 26. VHDL Assignment Selected signal assignment – Example 3
  • 27. VHDL Assignment Process statements  The process statement itself is a concurrent statement identified by its label, its sensitivity list, a declaration area and a begin-end area containing instructions executed sequentially.  The execution of the sequential statements is initiated when a change in the signal contained in the process sensitivity list occurs.
  • 30. Sequential Statements There are 3 types of sequential statements:  Signal assignment statement  statement  statement
  • 31. Sequential Statements  Signal assignment statement  The target is a signal that receives the values of the expression.
  • 32. Sequential Statements  statement  The statement is used to create a branch in the execution flow of the sequential statements.  Each -type statement contains an associated keyword. The final clause does not have the keyword associated with it.
  • 36. Sequential Statements  statement – Example 4 Using statement for Sequential Circuits (D flip-flop)
  • 37. Sequential Statements  statement – Example 5 Using statement for Sequential Circuits (D flip-flop)
  • 38. Sequential Statements  statement – Exercise 1 Design a 4-bit parallel-in register.
  • 39. Sequential Statements  statement – Exercise 2 Design a Serial-in shift register.
  • 40. Sequential Statements  statement  The statement is somewhat similar to the statement in that a sequence of statements is executed an associated expression is true.  The statement differs from the statement in that the resulting choice is made depending upon the value of the single control expression.
  • 41. Sequential Statements  statement – Example 1 F_OUT = A · B · C + B · C
  • 42.  statement – Example 2 Sequential Statements
  • 43. VHDL Operators VHDL operators  Operators in VHDL are grouped into seven different types: logical, relational, shift, addition, unary, multiplying and others.
  • 44. VHDL Operators VHDL shift operators Shift Operator
  • 45. VHDL Operators  The concatenation operator is often a useful operator when dealing with digital circuits.  There are many times when you will find a need to tack together two separate values. Concatenation operator
  • 46. Data Objects Types of Data Objects  There are four types of data objects in VHDL: signals, variables, constants and files.  File data objects, exclusively used in simulations.
  • 47. Data Objects Types of Data Objects  Each of the data objects can optionally be assigned initial values.  Signal declarations do not usually include initial values as opposed to constants which generally do.  Initial values for signals are in fact not implementable on silicon by the synthesizing tools but are taken into consideration by VHDL simulation tools.
  • 48. Data Objects Signals vs. Variables  The use of signals and variables can be somewhat confusing because of their similarities.  A signal can be thought of as representing a wire or some type of physical connection in a design.  Assignments made to signals inside a process are actually only scheduled when the same process is completed. The actual assignment is not made until after the process terminates.  Variable assignment within processes is different. When a variable is assigned a value inside of a process, the assignment is immediate and the newly assigned value can be used immediately inside of the process.  Variables should only be used as iteration counters in loops or as temporary values when executing an algorithm that performs some type of calculation. It is possible to use variables outside of these areas, but it should be avoided.
  • 49. Data Objects Signals vs. Variables (example)
  • 50. Data Objects Standard Data Types List of some VHDL data types:
  • 51. Data Objects User-Defined Types  VHDL allows you to dene your own data type. A typical example of custom integer type is:  Obviously it is possible to dene more complex data structures.
  • 53. Data Objects Type  The type is defined in the VHDL package and provides a common standard that can be used in VHDL.
  • 54. Finite State Machine (FSM) Design Using VHDL  Finite state machines (FSMs) are mathematical abstractions that are used to solve a large variety of problems, among which are electronic design automation, communication protocol design, parsing and other engineering applications. Block diagram for a Moore-type FSM
  • 55. Finite State Machine (FSM) Design Using VHDL FSM Example
  • 56. Finite State Machine (FSM) Design Using VHDL FSM Example
  • 57. FSM Design Using VHDL FSM Example
  • 58. FSM Design Using VHDL FSM Example
  • 59.
  • 60. FSM Design Using VHDL FSM Example
  • 61. FSM Design Using VHDL FSM Example
  • 62.
  • 63. FSM Design Using VHDL Exercise - traffic light FSM Black box view of the finite state machine Campus map Design this traffic light FSM
  • 64. FSM Design Using VHDL Exercise - traffic light FSM
  • 65.
  • 66.
  • 67. Structural Modeling In VHDL  Structural modeling in VHDL supports hierarchical design concepts. The ability to abstract digital circuits to higher levels is the key to understanding and designing complex digital circuits.  The VHDL structural model supports the reuse of design units. This includes units you have previously designed as well as the ability to use predefined module libraries. Hierarchy design flow example of an MCU MCIP MCU Basic components Configurable components Peripherals Interrupt Controller Address Decoder CPU PLL Reset Module Program Counter Operation Unit Data Address Provider Instruction Decoder Table Read and Write Watchdog Ports Timers MSSPs ALU Multiplier Decoder Instruction Manager Program Memory Data Memory Memory Controllers
  • 68. Structural Modeling In VHDL VHDL Modularity with Components The approach to use a component in VHDL is: 1) Name the module you plan to describe (the entity) and describe what the module will do (the architecture), 2) Let the design tool know the module exists and can be used (component declaration),
  • 69. 3) Declare required internal signals used to connect the design units. Structural Modeling In VHDL VHDL Modularity with Components 4) Use the module in your code (component instantiation, or mapping).
  • 70. Structural Modeling In VHDL VHDL Modularity with Components AND Can be replaced with:
  • 71. Structural Modeling In VHDL Construction of parametrised components (Generics)  Generics allow the component to be customised.  The values assigned to generics in the component instantiation will override any initial values assigned to the generic in the entity statement or component declaration.  Generics can be of any type.
  • 72. Structural Modeling In VHDL Generic Map
  • 73. Structural Modeling In VHDL Generate Statement  The generate statement simplifies description of regular design structures.  Usually it is used to specify a group of identical components using just one component specification and repeating it using the generate mechanism.  A generate statement consists of three main parts: • generation scheme (either for scheme or if scheme); • declarative part (local declarations of subprograms, types, signals, constants, components, attributes, configurations, files and groups); • concurrent statements.
  • 74. Structural Modeling In VHDL Generate Statement - Example
  • 75. Structural Modeling In VHDL Generate Statement – Exercise (generic adder)
  • 76. Looping Constructs  There are two types of loops in VHDL: loops and loops.  Since these two types of loops are both sequential statements, they can only appear inside processes.  If you know the number of iterations the loop requires, you should use a loop.  The loop should be used when you do not know the number of iterations the loop needs to perform.
  • 78. Bibliography Bryan Mealy, Fabrizio Tappero, “Free Range VHDL” 2013. http://freerangefactory.org/pdf/free_range_vhdl.pdf