Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
03-03-2014, 04:58 PM
|
#1
|
LQ Newbie
Registered: May 2011
Posts: 7
Rep:
|
General USB testing ?
Hi,
I hope this is the correct forum for a USB testing question. I'm running Ubuntu 12.04, kernel 3.2.0-23. I've been looking at testing USB using a flash drive. My first question is simply, where is the latest usbtest.c file? I installed kernel sources, but that did not give me this file. I see that the usbtest.ko module is available which leads me to believe that this test can still be used, and that the source must be somewhere. When I try to run 'testusb -D /dev/sdb1', I get messages like:
unknown speed /dev/bus/usb/001/007 0
./testusb: /dev/sdb1 may see only control tests
can't open dev file r/w: No such file or directory
So it appears something is trying to run, and 001/007 corresponds to my flash device based on 'lsusb -v' output. I don't know if this is a configuration issue, or something else and maybe the source will help? Or maybe someone on the forum has some info?
TIA,
Anders
|
|
|
03-26-2014, 11:57 PM
|
#3
|
LQ Guru
Registered: Dec 2011
Distribution: Slackware, Debian 12, Devuan & MX Linux
Posts: 9,528
|
If you had to you could download the file here:
http://code.ohloh.net/file?fid=lvoia...lected=true#L0
I checked on the file and it says:
Code:
usbtest.c
Which is a HTML document
from http://code.ohloh.net
|
|
|
03-28-2014, 09:21 AM
|
#4
|
LQ Newbie
Registered: May 2011
Posts: 7
Original Poster
Rep:
|
Thanx for the reply/info. I've since moved on to working with the USB libraries such as usb & libusb. I'm accessing the flash device in a 'raw' mode, no partitions, no format, no OS. I can detach the existing kernel driver, claim the interface, and open the device. But I'm not writing data to the device successfully yet.
So my direction has changed but the issue is not yet resolved. If anyone has helpful hints for working with the usb/libusb library functions, I'd appreciate seeing such :^).
Regards,
Anders
|
|
|
03-28-2014, 06:32 PM
|
#5
|
LQ Guru
Registered: Dec 2011
Distribution: Slackware, Debian 12, Devuan & MX Linux
Posts: 9,528
|
Quote:
Originally Posted by eliasson
Thanx for the reply/info. I've since moved on to working with the USB libraries such as usb & libusb. I'm accessing the flash device in a 'raw' mode, no partitions, no format, no OS. I can detach the existing kernel driver, claim the interface, and open the device. But I'm not writing data to the device successfully yet.
So my direction has changed but the issue is not yet resolved. If anyone has helpful hints for working with the usb/libusb library functions, I'd appreciate seeing such :^).
Regards,
Anders
|
Your Welcome.
Maybe ( I'm guessing) by learning how the usb/libusb libraries work in functionality and how they provide support and distribute it that will perhaps lead you to being able to manipulate them to perform the task/test you want to put in motion. Libraries are programs that do things. Not entirely sure what those things and processes are but it's worth finding out IMO-
Good Luck
http://www.dreamincode.net/forums/to...ing-libusb-10/
http://libusb.sourceforge.net/api-1.0/group__lib.html
|
|
|
04-03-2014, 03:08 PM
|
#6
|
LQ Newbie
Registered: May 2011
Posts: 7
Original Poster
Rep:
|
Finally made good progress. Found some more code on-line that really helped, the xusb.c program example. So I now consider this request solved.
Anders
|
|
|
04-03-2014, 04:52 PM
|
#7
|
LQ Guru
Registered: Dec 2011
Distribution: Slackware, Debian 12, Devuan & MX Linux
Posts: 9,528
|
Glad to hear of the good progress--
Where did you find the xusb.c program?
|
|
|
04-04-2014, 09:33 PM
|
#9
|
LQ Guru
Registered: Dec 2011
Distribution: Slackware, Debian 12, Devuan & MX Linux
Posts: 9,528
|
Looks good for future use. Thanks for posting the link.
Don't forget: mark your thread solved-
Have a good weekend-
|
|
|
All times are GMT -5. The time now is 11:39 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|