> http://code.google.com/p/picusb/wiki/libusb_and_udev
The point is, that running it as root i discard the usual questions, "do you have the correct permissions?" Yes, i have, and tripple checked >> Now i am not sure if this fails >> - because of an error on pyusb >> - because the control message is badly built and the device does'nt >> answer (i read something about a timeout function) > > This is also possible. How do you know your control message > is correct? well, i dont. as said, Texas Instruments doesnt provide the documentation on how to comunicate with the device with its firmware, but there is a datasheet detailing the internal registers which i have to edit to accomplish things, like set DTR and RTS. And there is also a GPL'd driver in the kernel made by them, so i am extracting information out of it as i can. The message structure used in the kernel for a write operation is struct ti_write_data_bytes { __u8 bAddrType; __u8 bDataType; __u8 bDataCounter; __be16 wBaseAddrHi; __be16 wBaseAddrLo; __u8 bData[0]; } __attribute__((packed)); which is loaded with constants depending on the task, and passed as the data argument (many 8bits) on an usb_control_msg(). I convert that to the pyusb equivalent as i understand it works. In pyusb, the data argument is the list of integers (carefuly made to be 8bits each) ALSO This test is a WRITE operation. Should it fail if the device doesnt answer/discard the message? At this point i cant know if the usb transaction was received AND discarded, or not received at all. In any of both cases the error should be "Input/Output error", but "Timeout exceed: Target doesnt answer" or "Message discarded by device" >> - because it is not possible to communicate with a device which has a >> real driver assigned to it > If there is a kernel driver bound to the device, you have to detach > the kernel driver first. Even if you run as root, you will get problems > if the kernel driver is in the way. There is a driver in the kernel for sure. Could you please expand your answer on this? How do i detach a driver from the kernel in user space? Also the problem would be, that it is the driver the one that loads the firmware and initialices it. I have had experiences where an HID device can receive usb transactions from a normal application. Thanks. Diego ------------------------------------------------------------------------------ ThinkGeek and WIRED's GeekDad team up for the Ultimate GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the lucky parental unit. See the prize list and enter to win: http://p.sf.net/sfu/thinkgeek-promo _______________________________________________ pyusb-users mailing list pyusb-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pyusb-users