ISE 12.4 on Ubuntu 10.10  

HOWTO: Xilinx ISE 12.4 on Ubuntu Linux 10.10 (64-bit)

Updated 2011-01-20: The 64-bit version of ISE is basically broken by design. PACE doesn't run at all, meaning CPLD constraints editing is just about impossible... I've revised the tutorial (again!) to explain how to install ISE 32-bit on a 64-bit OS.

Apparently Xilinx have changed just about everything... again. So this is a rewritten version of my ISE 11.1 tutorial, modified for ISE 12.4...

Installing ISE 12.4 on a 32-bit system should be very similar, but you don't need Getlibs (use apt-get install libmotif3 instead), and the setup program needs to be run directly instead of being run through linux32.

The advantage of this method is that you gain support for parallel cables without having to install kernel drivers (which have to be recompiled every time the kernel is upgraded). All the Xilinx parallel cables (and most of the Parallel Cable III clones) should work fine -- I've personally tested with the Enterpoint PROG3 (a Xilinx USB cable clone) and a homebrew Xilinx Parallel Cable III clone.

  1. First you need to install ISE itself. Grab the tarball from Xilinx's website (it's about 5GB!) and un-TAR it. Open a terminal and 'cd' into the directory you untarred the files into. Type:

    sudo linux32 ./xsetup

    Follow the instructions on-screen. Make sure you remember where you installed ISE (the "base path") -- this will typically be /opt/Xilinx/12.4. For the rest of this tutorial, I'll use $XILINX to refer to this directory.

  2. Now you need to install the USB cable drivers:

    sudo -i
    cd $XILINX/ISE_DS/ISE/bin/lin
    source setup_pcusb
  3. But there's a problem... the installer sets up a Hotplug script, not a set of Udev rules! We need to fix that...

    • Type sudo gedit /etc/udev/rules.d/xusbdfwu.rules, and replace the contents of the file with:

      ATTR{idVendor}=="03fd", ATTR{idProduct}=="0008", MODE="666"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="0007", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusbdfwu.hex -D %N"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="0009", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusb_xup.hex -D %N"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="000d", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusb_emb.hex -D %N"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="000f", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusb_xlp.hex -D %N"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="0013", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusb_xp2.hex -D %N"
      SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03fd", ATTR{idProduct}=="0015", RUN+="/sbin/fxload -v -t fx2 -I /etc/hotplug/usb/xusbdfwu.fw/xusb_xse.hex -D %N"
  4. Install fxload:

    sudo apt-get install fxload
  5. Unplug and replug the Platform Cable. Note that iMPACT (the ISE device programmer utility) won't detect USB cables unless it sees the firmware files in /usr/share, even if the cable has already had its firmware loaded.

  6. Now we need to get rid of WinDriver. Grab a copy of Michael Gernoth's "libusb-driver" cable driver and compile it:

    sudo apt-get install libusb-dev libftdi-dev
    sudo getlibs -p libftdi1 libftdi-dev
    mkdir ~/xlnx_usb_driver
    cd ~/xlnx_usb_driver
    wget -O usb-driver-HEAD.tgz ";h=HEAD;sf=tgz"
    tar -zxf usb-driver-HEAD.tgz
    cd usb-driver
    make lib32

    Now copy the cable driver into the Xilinx library path:

    sudo cp $XILINX/ISE_DS/ISE/lib/lin
  7. Now we need to make iMPACT use the cable driver...

    cd $XILINX/ISE_DS/ISE/bin/lin
    sudo mv _impact _impact.bin
    sudo gedit _impact

    Copy-and-paste this into the gedit window that just appeared...

    # Preload driver binary $0.bin $*

    Save it and close gedit. Go back to the shell.

    sudo chmod +x _impact
  8. Done! Now create a script to start ISE...

    sudo gedit $XILINX/

    Paste this into the file:

    source $XILINX/ $XILINX

    And back to the shell...

    sudo chmod +x $XILINX/

    NOTE that you need to replace $XILINX on the second line of the script with your ISE installation path, e.g. /opt/Xilinx/12.4/ISE_DS

  9. Finished! Add a launcher icon to your desktop environment's menu, and make it run $XILINX/ If you want to create an icon to run iMPACT, copy as, edit the copy and change the last line from ise to impact.

If you want to run the FPGA Editor or PACE (i.e. if you're running , you need to install a few extra packages:

  1. Install Motif (this installs and Portmap (which PACE needs for its GUI library):

    sudo apt-get install libmotif3 libmotif-dev libstdc++5 portmap
    sudo getlibs -p libmotif3 libmotif-dev libstdc++5
  2. Unfortunately FPGA Editor is still built against an ancient X11 toolkit which can't handle the new-style ":0.0" $DISPLAY strings. This means that to actually start the FPGA Editor, you need to be a bit sneaky. Open your script and add this line right at the top, just after the hash-bang (#!/bin/sh) line:

    export DISPLAY=`echo $DISPLAY | sed 's/\.[0-9]*$//'`

Now you should be able to run ISE, the FPGA Editor and XPower with no trouble at all (unless you're running a remote X session or using SSH X11 forwarding, in which case you'll need to find another solution -- VNC maybe?).