On Mon, Apr 5, 2010 at 6:42 PM, Wander Lairson <[email protected]> wrote:
> Please, try to find the device from python prompt, just do it:
>
> import usb.core
> dev = usb.core.find(idVendor=0xFFFE)
> assert dev is not None
>
It seems to be fine.
[mc...@myfreebsd /usr/home/mcuee]$ python
Python 2.6.4 (r264:75706, Feb 21 2010, 13:01:16)
[GCC 4.2.1 20070719 [FreeBSD]] on freebsd8
Type "help", "copyright", "credits" or "license" for more information.
>>> import usb.core
>>> dev = usb.core.find(idVendor=0xFFFE)
>>> assert dev is not None
>>> dev
<usb.core.Device object at 0x2863d2ac>
>>> ep =usb.util.find_descriptor(dev.get_interface_altsetting(),custom_match =
>>> lambda e: usb.util.endpoint_direction(e.bEndpointAddress) ==
>>> usb.util.ENDPOINT_OUT)
>>> assert ep is not None
>>> ep
<usb.core.Endpoint object at 0x2863d40c>
>>> ep.write('test')
4
--
Xiaofan http://mcuee.blogspot.com
------------------------------------------------------------------------------
Download Intel® 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
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyusb-users