Klaus Gradinger <klaus.gradinger <at> gmail.com> writes:
 
> Hello, I've been running into the following Problem: I'm communicating using a
USB Handheld Barcode Scanner (USB HID Keyboard Device). Everything is fine, i've
opened the IN Endpoint using the UsbPipe and access it the following way: 
currentDui = new DefaultUsbIrp(buffer);  currentDui = new
DefaultUsbIrp(buffer);  currentDui.setAcceptShortPacket(true); 
usbScannerPipe.syncSubmit(currentDui);I receive the data i'm expecting and
everything works fine UNTIL i want to abort and cancel everything: 
usbScannerPipe.abortAllSubmissions();  usbScannerPipe.close();  usbScannerPipe =
null;  usbScannerInterface.release();  usbScannerInterface = null;The problem is
that syncSubmit immediately synchronizes using  "submitLock" (UsbPipeImp). After
that the whole thing just keeps blocking while waiting for data. When i call
abortAllSubmissions from another Thread, it too locks on "submitLock", waiting
for the submitSync method to release this lock. IF i scan another Barcode, the
syncSubmit method returns and everything is fine, otherwise it's a perfect
deadlock.What's the correct work-flow here? how can i cancel everything pending
and close the pipe and interface?i'm using Ubuntu 10.04, and java-usb
1.0.1Thanks in advanceKlaus Gradinger 
> 
> ------------------------------------------------------------------------------
> The Next 800 Companies to Lead America's Growth: New Video Whitepaper
> David G. Thomson, author of the best-selling book "Blueprint to a 
> Billion" shares his insights and actions to help propel your 
> business during the next growth cycle. Listen Now!
> http://p.sf.net/sfu/SAP-dev2dev
> 
> _______________________________________________
> javax-usb-devel mailing list
> javax-usb-devel <at> lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/javax-usb-devel
> 

Hello,

I am facing exactly the same problem. Are you able to resolve the problem you
mentioned. if yes please let me know the steps..

Many thanks

Shah






------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_jan
_______________________________________________
javax-usb-devel mailing list
javax-usb-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/javax-usb-devel

Reply via email to