我想读取USB数据。为此,我正在使用 pyusb 库。我写了一个脚本
import usb.core
import usb.util
device = usb.core.find(bDeviceClass=9) # 9 is for hub type usb device
if device is None:
sys.exit("Could not find Id System Barcode Reader.")
if device.is_kernel_driver_active(0):
print "Kernal Driver Active!"
在运行它时它给了我错误。像
usb.core.USBError: [Errno 13] Access denied (insufficient permissions)