Sending USB commands with Python

Tim Roberts timr at probo.com
Thu Aug 30 23:55:37 EDT 2012


"Adam W." <AWasilenko at gmail.com> wrote:
>
>You are correct about the 2 being the number of bytes written.  However when I issue a read command I get:
>
>>>> ep.write('\x1BA')
>4
>>>> ep.read(1)
>usb.core.USBError: [Errno None] b'libusb0-dll:err [_usb_setup_async] invalid endpoint 0x02\n'

USB endponts only go in one direction.  There will be one endpoint for
outoging data, and one endpoint for incoming data.
-- 
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.



More information about the Python-list mailing list