In a previous archive, Dan Streetman wrote that :
>>The most interesting change is the UsbInterfacePolicy.  An interesting
>>side note to the policy is the 'forceClaim' option, which allows you (on
>>certain Linux kernels, 2.5 and from 2.4.23-pre2) to remove existing USB
>>drivers from any usb interface, so you can drive the interface from
>>userspace.
Maybe is it a way to help you get the interface released.

If you don't have a recent kernel, I have a TEMPORARY solution. I have
exactly the same problem and solve it by calling the "rmmod hid" command
within the java program (using the Runtime and Process classes).
In my case, the HID driver isn't used by any other module. In yours, you
should maybe call "rmmod" on all modules that have called the HID driver
before you can remove it.
It allows not to modify the hid_core.c file but I insist that it is NOT a
very elegant solution (moreover, it requires to be connected as root).
PS : at the end of the java code, the "insmod" command is called to retrieve
a well-functionning linux system.

Aurelien

-----Message d'origine-----
De : [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] la part de Aaron
Metzger
Envoye : vendredi 10 octobre 2003 23:17
A : [EMAIL PROTECTED]
Objet : [javax-usb-devel] HID usage under Linux



This is a usability question in a Linux environment more than it is an
API question.

My experience is that I can't "claim" any device with javax-usb that
has already been claimed by the Linux kernel drivers.  Unfortunately,
the Linux HID driver claims a lot of devices including the one that I
would like to control from Java.

Does anyone have any advice as to how to forcefully claim a device
from Java or how to prevent the Linux HID driver from claiming one
particular HID device out of the many attached to my system?  I'm
ready to start hacking hid-core.c unless someone has a more elegant
solution.

Thanks in advance for any info.

--
Aaron




-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
_______________________________________________
javax-usb-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/javax-usb-devel



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
_______________________________________________
javax-usb-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/javax-usb-devel

Reply via email to