How can I connect 1 server to another one?

Hello,

Scenario:

I have one PLC (Programmable Logic Controller) that is a client.

I wrote the server code, it works.

PLCClient <->PLCServer( 1 to 1 )

Now I have to implements my clients on PCs.

The PCClient sends commands to PLCServer and it answers back.

How can I do this kind of connection?

I though to wrote a PCServer

PCServer <> PCClients ( 1 to N )

if the PCClient sends a command to the PCServer, then, the PCServer has to forward the command to the PLC Server, who sends to PLCClient that answers back through the PCClient.

I don't know how to setup this kind of comunication, any ideas?

thank you really much.

I have to develop the following project:

( 1 Client with 1 server )

ClientPLC

ServerPLC

ServerPCL sends commands to ClientPLC that answers back.

( N Clients with 1 Server )

Server PC

Client PC

ClientPC sends commands to ServerPC that before sending back the answers,

communicate with the ServerPLC.

Use Case:

ClientPC sends command "AAA" -->

erverPC >"AAA">ServerPLC>"AAA">ClientPLC.

At this point the ClientPLC sends

"OK">ServerPLC>"OK">ServerPC>"OK"-->ClientPC

Is that clear? :-)

Could you give me some links or hits to solve this puzzle?

Maybe there is a better way to solve it than what I have done ;-)

thank you

[1472 byte] By [_sfla] at [2007-11-26 17:18:33]
# 1
http://java.sun.com/docs/books/tutorial/networking/sockets/clientServer.html
masijade.a at 2007-7-8 23:46:33 > top of Java-index,Archived Forums,Socket Programming...