Solved

Using Java to communicate to a USB device from browser

Posted on 2008-06-15
4
998 Views
Last Modified: 2013-12-29
Hi Experts,
We have a ASPNET web application and now we have a new request: the client wants to communicate with their USB device using our application. They plug the device into their PCs, open a page of our web application and the page will communicate with the device to get some input. Of course the device must already have proper driver. Comunication here means reading some input from the device.

Someone said that we can use JAVA to do this. So I'd like to get more information about it. Can someone give me a guide or a link which tells me how to do?
Thank you for reading.
0
Comment
Question by:thuannguy
  • 2
4 Comments
 
LVL 4

Accepted Solution

by:
Meritor earned 300 total points
Comment Utility
Accessing USB using java is possible:
Please read through the following link:
http://www-128.ibm.com/developerworks/library/j-usb.html
and you can write applet which will run in browser.
for the detail please visit:
http://java.sun.com/applets/
http://www.dgp.utoronto.ca/~mjmcguff/learn/java/

Feel free to revert back in case of any doubts
0
 
LVL 6

Author Comment

by:thuannguy
Comment Utility
Hi,
Sorry for my late response. I have learned the links you gave me. I found out that the javax.usb library only works on Linux. It is not good for me :(
However, it seems that the library aims to help us access usb devices directly regardingless drivers, doesn't it? What about if a driver is ready? Is it easier to access it?
Thank for you help :)
0
 
LVL 3

Assisted Solution

by:softwarepearls_com
softwarepearls_com earned 200 total points
Comment Utility
Whether via an applet, or a JavaWebStart application, the simplest approach is to reach into the host OS' filesystem. For example on UNIX/Linux/OSX hosts, you would go to the mount points of drives, and simply locate the mounted USB drive there. For Windows, you'd need to deal with its drive letters, etc..

Personally, I would try to avoid USB-specific Java libraries at all costs, and try to create a solution based on the above approach. Sticking to standard JRE APIs is sticking to tried-and-tested, supported classes.
0
 
LVL 6

Author Closing Comment

by:thuannguy
Comment Utility
We are waiting for more input from our clients. Although your posts don't give me what I was looking for, which might not really exist, they are still good hints for me. Thank you all :)
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now