FTDI Community

Please login or register.

Login with username, password and session length.
Advanced Search  

News:

Welcome to the FTDI Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ FTDI Support


New Bridgetek Community is now open

Please note that we have created the Bridgetek Community to discuss all Bridgetek products e.g. EVE, MCU.

Please follow this link and create a new user account to get started.

Bridgetek Community

Author Topic: FT4222 use mode 2 and FT_OPEN_BY_LOCATION  (Read 276 times)

cwryu

  • Newbie
  • *
  • Posts: 1
    • View Profile
FT4222 use mode 2 and FT_OPEN_BY_LOCATION
« on: July 09, 2022, 01:38:08 AM »

I connect four FT4222H chips to one ARM Linux board and use the mode 2 method. When I check the device connection using the libft4222 Library, it is recognized as normal. However, if I reboot the ARM Linux board or disconnect FT4222H and reconnect it, the LocId returned from FT_DEVICE_LIST_INFO_NODE changes every time, and I want to know if there is a way to fix LocId.
Because the equipment I am developing needs to control the SPI Slave Device according to the order of FT4222H connected to the USB port of the ARM Linux board, so I need fixed LocId information.
Or, I would like to know if there is a way to match LocId with Linux's /sys/bus/usb/devices/ information.
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 774
    • View Profile
Re: FT4222 use mode 2 and FT_OPEN_BY_LOCATION
« Reply #1 on: July 11, 2022, 04:56:29 PM »

Hi,

The location IDs on Linux are just an estimate of where the USB device is. it is not like windows where it is the exact location. there is no way to have it fixed. Although it shouldn't change when you reconnect, there is no guarantee that it won't. i would suggest that you would be better opening the device by description or serial number. Or you could even check where the device is on the USB tree before opening it.   

Best Regards

FTDI Community                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   
Logged