You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using purejavahidapi to contact a HidDevice (a Ledger Nano S)
It works well,
I can PureJavaHidApi.enumerateDevices()
then PureJavaHidApi.openDevice(HidDeviceInfo)
then HidDevice.setOutputReport()
and I get a callback InputReportListener.onInputReport()
with the data I expect.
but when I make the HidDevice.close()
It shows an error message :
GetOverlappedResult failed with GetLastError()==995
if (GetLastError() == ERROR_DEVICE_NOT_CONNECTED)
break; // early exit if the device disappears
System.out.println("GetOverlappedResult failed with GetLastError()==" + GetLastError());
}`
All seems OK, but the error message is not normal...
Maybe I made a mistake in the call sequences...
Beside that, using a Logger like slf4j may helps to make the code more generic...
(By the way, thanks for the core functionality, it got me out of trouble.)
The text was updated successfully, but these errors were encountered:
if (GetLastError() == ERROR_DEVICE_NOT_CONNECTED)
break; // early exit if the device disappears
if(m_StopThread && GetLastError() == ERROR_OPERATION_ABORTED)
break;// on close
System.out.println("GetOverlappedResult failed with GetLastError()==" + GetLastError());
Hi,
I'm using purejavahidapi to contact a HidDevice (a Ledger Nano S)
It works well,
I can
PureJavaHidApi.enumerateDevices()
then
PureJavaHidApi.openDevice(HidDeviceInfo)
then
HidDevice.setOutputReport()
and I get a callback
InputReportListener.onInputReport()
with the data I expect.
but when I make the HidDevice.close()
It shows an error message :
from
purejavahidapi.windows.HidDevice.runReadOnBackground()
in:
`if (!GetOverlappedResult(m_Handle, m_InputReportOverlapped, m_InputReportBytesRead, true/* wait */)) {
}`
All seems OK, but the error message is not normal...
Maybe I made a mistake in the call sequences...
Beside that, using a Logger like slf4j may helps to make the code more generic...
(By the way, thanks for the core functionality, it got me out of trouble.)
The text was updated successfully, but these errors were encountered: