It seems to me that the openusb backend is not implemented yet.

Under Ubuntu 9.10 32bit, if I do not have openusb installed,
the test is okay. I have the test device with a PIC18F4550.

mc...@ubuntu:~/Desktop/build/pyusb/pyusb/trunk/tests$ python testall.py
Adding DeviceTest(usb.backend.libusb10) to test suite...
Adding ConfigurationTest(usb.backend.libusb10) to test suite...
Adding InterfaceTest(usb.backend.libusb10) to test suite...
Adding EndpointTest(usb.backend.libusb10) to test suite...
Adding DeviceTest(usb.backend.libusb01) to test suite...
Adding ConfigurationTest(usb.backend.libusb01) to test suite...
Adding InterfaceTest(usb.backend.libusb01) to test suite...
Adding EndpointTest(usb.backend.libusb01) to test suite...
Adding BackendTest(usb.backend.libusb10) to test suite...
Adding BackendTest(usb.backend.libusb01) to test suite...
.................
----------------------------------------------------------------------
Ran 17 tests in 2.765s

If I have OpenUSB installed (from Synaptic, I have
problems to build OpenUSB from source somehow),
then the test will fail.

mc...@ubuntu:~/Desktop/build/pyusb/pyusb/trunk/tests$ python testall.py
Adding DeviceTest(usb.backend.libusb10) to test suite...
Adding ConfigurationTest(usb.backend.libusb10) to test suite...
Adding InterfaceTest(usb.backend.libusb10) to test suite...
Adding EndpointTest(usb.backend.libusb10) to test suite...
Adding DeviceTest(usb.backend.libusb01) to test suite...
Adding ConfigurationTest(usb.backend.libusb01) to test suite...
Adding InterfaceTest(usb.backend.libusb01) to test suite...
Adding EndpointTest(usb.backend.libusb01) to test suite...
Traceback (most recent call last):
  File "testall.py", line 43, in <module>
    suite.addTest(m.get_suite())
  File "/home/mcuee/Desktop/build/pyusb/pyusb/trunk/tests/test_integration.py",
line 228, in get_suite
    b = m.get_backend()
  File "/usr/local/lib/python2.6/dist-packages/usb/backend/openusb.py",
line 566, in get_backend
    _setup_prototypes(_lib)
  File "/usr/local/lib/python2.6/dist-packages/usb/backend/openusb.py",
line 151, in _setup_prototypes
    lib.openusb.restype = c_int32
  File "/usr/lib/python2.6/ctypes/__init__.py", line 366, in __getattr__
    func = self.__getitem__(name)
  File "/usr/lib/python2.6/ctypes/__init__.py", line 371, in __getitem__
    func = self._FuncPtr((name_or_ordinal, self))
AttributeError: /usr/lib/libopenusb.so.0: undefined symbol: openusb



-- 
Xiaofan http://mcuee.blogspot.com

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
pyusb-users mailing list
pyusb-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pyusb-users

Reply via email to