Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #import usb stuff
- import usb.core
- import usb.util
- #find device
- dev = usb.core.find(idVendor=0x04f2,idProduct=0x0939)
- # was it found?
- if dev is None:
- raise ValueError('Device not found')
- # set the active configuration. With no arguments, the first
- # configuration will be the active one
- dev.set_configuration()
- bmRqueType=0x80;
- bRque=0x0;
- wVal=0x0;
- wIndex=0x0;
- wLength=0x0;
- ret = dev.ctrl_transfer(bmRqueType,bRque,wVal,wIndex,wLength)
- print ret
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement