?
Solved

Using Java to communicate to a USB device from browser

Posted on 2008-06-15
4
Medium Priority
?
1,014 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Accepted Solution

by:
Meritor earned 900 total points
ID: 21788616
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
ID: 21890808
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 600 total points
ID: 22018972
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
ID: 31478772
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

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Suggested Courses
Course of the Month8 days, 1 hour left to enroll

765 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