如何使用来自两个不同应用程序(桌面应用程序和移动应用程序)的单个串行端口 [英] How do I use a single serial port from two different applications (desktop app and mobile app)

查看:118
本文介绍了如何使用来自两个不同应用程序(桌面应用程序和移动应用程序)的单个串行端口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请帮我解决这个问题。我有两个应用程序,桌面应用程序和移动应用程序(移动终端在Windows CE中运行,并通过串口连接到PC)。

桌面应用程序向移动应用程序发送请求和移动应用程序进程请求并向pc(桌面应用程序)发送响应。我的老板想要达到的是,电脑会向终端发送请求,并等待终端的响应。终端总是等待来自PC的请求,然后在处理请求时向pc发送响应,PC和终端使用相同的端口..我为我糟糕的英语道歉。



问题:以上是否可行?

Please help me with this. I have two applications, desktop app and mobile app(the mobile terminal runs in windows CE and is connected to pc via serial port).
the desktop application sends a request to mobile app and the mobile apps process the request and send a response to pc (desktop app). what my boss want to attain is, the pc will send a request to terminal and will wait for a response from the terminal. the terminal always wait for a request from the pc then send a response to pc upon processing the request, the pc and terminal uses the same port.. I apologize for my bad English.

question: is the above doable?

推荐答案

(如果我找到你)是的,它是绝对可行的。它只是一个简单的客户端(PC)/服务器(移动设备)架构,使用串口进行通信。

(If I got you) Yes, it is doable, definitely. It is just a simple client (PC) / server (mobile device) architecture using the serial port for communication.
  • "simple client server architecture C#"[^].
  • "Serial communication in C#"[^].


在设备管理器上卸载并重新安装COM端口。
Uninstall and reinstall COM Port on the device manager.


这篇关于如何使用来自两个不同应用程序(桌面应用程序和移动应用程序)的单个串行端口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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