Documente Academic
Documente Profesional
Documente Cultură
Victor Andrei
Implementation
IMPLEMENTATION
Bitstream Generation
Translate
Simulation
Complexity of HDL design Map TIMING SIMULATION
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 3
Synthesis (1/2)
Three-step process:
syntax check & element association
optimisation
technology mapping
Output files:
design netlist Implementation
Xilinx format: Native Generic
Circuit (NGC)
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 4
Synthesis (2/2)
VHDL design
entity gates is
port( A,B: in std_logic;
Q,R: out std_logic);
end gates;
architecture implement of gates is
begin
FPGA Design Implementation
Q <= A and B;
R <= A or B;
end implement;
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 5
Implementation (1/4)
IMPLEMENTATION
Translate
Constraints Translate
Map .ucf .ngd
Place & Route (PAR) Map
.ncd
Translate Place & Route
combines all netlists and constraints into one large netlist .ncd
Xilinx format: Native Generic Database (NGD)
user-defined constraints:
pin assignment & time requirements (e.g. input clock period, maximum delay, etc.)
information provided via a User Constraints File (UCF)
NET "A" LOC = B3 | IOSTANDARD = LVCMOS33 | PULLDOWN;
NET "Q" LOC = L6 | IOSTANDARD = LVCMOS18;
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 6
Implementation (2/4)
Map
compares the resources specified in the input netlist (.ngd) against the
available resources of the target FPGA
insufficient or incorrectly specified resources .ngc
FPGA Design Implementation
generate errors
IMPLEMENTATION
divides netlist circuit into sub-blocks Constraints Translate
to fit into the FPGA logic blocks
.ucf .ngd
output: Map
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 7
Implementation (3/4)
VHDL design
Input pins & logic (A,B)
entity gates is
port( A,B: in std_logic;
Q,R: out std_logic);
end gates;
architecture implement of
FPGA Design Implementation
gates is
begin
Q <= A and B;
R <= A or B;
end implement; Floorplan view
(after PAR)
(Spartan-6)
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 8
Implementation (4/4)
B
Input pins & logic (A,B)
FPGA Design Implementation
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 9
Generate Programming File
Converts the final NCD file into a format the FPGA understands
bitstream (.bit) is the usual choice
can be directly loaded into FPGA (e.g. via JTAG interface)
or stored in non-volatile devices (PROMs, Flash) downloaded to FPGA
FPGA Design Implementation
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 10
Simulation (1/3)
Approach:
apply stimulus that mimics
real input data to the Unit (Design)
design Under Testing
Can be performed at
different stages: adapted from “FPGAs 101” (G.R.Smith)
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 11
Simulation (2/3)
Testbench
ARCHITECTURE behaviour OF tb_gates IS
-- Component Declaration for the Unit Under Test (UUT)
VHDL design (UUT)
COMPONENT gates
PORT( A, B : IN std_logic;
entity gates is
port( A,B: in std_logic;
Q, R : OUT std_logic; ); Q,R: out std_logic);
FPGA Design Implementation
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 12
Simulation (3/3)
Testbench
ARCHITECTURE behaviour OF tb_gates IS
-- Component Declaration for the Unit Under Test (UUT)
VHDL design (UUT)
COMPONENT gates
PORT( A, B : IN std_logic;
entity gates is
port( A,B: in std_logic;
Q, R : OUT std_logic; ); Q,R: out std_logic);
FPGA Design Implementation
Helmholtz Alliance, 6th Detector Workshop, Mainz, 26/02/2013 Victor Andrei, KIP 13