0

我正在使用 johnny-5,问题是如何关闭已经打开的串口?问题是当我重新部署红色节点中的代码时,它会引发错误,如下所示:

    10 Feb 10:38:33 - [info] Stopping flows
    10 Feb 10:38:33 - [info] Stopped flows
    10 Feb 10:38:33 - [info] Starting flows
    1518239313152 Connected COM6
    10 Feb 10:38:33 - [info] Started flows
    1518239313157 Error Opening COM6: Access denied
    (node:12788) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Unhandled "error" event. ([object Object])
    (node:12788) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
    1518239323160 Device or Firmware Error A timeout occurred while connecting to the Board.
4

1 回答 1

0

解决方法可能是将 Deploy 设置为“Modified Nodes Only”,这样 Node-RED 只会在 johnny-5 已更改时重新启动它。

您必须向 johnny-5 节点 ( node-red-contrib-gpio ?) 的开发人员提出问题才能正确修复此问题。

于 2018-02-10T08:49:18.053 回答