Can't claim USB interface on LinuxMint 5 (Ubuntu 8.04)
Brought to you by:
josejx
Hi. Neat app.
pk2-la had trouble claiming interface 0 of the PICKit2 on my linux box. After a bit of web searching, it turned out that sometimes an app has to release the interface from the kernel driver before claiming it (lost the link, sorry). So I added the following code before the claim try/except block and it worked:
try:
dev.detachKernelDriver(0)
except usb.USBError :
sys.stderr.write("Can't detach kernel driver to claim the PicKit2 USB interface!\n")
Marty
Thanks for the fix! I've applied it to the repository.