I am needing to esbilish an OPC Connection with a cut machine that are located in a sub network inside a router. I have the Router IP but and Computer with OPC IP... How to connect it using the correct type Endpoint ??
When i have the directly connection i'm puting this one and it is working: End point URL: opc.tcp://10.148.174.101:56000
But i need to pass trough the router reaching the Ip inside the sub network, what the correct writing for the endpoint ?? opc.tcp://10.148.174.101???????
Just to example:
Router IP: 10.148.174.101
Computer with OPC IP: 192.168.100.101
Correct Endpoint "Writing": ????
There's no correct answer for all cases. Depends on the router. If there's no NAT involved, then the same URL is used in both cases, and your network infrastructure is expected to forward to the correct router for you.
If there is NAT involved, then you will need to point at the NAT router, at whatever port you configure as a pinhole, and you will have to make sure the OPC server you are reaching understands what is happening. (Or you override the OPC server's endpoints to fake it out.)
I gues i got your point @pturmel, the best way will be to enable the NAT and make it works. I will try for this way !! Thanks for the explanation !!
I'm not sure how you arrived at that. I disagree. The best way is to have your routers do their job and route to the target IP address and in return. Without NAT, bidirectionally.