Serial Port

Ok , i've asked this question b4 and i don't think i was that clear on my line of questioning

I've spent the last 4 days researching on how to get around this problem with no luck.

I want to access a clients serial port through my server. My server brings up a browser application(Ajax) when the client connect to the server.

Digital signatures? If this is the answer...any good tutorials i can go check out except for javadocs that i've already read?

Thnx

Smilies all round

:) :) :) :)

Any suggestions, would be great.

[573 byte] By [monk3ya] at [2007-11-27 6:19:17]
# 1
Hi , The problem is you need to find a way to access the serial port http://java.sun.com/products/javacomm/ and provide permission to applet Hope this works Vijay
bhvijaya at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 2

Hi Vij

Thanx 4 the link, :)

The thing that i'm struggling with is accessing a clients serial port when they click on a button, on the browser.

I can already read from the RS232 device on my own computer, because i am the server and the client all in one, so i have access to my own ports.

The thing that i'm wondering is how can a grab access of the port from where the browser is been accessed from, a.k.a the client.

i know browsers have been built so this can't be accessed, but i was wondering if maybe RMI might help out in this situation or a digital signature(even though i don't know how to program a digital signiture, or RMI for that matter. I've jsut read alot about both but none give me the confirmation i need,:) ) and then somehow i can get the clients serial port.

All i really need is a "yes, it can be done using this technique, or this one..."

Eeesh, i really hope that there is a secure and easy way to do this, sigh, and lol.

Smilies all round

:) :) :) :)

monk3ya at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 3
There is absolutly no way that a server can access a clients serial port. It doesn't matter what you do.You can however move data collected on a client to a server. But that is two problems not one.1. Collect data in client2. Moved collected data to server.
jschella at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 4

Hi

Thanx for your reply jschell.

What i was thinking is maybe creating a java applet and somehow giving that applet rights to a serial com port.

Any links where i might find a tutorial on digital signatures apart from javadocs?

I've googled it as well and the links i've read , i've kinda understood but an example would be great. Or maybe i need to go RTFM again, lol.

Thanx for any1 that can help

Smilies all round

:) :) :) :)

monk3ya at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 5

> Hi

>

> Thanx for your reply jschell.

>

> What i was thinking is maybe creating a java applet

> and somehow giving that applet rights to a serial com

> port.

You have to run something on the client machine.

An applet would require special priviledges (like via signing) to access the serial port.

I suspect there will be complications as well with downloading the required dll.

jschella at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 6

Hi

Here is a link for anyone that is interested in signed applets, its a great step by step tutorial, very helpful

http://java.sun.com/developer/technicalArticles/Security/Signed/

And as far as the downloading of a DLL goes(which i'm guessing you're talking about a DLL file to talk to the RS232 device) thats not necessary for my app, my company has all these wonderful classes that let you connect to the device without the use of any external libraries, or better put....the device doesn't need any DLL files in order for it to work :)

So now its a matter of implementing it, i'll let you guys know if i run into any more problems

Thanx for all your help guys.

Smilies all round

:) :) :) :)

monk3ya at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 7

> And as far as the downloading of a DLL goes(which i'm

> guessing you're talking about a DLL file to talk to

> the RS232 device) thats not necessary for my app, my

> company has all these wonderful classes that let you

> connect to the device without the use of any external

> libraries, or better put....the device doesn't need

> any DLL files in order for it to work :)

That is impossible.

Accessing serial ports requires accessing OS specific APIs at a minimum. It might require some other exotic stuff as well. Excluding a custom VM that means that you must use JNI (even a custom Java API would still require shared libraries without a custom VM.)

What you are seeing is a library that hides the dll from you.

If your target machines have that already installed then you don't have to send the library via the link, but it doesn't mean the dll doesn't exist.

jschella at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...
# 8
That is the case, yesSmilies all round:) :) :) :)
monk3ya at 2007-7-12 17:33:44 > top of Java-index,Core,Core APIs...