Xilinx Programming Cables

Michael Adler edited this page Mar 3, 2015 · 1 revision

USB Programming Cable (All FPGAs)

Ubuntu Hardy and earlier

  1. Get the 2.6 kernel drivers for the Xilinx programming cable.

Recent versions of ISE support libusb (make sure it is installed on the machine).
To use libusb do the following:

1. apt-get install fxload

2. install usb-driver found at http://www.rmdir.de/~michael/xilinx/

3. install udev rules: sudo cp ${XILINX}/ISE/bin/lin/xusbdfwu.rules /etc/udev/rules.d/

4. sudo mount -t usbfs none /proc/bus/usb

5. lsusb to find the Xilinx USB to var_bus and var_number

6. sudo /sbin/fxload -v -t fx2 -I ${XILINX}/ISE/bin/lin/xusbdfwu.hex -D /proc/bus/usb/var_bus/var_number

7. Set XIL_IMPACT_USE_LIBUSB environment variable to tell impact to use
libusb.

Ubuntu Intrepid → Lucid

Here are some instructions working in Ubuntu Intrepid, Jaunty, Karmic, and Lucid

1. sudo apt-get fxload libusb-0.1-4
2. Run $XILINX/ISE/bin/lin64/setup_pcusb. $XILINX should be the directory where you have Xilinx installed. Note that this file is often not executable, so you need to cd into the relevant directory and run “sudo bash setup_pcusb” in order for it to execute properly.
3. Important adjust /etc/udev/rules.d/xusbdfwu.rules to use $tempnode rather than $TEMPNODE. This appears to have changed moving to Intrepid. If you don’t see this file after step 2, Xilinx failed to set up the relevant udev files; a common cause for this is that the number of udevd processes (run “pgrep udevd -l” to determine how many are running) is not exactly equal to one. If you have too many udevd processes running, it is suggested that you restart udev (“sudo service udev restart”).
4. /etc/init.d/udev restart
5. Set XIL_IMPACT_USE_LIBUSB environment variable to tell impact to use5
libusb. This is not necessary post Xilinx 10.1

Ubuntu Precise

Here are some instructions working in Precise. The main challenge here is that the udev rule syntax underwent significant change moving into Precise. The semantics of udev also changed — device handles are no longer automatically mounted with the correct permissions. Additonally, the Xilinx installation script seems to have stopped working.

The instructions begin as before, using an existing installation of Xilinx ISE (in this case, 14.7)

sudo apt-get install fxload libusb-dev
cd $XILINX/ISE/bin/lin64/
cp xusbdfwu.rules /etc/udev/rules.d
cp *.hex /usr/share/

Now we must modify the xusbdfwu.rules, as below. Note that we change BUS, SYSFS, and TEMPNODE to SUBSYSTEMS, ATTRS, and tempnode. We also add MODE:=“666” to each udev rule.

  1. Modified by kfleming from Xilinx distribution to support Ubuntu 12.04
    ATTRS{idVendor}"03fd", ATTRS{idProduct}“0008”, MODE:=“666”
    SUBSYSTEMS"usb", ACTION“add”, ATTRS{idVendor}"03fd", ATTRS{idProduct}“0007”, MODE:=“666”, RUN+=“/sbin/fxload -v -t fx2 -I /usr/share/xusbdfwu.hex -D $tempnode”
    SUBSYSTEMS"usb", ACTION“add”, ATTRS{idVendor}"03fd", ATTRS{idProduct}“0009”, MODE:=“666”, RUN+=“/sbin/fxload -v -t fx2 -I /usr/share/xusb_xup.hex -D $tempnode”
    SUBSYSTEMS"usb", ACTION“add”, ATTRS{idVendor}"03fd", ATTRS{idProduct}“000d”, MODE:=“666”, RUN+=“/sbin/fxload -v -t fx2 -I /usr/share/xusb_emb.hex -D $tempnode”
    SUBSYSTEMS"usb", ACTION“add”, ATTRS{idVendor}"03fd", ATTRS{idProduct}“000f”, MODE:=“666”, RUN+=“/sbin/fxload -v -t fx2 -I /usr/share/xusb_xlp.hex -D $tempnode”
    SUBSYSTEMS"usb", ACTION“add”, ATTRS{idVendor}"03fd", ATTRS{idProduct}“0013”, MODE:=“666”, RUN+=“/sbin/fxload -v -t fx2 -I /usr/share/xusb_xpr.hex -D $tempnode”

Finally, reboot the system.

Testing Driver Installation

If all went well, you should be able to see the new USB device with lsusb.

Below, we show the output of the ML605 programming cable. Notice that the minor number of the Xilinx device is listed as 0008. This indicates that the device firmware has been successfully programmed.

kfleming@vs-lin64-2:~$ lsusb
Bus 002 Device 005: ID 058f:6362 Alcor Micro Corp. Flash Card Reader/Writer
Bus 002 Device 004: ID 03f0:0024 Hewlett-Packard KU-0316 Keyboard
Bus 002 Device 003: ID 046d:c06a Logitech, Inc. USB Optical Mouse
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 004: ID 0cf3:e004 Atheros Communications, Inc. 
Bus 001 Device 006: ID 03fd:0008 Xilinx, Inc. 
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Below, we show the output of the VC707 programming cable, which uses an FTD USB UART to implement programming capability.

[keflemin-vs-fpga-1 mig2014.4(22)] lsusb
Bus 001 Device 002: ID 8087:0024  
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 005: ID 0403:6010 Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC
Bus 002 Device 004: ID 0403:6010 Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC
Bus 002 Device 003: ID 046b:ff10 American Megatrends, Inc. 
Bus 002 Device 002: ID 8087:0024  
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

If you don’t see the the usb device, check /etc/udev/rules.d/xusbdfwu.rules to make sure the Xilinx installation process succeeded.

The next step is to use impact to verify that that the Xilinx drivers can correctly interface with the USB. You should be able to start impact and execute a boundary scan. If all is in working order, impact will enumerate an FPGA. If not, you’ll get a warning about installing drivers.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.