Introduction To Xilinx Vivado
Introduction To Xilinx Vivado
Project Settings
Summary of project
Runs Behavioral
and results
Simulation
Implementation
run and settings
Messages tab shows useful information
(warnings, errors) about your design.
Vivado Interface
• From Settings under PROJECT MANAGER tab, you can change the settings of your
project (e.g., Board or FPGA).
Vivado Interface
• From Settings under PROJECT MANAGER tab, you can change the settings of
your project (e.g., Board or FPGA).
• For example, you can change the font type and size of the text editor.
Vivado Interface
• Language Templates under PROJECT MANAGER tab shows useful Verilog and
Xilinx IP constructions.
Vivado Interface
• See Vivado IDE Viewing Enviroment chapter of Vivado Design Suite User Guide[1].
[1] https://docs.xilinx.com/r/2021.1-English/ug893-vivado-ide/Vivado-IDE-Viewing-Environment
Adding/Creating Design and Simulation Files
Create a Design
Source
• For your design, you should add a design source (*.v file). Click on Add Sources in Flow
Navigator Window or "+" button on Sources window or File -> Add Sources on menu
bar, select Add or create design resources and then click on Next.
Create a Design
Source
• Click on Create File button, name your source file (e.g., design1.v) and click on Next.
• If you want to add an existing file to your project, click on Add Files and select the
files that you want to add to the project.
Create a Design
Source
• Set your module name (it is set as source file name per default) and click on OK. Then,
you will see your source file under Design Sources tab on Sources window.
Create a Design
Source
• Open design1.v and write the following (or any other) Verilog code as an example and
save it.
`timescale 1ns / 1ps
module design1(
input clk,
input [7:0] a,b,
input [15:0] c,
output[16:0] d
);
reg [15:0] m;
reg [16:0] d;
endmodule
Create a Simulation
Source
• In order to test your design, you should add a simulation source. Click on Add Sources in
Flow Navigator Window, select Add or create simulation resources and then click on
Next.
• Click on Create File button, name your simulation file (e.g., design1_tb.v) and click on
Next.
• Set your module name (it is set as simulation file name per default) and click on OK.
Then, you will see your simulation file under Simulation Sources tab on Sources window.
Create a Simulation
Source
• Open design1_tb.v and write the following example Verilog testbench code and save it.
module design1_tb();
initial begin
a=0; b=0; c=0;
#10;
a=10; b=40; c=25;
#10;
a=53; b=19; c=100;
end
endmodule
Design Elaboration
• Design Elaboration and RTL Analysis
• It compiles RTL code and loads RTL netlist
• You can check RTL structure, syntax, and logic definitions
• You can view the schematic of your design
Running Behavioral Simulation
Behavioral Simulation
• Before running simulation, first make sure that your simulation source (testbench) is
selected as top simulation module (its module name should be in boldcase letters)
under Simulation Sources tab on Sources window.
• If it is not, right click on its name and click on Set as Top.
• Then, click on Run Simulation in Flow Navigator Window and click Run
Behavioral Simulation.
Behavioral Simulation
• If there is no error in your design and testbench files, you will see the following
simulation screen.
Go to time=0
Restart the simulation. Use this to restart the simulation with current state of the
design. Run All. Use this to run simulation until it reaches a stop/finish command in
testbench .
Run for specified time. Use this to run simulation for specified time.
Time and unit. Use this to specify run time and unit for the command above.
Relaunch the simulation. Use this to relaunch the simulation for elaborating
the changes you made in your design.
Behavioral Simulation
• In the Scope window, you can see the design hierarchy. When you select a scope in
the Scope window, all HDL objects visible from that scope appear in the Objects window.
Behavioral Simulation
• When you start simulation, you will see signals defined in testbench on the waveform.
In order to observe internal signals (for debugging), click on the module you want to
investigate on Scope window. Then right click on the signal you want to observe in the
Objects window and click on Add to wave window.
Synthesis/Implementation
Constraint File
• Constraint file
• Timing: For setting clock frequency of your design
• Placement: For floorplanning
• I/O: Assigning your design inputs/outputs to FPGA pins
• Other user-defined constraints (i.e., false paths)
• For adding the constraint file, click on Add Sources in Flow Navigator Window, select Add
or create constraints and then click on Next.
• Click on Create File button, name your simulation file (e.g., const.xdc) and click on Next.
• Then, you will see your source file under Design Sources tab on Sources window.
Constraint File
• We will only use timing constraint for clock frequency/period [1]
[1] https://docs.xilinx.com/r/2021.2-English/ug835-vivado-tcl-commands/create_clock
Synthesis
• Synthesis translates RTL code to a netlist which defines the circuit[1]
• You can change synthesis strategy (i.e., area optimized or performance
optimized) from synthesis settings (right click on SYNTHESIS -> Synthesis Settings)
• For starting synthesis, click on Run Synthesis.
[1] https://docs.xilinx.com/v/u/2021.1-English/ug901-vivado-synthesis
Synthesis
• After synthesis is finished, you can directly start implementation, open the
synthesized
design
• Youorcan
viewsee
synthesis reports.
synthesis report summary in Project
Summary.
Synthesis
• After synthesis is finished, you can directly start implementation, open the
synthesized
design
• Youorcan
viewsee
synthesis reports.
synthesis report summary in Project
Summary.
• For detailed report/results, open the synthesized design.
Implementation
• Implementation takes the netlist with user constraint and maps it to actual
FPGA components[1].
• Similar to Synthesis, you can change implementation strategy
• For starting implementation, click on Run Implementation.
[1] https://docs.xilinx.com/r/2021.1-English/ug904-vivado-implementation/Revision-History
Implementation
• For detailed report/results and the placed & routed design, open the implemented design.
Placed design
For detailed
timing report
For detailed
utilization report
Timing summary
Implementation
• For detailed report/results and the placed & routed design, open the implemented design.
• Placed design
Implementation
• For detailed report/results and the placed & routed design, open the implemented
• Detailed timing result (showing critical paths in your design).
design.
• Worst Negative Slack (WNS): If it is negative, then it means your design could not
meet the timing requirement (given in your constraint file) and your design has failing
paths.
• Click on WNS value to see critical paths.
Implementation
• For detailed report/results and the placed & routed design, open the implemented
design.
• Detailed timing result (showing critical paths in your design).
Implementation
• For detailed report/results and the placed & routed design, open the implemented
design.
• Detailed area (utilization) result.
information such as the main messages, warnings, errors.