|Online Development Notebook > Index > Programming Overview > DLL Commands > NumberOfDevices|
NumberOfDevices - Return the number of U4x1 devices found
This is a USBm.dll function that returns the number of valid devices on the USB bus. (0 to 20)
The USBm_NumberOfDevices function syntax has these parts:
Note: USBm_NumberOfDevices does not return TRUE⁄FALSE. The return value is the number of detected devices.
VB Declaration (USBmAPI.bas)
|Public Declare Function USBm_NumberOfDevices _|
Lib "USBm.dll" _
|Dim result As Integer|
This code fragment shows that result is loaded with the number of detected devices.
|int USBm_NumberOfDevices( void );|
Returns the number of U4x1 devices connected to the PC. 0 means there are no devices connected.
Hardware: U401 USB Interface U421 USB Interface U451 USB Interface
Programming: USBm DLL Programming Download Files
Application Notes: U4x1 Application Notes Misc Applications and Information FAQ
While every effort has been made to make sure that the information posted on this site is correct, the author can not be held liable for any damages whatsoever for losses as a result of the application of this information. Use this information at your own risk.
USBmicro can design your custom and semi-custom USB product. Email about USB design can be directed to " Robert " at usbmicro.com.
Copyright © USBmicro, L.L.C., 2002-2010