通过互联网控制设备
我想使用互联网控制远程位置的设备。
我做了一些实验。我有一台通过 WIFI 连接的笔记本电脑和一台通过路由器连接的计算机。效果很好。现在,当我从连接到其他路由器的系统运行时,即使两个路由器都有互联网连接,它也无法工作。
原因之一可能是由于计算机数量较多,无法追踪IP。此处是否已实施 http://csharp.net-informations.com/communications /csharp-server-socket.htm
是否可以通过互联网控制设备?
其次,Sockets
和 Winsock
之间有什么区别?
I want to control devices to remote location using Internet.
I did some Experiments. I have one Laptop connected via WIFI and a computer connected via Router. it works fine. now when i run from system connected to other router it did not worked even both had internet connections.
one reason may be it cannot trace IP because there are many computers. Did implementation done here http://csharp.net-informations.com/communications/csharp-server-socket.htm
is it possible to control devices over the internet?
secondly what is difference b/w Sockets
and Winsock
?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
当您尝试使用 wifi 和路由器的系统时,我假设您位于同一网络上。现在您正在使用互联网,您应该使用路由器的公共 IP 地址,并将您正在使用的端口映射到您希望将数据路由到的特定计算机。如果您没有可用的静态 IP 地址,您可能应该考虑使用 DyDNS 和 OpenVPN 创建专用网络。
至于您关于 Winsock 与 Sockets 的问题,请查看这篇文章
编辑:查看这篇关于端口转发的文章
When you tried your system with wifi and the router I assume you were on the same network. Now you are using the internet you should be using the public IP addresses of your routers and map the port(s) you are using to the specific computers you want the data routed to. If you do not have static IP addresses available you probably should look into using something like DyDNS and OpenVPN to create a private network.
As far as your question about Winsock vs Sockets look at this article
Edit: Take a look at this article on port forwarding