
I’ve decided to learn how to program FPGA:s. So I got myself two Terasic boards, one Terasic DE10-Nano for testing out the excellent MiSTer FPGA hardware arcade/computer/console emulator and a simpler DE0-Nano for beginning to learn Verilog.
But the software used, called Intel Quartus Prime 19.1, is truly horrible. The Windows version doesn’t work with high-resolution screens when using scaling; the text is cut off on the display. So I installed it on my Linux Ubuntu 18.04 machine instead. Now the display works, but there’s a lot of other problems, like getting the dreaded error message: “USB-Blaster unable to scan device chain”. I’ve written them down here for later reference, and maybe you have the same install problems, so this might help.
USB-Blaster “unable to scan device chain” Error Message
After installing the software, I tried to use the programmer to connect my development board, but I got the error Unable to scan device chain. After searching the net, I found information on setting up the computer so that you don’t need to run the JTAG as root.
So I added the file /etc/udev/rules.d/51-usbblaster.rules
and put the following text into the file to allow a regular user to access the Terasic FPGA board.
USB Blaster SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="09fb", ATTR{idProduct}=="6001", MODE="0666", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", RUN+="/bin/chmod 0666 %c" SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="09fb", ATTR{idProduct}=="6002", MODE="0666", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", RUN+="/bin/chmod 0666 %c" SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="09fb", ATTR{idProduct}=="6003", MODE="0666", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", RUN+="/bin/chmod 0666 %c" # USB Blaster II SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="09fb", ATTR{idProduct}=="6010", MODE="0666", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", RUN+="/bin/chmod 0666 %c" SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="09fb", ATTR{idProduct}=="6810", MODE="0666", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", RUN+="/bin/chmod 0666 %c"
Well, that didn’t work, but it is probably a good idea to have this file installed.
This Fixed It!
The next thing did the trick, however. It seems this is an old bug that Intel hasn’t managed to fix for several release versions. Great stuff.
You need to add a soft link so the software can find a library.
Open a terminal window and write this command:
sudo ln -s /lib64/libudev.so.1 /lib64/libudev.so.0
Restart the machine, connect your Terasic FPGA board with a USB cable, and open a terminal window. You can now write the following command in the terminal window
jtagconfig
And if you don’t get any errors and the system recognizes the USB-Blaster hardware, you should now be able to download bitstreams from Quartus to your FPGA board.
If you get any error messages about missing libraries when starting Quartus, make sure to install them. For example, I had to install the following libraries.
sudo apt install libcanberra-gtk-module libcanberra-gtk3-module
To make this even more annoying, I sometimes have to enlarge the Quartus Programming window; otherwise, the program would hang.
Quartus Prime is the software that keeps on giving.
I hope that helped.
Paul Saffren says
The only thing that worked for me on Ubuntu 18.04 is:
1) I added the 51-usbblaster rules file.
2) and this was key: https://ecen3350.rocks/static/usb-blaster.pdf
Basically create the directory /etc/jtagd
Then: cp quartus/linux64/pgm_parts.txt /etc/jtagd/jtagd.pgm_parts