purejavahidapi icon indicating copy to clipboard operation
purejavahidapi copied to clipboard

RFE: device path: bus/addr/port

Open Andrei-Pozolotin opened this issue 6 years ago • 3 comments

please expose libusb/usb4java compatible device path: bus/addr/port

for example, see: https://github.com/usb4java/usb4java-javax/issues/10

Andrei-Pozolotin avatar Jun 05 '18 17:06 Andrei-Pozolotin

usb4java is based on libusb. Last time I checked libusb source code the device path was not available on all platforms. I'm not willing to add a feature that is not cross platform.

nyholku avatar Jun 06 '18 03:06 nyholku

you expose public String getDeviceId() https://github.com/nyholku/purejavahidapi/blob/master/src/purejavahidapi/HidDeviceInfo.java#L159

which looks like /dev/bus/usb/${bus}/${addr}

and is conceptually identical to libusb parameters ${bus}/${addr}

so essentially I am asking for unified platform-agnostic ${bus}/${addr} extract

Andrei-Pozolotin avatar Jun 06 '18 21:06 Andrei-Pozolotin

Yes, but the 'agnostic' is the problem, I do not see how to implement that.

nyholku avatar Jun 07 '18 03:06 nyholku