1 Reply Latest reply on Aug 22, 2018 1:34 AM by srnt

    CyUSB cannot enumerate FX3 UVC device

    sdz_2011_3494506

      Hi

          

          I run AN75779 demo in usb device side and ensure there is   a UVC device named FX3 in device manager in windows.But I failed to enumerate it using CyUSB API USBDeviceList .

              The host code(Form1.cs)detail is as following:

              public Form1()

              {

                  InitializeComponent();

                  usbDevices = new USBDeviceList(CyConst.DEVICES_CYUSB);

                  usbDevices.DeviceAttached += new EventHandler(usbDevices_DeviceAttached);

                  usbDevices.DeviceRemoved += new EventHandler(usbDevices_DeviceRemoved);

                  setDevice();

              }

       

              public void setDevice()

              {

                  int nCurSelection = 0;

                  if (cboDeviceConnected.Items.Count > 0)

                  {

                      nCurSelection = cboDeviceConnected.SelectedIndex;

                      cboDeviceConnected.Items.Clear();

                  }

                  int nDeviceList = usbDevices.Count;     //here get 0

                  for (int nCount = 0; nCount < nDeviceList; nCount++)

                  {

                      USBDevice fxDevice = usbDevices[nCount];

                      String strmsg;

                      strmsg = "(0x" + fxDevice.VendorID.ToString("X4") + " - 0x" + fxDevice.ProductID.ToString("X4") + ") " + fxDevice.FriendlyName;

                      cboDeviceConnected.Items.Add(strmsg);

                  }

       

       

                  if (cboDeviceConnected.Items.Count > 0)

                      cboDeviceConnected.SelectedIndex = nCurSelection;

       

       

                  myDevice = usbDevices[cboDeviceConnected.SelectedIndex] as CyUSBDevice;

       

       

                  //StartBtn.Enabled = (myDevice != null);

       

       

                  if (myDevice != null)

                      Text = myDevice.FriendlyName;

                  else

                      Text = "C# UVC - no device";

               }

       

               private void cboDeviceConnected_SelectionChangeCommitted(object sender, EventArgs e)

              {

                  setDevice();

              }

       

       

          As a contrast,I repower the FX3 board and it is a Cypress FX3 USB BootLoader Device in  USB Control Center. At the time I run my host code and it can enumerate the bootloader device using USBDeviceList API.

          I appreciate any help, thank you,

        

           Attachment is my host code.

        • 1. Re: CyUSB cannot enumerate FX3 UVC device
          srnt

          Hello,

           

          When the FX3 is loaded with AN75779 firmware, the device comes up as a UVC class device and binds to the UVC class driver whereas when it is in boot-loader mode, the device falls under vendor class and binds to the CYUSB3 driver (vendor driver). The CyUSB API is capable of identifying devices bound to the CYUSB3 driver and not others. This is the reason for the behavior that you have mentioned.

           

          When you are using the An75779 firmware, you can use any of the UVC Windows applications such as e-Cam View, VLC Media Player, AMCap etc.

           

          Best regards,

          Srinath S

          1 of 1 people found this helpful