Luftballon пишет:
> Hallo @ all
>
> in the code below i have the problem that the method 
> getAttachedUsbDevices() returns an empty list. But it should return a 
> list of the internal UsbHubs that is never empty because my pc has 6 
> usb ports!?
>
> ------------------------------------------------------------------
> public static void showAttachedDevice(){
> try {
> UsbServices usbServices = UsbHostManager.getUsbServices();
> UsbHub usbRootHub = usbServices.getRootUsbHub();
> System.out.println(usbRootHub.getAttachedUsbDevices().size());
> } catch (SecurityException e) {
> e.printStackTrace();
> } catch (UsbException e) {
> e.printStackTrace();
> }
> }
>
> public static void main(String[] args) {
> showAttachedDevice();
> }
> ------------------------------------------------------------------
>
> Does someone see the problem
You must be root.

Use su or sudo for start application.

-- 
Sincerely yours,
Vitaliy Berdinskikh
xmpp:[EMAIL PROTECTED]


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
javax-usb-devel mailing list
javax-usb-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/javax-usb-devel

Reply via email to