简体   繁体   English

node.js和串行端口

[英]node.js and Serial ports

I'm trying to build a simple web app that reads the clients' serial port that is connected to a barcode scanner. 我正在尝试构建一个简单的Web应用程序,该应用程序读取连接到条形码扫描仪的客户端的串行端口。 I have done this using ActiveX but it only works on IE browsers, i have heard that I can now do this using node.js and serial-node. 我已经使用ActiveX做到了这一点,但是它只能在IE浏览器上运行,听说现在我可以使用node.js和serial-node来做到这一点。 Can someone tell me if this is even possible using these two technologies? 有人可以告诉我使用这两种技术是否有可能? Also if anyone can direct me to a working tutorial on how to do this. 另外,如果有人可以引导我阅读有关如何执行此操作的教程。 Thanks! 谢谢!

You can't read the serial port of the web app's client's computer using serial-node, no. 您无法使用串行节点读取网络应用程序客户端计算机的串行端口。 Node.js and serial-node run server side, they do not have direct access to the web clients' hardware. Node.js和串行节点运行在服务器端,它们无法直接访问Web客户端的硬件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM