Anonymous
Not applicable
Feb 25, 2009
10:09 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Feb 25, 2009
10:09 AM
I tried to iterate through the UsbDeviceList but have no success because the List is empty (I cannot understand why) .
The usbDevices.Count always be 0 whatever the dev-Board is pluged in or not .
pls help ~~
public Form1()
{
InitializeComponent();
// Setup the callback routine for updating the UI
updateUI = new UpdateUICallback(StatusUpdate);
// Setup PnP event handling
evHandler = new App_PnP_Callback(PnP_Event_Handler);
// Create a list of CYUSB devices
usbDevices = new USBDeviceList(CyConst.DEVICES_CYUSB, evHandler);
setDevice();
}
public void setDevice()
{
if (usbDevices.Count > 0)
loopDevice = usbDevices[0x0547, 0x0080] as CyUSBDevice;
StartBtn.Enabled = (loopDevice != null);
if (loopDevice != null)
Text = loopDevice.FriendlyName;
else
Text = "Bulkloop - no device";
// Set the in and out endpoints per the selected radio buttons.
EptPair1Btn_Click(this, null);
}
The usbDevices.Count always be 0 whatever the dev-Board is pluged in or not .
pls help ~~
public Form1()
{
InitializeComponent();
// Setup the callback routine for updating the UI
updateUI = new UpdateUICallback(StatusUpdate);
// Setup PnP event handling
evHandler = new App_PnP_Callback(PnP_Event_Handler);
// Create a list of CYUSB devices
usbDevices = new USBDeviceList(CyConst.DEVICES_CYUSB, evHandler);
setDevice();
}
public void setDevice()
{
if (usbDevices.Count > 0)
loopDevice = usbDevices[0x0547, 0x0080] as CyUSBDevice;
StartBtn.Enabled = (loopDevice != null);
if (loopDevice != null)
Text = loopDevice.FriendlyName;
else
Text = "Bulkloop - no device";
// Set the in and out endpoints per the selected radio buttons.
EptPair1Btn_Click(this, null);
}
1 Reply
Anonymous
Not applicable
Apr 04, 2009
07:54 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Apr 04, 2009
07:54 AM
This is because DriverGUID is not registered in the registry. In the inf file used take care that it registers driver guid in the registry...