Arvid

Members
  • Content Count

    11
  • Joined

  • Last visited

Posts posted by Arvid


  1. Hello,

    Yes, I do use FT_Open(), because most FTDI devices I work with lack the EEPROM and therefore doesn't have any serial or meaningful description.

    I have installed the updated runtime.

    $ dpkg -s digilent.adept.runtime | grep Version
    Version: 2.19.1

    Here is the log with the non-working setup:

    $ ADEPT_RT_LOGDETAIL=5 djtgcfg enum && cat DebugErc.log
    No devices found
    System Time     Process     Thread        ERC     ERC String                  Message
    517481022       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - cftdevPrev = 0, cfdevCur = 3
    517481029       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - CreateDeviceInfoList found 3 devices
    517481029       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - skipped non-Digilent device 0
    517481029       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - skipped non-Digilent device 1
    517481029       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - interface list contains 0 devices
    517481034       11136       248846144     0       ercNoErc                    FEnumAndUpdateCache - OpenEx failed on serial 210299A06B5F, erc = 2
    

     

    And if I swap USB ports:

    $ ADEPT_RT_LOGDETAIL=5 djtgcfg enum && cat DebugErc.log
    Found 1 device(s)
    
    Device: JtagHs3
        Product Name:   Digilent JTAG-HS3
        User Name:      JtagHs3
        Serial Number:  210299A06B5F
    System Time     Process     Thread        ERC     ERC String                  Message
    517319541       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - cftdevPrev = 0, cfdevCur = 3
    517319548       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - CreateDeviceInfoList found 3 devices
    517319548       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - skipped non-Digilent device 1
    517319548       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - skipped non-Digilent device 2
    517319548       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - interface list contains 0 devices
    517319608       11024       3140945728    0       ercNoErc                    FEnumAndUpdateCache - added interface 210299A06B5F to the list
    

     


  2. Hi malexander,

     

    FT_GetDeviceInfoDetail(0)
      Flags:  0x00000002
      Type:   0x00000008 (FT_DEVICE_232H)
      Id:     0x04036014
      LocId:  0x0000010e
      Serial: 210299A06B5F
      Desc:   Digilent USB Device
    FT_OPEN(0) returns FT_OK
    
    FT_GetDeviceInfoDetail(1)
      Flags:  0x00000002
      Type:   0x00000006 (FT_DEVICE_2232H)
      Id:     0x04036010
      LocId:  0x000010f1
      Serial: 
      Desc:   Dual RS232-HS A
    FT_OPEN(1) returns FT_OK
    
    FT_GetDeviceInfoDetail(2)
      Flags:  0x00000002
      Type:   0x00000006 (FT_DEVICE_2232H)
      Id:     0x04036010
      LocId:  0x000010f2
      Serial: 
      Desc:   Dual RS232-HS B
    FT_OPEN(2) returns FT_OK
    

     


  3. Hello Malexander,

    No, root permissions does not make any difference.

    And when I have the setup where the JTAG-HS3 is not found, if I pull out the power on the board with the FTDI chip (USB cable still connected to PC), then the JTAG-HS3 starts to work. And if I plug in the power to the FTDI device once more, the  JTAG -HS3 is not found any more. 

    $ sudo djtgcfg enum
    [sudo] password for arvid: 
    No devices found

    $ sudo djtgcfg enum
    Found 1 device(s)

    Device: JtagHs3
        Product Name:   Digilent JTAG-HS3
        User Name:      JtagHs3
        Serial Number:  210299A06B5F

    $ sudo djtgcfg enum
    No devices found

    I have tried doing the same experiments with JTAG-HS1 and JTAG-HS2, and I get the same behaviour. I have tried with a FTDI FT2232H and a FT4232H device and I get the same behaviour.

    To add more confusion, I have my own application that enumerates FTDI devices (this application can either use the the official libftd2xx or the open source libftdi to enumerate FTDI based devices). An it finds the the JTAG-HS3 dongle (and the FTDI device). 

    /* Using the libftd2xx */
    DWORD cnt = 0;
    FT_DEVICE_LIST_INFO_NODE node = {0};
    if (FT_CreateDeviceInfoList(&cnt) == FT_OK) {
    	for (int i=0; i<cnt; i++) {
    		if (FT_GetDeviceInfoDetail(i, &node.Flags, ... , &node.Description, &node.ftHandle) == FT_OK) {
              	/* Print devices */
    			...
    		}
    	}
    }
    /* Using libftdi */
    struct ftdi_context *ftdi = ftdi_new();
    int vid[] = {0x0403, 0x0403, 0x0403};
    int pid[] = {0x6010, 0x6011, 0x6014};
    struct ftdi_device_list *devs;
    struct ftdi_device_list *dev;
    char name[64] = {0};
    int cnt;
    for (int j=0; j<3; j++) {
    	cnt = ftdi_usb_find_all(ftdi, &devs, vid[j], pid[j]);
    	dev = devs;
    	for (int i=0; i<cnt; i++, dev = dev->next) {
    		ftdi_usb_get_strings(ftdi, dev->dev, NULL, 0, name, sizeof(name)-1, NULL, 0);
    		/* Print devices */
    		...
    	}
    }

    However, if I try to list all Digilent JTAG dongles, using the Digilent Adept SDK, it's not found (similar to djtagcfg). So the device seems to get lost somewhere in the Digilent Adept software.

    /* Using Digilent Adept SDK*/
    int ndvc;
    DCAP dcap = dcapJtg;
    DmgrEnumDevicesEx(&ndvc, dtpUSB, dtpUSB, dinfoDCAP, &dcap);
    DVC dvc;
    char name[cchProdNameMax+1] = {0};
    for (int i=0; i<ndvc; i++) {
        if (DmgrGetDvc(i, &dvc) == fTrue) {
    		/* Print devices */
    		if (DmgrGetInfo(&dvc, dinfoProdName, name) == fTrue) {
    			...
    		}
    	}
    }

     

    My application never use the JTAG-HS3 via the ftdi libraries directly.  It only use the ftdi libraries to communicate with stand-alone FTDI devices. The application only uses the Digilent Adept SDK to communicate with the JTAG-HS3, even if it can be found via the ftdi libraries.

    Is there any other information that I can provide?


  4. Hello,

    My computer is a Ubuntu 18.01 machine. I have a Digilent JTAG-HS3 and 3rd-part board with a FTDI FT2232 chip connected to my computer. The FT2232 chip is just a simple FTDI device, it doesn't have any EEPROM connected to it.

    If the devices are are connected to my PC in the wrong order, the Digilent JTAG-HS3 will not be discovered by the Adepts utilities. If I then swap the physical USB ports for the cables, the Digilent JTAG-HS3 can be found.

    Is this a bug in the Adept Runtime for Linux?

     

    $ djtgcfg enum
    No devices found
    
    $ lsusb
    Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 001 Device 066: ID 0403:6010 Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC
    Bus 001 Device 067: ID 0403:6014 Future Technology Devices International, Ltd FT232H Single HS USB-UART/FIFO IC
    Bus 001 Device 007: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub
    Bus 001 Device 005: ID 0bc2:2300 Seagate RSS LLC Expansion Portable
    Bus 001 Device 006: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 001 Device 004: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 001 Device 003: ID 046d:c30e Logitech, Inc. UltraX Keyboard (Y-BL49)
    Bus 001 Device 002: ID 046d:c03f Logitech, Inc. M-BT85 [UltraX Optical Mouse]
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    
    $ lsusb -t
    /:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/8p, 5000M
    /:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/16p, 480M
        |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 2: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 2: Dev 3, If 1, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 3: Dev 4, If 0, Class=Hub, Driver=hub/4p, 480M
            |__ Port 1: Dev 6, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 5: Dev 5, If 0, Class=Mass Storage, Driver=usb-storage, 480M
        |__ Port 6: Dev 7, If 0, Class=Hub, Driver=hub/2p, 480M
        |__ Port 8: Dev 67, If 0, Class=Vendor Specific Class, Driver=, 480M
        |__ Port 9: Dev 66, If 0, Class=Vendor Specific Class, Driver=ftdi_sio, 480M
        |__ Port 9: Dev 66, If 1, Class=Vendor Specific Class, Driver=ftdi_sio, 480M

     

    $ djtgcfg enum
    Found 1 device(s)
    
    Device: JtagHs3
        Product Name:   Digilent JTAG-HS3
        User Name:      JtagHs3
        Serial Number:  210299A06B5F
    
    $ lsusb
    Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 001 Device 065: ID 0403:6014 Future Technology Devices International, Ltd FT232H Single HS USB-UART/FIFO IC
    Bus 001 Device 064: ID 0403:6010 Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC
    Bus 001 Device 007: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub
    Bus 001 Device 005: ID 0bc2:2300 Seagate RSS LLC Expansion Portable
    Bus 001 Device 006: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 001 Device 004: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 001 Device 003: ID 046d:c30e Logitech, Inc. UltraX Keyboard (Y-BL49)
    Bus 001 Device 002: ID 046d:c03f Logitech, Inc. M-BT85 [UltraX Optical Mouse]
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    
    $ lsusb -t
    /:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/8p, 5000M
    /:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/16p, 480M
        |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 2: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 2: Dev 3, If 1, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 3: Dev 4, If 0, Class=Hub, Driver=hub/4p, 480M
            |__ Port 1: Dev 6, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 5: Dev 5, If 0, Class=Mass Storage, Driver=usb-storage, 480M
        |__ Port 6: Dev 7, If 0, Class=Hub, Driver=hub/2p, 480M
        |__ Port 8: Dev 64, If 1, Class=Vendor Specific Class, Driver=ftdi_sio, 480M
        |__ Port 8: Dev 64, If 0, Class=Vendor Specific Class, Driver=ftdi_sio, 480M
        |__ Port 9: Dev 65, If 0, Class=Vendor Specific Class, Driver=, 480M