SlideShare a Scribd company logo
1 of 46
Download to read offline
VHDL Session 1
Authors : Gamal Saied & Hazem Fathy
10/22/20181
Table of contents
Introduction to Digital Design Flow
i. Digital Design
ii. Digital Verification
Introduction to VHDL
i. Basic rules of VHDL
ii. Design basics
iii. Data types
iv. Operators
v. Design rules
2 10/22/2018
10/22/20183
Introduction to Digital Design
HDLs perquisites
– Programming languages
– Digital logic circuits
Make your own hardware!!
Recall your logic courses
a
b
c
y
y a b c  
Introduction to Digital Design
FPGA & CPLD
ASICs
Application Specific
Integrated Circuits
Microprocessors
Microcontrollers
Industry Pioneers
– Mentor Graphics
– Xilinx
– Synopsys
– Qualcomm
– Altera (INTEL)
Introduction to Digital Design
5
10/22/20186
FPGAs
An integrated circuit that can be
programmed/reprogrammed with a digital logic of
a curtain level.
Started at late 70s and constantly growing
Now available of up to approximately 700K Flip-
Flops in a single chip.
Rare industrial usage
I/O
I/O
Logic
block
Interconnection switches
I/O
I/O
Advantages
– Reconfigurable
– Saves board space
– Flexible to changes
– No need for ASIC expensive design and production
– Fast time to market
– Bugs can be fixed easily
– Of the shelf solutions are available
FPGAs
10/22/20188
ASICs
ASIC stands for Application Specified Integrated
circuit
Widely used in industrial applications
More complex than FPGAs
10/22/20189
FPGAs vs ASIC
Digital Verification
Digital Manufacture Process
Verification
Design
10 10/22/2018
 Digital Design only presents 30% of
the Manufacturing process!!
 Verification Cycle is more complex
than design cycle.
Digital Verification
Verification methods:
– Formal Verification
– Lint Verification
– Clock Domain Checking (CDC)
– Test Benches
11 10/22/2018
Design Flow
12 10/22/2018
Design Flow
13 10/22/2018
Specification
HDL
(VHDL , Verilog ,C , Simulink)
Simulation
(Modelsim / Quartus)
Synthesis
Convert HDL to FPGA logic
(Quartus / Third party tools)
Place and Route
(Quartus)
Bit-File
(FPGA configuration)
Timing constrains
FPGA
(Debug using Signal TAP logic analyser)
Timing Simulation if needed
(Modelsim / Quartus)
Timing Analyzer
(Quartus)
Timing constrains
Pin-out
Introduction to VHDL
VHDL stands for VHSIC(Very high speed integrated circuit)
Hardware Description Language
Used in both Design and Verification processes.
Developed in the early 1980’s by the Pentagon base on ADA
Updated over the last 4 decades (93-95-2002-2008)
We will use IEEE 1076-2002 STD
14 10/22/2018
Remember HDLs are NOT for software
purposes
Introduction to VHDL
All names should start with an alphabet character (a-z or A-Z)
Use only alphabet characters (a-z or A-Z) digits (0-9) and
underscore (_)
Do not use any punctuation or reserved characters within a name
(!, ?, ., &, +, -, etc.)
Do not use two or more consecutive underscore characters (__)
within a name (e.g., Sel__A is invalid)
All names and labels in a given entity and architecture must be
unique
All names should not be from the reserved words list(IN,OUT,..)
15 10/22/2018
Introduction to VHDL
VHDL is not case sensitive (except for rare instances) i.e:
– Signal2
– SIGnal2
– SIGNAL2
– signaL2
– All of the above naming are valid and index the same identifier
16 10/22/2018
Introduction to VHDL
Comments are indicated with double dash chars (--) i.e:
1. Entity data ;
2. --Entity data2 ;  Ignored by the compiler
3. End entity ;
No block comments are allowed in VHDL
Double dashing any part of a line is allowed
17 10/22/2018
REFRESH
Design an OR gate using 2 NAND gates
18 10/22/2018
REFRESH
Design an OR gate using 2 NAND gates
19 10/22/2018
Design basics
A design has 3 main parts :
– Package and Library declaration
– Entity declaration
– Architecture
20 10/22/2018
Design basics
Libraries are collections of reusable pieces of codes
Most common used library is IEEE
Most used packages are
– Std_logic_1164
– Std_logic_arithmetic
– Std_logic_unsigned
– Std_logic_signed
– Numeric_std
– Numeric_bit
– User defined packages
21 10/22/2018
Design basics
Package declaration syntax (section 2.5)
Packages are useful design wise for reusable functions/pieces of
code
.all prefix allows usage of all package elements
22 10/22/2018
Design basics
Entity declaration syntax
23 10/22/2018
Design basics
24 10/22/2018
Entity is the wrapper of the design module
It describes the interface of the design (input/output ports ,
components,..)
An entity may contain numerous libraries/packages/architectures
Entities may be used in other instances (explained later)
Design basics
Port modes variation define the direction of data carried by
an identified port
– IN PORTS : an input to the entity that is ONLY used for assignments
– OUT PORTS : an output of the entity that is assigned to
– INOUT/BUFFER PORTS : combination of both modes ( Not practical)
25 10/22/2018
Design basics
Architecture Body
26 10/22/2018
Design basics
Declarative part of Architecture may contain local signal and
variable declarations
An entity may contain multiple architectures
Architectures statements must
be in begin-end scope
27 10/22/2018
Design basics
SCOPE RULES*
– Global scope
 INCLUDED PACKAGE/LIBRARY
 ENTITY PORTS
– Local scope
 ARCHITECTURES DECLARATIVE PART
 BEGIN-END STATEMENTS
 CONCURRENT AND SEQUENTIAL STATEMENTS
*Refer to section 10.2
28 10/22/2018
Design basics
Signals are wires that interconnect ports and other signals or ports
Signal carry the same types as ports*
Signals are better declared locally
<= assignment operator is used to assign (to) signals.
*Signals do not have direction
29 10/22/2018
Data types
VHDL has numerous data types :
– BIT: holds value of (0,1) only
– Predefined types ( integers , strings,
characters,..)
– Std_logic and std_ulogic
STD_LOGIC is the most used type
It may hold 9 values (useful for
simulation)
30 10/22/2018
Data types
31 10/22/2018
Only 1,0,Z values are synthesizable
Is included in std_logic_1164
package
May be declared as a vector with
specified range :
– Signal A:std_logic_vector(3 downto 0 )
Data types
32 10/22/2018
Std_logic is a resolved data
type
X state indicates multi driven
bit
VHDL is HARD-WRITTEN
language
Operators
33 10/22/2018
Operators
Operators are used in description of functional assignments
Each group of operators belong to a specific types of operands
(why)?
34 10/22/2018
Operators
Concatenation operator --&--
Single quotes are for bit
selects
Double quotes are for bit
vector select
35 10/22/2018
Operators
SLL and SRL operators are
used to shift vectors.
These operators DOES NOT
operate on
STD_LOGIC_VECTORS
VHDL 2008 Supports this
feature
36 10/22/2018
Operators
ROL and ROR operators
behave the same as shift
operators
You may use concatenation
instead of operators
Value of rotation/shifting
must be integer
37 10/22/2018
EX1
Describe the following circuit using VHDL.
38 10/22/2018
EX1
39 10/22/2018
EX2
Describe the following circuit using VHDL
40 10/22/2018
EX2
41 10/22/2018
Design rules
Use tabs for every scope generated
Choose a specific naming method i.e ( inputs : i1,i2 , outputs :
o1,o2..)
Comment expression with useful statements (make your code
readable)
Constants are UPPER CASE named i.e( constant CYCLE_D : integer
:= 2 );
File name should be the same as entity name
42 10/22/2018
Assignment1
Describe the following circuit using VHDL
43 10/22/2018
Assignment1 solution
44 10/22/2018
HOMEWORK
Write the truth table of the following circuit and write its equivalent
VHDL code
45 10/22/2018
HOMEWORK
Deliverables:
– Compiled .vhd file containing the function code
– READABLE code written w.r.t design rules
Please send your .vhd files to gamal.saiedeece@gmail.com
Good Luck 
46 10/22/2018

More Related Content

What's hot (20)

VHDL
VHDLVHDL
VHDL
 
Introduction to VHDL - Part 1
Introduction to VHDL - Part 1Introduction to VHDL - Part 1
Introduction to VHDL - Part 1
 
Hdl
HdlHdl
Hdl
 
VHDL course
VHDL courseVHDL course
VHDL course
 
HDL (hardware description language) presentation
HDL (hardware description language) presentationHDL (hardware description language) presentation
HDL (hardware description language) presentation
 
Verilog
VerilogVerilog
Verilog
 
Spdas2 vlsibput
Spdas2 vlsibputSpdas2 vlsibput
Spdas2 vlsibput
 
Vhdl 1 ppg
Vhdl 1 ppgVhdl 1 ppg
Vhdl 1 ppg
 
Chapter 5 introduction to VHDL
Chapter 5 introduction to VHDLChapter 5 introduction to VHDL
Chapter 5 introduction to VHDL
 
Vhdl
VhdlVhdl
Vhdl
 
vhdl
vhdlvhdl
vhdl
 
Vhdl introduction
Vhdl introductionVhdl introduction
Vhdl introduction
 
Introduction to VHDL
Introduction to VHDLIntroduction to VHDL
Introduction to VHDL
 
Summer training vhdl
Summer training vhdlSummer training vhdl
Summer training vhdl
 
Verilog HDL Training Course
Verilog HDL Training CourseVerilog HDL Training Course
Verilog HDL Training Course
 
Vhdl design flow
Vhdl design flowVhdl design flow
Vhdl design flow
 
Vhdl 1
Vhdl 1Vhdl 1
Vhdl 1
 
Summer training vhdl
Summer training vhdlSummer training vhdl
Summer training vhdl
 
Vhdl
VhdlVhdl
Vhdl
 
Vhdl
VhdlVhdl
Vhdl
 

Similar to Session1pdf

Project report of 2016 Trainee_final
Project report of 2016 Trainee_finalProject report of 2016 Trainee_final
Project report of 2016 Trainee_finalAkash Chowdhury
 
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
 
L6_Slides_vhdl coures temporary hair dye for dark hair
L6_Slides_vhdl coures temporary hair dye for dark hairL6_Slides_vhdl coures temporary hair dye for dark hair
L6_Slides_vhdl coures temporary hair dye for dark hairloyad20119
 
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
 
IRJET- Home Automation System for Specially Challenged and Senior Citizens
IRJET- Home Automation System for Specially Challenged and Senior CitizensIRJET- Home Automation System for Specially Challenged and Senior Citizens
IRJET- Home Automation System for Specially Challenged and Senior CitizensIRJET Journal
 
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded Systems
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I   Core of Embedded SystemsSYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I   Core of Embedded Systems
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded SystemsArti Parab Academics
 
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptxtectectechnical
 
IRJET- ARGON2id IP Core
IRJET- ARGON2id IP CoreIRJET- ARGON2id IP Core
IRJET- ARGON2id IP CoreIRJET Journal
 
IRJET- FPGA based Controller Design for Mobile Robots
IRJET- FPGA based Controller Design for Mobile RobotsIRJET- FPGA based Controller Design for Mobile Robots
IRJET- FPGA based Controller Design for Mobile RobotsIRJET Journal
 
DebojyotiLahiri_DetailedResume
DebojyotiLahiri_DetailedResumeDebojyotiLahiri_DetailedResume
DebojyotiLahiri_DetailedResumeDebojyoti Lahiri
 

Similar to Session1pdf (20)

Project report of 2016 Trainee_final
Project report of 2016 Trainee_finalProject report of 2016 Trainee_final
Project report of 2016 Trainee_final
 
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
 
Embedded system
Embedded systemEmbedded system
Embedded system
 
Verilog
VerilogVerilog
Verilog
 
Project
ProjectProject
Project
 
Report on VLSI
Report on VLSIReport on VLSI
Report on VLSI
 
VLSI
VLSIVLSI
VLSI
 
L6_Slides_vhdl coures temporary hair dye for dark hair
L6_Slides_vhdl coures temporary hair dye for dark hairL6_Slides_vhdl coures temporary hair dye for dark hair
L6_Slides_vhdl coures temporary hair dye for dark hair
 
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
 
IRJET- Home Automation System for Specially Challenged and Senior Citizens
IRJET- Home Automation System for Specially Challenged and Senior CitizensIRJET- Home Automation System for Specially Challenged and Senior Citizens
IRJET- Home Automation System for Specially Challenged and Senior Citizens
 
Dica ii chapter slides
Dica ii chapter slidesDica ii chapter slides
Dica ii chapter slides
 
VLSI
VLSIVLSI
VLSI
 
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded Systems
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I   Core of Embedded SystemsSYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I   Core of Embedded Systems
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded Systems
 
Wi Fi documantation
Wi Fi documantationWi Fi documantation
Wi Fi documantation
 
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx
9233a9b7-e6e2-45ee-bfff-6e8cdd3c97c2.pptx
 
VHDL_VIKAS.pptx
VHDL_VIKAS.pptxVHDL_VIKAS.pptx
VHDL_VIKAS.pptx
 
IRJET- ARGON2id IP Core
IRJET- ARGON2id IP CoreIRJET- ARGON2id IP Core
IRJET- ARGON2id IP Core
 
Ankit sarin
Ankit sarinAnkit sarin
Ankit sarin
 
IRJET- FPGA based Controller Design for Mobile Robots
IRJET- FPGA based Controller Design for Mobile RobotsIRJET- FPGA based Controller Design for Mobile Robots
IRJET- FPGA based Controller Design for Mobile Robots
 
DebojyotiLahiri_DetailedResume
DebojyotiLahiri_DetailedResumeDebojyotiLahiri_DetailedResume
DebojyotiLahiri_DetailedResume
 

Recently uploaded

MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
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 IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
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
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...ranjana rawat
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingrknatarajan
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxhumanexperienceaaa
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Dr.Costas Sachpazis
 
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...ranjana rawat
 
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...RajaP95
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130Suhani Kapoor
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
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
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 

Recently uploaded (20)

MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
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 IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
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...
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
 
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...
(TARA) Talegaon Dabhade Call Girls Just Call 7001035870 [ Cash on Delivery ] ...
 
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
 
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
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
★ 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
 
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
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 

Session1pdf

  • 1. VHDL Session 1 Authors : Gamal Saied & Hazem Fathy 10/22/20181
  • 2. Table of contents Introduction to Digital Design Flow i. Digital Design ii. Digital Verification Introduction to VHDL i. Basic rules of VHDL ii. Design basics iii. Data types iv. Operators v. Design rules 2 10/22/2018
  • 3. 10/22/20183 Introduction to Digital Design HDLs perquisites – Programming languages – Digital logic circuits Make your own hardware!! Recall your logic courses a b c y y a b c  
  • 4. Introduction to Digital Design FPGA & CPLD ASICs Application Specific Integrated Circuits Microprocessors Microcontrollers
  • 5. Industry Pioneers – Mentor Graphics – Xilinx – Synopsys – Qualcomm – Altera (INTEL) Introduction to Digital Design 5
  • 6. 10/22/20186 FPGAs An integrated circuit that can be programmed/reprogrammed with a digital logic of a curtain level. Started at late 70s and constantly growing Now available of up to approximately 700K Flip- Flops in a single chip. Rare industrial usage I/O I/O Logic block Interconnection switches I/O I/O
  • 7. Advantages – Reconfigurable – Saves board space – Flexible to changes – No need for ASIC expensive design and production – Fast time to market – Bugs can be fixed easily – Of the shelf solutions are available FPGAs
  • 8. 10/22/20188 ASICs ASIC stands for Application Specified Integrated circuit Widely used in industrial applications More complex than FPGAs
  • 10. Digital Verification Digital Manufacture Process Verification Design 10 10/22/2018  Digital Design only presents 30% of the Manufacturing process!!  Verification Cycle is more complex than design cycle.
  • 11. Digital Verification Verification methods: – Formal Verification – Lint Verification – Clock Domain Checking (CDC) – Test Benches 11 10/22/2018
  • 13. Design Flow 13 10/22/2018 Specification HDL (VHDL , Verilog ,C , Simulink) Simulation (Modelsim / Quartus) Synthesis Convert HDL to FPGA logic (Quartus / Third party tools) Place and Route (Quartus) Bit-File (FPGA configuration) Timing constrains FPGA (Debug using Signal TAP logic analyser) Timing Simulation if needed (Modelsim / Quartus) Timing Analyzer (Quartus) Timing constrains Pin-out
  • 14. Introduction to VHDL VHDL stands for VHSIC(Very high speed integrated circuit) Hardware Description Language Used in both Design and Verification processes. Developed in the early 1980’s by the Pentagon base on ADA Updated over the last 4 decades (93-95-2002-2008) We will use IEEE 1076-2002 STD 14 10/22/2018 Remember HDLs are NOT for software purposes
  • 15. Introduction to VHDL All names should start with an alphabet character (a-z or A-Z) Use only alphabet characters (a-z or A-Z) digits (0-9) and underscore (_) Do not use any punctuation or reserved characters within a name (!, ?, ., &, +, -, etc.) Do not use two or more consecutive underscore characters (__) within a name (e.g., Sel__A is invalid) All names and labels in a given entity and architecture must be unique All names should not be from the reserved words list(IN,OUT,..) 15 10/22/2018
  • 16. Introduction to VHDL VHDL is not case sensitive (except for rare instances) i.e: – Signal2 – SIGnal2 – SIGNAL2 – signaL2 – All of the above naming are valid and index the same identifier 16 10/22/2018
  • 17. Introduction to VHDL Comments are indicated with double dash chars (--) i.e: 1. Entity data ; 2. --Entity data2 ;  Ignored by the compiler 3. End entity ; No block comments are allowed in VHDL Double dashing any part of a line is allowed 17 10/22/2018
  • 18. REFRESH Design an OR gate using 2 NAND gates 18 10/22/2018
  • 19. REFRESH Design an OR gate using 2 NAND gates 19 10/22/2018
  • 20. Design basics A design has 3 main parts : – Package and Library declaration – Entity declaration – Architecture 20 10/22/2018
  • 21. Design basics Libraries are collections of reusable pieces of codes Most common used library is IEEE Most used packages are – Std_logic_1164 – Std_logic_arithmetic – Std_logic_unsigned – Std_logic_signed – Numeric_std – Numeric_bit – User defined packages 21 10/22/2018
  • 22. Design basics Package declaration syntax (section 2.5) Packages are useful design wise for reusable functions/pieces of code .all prefix allows usage of all package elements 22 10/22/2018
  • 23. Design basics Entity declaration syntax 23 10/22/2018
  • 24. Design basics 24 10/22/2018 Entity is the wrapper of the design module It describes the interface of the design (input/output ports , components,..) An entity may contain numerous libraries/packages/architectures Entities may be used in other instances (explained later)
  • 25. Design basics Port modes variation define the direction of data carried by an identified port – IN PORTS : an input to the entity that is ONLY used for assignments – OUT PORTS : an output of the entity that is assigned to – INOUT/BUFFER PORTS : combination of both modes ( Not practical) 25 10/22/2018
  • 27. Design basics Declarative part of Architecture may contain local signal and variable declarations An entity may contain multiple architectures Architectures statements must be in begin-end scope 27 10/22/2018
  • 28. Design basics SCOPE RULES* – Global scope  INCLUDED PACKAGE/LIBRARY  ENTITY PORTS – Local scope  ARCHITECTURES DECLARATIVE PART  BEGIN-END STATEMENTS  CONCURRENT AND SEQUENTIAL STATEMENTS *Refer to section 10.2 28 10/22/2018
  • 29. Design basics Signals are wires that interconnect ports and other signals or ports Signal carry the same types as ports* Signals are better declared locally <= assignment operator is used to assign (to) signals. *Signals do not have direction 29 10/22/2018
  • 30. Data types VHDL has numerous data types : – BIT: holds value of (0,1) only – Predefined types ( integers , strings, characters,..) – Std_logic and std_ulogic STD_LOGIC is the most used type It may hold 9 values (useful for simulation) 30 10/22/2018
  • 31. Data types 31 10/22/2018 Only 1,0,Z values are synthesizable Is included in std_logic_1164 package May be declared as a vector with specified range : – Signal A:std_logic_vector(3 downto 0 )
  • 32. Data types 32 10/22/2018 Std_logic is a resolved data type X state indicates multi driven bit VHDL is HARD-WRITTEN language
  • 34. Operators Operators are used in description of functional assignments Each group of operators belong to a specific types of operands (why)? 34 10/22/2018
  • 35. Operators Concatenation operator --&-- Single quotes are for bit selects Double quotes are for bit vector select 35 10/22/2018
  • 36. Operators SLL and SRL operators are used to shift vectors. These operators DOES NOT operate on STD_LOGIC_VECTORS VHDL 2008 Supports this feature 36 10/22/2018
  • 37. Operators ROL and ROR operators behave the same as shift operators You may use concatenation instead of operators Value of rotation/shifting must be integer 37 10/22/2018
  • 38. EX1 Describe the following circuit using VHDL. 38 10/22/2018
  • 40. EX2 Describe the following circuit using VHDL 40 10/22/2018
  • 42. Design rules Use tabs for every scope generated Choose a specific naming method i.e ( inputs : i1,i2 , outputs : o1,o2..) Comment expression with useful statements (make your code readable) Constants are UPPER CASE named i.e( constant CYCLE_D : integer := 2 ); File name should be the same as entity name 42 10/22/2018
  • 43. Assignment1 Describe the following circuit using VHDL 43 10/22/2018
  • 45. HOMEWORK Write the truth table of the following circuit and write its equivalent VHDL code 45 10/22/2018
  • 46. HOMEWORK Deliverables: – Compiled .vhd file containing the function code – READABLE code written w.r.t design rules Please send your .vhd files to gamal.saiedeece@gmail.com Good Luck  46 10/22/2018