Resources‎ > ‎

FPGA

Hardware

For the lab component of this class, we will be using the ZYBO Zynq-7000 Development Board [Digilent | Xilinx].

ZYBO board


Each team will be able to check out a kit containing the board, a USB programming cable, an external power supply (in normal use the board can be powered over USB), and a microSD card.

References


Pmod peripheral modules

We have a number of small Pmod daughterboards that may be useful for testing/debugging or adding functionality to the ZYBO development board.
  • Plug the Pmod into one of the ports along the bottom/right side of the ZYBO board (JA - JE)
  • Uncomment the relevant ports in your project constraint file
  • Include the relevant port as an input (switch) or output (LEDs) in your top-level module and drive as appropriate from your Verilog code
Since we have a limited number of Pmods, they will be treated as course reserves to be checked out on a short-term (~1 hour) basis from the library. Please keep the Pmods in their protective static bags when not in use.

Software

To program the FPGA, we will be using Xilinx Vivado (successor to ISE). The WebPACK edition is free to use and is all we need for this class. When installing, you only need support for the Zybo board (ZYNQ FPGA) and can omit the other FPGA types to save space.

Virtual Machine

We've provided a virtual machine that has Vivado and some other software tools pre-installed. Make sure you have adequate space, the VM will be about 32GB (!) once installed. To get started:
  1. Install VirtualBox for your host OS. Once it's installed, add the latest Extension Pack. Both of these are cached at Sandbox\CompArch FA17 installers
    1. If you're using a Linux host, you may need to add yourself to the vboxusers group in order to be able to connect USB devices to your VM:
      sudo usermod -a -G vboxusers <username>
  2. Obtain CompArchFA17.ova (~13GB) from Sandbox or on a flash drive from Ben. If you're really tight on disk space you can try to install over the network, but I recommend downloading it to your computer first (you can delete the .ova after creating your VM).
  3. In VirtualBox, goto File > Import Appliance.... Point the dialog at CompArchFA17.ova and follow the instructions.
  4. Boot up the OS and log in. Default credentials are comparch/comparch (feel free to change).
  5. To launch Vivado, open a terminal and run:
    source /opt/Xilinx/Vivado/2017.2/settings64.sh
    vivado &

Local Install

If you'd prefer to install the software locally (no VM), you can obtain Icarus Verilog, GTKWave, and Verilator through apt-get. To install Vivado, download the web-based installer (registration required) for Linux or Windows. It's still quite large, but you can save a little space and get the install down to ~13GB if you follow the minimal configuration shown below (you might want the Software Development Kit later, but it's easy to install additional components/harder to uninstall them).

Vivado recommended minimum install

Make sure to install the cable drivers as well (instructions in the Vivado Release Notes/Installation Guide). Optionally, you can install the Digilent Board Files for Vivado so that ZYBO is an option when creating new projects.


Getting started

After the Vivado software is installed, run through the tutorial below to build your first project and test out the toolflow.

Vivado Bringup


Example code from the presentation:

// Vivado bring-up example

module dff4(

   input trigger,

   input [3:0] d,

   output [3:0] q

   );

   reg[3:0] q;

   always @(posedge trigger) begin

       q <= d;

   end

endmodule


module hw_wrapper(

   input[3:0] sw,

   input clk,

   output[3:0] led

   );

   

   dff4 device(clk, sw, led);

   

endmodule




Comments