USB in python

Tino Wildenhain tino at
Thu Jan 22 11:21:00 CET 2009

Astan Chee wrote:
> Hi,
> Im trying to write a program for my USB device and I'm thinking of using 
> python to do this. The USB device is of my own making and it is 
> activated when one of the two data pins of the USB is given about 5V (or 
> similar to whatever the power pin is getting). Now I'm confused to if 
> the software to activate this can actually be written and how do I do 
> it? Any examples? I've seen pyUSB but it doesn't give me control over 
> the hardware and how much power is going through the data pins.
> Thanks for any help.

Your approach doesn't sound right to me. I don't believe you can control
the PINs of the USB host interface directly. You need to configure the
host controller - OS is giving you interfaces and abstration for the
different device types. All you need to do is to implement the end
points as per spec in your hardware and write handler for your
hardware's USB ids.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3241 bytes
Desc: S/MIME Cryptographic Signature
URL: <>

More information about the Python-list mailing list