如何使用rxtx测试Windows中的串口通信?
我正在使用 RXTX 和 Java 连接到串行端口。但现在我要测试一下通讯是否正常?如何做到这一点。我需要调制解调器吗?或者我们可以在没有调制解调器的情况下在本地进行任何测试吗?
这是我想测试的程序 http://rxtx.qbang.org/wiki/index .php/Two_way_communcation_with_the_serial_port
I am using RXTX with Java to connect to serial port. But now i have to test whether the communication is working properly or not? How to do this. Do i need modem or can we test any way in my local with out modem.
this is the program i want to test http://rxtx.qbang.org/wiki/index.php/Two_way_communcation_with_the_serial_port
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在 Windows 上,您可以使用名为 com0com 的“空调制解调器模拟器”。这会将 2 个虚拟 com 端口注册到操作系统上,这些端口将相互通信。
因此,您需要“两次”连接它,串行连接的每一端各一次。
com0com 还有名为 com2tcp 和 com2tcp 的变体。 hub4com,如果这更适合您。
华泰
On Windows you can use a 'null modem emulator' called com0com. This registers 2 dummy com ports onto the OS, which will communicate between each other.
So, you'd need to connect to it 'twice', one for each end of the serial connection.
com0com also has variants called com2tcp & hub4com, if that's more appropriate for you.
HTH
呃,不,你不需要调制解调器(?)。您可以使用零调制解调器串行电缆进行从一个 COM 端口到另一个 COM 端口的环回测试。您可以在一台 PC 或两台不同的计算机上执行此操作。如果没有足够的 COM 端口,请使用 USB 转串口转换器。
Uh, no you don't need a modem(?). You can use a null modem serial cable to do loopback testing from one COM port to another. You can do this on a single PC or two different computers. If you don't have enough COM ports, use a USB to serial converter.