Skip to content

Latest commit

 

History

History
177 lines (119 loc) · 9.12 KB

install-instructions.md

File metadata and controls

177 lines (119 loc) · 9.12 KB

Tools Installation Instructions

This document describes how to install the EDA software tools that are needed to complete the projects described in this tutorial.

Prerequisites

  • A computer running 64-bit Ubuntu 18.04 LTS physically or in virtualization (via VirtualBox, Parallels, etc). Microsoft Windows should also work, but instructions are targeted at Linux. MacOS cannot be used natively because Xilinx does not provide tooling for the Mac; macOS users are recommended to run Ubuntu in Parallels Desktop Lite, free.

All of the design entry and simulation tools will run on Windows, Linux, and Mac OS. Ubuntu or Windows is required when working with the Papilio/Xilinx hardware.

What to Install?

If you have a Papilio development board, install everything described in this document:

If you do not have a Papilio board (or are interested only in simulating designs), then install:

Icarus Verilog

What's it do? Simulates hardware designs written in the Verilog language. Who needs it? Individuals interested in designing and simulating digital circuits in Verilog.

On Ubuntu

$ sudo apt update             
$ sudo apt install verilog

On Mac OS X

$ brew install icarus-verilog

GTKWave

What's it do? Provides a GUI to view waveform output generated by Icarus Verilog and a variety of other industry standard circuit simulators. Who needs it? Individuals interested in designing and simulating digital circuits in Verilog.

On Ubuntu:

$ sudo apt install gtkwave

On Mac OS X:

$ brew install gtkwave

macOS Users: I've found the build of GTKWave generated by Homebrew to be usable but less stable than the pre-packaged builds available on the web. If Homebrew fails you, try one such as this.

Yosys Open Synthesis Suite

What's it do? Synthesizes Verilog hardware designs from RTL into a gate-level netlist (for demonstration only; Xilinx EDA tools will be utilized to synthesize our design for the Papilio board.) Who needs it? Individuals interested in experimenting with the process of synthesizing Verilog into gate-level netlists.

On Ubuntu:

$ sudo apt install yosys

On Mac OS X:

$ brew tap bsmt/homebrew-tap
$ brew install yosys

Xilinx ISE WebPack

What's it do? Synthesizes Verilog into a format that can be programmed into the Papilio's Spartan FPGA. Who needs it? If you intend to realize your Verilog code in hardware form, you need this software. There's no way around it. Skip this tool if you don't own a Papilio or other Spartan 6-based development board (it has no use if you're not targeting your design to these FGPAs).

Note that ISE was EOL'd in 2013 and is no longer actively maintained (although a new build was made available in February, 2018 to support Windows 10). Nevertheless, it's required for hardware designs targeting the older Spartan-family of FPGAs found on the Papilio hardware.

Xilinx makes WebPack available at no cost, but the installation process is a hassle. Xilinx requires you to register on their website before downloading anything, the download size is huge and then you have to generate and install a license file before using it.

Xilinx does not offer a macOS version of the software.

1. Download

Download the most recent version (14.7) of the ISE Design tools (full product installation, all 6 GBs of it) from Xilinx's site. For Windows, here and for Linux, here. Find the "Full Installer for Linux" (or Windows) link and download it. If you have trouble downloading such a large file, you can download the installer broken into four segments (approximately 2GB each).

Note that you will have to create an Xilinx account and fill out a "US Government Export Approval" survey in order to download.

2. Install

Windows users can execute the installer tool; Linux users should follow the instructions below:

  1. Un-tar the download (tar -xvf <filename>). If you've downloaded the segmented installer, be sure to have downloaded the other three segments but leave them intact (they should end in .zip.xz; don't try to untar or unzip these).
  2. Navigate into the un-tarred Xilinx directory, then run xsetup as superuser (sudo ./xsetup).
  3. When prompted for which suite of tools to install, choose ISE WebPack (note that this is not the default selection). Leave all other installation options as their default, and allow the tools to be installed into the (default) /opt/Xilinx directory.

3. Fix the libraries (Linux)

ISE ships with an old version of the C Standard Library and installs it into your LD_LOAD_LIBRARY path. This will prevent most every other Linux tool from running in a shell that sources Xilinx's settings.sh scripts (as described below).

Disable obsolete versions of the C standard library to prevent issues with other tools:

sudo mv /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so.disable
sudo mv /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so.6 /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so.6.disable
sudo mv /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so.6.0.8 /opt/Xilinx/14.7/ISE_DS/common/lib/lin64/libstdc++.so.6.0.8.disable
sudo mv /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so.disable
sudo mv /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so.6 /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so.6.disable
sudo mv /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so.6.0.8 /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/libstdc++.so.6.0.8.disable

4. Fire it up

As noted in the installation wizard, you must source a shell script to configure your path, environmental variables and whatnot prior to running ISE WebPack.

For 64-bit Ubuntu users, this is as simple as:

$ source /opt/Xilinx/14.7/ISE_DS/settings64.sh

I find it convenient to source this settings file from my login script. Various Makefiles and instructions found in these tutorials assume that this script has been sourced prior to executing any Xilinx-related instructions. Add this your .bashrc file by executing this command:

echo 'source /opt/Xilinx/14.7/ISE_DS/settings64.sh > /dev/null' >> ~/.bashrc

Finally, you're ready to fire-up the ISE Design Suite software (but do not run as superuser):

$ ise

5. Get a license

The first time you run ISE you'll be prompted to install a feature license. Follow the prompts to open the Xilinx License Configuration Manager (or choose "Manage License..." from the ISE "Help" menu) and follow these instructions:

  1. Click the "Acquire a License" tab
  2. Select the "Get free Vivado/ISE WebPack License" radio button
  3. Click "Next"
  4. A dialog will appear showing local system information; click "Save Information". Save the Xilinx_Connect_Later.html file to your filesystem.
  5. Open the Xilinx_Connect_Later.html file with a web browser and complete the Xilinx registration and license request (there is no cost for this license but you do have to provide contact information and assure you're complying with applicable export laws).
  6. The license file will be emailed to you. When you receive it, return to the Xilinx License Configuration Manager, click the "Manage Licenses" tab; click the "Load License..." button and navigate to the .lic file you received in email. Voila! You're ready to go!

Papilio Loader

What's it do? Loads the Xilinx-synthesized designs (created using ISE WebPack) onto the Papilio board. Who needs it? Individuals with a Papilio development board. Not useful to those without Papilio hardware.

The Papilio loader replaces standard JTAG device programming tools (providing a less expensive, more user-friendly approach to FPGA development). The most reliable way to install this software on Linux is to clone its Git repository and run the installer script.

The Papilio Loader requires Java and a USB device driver to operate, plus we'll be using Git to fetch it. Install these dependent packages first:

$ sudo apt update
$ sudo apt install default-jdk libftdi-dev git

Then, from within your home directory (or other convenient location), use Git to fetch the Papilio Loader source code:

$ cd ~
$ git clone https://github.com/GadgetFactory/Papilio-Loader.git

Run the Linux installer script (located in the source directory we just cloned):

$ cd Papilio-Loader/
$ ./linux-installer.sh

The installer script will load various application components in the /opt/GadgetFactory/ directory and place links to the papilio-loader-gui and papilio-prog in /usr/local/bin/