-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tue, 23 Dec 2003 13:10 pm, Froilan A. Olivas wrote:
> C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=500mA
> I: If#= 0 Alt= 0 #EPs= 2 Cls=03(HID ) Sub=00 Prot=00
> Driver=hid
> E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
> E: Ad=01(O) Atr=03(Int.) MxPS= 8 Ivl=10ms
The lines above this are one configuration.
> C: #Ifs= 1 Cfg#= 2 Atr=80 MxPwr=500mA
> I: If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00
> Driver=(none)
> E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
> E: Ad=01(O) Atr=03(Int.) MxPS= 8 Ivl=10ms
And this is a second configuration.
> Here is my question, please, please help me. I know
> that Cls=03( HID ) means it is using a human
> interface device driver, it is at /dev/usb/hiddev0.
Yep.
> When I open it and try to write to it and read from
> it, it hangs i.e it waits forever for a read. (Note: I
> am trying to write my own program to send and receive
> commands to this device.) Does the 2nd "D" line
> Cls=ff(vend.) mean I need a vendor specific driver
> along with the hid driver?? If not then shouldn't a
> simple fd = open("/dev/usb/hiddev0") ... work. Maybe
> a simple explination on how hid driver works. Please
> help.
There are two interfaces to the HID parser. There is a small file in the
kernel distribution (in Documentation/usb/hiddev.txt) that has a little ASCII
art drawing that I did that tries to explain it.
The use of the hiddev interface is badly underdocumented - like much of the
kernel API. I keep meaning to go back and do it, but never got that enthused.
http://www.frogmouth.net/hid-doco/examples/hiddev-misc/dump-events.c
and
http://www.frogmouth.net/hid-doco/examples/hiddev-misc/write-events.c
might help.
Also, Arnauld Quette (from MGE) has written a libHID, which doesn't use the
in-kernel HID code, but instead bypasses it. That might be worth a look too -
see http://www.mgeups.com/opensource/projects/newhidups/
HTH
Brad
- --
http://linux.conf.au - I'm registered. Are you?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
iD8DBQE/8+n4GwwszQ/PZzgRAhRcAJ9IfiUNwHVv+W8EossE2/EIUyV8bQCfSfO9
WS3FYEzimwgOv6/mNCjfznY=
=Pjg0
-----END PGP SIGNATURE-----
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id78&alloc_id371&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users