JTAG-MPSSE-Blaster
==================
This project allows to use an MPSSE capable FTDI device as a JTAG interface in Quartus tools.
ftd2xx.dll
is present in the target machine. This step is usually performed in the Windows automatic driver installation process, if needed, it can be downloaded from the FTDI website. jtag_hw_mpsse.dll
and copy it to quartus_install_dir/quartus/bin64
. Ensure that libftd2xx.so
is present in the target machine, if needed, it can be downloaded from the FTDI website, then copy it to /usr/lib and create a symbolic link.
$ wget https://ftdichip.com/wp-content/uploads/2022/07/libftd2xx-x86_64-1.4.27.tgz
$ tar -xvf libftd2xx-x86_64-1.4.27.tgz
$ cd release/build
$ sudo cp libftd2xx.so.1.4.27 /usr/lib/
$ sudo chmod 0755 /usr/lib/libftd2xx.so.1.4.27
$ sudo ln -sf /usr/lib/libftd2xx.so.1.4.27 /usr/lib/libftd2xx.so
Copy the provided USB udev rule for the FTDI device. This rule disables the load of VCP kernel driver (ftdi_sio) and allows non-root access to the device.
$ sudo cp 98-jtag-mpsse-blaster.rules /etc/udev/rules.d/
Reload the new rule or reboot the target system.
$ sudo udevadm trigger
Install the build tools.
# Debian based distro
$ sudo apt install build-essential
$ sudo yum groupinstall "Development tools"
- Build the `libjtag_hw_mpsse.so` using the provided Makefile and copy it to the Quartus install path.
```console
$ make
$ sudo cp libjtag_hw_mpsse.so quartus_install_dir/quartus/linux64/
This library targets the FT232H device and has been tested with the Catapult Smartnics described in my other repo: catapult-v3-smartnic-re.
Several tests have been performed in Mint-21.2 / Fedora-38 / Windows 11-22H2, running Quartus 20.1 / 22.1, the following tools have been checked:
Support for other MPSSE devices such as the FT2232H, FT2232D or the FT4232H can easilly done by adding new entries in the validDevices
array and creating the matching udev rules for them when used in Linux systems.
const ValidDevice validDevices[] =
{
{ .Type = FT_DEVICE_232H, .VID = 0x0403, .PID = 0x6014 }, // Single RS232-HS - (FT232H)
{ .Type = FT_DEVICE_2232H, .VID = 0x0403, .PID = 0x6012 }, // Dual RS232-HS - (FT2232H/FT2232D)
{ .Type = FT_DEVICE_4232H, .VID = 0x0403, .PID = 0x6011 }, // Quad RS232-HS - (FT4232H)
};
These are the default VID/PID values for FTDI devices when no EEPROM is attached to them. If the device has an EEPROM with custom VID/PID then it can be also added to this array.
This tool is a standalone executable and uses the library routines to perform a basic JTAG scan on all available interfaces, then prints the first device IDCode that has been found in the JTAG chain foreach interface.
The tool can be used to troubleshoot JTAG connectivity problems or easily debug the library code.
Device: [JTAG-MPSSE-Blaster]
Port: [00 Single RS232-HS (0403:6014)]
Raw TDO bits: 11111111 11111111 10111011 00000110 00000111 0100000
Raw TDO bytes: FF FF DD 60 E0 02
JTAG IDCode: 02E060DD
Port: [01 Single RS232-HS (0403:6014)]
Raw TDO bits: 11111111 11111111 10111011 00001110 00001001 0100000
Raw TDO bytes: FF FF DD 70 90 02
JTAG IDCode: 029070DD
Port: [02 Single RS232-HS (0403:6014)]
Raw TDO bits: 11111111 11111111 10111011 00000110 00000111 0100000
Raw TDO bytes: FF FF DD 60 E0 02
JTAG IDCode: 02E060DD
Implement the ability to set a custom JTAG TCK frequency. For now the target TCK frequency is harcoded:
All trademarks mentioned in this project are the property of their respective owners.
This project has no commercial purpose.