Location>code7788 >text

Win10 ILA debugging of ZCU 102 PYNQ using Vivado on WSL

Popularity:995 ℃/2025-04-08 15:06:35
  • WSL itself does not support connecting to USB devices, so you need to install the open source usbipd-win project.

    • Open the wsl command line and enter uname -a to ensure that the installed kernel version is not lower than 5.10.60.1. If the installed kernel version is lower than 5.10.60.1, it can be usedwsl --shutdownFirst close any running instance of WSL and then run the following command to update it:wsl --update

    • Open the windows command line (such as windows power shell) and use the commandwinget install --interactive --exact -winJust install usbipd-win. If you omit --interactive, winget may restart the computer immediately (if this is a necessary action to install the driver). This process will download the open source installation package on github for installation, paying attention to keeping the network open.

  • Install driver for vivado in wsl

    • Navigate to /data/xicom/cable_drivers/lin64/install_script/install_drivers/ in the Vivado installation directory, and then run the install_drivers executable file below (requires root permissions).

    •  cd ${vivado_install_dir}/data/xicom/cable_drivers/lin64/install_script/install_drivers/
       sudo ./install_drivers
  • Use an administrator to open the windows command line (such as Windows Power shell) and enter the usbipd list to view all USB devices connected to Windows. The first line is the BUS ID of the corresponding USB device.

  • Start the development board, connect the jtag port and windows of the development board, enter the usbipd list, and you can find that there are more USB Serial Converter items under DEVICE (if it is a uart port, you can find that there are more Silicon Labs Quad CP2108 USB to UART Bridge items, which may vary depending on the USB to serial driver)

  • Share USB device using the following command on the windows command line

    •  - usbipd bind --busid 1-3 (This command is used to share USB, 1-3 is the BUS ID corresponding to my jtag port, please modify it according to the actual situation)
       - usbipd attach --wsl --busid 1-3 (This command is used to hand over USB control to wsl. Before executing this command, make sure that wsl is in the power-on state. After inserting and unplugging the USB connection cable, you need to re-execute the command)
  • Enter lsusb in the wsl command line to view all USB devices. If jtag is bound successfully, you can find it in the list

    • Due to permission reasons, Vivado cannot access this device. In theory, you can use root permissions to run vivado, which may be OK. The method used here is to modify the permissions of the USB device. It is more brutal here, and you directly grant all USB devices permissions.

    •  chmod -R 777 /dev/bus/usb/