如何在C#中将ip地址转换为comport? [英] How to convert ip address to comport in C#?

查看:93
本文介绍了如何在C#中将ip地址转换为comport?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我想访问每个IP地址作为comport以及如何通过ether-net将数据发送到rs 485并从rs485接收数据到以太网。



我的尝试:



i didn'对它有任何想法。

Hi,

I want to access each IP address as comport and how to send the data to rs 485 through ether-net and also receive data from rs485 to ether-net.

What I have tried:

i didn't have any idea about it.

推荐答案

我对它一无所知。



这可能是因为它不可能。

IP地址不是com端口,你无法通过互联网直接与RS485设备通信充当互联网设备并将信息双向传递到485通信链路的硬件设备。就硬件和信号类型而言,两者甚至没有轻微兼容。

要使用硬件设备来执行此操作,您需要查看特定的设备手册(或与之交谈)制造商的技术支持人员)。



如果您的PC中有485卡,您可以将其连接到互联网,并编写C#代码以在二,但IP地址与com端口无关!
"i didn't have any idea about it."

That's probably because it isn't possible.
IP addresses aren't com ports, and you can't communicate directly with an RS485 device via the internet without a hardware device which acts as an internet device and passes info bidirectionally to the 485 comms link. The two aren't even slightly compatible as far as hardware and signal types are concerned.
And to use a hardware device to do it, you would need to look at the specific device manual (or talk to the manufacturer's technical support people).

If you have a 485 card in you PC, you can connect that to the internet, and write C# code to transfer data between the two, but IP addresses have nothing to do with com ports!


这篇关于如何在C#中将ip地址转换为comport?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆