(self, skip_on_access_error=False, skip_on_error=False)
return result
Return a list of all USB devices currently plugged in, as USBDevice
        instances.

        skip_on_error (bool)
            If True, ignore devices which raise USBError.

        skip_on_access_error (bool)
            DEPRECATED. Alias for skip_on_error.
Return a list of all USB devices currently plugged in, as USBDevice
        instances.
Return a list of all USB devices currently plugged in as USBDevice instances .
def getDeviceList(self, skip_on_access_error=False, skip_on_error=False):
        """
        Return a list of all USB devices currently plugged in, as USBDevice
        instances.

        skip_on_error (bool)
            If True, ignore devices which raise USBError.

        skip_on_access_error (bool)
            DEPRECATED. Alias for skip_on_error.
        """
        skip_on_error = skip_on_error or skip_on_access_error
        device_p_p = libusb1.libusb_device_p_p()
        libusb_device_p = libusb1.libusb_device_p
        device_list_len = libusb1.libusb_get_device_list(self.__context_p,
                                                         byref(device_p_p))
        if device_list_len < 0:
            raise libusb1.USBError(device_list_len)
        try:
            result = []
            append = result.append
            for device_p in device_p_p[:device_list_len]:
                try:
                    # Instanciate our own libusb_device_p object so we can free
                    # libusb-provided device list. Is this a bug in ctypes that it
                    # doesn't copy pointer value (=pointed memory address) ? At
                    # least, it's not so convenient and forces using such weird
                    # code.
                    device = USBDevice(self, libusb_device_p(device_p.contents))
                except libusb1.USBError:
                    if not skip_on_error:
                        raise
                else:
                    append(device)
        finally:
            libusb1.libusb_free_device_list(device_p_p, 0)
        return result
def getDeviceList ( self , skip_on_access_error = False , skip_on_error = False ) : skip_on_error = skip_on_error or skip_on_access_error device_p_p = libusb1 . libusb_device_p_p ( ) libusb_device_p = libusb1 . libusb_device_p device_list_len = libusb1 . libusb_get_device_list ( self . __context_p , byref ( device_p_p ) ) if device_list_len < 0 : raise libusb1 . USBError ( device_list_len ) try : result = [ ] append = result . append for device_p in device_p_p [ : device_list_len ] : try : # Instanciate our own libusb_device_p object so we can free # libusb-provided device list. Is this a bug in ctypes that it # doesn't copy pointer value (=pointed memory address) ? At # least, it's not so convenient and forces using such weird # code. device = USBDevice ( self , libusb_device_p ( device_p . contents ) ) except libusb1 . USBError : if not skip_on_error : raise else : append ( device ) finally : libusb1 . libusb_free_device_list ( device_p_p , 0 ) return result