[Wlug] Seeking help with a USB barcode scanner
Tim Keller
turbofx at gmail.com
Mon Apr 2 16:14:22 EDT 2007
This is what I would do.
1. Install "lsusb". It behaves much like lspci so you can what devices are
on your system.
When you do a "lsusb" it'll list what devices are hanging off of each USB
bus. Do a before and after so you can see the major/minor numbers.
2. When you know the devices major and minor number you can write a program
using libusb that'll look for the device, open the device if it exists,
take posession of it and then read data to and from it, hopefully.
http://libusb.sourceforge.net/doc/examples-code.html
Looking at that example, I don't think it would be too hard to whip up a
program to open the device and then loop until there's input and then dump
it on the screen.
Thanks,
Tim.
On 3/31/07, Keith Wright <kwright at keithdiane.us> wrote:
>
> > From: Jamie Guinan <guinan at bluebutton.com>
> > >
> > > I tried your "od -x" trick on each of these to no avail. I
> > > pointed the barcode scanner at some arbitrary barcodes, and it
> > > beeped and turned off the red light, but nothing appeared on my
> > > screen as a result of the "od -x".
> > >
> > > Are there other possibilities to consider?
> >
> > At this point I'd start putting printk's and turning on DEBUGs in
> > the kernel source. For starters,
>
> If you get to the point of modifying the kernel source,
> can you be far from wanting an oscilloscope on the pins?
>
> -- Keith
> _______________________________________________
> Wlug mailing list
> Wlug at mail.wlug.org
> http://mail.wlug.org/mailman/listinfo/wlug
>
--
I am leary of the allegiances of any politician who refers to their
constituents as "consumers".
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.wlug.org/pipermail/wlug/attachments/20070402/95c435f2/attachment.html
More information about the Wlug
mailing list